Class TokenStreamOffsetStrategy.TokenStreamOffsetsEnum
java.lang.Object
org.apache.lucene.search.uhighlight.OffsetsEnum
org.apache.lucene.search.uhighlight.TokenStreamOffsetStrategy.TokenStreamOffsetsEnum
- All Implemented Interfaces:
Closeable,AutoCloseable,Comparable<OffsetsEnum>
- Enclosing class:
TokenStreamOffsetStrategy
-
Nested Class Summary
Nested classes/interfaces inherited from class org.apache.lucene.search.uhighlight.OffsetsEnum
OffsetsEnum.MultiOffsetsEnum, OffsetsEnum.OfMatchesIterator, OffsetsEnum.OfMatchesIteratorWithSubs, OffsetsEnum.OfPostings -
Field Summary
FieldsModifier and TypeFieldDescription(package private) final CharTermAttribute(package private) int(package private) final BytesRef[](package private) final CharArrayMatcher[](package private) final OffsetAttribute(package private) TokenStreamFields inherited from class org.apache.lucene.search.uhighlight.OffsetsEnum
EMPTY -
Constructor Summary
Constructors -
Method Summary
Methods inherited from class org.apache.lucene.search.uhighlight.OffsetsEnum
compareTo, toString
-
Field Details
-
stream
TokenStream stream -
matchers
-
charTermAtt
-
offsetAtt
-
currentMatch
int currentMatch -
matchDescriptions
-
-
Constructor Details
-
TokenStreamOffsetsEnum
TokenStreamOffsetsEnum(TokenStream ts, CharArrayMatcher[] matchers) throws IOException - Throws:
IOException
-
-
Method Details
-
nextPosition
Description copied from class:OffsetsEnumAdvances to the next position and returns true, or if can't then returns false. Note that the initial state of this class is not positioned.- Specified by:
nextPositionin classOffsetsEnum- Throws:
IOException
-
freq
Description copied from class:OffsetsEnumAn estimate of the number of occurrences of this term/OffsetsEnum.- Specified by:
freqin classOffsetsEnum- Throws:
IOException
-
startOffset
- Specified by:
startOffsetin classOffsetsEnum- Throws:
IOException
-
endOffset
- Specified by:
endOffsetin classOffsetsEnum- Throws:
IOException
-
getTerm
Description copied from class:OffsetsEnumThe term at this position. This BytesRef is safe to continue to refer to, even after we move to the next position.- Specified by:
getTermin classOffsetsEnum- Throws:
IOException- See Also:
-
close
- Specified by:
closein interfaceAutoCloseable- Specified by:
closein interfaceCloseable- Overrides:
closein classOffsetsEnum- Throws:
IOException
-