org.compass.needle.gigaspaces.store
Class GigaSpaceIndexInput

java.lang.Object
  extended by org.apache.lucene.store.IndexInput
      extended by org.compass.needle.gigaspaces.store.GigaSpaceIndexInput
All Implemented Interfaces:
Cloneable

 class GigaSpaceIndexInput
extends IndexInput

An index input using the FileEntry as the "header" information and load buckets as needed.

Author:
kimchy

Constructor Summary
GigaSpaceIndexInput(GigaSpaceDirectory dir, FileEntry fileEntry)
           
 
Method Summary
 Object clone()
           
 void close()
           
 long getFilePointer()
          Returns the current position in this file, where the next read will occur.
 long length()
          The number of bytes in the file.
 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.
 void seek(long pos)
          Sets current position in this file, where the next read will occur.
 
Methods inherited from class org.apache.lucene.store.IndexInput
readBytes, readChars, readInt, readLong, readString, readVInt, readVLong, setModifiedUTF8StringsMode, skipChars
 
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

GigaSpaceIndexInput

public GigaSpaceIndexInput(GigaSpaceDirectory dir,
                           FileEntry fileEntry)
Method Detail

close

public void close()
           throws IOException
Specified by:
close in class IndexInput
Throws:
IOException

getFilePointer

public long getFilePointer()
Returns the current position in this file, where the next read will occur.

Specified by:
getFilePointer in class IndexInput
See Also:
seek(long)

length

public long length()
The number of bytes in the file.

Specified by:
length in class IndexInput

readByte

public byte readByte()
              throws IOException
Reads and returns a single byte.

Specified by:
readByte in class IndexInput
Throws:
IOException
See Also:
IndexOutput.writeByte(byte)

readBytes

public void readBytes(byte[] b,
                      int offset,
                      int len)
               throws IOException
Reads a specified number of bytes into an array at the specified offset.

Specified by:
readBytes in class IndexInput
Parameters:
b - the array to read bytes into
offset - the offset in the array to start storing bytes
len - the number of bytes to read
Throws:
IOException
See Also:
IndexOutput.writeBytes(byte[],int)

seek

public void seek(long pos)
          throws IOException
Sets current position in this file, where the next read will occur.

Specified by:
seek in class IndexInput
Throws:
IOException
See Also:
getFilePointer()

clone

public Object clone()
Overrides:
clone in class IndexInput


Copyright (c) 2004-2009 The Compass Project.