Package org.apache.lucene.util
Class BytesRefHash.BytesStartArray
- java.lang.Object
-
- org.apache.lucene.util.BytesRefHash.BytesStartArray
-
- Direct Known Subclasses:
BytesRefHash.DirectBytesStartArray
- Enclosing class:
- BytesRefHash
public abstract static class BytesRefHash.BytesStartArray extends Object
Manages allocation of the per-term addresses.
-
-
Constructor Summary
Constructors Constructor Description BytesStartArray()
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description abstract CounterbytesUsed()ACounterreference holding the number of bytes used by thisBytesRefHash.BytesStartArray.abstract int[]clear()clears theBytesRefHash.BytesStartArrayand returns the cleared instance.abstract int[]grow()Grows theBytesRefHash.BytesStartArrayabstract int[]init()Initializes the BytesStartArray.
-
-
-
Method Detail
-
init
public abstract int[] init()
Initializes the BytesStartArray. This call will allocate memory- Returns:
- the initialized bytes start array
-
grow
public abstract int[] grow()
Grows theBytesRefHash.BytesStartArray- Returns:
- the grown array
-
clear
public abstract int[] clear()
clears theBytesRefHash.BytesStartArrayand returns the cleared instance.- Returns:
- the cleared instance, this might be
null
-
bytesUsed
public abstract Counter bytesUsed()
ACounterreference holding the number of bytes used by thisBytesRefHash.BytesStartArray. TheBytesRefHashuses this reference to track it memory usage- Returns:
- a
AtomicLongreference holding the number of bytes used by thisBytesRefHash.BytesStartArray.
-
-