Class MemoryIndex.SlicedIntBlockPool

java.lang.Object
org.apache.lucene.util.IntBlockPool
org.apache.lucene.index.memory.MemoryIndex.SlicedIntBlockPool
Enclosing class:
MemoryIndex

static class MemoryIndex.SlicedIntBlockPool extends IntBlockPool
  • Field Details

    • NEXT_LEVEL_ARRAY

      private static final int[] NEXT_LEVEL_ARRAY
      An array holding the offset into the LEVEL_SIZE_ARRAY to quickly navigate to the next slice level.
    • LEVEL_SIZE_ARRAY

      private static final int[] LEVEL_SIZE_ARRAY
      An array holding the level sizes for int slices.
    • FIRST_LEVEL_SIZE

      private static final int FIRST_LEVEL_SIZE
      The first level size for new slices
  • Constructor Details

  • Method Details

    • assertSliceBuffer

      private static boolean assertSliceBuffer(int[] buffer)
      For slices, buffers must be filled with zeros, so that we can find a slice's end based on a non-zero final value.
    • newSlice

      private int newSlice(int size)
      Creates a new int slice with the given starting size and returns the slices offset in the pool.
      See Also:
    • allocSlice

      private int allocSlice(int[] slice, int sliceOffset)
      Allocates a new slice from the given offset