Class MultiFieldsOffsetStrategy
java.lang.Object
org.apache.lucene.search.uhighlight.FieldOffsetStrategy
org.apache.lucene.search.uhighlight.MultiFieldsOffsetStrategy
FieldOffsetStrategy that combines offsets from multiple fields. Used to highlight a single field
based on matches from multiple fields.
- NOTE: This API is for internal purposes only and might change in incompatible ways in the next release.
-
Field Summary
Fields inherited from class org.apache.lucene.search.uhighlight.FieldOffsetStrategy
components
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptiongetField()
getOffsetsEnum
(LeafReader reader, int docId, String content) The primary method -- return offsets for highlightable words in the specified document.Methods inherited from class org.apache.lucene.search.uhighlight.FieldOffsetStrategy
createOffsetsEnumFromReader, createOffsetsEnumsForAutomata, createOffsetsEnumsForTerms, createOffsetsEnumsWeightMatcher
-
Constructor Details
-
MultiFieldsOffsetStrategy
-
-
Method Details
-
getField
- Overrides:
getField
in classFieldOffsetStrategy
-
getOffsetSource
- Specified by:
getOffsetSource
in classFieldOffsetStrategy
-
getOffsetsEnum
Description copied from class:FieldOffsetStrategy
The primary method -- return offsets for highlightable words in the specified document.Callers are expected to close the returned OffsetsEnum when it has been finished with
- Specified by:
getOffsetsEnum
in classFieldOffsetStrategy
- Throws:
IOException
-