it.unimi.di.mg4j.index
Class QuasiSuccinctIndexWriter.Accumulator

java.lang.Object
  extended by it.unimi.di.mg4j.index.QuasiSuccinctIndexWriter.Accumulator
All Implemented Interfaces:
Closeable
Enclosing class:
QuasiSuccinctIndexWriter

protected static final class QuasiSuccinctIndexWriter.Accumulator
extends Object
implements Closeable


Field Summary
 long bitsForLowerBits
          The number of bits used for the lower-bits array.
 long bitsForPointers
          The number of bits used for forward/skip pointers.
 long bitsForUpperBits
          The number of bits used for the upper-bits array.
 
Constructor Summary
QuasiSuccinctIndexWriter.Accumulator(int bufferSize, int log2Quantum)
           
 
Method Summary
 void add(long x)
           
 void close()
           
 long dump(QuasiSuccinctIndexWriter.LongWordOutputBitStream lwobs)
           
 void init(long length, long upperBound, boolean strict, boolean indexZeroes, int log2Quantum)
           
 int lowerBits()
           
 long numberOfPointers()
           
 int pointerSize()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

bitsForUpperBits

public long bitsForUpperBits
The number of bits used for the upper-bits array.


bitsForLowerBits

public long bitsForLowerBits
The number of bits used for the lower-bits array.


bitsForPointers

public long bitsForPointers
The number of bits used for forward/skip pointers.

Constructor Detail

QuasiSuccinctIndexWriter.Accumulator

public QuasiSuccinctIndexWriter.Accumulator(int bufferSize,
                                            int log2Quantum)
                                     throws IOException
Throws:
IOException
Method Detail

lowerBits

public int lowerBits()

pointerSize

public int pointerSize()

numberOfPointers

public long numberOfPointers()

init

public void init(long length,
                 long upperBound,
                 boolean strict,
                 boolean indexZeroes,
                 int log2Quantum)

add

public void add(long x)
         throws IOException
Throws:
IOException

dump

public long dump(QuasiSuccinctIndexWriter.LongWordOutputBitStream lwobs)
          throws IOException
Throws:
IOException

close

public void close()
           throws IOException
Specified by:
close in interface Closeable
Throws:
IOException