Class Snippet
java.lang.Object
org.elasticsearch.lucene.search.uhighlight.Snippet
Represents a scored highlighted snippet.
It's our own arbitrary object that we get back from the unified highlighter when highlighting a document.
Every snippet contains its formatted text and its score.
The score is needed in case we want to sort snippets by score, they get sorted by position in the text by default.
-
Constructor Summary
-
Method Summary
-
Constructor Details
-
Snippet
-
-
Method Details
-
getText
-
getScore
public float getScore() -
isHighlighted
public boolean isHighlighted()
-