|
Xindice API | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--org.apache.xindice.core.filer.Paged | +--org.apache.xindice.core.filer.BTree | +--org.apache.xindice.core.filer.BTreeFiler
BTreeFiler is a Filer implementation based on the BTree class.
Inner classes inherited from class org.apache.xindice.core.filer.BTree |
BTree.BTreeRootInfo |
Inner classes inherited from class org.apache.xindice.core.filer.Paged |
Paged.FileHeader, Paged.Page, Paged.PageHeader |
Constructor Summary | |
BTreeFiler()
|
Method Summary | |
boolean |
create()
create creates a new DBObject and any associated resources for the new DBObject, such as disk files, etc. |
Paged.FileHeader |
createFileHeader()
createFileHeader must be implemented by a Paged implementation in order to create an appropriate subclass instance of a FileHeader. |
Paged.FileHeader |
createFileHeader(boolean read)
createFileHeader must be implemented by a Paged implementation in order to create an appropriate subclass instance of a FileHeader. |
Paged.FileHeader |
createFileHeader(long pageCount)
createFileHeader must be implemented by a Paged implementation in order to create an appropriate subclass instance of a FileHeader. |
Paged.FileHeader |
createFileHeader(long pageCount,
int pageSize)
createFileHeader must be implemented by a Paged implementation in order to create an appropriate subclass instance of a FileHeader. |
Paged.PageHeader |
createPageHeader()
createPageHeader must be implemented by a Paged implementation in order to create an appropriate subclass instance of a PageHeader. |
boolean |
deleteRecord(Key key)
deleteRecord removes a Record from the Filer based on the specified Key. |
void |
flush()
flush forcefully flushes any unwritten buffers to disk. |
Configuration |
getConfig()
getConfig retrieves the configuration information for the Configurable object instance. |
java.lang.String |
getName()
getName retrieves the contextually important name of the object |
long |
getRecordCount()
getRecordCount returns the number of Records in the Filer. |
RecordSet |
getRecordSet()
getRecordSet returns a RecordSet object for the current Filer. |
boolean |
open()
open opens the DBObject |
Record |
readRecord(Key key)
readRecord returns a Record from the Filer based on the specified Key. |
void |
setCollection(Collection collection)
setCollection tells the Filer who its parent is. |
void |
setConfig(Configuration config)
setConfig sets the configuration information for the Configurable object instance. |
void |
setLocation(java.lang.String location)
|
boolean |
writeRecord(Key key,
Value value)
writeRecord writes a Value to the Filer based on the specified Key. |
Methods inherited from class org.apache.xindice.core.filer.BTree |
addValue, addValue, findValue, findValue, query, query, removeValue, removeValue |
Methods inherited from class org.apache.xindice.core.filer.Paged |
close, deleteArrayInt, deleteArrayLong, deleteArrayShort, deleteArrayValue, drop, exists, getFileHeader, insertArrayInt, insertArrayLong, insertArrayShort, insertArrayValue, isOpened |
Methods inherited from class java.lang.Object |
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Methods inherited from interface org.apache.xindice.core.DBObject |
close, drop, exists, isOpened |
Constructor Detail |
public BTreeFiler()
Method Detail |
public void setConfig(Configuration config)
Configurable
setConfig
in interface Configurable
org.apache.xindice.util.Configurable
config
- The configuration Nodepublic Configuration getConfig()
Configurable
getConfig
in interface Configurable
org.apache.xindice.util.Configurable
public void setLocation(java.lang.String location)
public java.lang.String getName()
Named
getName
in interface Named
org.apache.xindice.util.Named
public boolean open() throws DBException
DBObject
open
in interface DBObject
open
in class BTree
org.apache.xindice.core.DBObject
public boolean create() throws DBException
DBObject
create
in interface DBObject
create
in class BTree
org.apache.xindice.core.DBObject
public void setCollection(Collection collection)
Filer
setCollection
in interface Filer
org.apache.xindice.core.filer.Filer
collection
- The owner Collectionpublic Record readRecord(Key key) throws DBException
Filer
readRecord
in interface Filer
org.apache.xindice.core.filer.Filer
key
- The Record's Keypublic boolean writeRecord(Key key, Value value) throws DBException
Filer
writeRecord
in interface Filer
org.apache.xindice.core.filer.Filer
key
- The Record's Keyvalue
- The Record's Valuepublic boolean deleteRecord(Key key) throws DBException
Filer
deleteRecord
in interface Filer
org.apache.xindice.core.filer.Filer
key
- The Record's Keypublic long getRecordCount() throws DBException
Filer
getRecordCount
in interface Filer
org.apache.xindice.core.filer.Filer
public RecordSet getRecordSet() throws DBException
Filer
getRecordSet
in interface Filer
org.apache.xindice.core.filer.Filer
public void flush() throws DBException
Filer
flush
in interface Filer
flush
in class Paged
public Paged.FileHeader createFileHeader()
Paged
createFileHeader
in class BTree
org.apache.xindice.core.filer.Paged
public Paged.FileHeader createFileHeader(boolean read) throws java.io.IOException
Paged
createFileHeader
in class BTree
org.apache.xindice.core.filer.Paged
read
- If true, reads the FileHeader from diskjava.io.IOException
- if an exception occurspublic Paged.FileHeader createFileHeader(long pageCount)
Paged
createFileHeader
in class BTree
org.apache.xindice.core.filer.Paged
pageCount
- The number of pages to allocate for primary storagepublic Paged.FileHeader createFileHeader(long pageCount, int pageSize)
Paged
createFileHeader
in class BTree
org.apache.xindice.core.filer.Paged
pageCount
- The number of pages to allocate for primary storagepageSize
- The size of a Page (should be a multiple of a FS block)public Paged.PageHeader createPageHeader()
Paged
createPageHeader
in class BTree
org.apache.xindice.core.filer.Paged
|
Xindice API | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |