|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectcom.timeindexing.index.DefaultIndexHeader
com.timeindexing.io.IndexDecoder
com.timeindexing.io.IndexHeaderIO
An Index Header IO object. It represents the file version of an index header in core.
| Constructor Summary | |
IndexHeaderIO(IndexFileInteractor indexInteractor)
Create a IndexHeaderIO. |
|
| Method Summary | |
long |
close()
Operation on close |
protected java.nio.ByteBuffer |
convertOptions()
Convert the options to their file format. |
boolean |
create(java.lang.String filename)
Create an index header. |
boolean |
create(java.lang.String filename,
java.util.Properties options)
Create an index header. |
long |
flush()
Flush the current values to the header file. |
java.nio.channels.FileLock |
getWriteLock()
Get a write-lock on this index. |
boolean |
isWriteLocked()
Has the Index been write-locked. |
boolean |
open(java.lang.String filename)
Open an index header. |
protected int |
processDataPath(HeaderOptionProcess what,
HeaderOption anOption,
java.nio.ByteBuffer optionBuffer)
A data path name. |
protected int |
processDataType(HeaderOptionProcess what,
HeaderOption anOption,
java.nio.ByteBuffer optionBuffer)
A data type. |
protected int |
processDescription(HeaderOptionProcess what,
HeaderOption anOption,
java.nio.ByteBuffer optionBuffer)
A description. |
protected int |
processIndexPath(HeaderOptionProcess what,
HeaderOption anOption,
java.nio.ByteBuffer optionBuffer)
An index path name. |
protected int |
processIsInTimeOrder(HeaderOptionProcess what,
HeaderOption anOption,
java.nio.ByteBuffer optionBuffer)
Is the index in time order |
protected int |
processReferenceMapping(HeaderOptionProcess what,
HeaderOption anOption,
java.nio.ByteBuffer optionBuffer)
The referenced indexes mapping |
boolean |
releaseWriteLock()
Release a FileLock. |
long |
write()
Write the contents of the header file out It assumes the header file is alreayd open for writing. |
| Methods inherited from class com.timeindexing.io.IndexDecoder |
getHeaderPathName, isOpen, open, processDataPath, processDataType, processDescription, processIndexPath, processIsInTimeOrder, processReferenceMapping, read |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Methods inherited from interface com.timeindexing.io.IndexHeaderReader |
isOpen, read |
| Methods inherited from interface com.timeindexing.io.IndexHeaderWriter |
isOpen |
| 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 |
| Methods inherited from interface com.timeindexing.index.ManagedIndexHeader |
addIndexURI, getAllOptions, getIndexURI, getOption, hasIndexURI, hasOption, listOptions, notInTimeOrder, setDataPathName, setDataSize, setDescription, setEndTime, setFirstDataTime, setFirstOffset, setFirstTime, setID, setIndexDataType, setIndexPathName, setIndexType, setItemSize, setLastDataTime, setLastOffset, setLastTime, setLength, setName, setOption, setOptions, setReadOnly, setStartTime, setTerminated, setURI, syncHeader |
| Methods inherited from interface com.timeindexing.index.ExtendedIndexHeader |
addDataType, getAnnotationStyle, getDataSize, getDataType, getFirstOffset, getItemSize, getLastOffset, hasAnnotations, hasDataType |
| Constructor Detail |
public IndexHeaderIO(IndexFileInteractor indexInteractor)
| Method Detail |
public boolean open(java.lang.String filename)
throws java.io.IOException
open in interface IndexHeaderReaderopen in class IndexDecoderjava.io.IOException
public boolean create(java.lang.String filename)
throws java.io.IOException
create in interface IndexHeaderWriterjava.io.IOException
public boolean create(java.lang.String filename,
java.util.Properties options)
throws java.io.IOException
create in interface IndexHeaderWriterjava.io.IOException
public long flush()
throws java.io.IOException
flush in interface IndexHeaderWriterjava.io.IOExceptionpublic java.nio.channels.FileLock getWriteLock()
public boolean releaseWriteLock()
public boolean isWriteLocked()
public long close()
throws java.io.IOException
close in interface IndexHeaderReaderclose in class IndexDecoderjava.io.IOException
public long write()
throws java.io.IOException
write in interface IndexHeaderWriterjava.io.IOExceptionprotected java.nio.ByteBuffer convertOptions()
protected int processDescription(HeaderOptionProcess what,
HeaderOption anOption,
java.nio.ByteBuffer optionBuffer)
protected int processIndexPath(HeaderOptionProcess what,
HeaderOption anOption,
java.nio.ByteBuffer optionBuffer)
protected int processDataPath(HeaderOptionProcess what,
HeaderOption anOption,
java.nio.ByteBuffer optionBuffer)
protected int processDataType(HeaderOptionProcess what,
HeaderOption anOption,
java.nio.ByteBuffer optionBuffer)
protected int processIsInTimeOrder(HeaderOptionProcess what,
HeaderOption anOption,
java.nio.ByteBuffer optionBuffer)
protected int processReferenceMapping(HeaderOptionProcess what,
HeaderOption anOption,
java.nio.ByteBuffer optionBuffer)
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||