|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.apache.lucene.store.IndexInput
org.apache.lucene.store.BufferedIndexInput
public abstract class BufferedIndexInput
Base implementation class for buffered IndexInput.
| Field Summary | |
|---|---|
static int |
BUFFER_SIZE
Default buffer size |
| Constructor Summary | |
|---|---|
BufferedIndexInput()
|
|
BufferedIndexInput(int bufferSize)
Inits BufferedIndexInput with a specific bufferSize |
|
| Method Summary | |
|---|---|
java.lang.Object |
clone()
Returns a clone of this stream. |
int |
getBufferSize()
Returns buffer size. |
long |
getFilePointer()
Returns the current position in this file, where the next read will occur. |
byte |
readByte()
Reads and returns a single byte. |
void |
readBytes(byte[] b,
int offset,
int len)
Reads a specified number of bytes into an array at the specified offset. |
protected abstract void |
readInternal(byte[] b,
int offset,
int length)
Expert: implements buffer refill. |
void |
seek(long pos)
Sets current position in this file, where the next read will occur. |
protected abstract void |
seekInternal(long pos)
Expert: implements seek. |
void |
setBufferSize(int newSize)
Change the buffer size used by this IndexInput |
| Methods inherited from class org.apache.lucene.store.IndexInput |
|---|
close, length, readChars, readInt, readLong, readString, readVInt, readVLong, skipChars |
| Methods inherited from class java.lang.Object |
|---|
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
public static final int BUFFER_SIZE
| Constructor Detail |
|---|
public BufferedIndexInput()
public BufferedIndexInput(int bufferSize)
| Method Detail |
|---|
public byte readByte()
throws java.io.IOException
IndexInput
readByte in class IndexInputjava.io.IOExceptionIndexOutput.writeByte(byte)public void setBufferSize(int newSize)
public int getBufferSize()
public void readBytes(byte[] b,
int offset,
int len)
throws java.io.IOException
IndexInput
readBytes in class IndexInputb - the array to read bytes intooffset - the offset in the array to start storing byteslen - the number of bytes to read
java.io.IOExceptionIndexOutput.writeBytes(byte[],int)
protected abstract void readInternal(byte[] b,
int offset,
int length)
throws java.io.IOException
b - the array to read bytes intooffset - the offset in the array to start storing byteslength - the number of bytes to read
java.io.IOExceptionpublic long getFilePointer()
IndexInput
getFilePointer in class IndexInputIndexInput.seek(long)
public void seek(long pos)
throws java.io.IOException
IndexInput
seek in class IndexInputjava.io.IOExceptionIndexInput.getFilePointer()
protected abstract void seekInternal(long pos)
throws java.io.IOException
readInternal(byte[],int,int) will occur.
java.io.IOExceptionreadInternal(byte[],int,int)public java.lang.Object clone()
IndexInputClones of a stream access the same data, and are positioned at the same point as the stream they were cloned from.
Expert: Subclasses must ensure that clones may be positioned at different points in the input from each other and from the stream they were cloned from.
clone in class IndexInput
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||