Package com.yahoo.prelude.fastsearch
Class PartialSummaryHandler
java.lang.Object
com.yahoo.prelude.fastsearch.PartialSummaryHandler
PartialSummaryHandler is a helper class to help handling of fill()
requests which only cover some of the possible summary fields.
Usage:
1) construct from DocumentDatabase or DocsumDefinitionSet
2) call wantToFill to specify intent
3) use askForSummary and askForFields for making the backend request
4) use needFill to see if the Hit actually needs filling
5) use effectiveDocsumDef for decoding the backend response
6) use markFilled to mark the Hit with what actually got filled
- Author:
- arnej
-
Field Summary
Fields -
Constructor Summary
ConstructorsConstructorDescriptionPartialSummaryHandler(DocsumDefinitionSet docsumDefinitionSet) PartialSummaryHandler(Map<String, Set<String>> knownSummaryClasses) -
Method Summary
Modifier and TypeMethodDescriptionstatic StringenoughFields(String summaryClass, Result result) voidmarkFilled(Hit hit) booleanstatic StringquotedSummaryClassName(String summaryClass, Set<String> summaryFields) static StringresolveSummaryClass(Result result) resolve summary class to use when none providedbooleanvoidvalidateSummaryClass(String summaryClass, Query query) voidwantToFill(Query query) voidwantToFill(Result result, String summaryClass)
-
Field Details
-
DEFAULT_CLASS
- See Also:
-
ALL_FIELDS_CLASS
- See Also:
-
PRESENTATION
- See Also:
-
-
Constructor Details
-
PartialSummaryHandler
-
PartialSummaryHandler
-
PartialSummaryHandler
-
-
Method Details
-
resolveSummaryClass
resolve summary class to use when none provided -
wantToFill
-
wantToFill
-
askForSummary
-
askForFields
-
needFill
-
resultAlreadyFilled
public boolean resultAlreadyFilled() -
effectiveDocsumDef
-
markFilled
-
quotedSummaryClassName
-
enoughFields
-
validateSummaryClass
-