Package io.goobi.viewer.model.search
Class SearchHitFactory
java.lang.Object
io.goobi.viewer.model.search.SearchHitFactory
-
Constructor Summary
ConstructorDescriptionSearchHitFactory
(Map<String, Set<String>> searchTerms, List<StringPair> sortFields, List<String> exportFields, int proximitySearchDistance, ThumbnailHandler thumbnailHandler, Locale locale) -
Method Summary
Modifier and TypeMethodDescriptioncreateSearchHit
(org.apache.solr.common.SolrDocument doc, org.apache.solr.common.SolrDocument ownerDoc, String fulltext, HitType overrideType) createSearchHit.getHitType
(HitType overrideType, StructElement se, String docType) setAdditionalMetadataListType
(String additionalMetadataListType)
-
Constructor Details
-
SearchHitFactory
public SearchHitFactory(Map<String, Set<String>> searchTerms, List<StringPair> sortFields, List<String> exportFields, int proximitySearchDistance, ThumbnailHandler thumbnailHandler, Locale locale) - Parameters:
searchTerms
-sortFields
-exportFields
-proximitySearchDistance
-thumbnailHandler
-locale
-
-
-
Method Details
-
createSearchHit
public SearchHit createSearchHit(org.apache.solr.common.SolrDocument doc, org.apache.solr.common.SolrDocument ownerDoc, String fulltext, HitType overrideType) throws PresentationException, IndexUnreachableException createSearchHit.
- Parameters:
doc
- aSolrDocument
object.ownerDoc
- aSolrDocument
object.fulltext
- Optional fulltext (page docs only).overrideType
- aHitType
object.- Returns:
- a
SearchHit
object. - Throws:
PresentationException
- if any.IndexUnreachableException
- if any.
-
getHitType
-
setAdditionalMetadataListType
- Parameters:
additionalMetadataListType
- the additionalMetadataListType to set- Returns:
- this
-
getAdditionalMetadataIgnoreFields
- Returns:
- the additionalMetadataIgnoreFields
-
getAdditionalMetadataTranslateFields
- Returns:
- the additionalMetadataTranslateFields
-
getAdditionalMetadataOneLineFields
- Returns:
- the additionalMetadataOneLineFields
-
getAdditionalMetadataSnippetFields
- Returns:
- the additionalMetadataSnippetFields
-
getAdditionalMetadataNoHighlightFields
- Returns:
- the additionalMetadataNoHighlightFields
-