com.timeindexing.index
Interface IndexView

All Superinterfaces:
Index, IndexHeader
All Known Implementing Classes:
TimeIndex

public interface IndexView
extends Index

An index view has the moethods needed for view on an Index.


Method Summary
 IndexView backward()
          Sets the current navigation position into the IndexView to be one backward.
 IndexView exchange()
          Exchanges the mark into the IndexView, with the current navigation position.
 IndexView forward()
          Sets the current navigation position into the IndexView to be one forward.
 Position getEndPosition()
          Get the end position, in the index, of this IndexView.
 IndexItem getItem()
          Get the Index Item from the Index at position position().
 IndexItem getItemAtMark()
          Get the Index Item from the Index at position mark().
 IndexView getSelectionIndexView()
          Return the IndexView used to get a selection.
 Interval getSelectionInterval()
          Return the Interval used to get a selection.
 Position getStartPosition()
          Get the start position, in the index, of this IndexView.
 boolean isSelection()
          Is the IndexView a selection.
 IndexView mark()
          Sets the mark into the IndexView, using the current navigation position as the mark value.
 Position position()
          Gets the current navigation position into the IndexView.
 IndexView position(long n)
          Sets the current navigation position into the IndexView.
 IndexView position(Position p)
          Sets the current navigation position into the IndexView specified as a Position.
 IndexView position(Timestamp t, IndexTimestampSelector selector, Lifetime lifetime)
          Sets the current navigation position into the IndexView.
 Interval region()
          What is the region covered by position and mark.
 IndexView select(Interval interval, IndexTimestampSelector sel, Overlap overlap, Lifetime lifetime)
          Select an Interval and return an IndexView which is a view on the underlying Index.
 
Methods inherited from interface com.timeindexing.index.Index
activate, addDataType, addItem, addItem, addReference, addReference, asView, close, commit, contains, getAnnotationStyle, getDataType, getItem, getItem, getItem, getItemSize, getLastAccessTime, hasAnnotations, hasDataType, isActivated, isChanged, isClosed, isWriteLocked, iterator, locate, locate, setAutoCommit, setCachePolicy, terminate, updateDescription
 
Methods inherited from interface com.timeindexing.index.IndexHeader
getDataPathName, getDataSize, getDescription, getEndTime, getFirstDataTime, getFirstTime, getID, getIndexDataType, getIndexPathName, getIndexType, getLastDataTime, getLastTime, getLength, getName, getStartTime, getURI, isFixedSizeData, isInTimeOrder, isReadOnly, isTerminated
 

Method Detail

select

public IndexView select(Interval interval,
                        IndexTimestampSelector sel,
                        Overlap overlap,
                        Lifetime lifetime)
Select an Interval and return an IndexView which is a view on the underlying Index.


getSelectionInterval

public Interval getSelectionInterval()
Return the Interval used to get a selection.

Returns:
null if the view is not a selection.

getSelectionIndexView

public IndexView getSelectionIndexView()
Return the IndexView used to get a selection.

Returns:
null if the view is not a selection.

isSelection

public boolean isSelection()
Is the IndexView a selection.


position

public Position position()
Gets the current navigation position into the IndexView.


position

public IndexView position(Position p)
Sets the current navigation position into the IndexView specified as a Position.


position

public IndexView position(long n)
Sets the current navigation position into the IndexView. specified as a long.


position

public IndexView position(Timestamp t,
                          IndexTimestampSelector selector,
                          Lifetime lifetime)
Sets the current navigation position into the IndexView. specified as a Timestamp.


getStartPosition

public Position getStartPosition()
Get the start position, in the index, of this IndexView.


getEndPosition

public Position getEndPosition()
Get the end position, in the index, of this IndexView.


mark

public IndexView mark()
Sets the mark into the IndexView, using the current navigation position as the mark value.


forward

public IndexView forward()
Sets the current navigation position into the IndexView to be one forward.


backward

public IndexView backward()
Sets the current navigation position into the IndexView to be one backward.


getItem

public IndexItem getItem()
                  throws GetItemException
Get the Index Item from the Index at position position().

Throws:
GetItemException

getItemAtMark

public IndexItem getItemAtMark()
                        throws GetItemException
Get the Index Item from the Index at position mark().

Throws:
GetItemException

region

public Interval region()
What is the region covered by position and mark. Returned value is an Interval.


exchange

public IndexView exchange()
Exchanges the mark into the IndexView, with the current navigation position.