Interface HighlightProjectionOptionsStep
- All Superinterfaces:
HighlightProjectionFinalStep,ProjectionFinalStep<List<String>>
The initial and final step in a highlight definition, where optional parameters can be set.
-
Method Summary
Modifier and TypeMethodDescriptionhighlighter(String highlighterName) Defines a name of a named highlighter to be used by this field projection.single()Defines the projection as single-valued, i.e. returningStringinstead ofList<String>.Methods inherited from interface org.hibernate.search.engine.search.projection.dsl.ProjectionFinalStep
toProjection
-
Method Details
-
highlighter
Defines a name of a named highlighter to be used by this field projection.- Parameters:
highlighterName- The name of a highlighterdefined on the query.- Returns:
- A final step to finish the definition of a highlight projection.
- See Also:
-
single
SingleHighlightProjectionFinalStep single()Defines the projection as single-valued, i.e. returningStringinstead ofList<String>.Can only be used when the highlighter that creates highlighted fragments for this projection is configured to return a single fragment at most, i.e. when
.numberOfFragments(1)is applied to the highlighter. Otherwise, it will lead to an exception being thrown when the query is created.- Returns:
- A final step in the highlight projection definition.
- See Also:
-