public final class IndexDocument extends Object
Modifier and Type | Method and Description |
---|---|
void |
addPair(String key,
String value,
boolean searchable,
boolean stored)
Add a [key,value] pair to this document.
|
public void addPair(String key, String value, boolean searchable, boolean stored)
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).