org.netbeans.modules.parsing.spi.indexing.support
Class IndexDocument
java.lang.Object
org.netbeans.modules.parsing.spi.indexing.support.IndexDocument
public final class IndexDocument
- extends Object
An IndexDocument lets you store a series of [key,value] pairs in the
persistent store.
|
Method Summary |
void |
addPair(String key,
String value,
boolean searchable,
boolean stored)
Add a [key,value] pair to this document. |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
addPair
public void addPair(String key,
String value,
boolean searchable,
boolean stored)
- Add a [key,value] pair to this document. Note that the document really
contains a multi-map, so it is okay and normal to call addPair multiple
times with the same key. This just adds the value to the set of values
associated with the key.
- Parameters:
key - The key that you will later search by. Note that you are NOT
allowed to use the keys filename or timestamp
since these are reserved (and in fact used) by GSF.value - The value that will be retrieved for this keysearchable - A boolean which if set to true will store the pair with
an indexed/searchable field key, otherwise with an unindexed field (that cannot be
searched). You must be consistent in how keys are identified
as searchable; the same key must always be referenced with the same
value for searchable when pairs are added (per document).