Method GetTerms
GetTerms(AtomicReader, String, Boolean)
Checks the internal cache for an appropriate entry, and if none
is found, reads the term values in field
and returns a BinaryDocValues instance, providing a
method to retrieve the term (as a BytesRef) per document.
Declaration
BinaryDocValues GetTerms(AtomicReader reader, string field, bool setDocsWithField)
Parameters
Type | Name | Description |
---|---|---|
AtomicReader | reader | Used to get field values. |
System.String | field | Which field contains the strings. |
System.Boolean | setDocsWithField | If true then GetDocsWithField(AtomicReader, String) will also be computed and stored in the IFieldCache. |
Returns
Type | Description |
---|---|
BinaryDocValues | The values in the given field for each document. |
GetTerms(AtomicReader, String, Boolean, Single)
Expert: just like GetTerms(AtomicReader, String, Boolean), but you can specify whether more RAM should be consumed in exchange for faster lookups (default is "true"). Note that the first call for a given reader and field "wins", subsequent calls will share the same cache entry.
Declaration
BinaryDocValues GetTerms(AtomicReader reader, string field, bool setDocsWithField, float acceptableOverheadRatio)
Parameters
Type | Name | Description |
---|---|---|
AtomicReader | reader | |
System.String | field | |
System.Boolean | setDocsWithField | |
System.Single | acceptableOverheadRatio |
Returns
Type | Description |
---|---|
BinaryDocValues |