Package org.apache.lucene.index
Class BinaryDocValuesFieldUpdates
- java.lang.Object
-
- org.apache.lucene.index.DocValuesFieldUpdates
-
- org.apache.lucene.index.BinaryDocValuesFieldUpdates
-
- All Implemented Interfaces:
Accountable
final class BinaryDocValuesFieldUpdates extends DocValuesFieldUpdates
ADocValuesFieldUpdateswhich holds updates of documents, of a singleBinaryDocValuesField.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description (package private) static classBinaryDocValuesFieldUpdates.Iterator-
Nested classes/interfaces inherited from class org.apache.lucene.index.DocValuesFieldUpdates
DocValuesFieldUpdates.AbstractIterator, DocValuesFieldUpdates.SingleValueDocValuesFieldUpdates
-
-
Field Summary
Fields Modifier and Type Field Description private PagedGrowableWriterlengthsprivate PagedGrowableWriteroffsetsprivate BytesRefBuildervalues-
Fields inherited from class org.apache.lucene.index.DocValuesFieldUpdates
delGen, docs, field, maxDoc, PAGE_SIZE, size, type
-
Fields inherited from interface org.apache.lucene.util.Accountable
NULL_ACCOUNTABLE
-
-
Constructor Summary
Constructors Constructor Description BinaryDocValuesFieldUpdates(long delGen, java.lang.String field, int maxDoc)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidadd(int doc, long value)voidadd(int docId, DocValuesFieldUpdates.Iterator iterator)Adds the value for the given docID.voidadd(int doc, BytesRef value)protected voidgrow(int size)BinaryDocValuesFieldUpdates.Iteratoriterator()Returns anDocValuesFieldUpdates.Iteratorover the updated documents and their values.longramBytesUsed()Return the memory usage of this object in bytes.protected voidresize(int size)protected voidswap(int i, int j)-
Methods inherited from class org.apache.lucene.index.DocValuesFieldUpdates
add, any, ensureFinished, finish, getFinished, mergedIterator, reset, size
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface org.apache.lucene.util.Accountable
getChildResources
-
-
-
-
Field Detail
-
offsets
private PagedGrowableWriter offsets
-
lengths
private PagedGrowableWriter lengths
-
values
private BytesRefBuilder values
-
-
Method Detail
-
add
public void add(int doc, long value)- Specified by:
addin classDocValuesFieldUpdates
-
add
public void add(int docId, DocValuesFieldUpdates.Iterator iterator)Description copied from class:DocValuesFieldUpdatesAdds the value for the given docID. This method prevents conditional calls toDocValuesFieldUpdates.Iterator.longValue()orDocValuesFieldUpdates.Iterator.binaryValue()since the implementation knows if it's a long value iterator or binary value- Specified by:
addin classDocValuesFieldUpdates
-
add
public void add(int doc, BytesRef value)- Specified by:
addin classDocValuesFieldUpdates
-
swap
protected void swap(int i, int j)- Overrides:
swapin classDocValuesFieldUpdates
-
grow
protected void grow(int size)
- Overrides:
growin classDocValuesFieldUpdates
-
resize
protected void resize(int size)
- Overrides:
resizein classDocValuesFieldUpdates
-
iterator
public BinaryDocValuesFieldUpdates.Iterator iterator()
Description copied from class:DocValuesFieldUpdatesReturns anDocValuesFieldUpdates.Iteratorover the updated documents and their values.- Specified by:
iteratorin classDocValuesFieldUpdates
-
ramBytesUsed
public long ramBytesUsed()
Description copied from interface:AccountableReturn the memory usage of this object in bytes. Negative values are illegal.- Specified by:
ramBytesUsedin interfaceAccountable- Overrides:
ramBytesUsedin classDocValuesFieldUpdates
-
-