clean up getValueCount impl

git-svn-id: https://svn.apache.org/repos/asf/lucene/dev/branches/lucene4547@1430861 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
Robert Muir 2013-01-09 13:52:51 +00:00
parent a1ff333b26
commit 42113ec733
1 changed files with 2 additions and 3 deletions

View File

@ -193,8 +193,7 @@ class Lucene41SimpleDocValuesProducer extends SimpleDVProducer {
@Override
public SortedDocValues getSorted(FieldInfo field) throws IOException {
// nocommit: ugly hack to nuke size()
final BinaryEntry binaryEntry = binaries.get(field.number);
final int valueCount = binaries.get(field.number).count;
final BinaryDocValues binary = getBinary(field);
final NumericDocValues ordinals = getNumeric(field, ords.get(field.number));
return new SortedDocValues() {
@ -211,7 +210,7 @@ class Lucene41SimpleDocValuesProducer extends SimpleDVProducer {
@Override
public int getValueCount() {
return binaryEntry.count;
return valueCount;
}
};
}