Method GetTermsIndex
GetTermsIndex(AtomicReader, String)
Checks the internal cache for an appropriate entry, and if none
is found, reads the term values in field
and returns a SortedDocValues instance,
providing methods to retrieve sort ordinals and terms
(as a BytesRef) per document.
Declaration
SortedDocValues GetTermsIndex(AtomicReader reader, string field)
Parameters
Type | Name | Description |
---|---|---|
AtomicReader | reader | Used to get field values. |
System.String | field | Which field contains the strings. |
Returns
Type | Description |
---|---|
SortedDocValues | The values in the given field for each document. |
GetTermsIndex(AtomicReader, String, Single)
Expert: just like GetTermsIndex(AtomicReader, String), 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
SortedDocValues GetTermsIndex(AtomicReader reader, string field, float acceptableOverheadRatio)
Parameters
Type | Name | Description |
---|---|---|
AtomicReader | reader | |
System.String | field | |
System.Single | acceptableOverheadRatio |
Returns
Type | Description |
---|---|
SortedDocValues |