|
Xindice API version 1.2m1 |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.apache.xindice.core.indexer.MemValueIndexer
Provides an in-memory implementation of Xindice Indexer based upon the Java TreeSet class. This implementation is not persistent. A MemValueIndexer is useful for indexing of temporary Collections (e.g. those based on MemFiler). It is also useful for temporary indexing of persistent Collections.
Field Summary |
Fields inherited from interface org.apache.xindice.core.indexer.Indexer |
STYLE_FULLTEXT, STYLE_NODENAME, STYLE_NODEVALUE |
Constructor Summary | |
MemValueIndexer()
|
Method Summary | |
void |
addDocument(Key key)
|
boolean |
close()
Closes this index. |
boolean |
create()
Creates a new MemValueIndexer. |
boolean |
drop()
Removes this index from existence. |
boolean |
exists()
Indicates whether or not this index exists. |
void |
flush()
flush forcefully flushes any unwritten buffers to disk. |
Configuration |
getConfig()
getConfig retrieves the configuration information for the Configurable object instance. |
IndexerEventHandler |
getIndexerEventHandler()
getIndexerEventHandler returns an instance of IndexerEventHandler that handles Indexer-specific events. |
String |
getIndexStyle()
Provides the index style. |
String |
getName()
Provides the name of this index. |
IndexPattern[] |
getPatterns()
Provides the pattern recognized by this Indexer. |
boolean |
isOpened()
Indicates whether or not this indexer is open. |
boolean |
open()
Opens the index so it can be used. |
IndexMatch[] |
queryMatches(IndexQuery theQuery)
Provides a set of MatchEntry instances that match the specified query. |
void |
removeDocument(Key key)
|
void |
setCollection(Collection theCollection)
Sets the parent Collection of this indexer. |
void |
setConfig(Configuration theConfig)
setConfig sets the configuration information for the Configurable object instance. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
public MemValueIndexer()
Method Detail |
public void setCollection(Collection theCollection)
setCollection
in interface Indexer
theCollection
- The owner Collectionpublic String getIndexStyle()
getIndexStyle
in interface Indexer
public void addDocument(Key key) throws DBException
DBException
public void removeDocument(Key key) throws DBException
DBException
public IndexPattern[] getPatterns()
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.
getPatterns
in interface Indexer
public IndexMatch[] queryMatches(IndexQuery theQuery) throws DBException
queryMatches
in interface Indexer
theQuery
- The IndexQuery to use
DBException
public void flush() throws DBException
flush
in interface Indexer
DBException
public IndexerEventHandler getIndexerEventHandler()
Indexer
getIndexerEventHandler
in interface Indexer
IndexerEventHandler
public void setConfig(Configuration theConfig)
setConfig
in interface Configurable
theConfig
- The configuration Nodepublic Configuration getConfig()
getConfig
in interface Configurable
public boolean create() throws DBException
create
in interface DBObject
DBException
- if operation failedpublic boolean open() throws DBException
open
in interface DBObject
DBException
- if operation failedpublic boolean isOpened()
isOpened
in interface DBObject
public boolean exists() throws DBException
exists
in interface DBObject
DBException
- if operation failedpublic boolean drop() throws DBException
drop
in interface DBObject
DBException
- if operation failedpublic boolean close() throws DBException
close
in interface DBObject
DBException
- if operation failedpublic String getName()
getName
in interface Named
|
Xindice API version 1.2m1 |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |