Class ResourceReturnable
java.lang.Object
org.ametys.web.frontoffice.search.metamodel.impl.ResourceReturnable
- All Implemented Interfaces:
Returnable
,Configurable
,Serviceable
Returnable
for Resource
s-
Field Summary
Modifier and TypeFieldDescriptionprotected I18nizableText
The labelprotected ReturnableSaxer
The saxerprotected TikaProvider
The tika providerstatic final String
Avalon Role -
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionvoid
configure
(Configuration configuration) filterReturnedDocumentQuery
(Collection<ContextQueriesWrapper> contextQueriesWrappers, AdditionalParameterValueMap additionalParameterValues) Returns the query to execute in order to filter returned objects (according to their type) during the search.getFacets
(AdditionalParameterValueMap additionalParameterValues) Gets the facetsgetId()
Gets the id of the extensiongetLabel()
Gets the label of the type of resultgetSaxer
(Collection<Returnable> allReturnables, AdditionalParameterValueMap additionalParameterValues) Returns thesaxer
responsible to SAX hits of this Returnable.getSorts
(AdditionalParameterValueMap additionalParameterValues) Gets the sortsboolean
Returnstrue
if the type must be selected by defaultvoid
service
(ServiceManager manager) Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface org.ametys.web.frontoffice.search.metamodel.Returnable
additionalServiceParameters, relationsWith
-
Field Details
-
ROLE
Avalon Role -
_tikaProvider
The tika provider -
_label
The label -
_saxer
The saxer
-
-
Constructor Details
-
ResourceReturnable
public ResourceReturnable()
-
-
Method Details
-
service
- Specified by:
service
in interfaceServiceable
- Throws:
ServiceException
-
configure
- Specified by:
configure
in interfaceConfigurable
- Throws:
ConfigurationException
-
getId
Description copied from interface:Returnable
Gets the id of the extension- Specified by:
getId
in interfaceReturnable
- Returns:
- the id of the extension
-
getLabel
Description copied from interface:Returnable
Gets the label of the type of result- Specified by:
getLabel
in interfaceReturnable
- Returns:
- the label of the type of result
-
selectedByDefault
Description copied from interface:Returnable
Returnstrue
if the type must be selected by default- Specified by:
selectedByDefault
in interfaceReturnable
- Returns:
true
if the type must be selected by default
-
filterReturnedDocumentQuery
public Query filterReturnedDocumentQuery(Collection<ContextQueriesWrapper> contextQueriesWrappers, AdditionalParameterValueMap additionalParameterValues) Description copied from interface:Returnable
Returns the query to execute in order to filter returned objects (according to their type) during the search.
It should callContextQueriesWrapper#getQuery
in order to make aJoinQuery
on interesting parts ofContextQueriesWrapper
s and then constructs anAndQuery
composed of aDocumentTypeQuery
and the result of the call.- Specified by:
filterReturnedDocumentQuery
in interfaceReturnable
- Parameters:
contextQueriesWrappers
- The contextqueries
additionalParameterValues
- The additional parameter values- Returns:
- the query to execute in order to filter returned objects (according to their type) during the search.
-
getSaxer
public ReturnableSaxer getSaxer(Collection<Returnable> allReturnables, AdditionalParameterValueMap additionalParameterValues) Description copied from interface:Returnable
Returns thesaxer
responsible to SAX hits of this Returnable.- Specified by:
getSaxer
in interfaceReturnable
- Parameters:
allReturnables
- AllReturnable
s (including this)additionalParameterValues
- The additional parameter values- Returns:
- the
saxer
responsible to SAX hits of this Returnable.
-
getFacets
Description copied from interface:Returnable
Gets the facets- Specified by:
getFacets
in interfaceReturnable
- Parameters:
additionalParameterValues
- The additional parameter values- Returns:
- the facets
-
getSorts
Description copied from interface:Returnable
Gets the sorts- Specified by:
getSorts
in interfaceReturnable
- Parameters:
additionalParameterValues
- The additional parameter values- Returns:
- the sorts
-