org.apache.lucene.codecs.intblock
Class FixedIntBlockIndexInput

java.lang.Object
  extended by org.apache.lucene.codecs.sep.IntIndexInput
      extended by org.apache.lucene.codecs.intblock.FixedIntBlockIndexInput
All Implemented Interfaces:
Closeable

public abstract class FixedIntBlockIndexInput
extends IntIndexInput

Abstract base class that reads fixed-size blocks of ints from an IndexInput. While this is a simple approach, a more performant approach would directly create an impl of IntIndexInput inside Directory. Wrapping a generic IndexInput will likely cost performance.

WARNING: This API is experimental and might change in incompatible ways in the next release.

Nested Class Summary
static interface FixedIntBlockIndexInput.BlockReader
          Interface for fixed-size block decoders.
 
Field Summary
protected  int blockSize
           
 
Constructor Summary
FixedIntBlockIndexInput(IndexInput in)
           
 
Method Summary
 void close()
           
protected abstract  FixedIntBlockIndexInput.BlockReader getBlockReader(IndexInput in, int[] buffer)
           
 IntIndexInput.Index index()
           
 IntIndexInput.Reader reader()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

blockSize

protected final int blockSize
Constructor Detail

FixedIntBlockIndexInput

public FixedIntBlockIndexInput(IndexInput in)
                        throws IOException
Throws:
IOException
Method Detail

reader

public IntIndexInput.Reader reader()
                            throws IOException
Specified by:
reader in class IntIndexInput
Throws:
IOException

close

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

index

public IntIndexInput.Index index()
Specified by:
index in class IntIndexInput

getBlockReader

protected abstract FixedIntBlockIndexInput.BlockReader getBlockReader(IndexInput in,
                                                                      int[] buffer)
                                                               throws IOException
Throws:
IOException


Copyright © 2000-2013 Apache Software Foundation. All Rights Reserved.