com.timeindexing.io
Interface IndexInteractor

All Known Subinterfaces:
IndexFileInteractor
All Known Implementing Classes:
AbstractFileIO, AbstractIndexIO, ExternalIndexIO, InlineIndexIO, ShadowIndexIO

public interface IndexInteractor

An interface for objects that interact with indexes.


Method Summary
 long addItem(ManagedIndexItem item)
          Add an IndexItem to the index.
 StoredIndex getIndex()
          Get the index which this is doing I/O for.
 ManagedIndexItem getItem(Position position, boolean withData)
          Get the item
 

Method Detail

getIndex

public StoredIndex getIndex()
Get the index which this is doing I/O for.


getItem

public ManagedIndexItem getItem(Position position,
                                boolean withData)
                         throws java.io.IOException
Get the item

Parameters:
position - the position of the index item to get
withData - read the data for this IndexItem if withData is true, the data needs to be read at a later time, otherwise
Throws:
java.io.IOException

addItem

public long addItem(ManagedIndexItem item)
             throws java.io.IOException
Add an IndexItem to the index.

Throws:
java.io.IOException