|
dbXML API | ||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.dbxml.db.common.btree.Paged
com.dbxml.db.common.btree.BTree
com.dbxml.db.common.indexers.NameIndexer
NameIndexer is a basic implementation of the Indexer interface. It is used for maintaining element and element@attribute unique indexes.
Nested Class Summary |
Nested classes inherited from class com.dbxml.db.common.btree.Paged |
Paged.FileHeader, Paged.Page, Paged.PageHeader |
Field Summary |
Fields inherited from interface com.dbxml.db.core.indexer.Indexer |
STYLE_FULLTEXT, STYLE_NODENAME, STYLE_NODEVALUE |
Constructor Summary | |
NameIndexer()
|
Method Summary | |
void |
add(Transaction tx,
java.lang.String value,
Key key,
int pos,
int elemID,
int attrID)
add adds a Document to the Indexer. |
java.lang.String |
getIndexStyle()
getIndexStyle returns the Index style. |
java.lang.String |
getName()
getName returns the name of this Indexer. |
java.lang.String |
getPattern()
getPattern returns the pattern recognized by this Indexer. |
IndexMatch[] |
queryMatches(Transaction tx,
IndexQuery query)
queryMatches retrieves a set of MatchEntry instances that match the supplied query. |
void |
remove(Transaction tx,
java.lang.String value,
Key key,
int pos,
int elemID,
int attrID)
remove removes all references to the specified Key from the Indexer. |
void |
setCollection(Collection collection)
setCollection tells the Indexer who its parent is. |
void |
setConfig(Configuration config)
setConfig sets the configuration information for the Configurable object instance. |
void |
setLocation(java.lang.String location)
|
Methods inherited from class com.dbxml.db.common.btree.BTree |
addValue, create, createFileHeader, createFileHeader, createFileHeader, createFileHeader, createPageHeader, findValue, open, query, removeValue |
Methods inherited from class com.dbxml.db.common.btree.Paged |
addPageFilter, close, deleteArrayValue, drop, exists, flush, getConfig, getFileHeader, getTransactionLog, insertArrayValue, isOpened, listPageFilters, removePageFilter |
Methods inherited from class java.lang.Object |
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Methods inherited from interface com.dbxml.db.core.indexer.Indexer |
close, create, drop, exists, flush, getTransactionLog, isOpened, open |
Methods inherited from interface com.dbxml.util.Configurable |
getConfig |
Constructor Detail |
public NameIndexer()
Method Detail |
public void setConfig(Configuration config) throws dbXMLException
Configurable
setConfig
in interface Configurable
setConfig
in class Paged
dbXMLException
public java.lang.String getName()
Indexer
getName
in interface Indexer
public void setLocation(java.lang.String location)
public void setCollection(Collection collection)
Indexer
setCollection
in interface Indexer
collection
- The owner Collectionpublic java.lang.String getIndexStyle()
Indexer
getIndexStyle
in interface Indexer
public java.lang.String getPattern()
Indexer
contact@name Indexes all contacts by name attribute memo Indexes the text of all memo elements contact@* Indexes all contact attributes *@name Indexes the name attribute for all elements * Indexes the text of all elements *@* Indexes all attributes of all elementsThese patterns are used by the IndexManager when handling SAX events. All events that match the specified pattern will result in an add or remove call to the Indexer.
getPattern
in interface Indexer
public void remove(Transaction tx, java.lang.String value, Key key, int pos, int elemID, int attrID) throws DBException
Indexer
remove
in interface Indexer
tx
- The controlling Transactionvalue
- The value to removekey
- The Object IDpos
- The offset into the stream the Element occurs atelemID
- The Element ID of the valueattrID
- The Attribute ID of the value (if any, else -1)
DBException
public void add(Transaction tx, java.lang.String value, Key key, int pos, int elemID, int attrID) throws DBException
Indexer
add
in interface Indexer
tx
- The controlling Transactionvalue
- The value to removekey
- The Object IDpos
- The offset into the stream the Element occurs atelemID
- The Element ID of the valueattrID
- The Attribute ID of the value (if any, else -1)
DBException
public IndexMatch[] queryMatches(Transaction tx, IndexQuery query) throws DBException
Indexer
queryMatches
in interface Indexer
tx
- The controlling Transactionquery
- The IndexQuery to use
DBException
|
dbXML API | ||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |