Package org.dspace.app.iiif.service
Class WordHighlightSolrSearch
java.lang.Object
org.dspace.app.iiif.service.WordHighlightSolrSearch
- All Implemented Interfaces:
SearchAnnotationService
@Scope("prototype")
@Component
public class WordHighlightSolrSearch
extends Object
implements SearchAnnotationService
This service implements methods for executing a solr search and creating IIIF search result annotations.
https://github.com/dbmdz/solr-ocrhighlighting
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptiongetSearchResponse(UUID uuid, String query) Executes the Search API solr query and returns iiif search result annotations.voidinitializeQuerySettings(String endpoint, String manifestId) Initializes required values.booleanuseSearchPlugin(String className) Tests to see if the plugin is configured in iiif.cfg.
-
Constructor Details
-
WordHighlightSolrSearch
public WordHighlightSolrSearch()
-
-
Method Details
-
useSearchPlugin
Description copied from interface:SearchAnnotationServiceTests to see if the plugin is configured in iiif.cfg.- Specified by:
useSearchPluginin interfaceSearchAnnotationService- Parameters:
className- the canonical name of class- Returns:
- true if provided value matches plugin class name
-
initializeQuerySettings
Description copied from interface:SearchAnnotationServiceInitializes required values.- Specified by:
initializeQuerySettingsin interfaceSearchAnnotationService- Parameters:
endpoint- the iiif service endpointmanifestId- the id of the manifest to search within
-
getSearchResponse
Description copied from interface:SearchAnnotationServiceExecutes the Search API solr query and returns iiif search result annotations.- Specified by:
getSearchResponsein interfaceSearchAnnotationServicequery- encoded query terms- Returns:
- iiif json response
-