Class DefaultSearchUIModel
java.lang.Object
org.ametys.cms.search.model.DefaultSearchModel
org.ametys.cms.search.ui.model.impl.DefaultSearchUIModel
- All Implemented Interfaces:
SearchModel,SearchUIModel
Default implementation of a
SearchUIModel.-
Field Summary
FieldsModifier and TypeFieldDescriptionprotected StringThe URL for CSV export of resultsprotected StringThe plugin name for CSV export of resultsprotected StringThe URL for doc export of resultsprotected StringThe plugin name for doc export of resultsprotected StringThe URL for PDF export of resultsprotected StringThe plugin name for PDF export of resultsprotected StringThe URL for XML export of resultsprotected StringThe plugin name for XML export of resultsprotected intThe page sizeprotected StringThe URL for print resultsprotected StringThe plugin name for print resultsprotected StringThe URL for searchprotected StringThe plugin name for searchprotected StringThe name of the view to use for summary of the contentprotected Map<String,SearchUICriterion> The advanced search ui criteria, indexed by ID.protected Map<String,SearchUICriterion> The simple search ui criteria, indexed by ID.protected Map<String,SearchUICriterion> The faceted search ui criteria, indexed by ID.Fields inherited from class org.ametys.cms.search.model.DefaultSearchModel
_criteria, _cTypes, _excludedCTypes, _facetedCriteria, _resultItems, _workspace -
Constructor Summary
ConstructorsConstructorDescriptionDefault constructor.DefaultSearchUIModel(SearchUIModel searchUIModelToCopy, Map<String, Object> contextualParameters) Constructor by copying an existingSearchUIModel. -
Method Summary
Modifier and TypeMethodDescriptionvoidaddAdvancedCriterion(SearchUICriterion criterion) Add an advanced criterionvoidaddCriterion(SearchCriterion criterion) Add a criterionvoidaddFacetedCriterion(SearchCriterion criterion) Add a faceted criteriongetAdvancedCriteria(Map<String, Object> contextualParameters) Get the list of search criteria in advanced modegetCriteria(Map<String, Object> contextualParameters) Get the list of search criteria in simple modegetExportCSVUrl(Map<String, Object> contextualParameters) Get the URL for CSV export of resultsgetExportCSVUrlPlugin(Map<String, Object> contextualParameters) Get the plugin name for CSV export of resultsgetExportDOCUrl(Map<String, Object> contextualParameters) Get the URL for DOC export of resultsgetExportDOCUrlPlugin(Map<String, Object> contextualParameters) Get the plugin name for DOC export of resultsgetExportPDFUrl(Map<String, Object> contextualParameters) Get the URL for PDF export of resultsgetExportPDFUrlPlugin(Map<String, Object> contextualParameters) Get the plugin name for PDF export of resultsgetExportXMLUrl(Map<String, Object> contextualParameters) Get the URL for XML export of resultsgetExportXMLUrlPlugin(Map<String, Object> contextualParameters) Get the plugin name for XML export of resultsgetFacetedCriteria(Map<String, Object> contextualParameters) Get the list of faceted search criteria.intgetPageSize(Map<String, Object> contextualParameters) Get the page size.getPrintUrl(Map<String, Object> contextualParameters) Get the URL for print resultsgetPrintUrlPlugin(Map<String, Object> contextualParameters) Get the plugin name for print resultsgetSearchUrl(Map<String, Object> contextualParameters) Get the URL for searchgetSearchUrlPlugin(Map<String, Object> contextualParameters) Get the plugin name for searchGet the name of the view to use for summary of the content.voidsetAdvancedCriteria(Collection<? extends SearchUICriterion> criteria) Set the advanced criteriavoidsetCriteria(Collection<? extends SearchCriterion> criteria) Set the criteriavoidsetExportCSVUrl(String exportCSVUrl) Set the URL for CSV export of resultsvoidsetExportCSVUrlPlugin(String exportCSVUrlPlugin) Set the plugin name for CSV export of resultsvoidsetExportDOCUrl(String exportDOCUrl) Set the URL for Doc export of resultsvoidsetExportDOCUrlPlugin(String exportDOCUrlPlugin) Set the plugin name for Doc export of resultsvoidsetExportPDFUrl(String exportPDFUrl) Set the URL for PDF export of resultsvoidsetExportPDFUrlPlugin(String exportPDFUrlPlugin) Set the plugin name for PDF export of resultsvoidsetExportXMLUrl(String exportXMLUrl) Set the URL for XML export of resultsvoidsetExportXMLUrlPlugin(String exportXMLUrlPlugin) Set the plugin name for XML export of resultsvoidsetFacetedCriteria(Collection<? extends SearchCriterion> criteria) Set the faceted criteriavoidsetPageSize(int pageSize) Set the page sizevoidsetPrintUrl(String printUrl) Set the URL for print resultsvoidsetPrintUrlPlugin(String printUrlPlugin) Set the plugin name for print resultsvoidsetSearchUrl(String searchUrl) Set the URL for searchvoidsetSearchUrlPlugin(String searchUrlPlugin) Set the plugin name for searchvoidsetSummaryView(String summaryView) Set The name of the view to use for summary of the contentMethods inherited from class org.ametys.cms.search.model.DefaultSearchModel
getContentTypes, getExcludedContentTypes, getResultItems, getWorkspace, setContentTypes, setExcludedContentTypes, setResulItems, setWorkspaceMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface org.ametys.cms.search.model.SearchModel
getContentTypes, getExcludedContentTypes, getResultItem, getResultItems, getWorkspaceMethods inherited from interface org.ametys.cms.search.ui.model.SearchUIModel
allowSortOnMultipleJoin, getAdvancedCriterion, getCriterion, getFacetedCriterion
-
Field Details
-
_uiCriteria
The simple search ui criteria, indexed by ID. -
_uiFacetedCriteria
The faceted search ui criteria, indexed by ID. -
_uiAdvancedCriteria
The advanced search ui criteria, indexed by ID. -
_pageSize
The page size -
_searchUrl
The URL for search -
_searchUrlPlugin
The plugin name for search -
_exportCSVUrl
The URL for CSV export of results -
_exportCSVUrlPlugin
The plugin name for CSV export of results -
_exportDOCUrl
The URL for doc export of results -
_exportDOCUrlPlugin
The plugin name for doc export of results -
_exportXMLUrl
The URL for XML export of results -
_exportXMLUrlPlugin
The plugin name for XML export of results -
_exportPDFUrl
The URL for PDF export of results -
_exportPDFUrlPlugin
The plugin name for PDF export of results -
_printUrl
The URL for print results -
_printUrlPlugin
The plugin name for print results -
_summaryView
The name of the view to use for summary of the content
-
-
Constructor Details
-
DefaultSearchUIModel
public DefaultSearchUIModel()Default constructor. -
DefaultSearchUIModel
public DefaultSearchUIModel(SearchUIModel searchUIModelToCopy, Map<String, Object> contextualParameters) Constructor by copying an existingSearchUIModel.- Parameters:
searchUIModelToCopy- TheSearchUIModelto copycontextualParameters- The contextual parameters
-
-
Method Details
-
getCriteria
Description copied from interface:SearchModelGet the list of search criteria in simple mode- Specified by:
getCriteriain interfaceSearchModel- Specified by:
getCriteriain interfaceSearchUIModel- Overrides:
getCriteriain classDefaultSearchModel- Parameters:
contextualParameters- the contextual parameters- Returns:
- the list of search criteria in simple mode
-
addCriterion
Description copied from class:DefaultSearchModelAdd a criterion- Overrides:
addCriterionin classDefaultSearchModel- Parameters:
criterion- the criterion to add
-
setCriteria
Description copied from class:DefaultSearchModelSet the criteria- Overrides:
setCriteriain classDefaultSearchModel- Parameters:
criteria- The criteria list
-
getFacetedCriteria
Description copied from interface:SearchModelGet the list of faceted search criteria.- Specified by:
getFacetedCriteriain interfaceSearchModel- Specified by:
getFacetedCriteriain interfaceSearchUIModel- Overrides:
getFacetedCriteriain classDefaultSearchModel- Parameters:
contextualParameters- the contextual parameters- Returns:
- the list of faceted search criteria.
-
addFacetedCriterion
Description copied from class:DefaultSearchModelAdd a faceted criterion- Overrides:
addFacetedCriterionin classDefaultSearchModel- Parameters:
criterion- the faceted criterion to add
-
setFacetedCriteria
Description copied from class:DefaultSearchModelSet the faceted criteria- Overrides:
setFacetedCriteriain classDefaultSearchModel- Parameters:
criteria- The list of faceted criteria
-
getAdvancedCriteria
Description copied from interface:SearchUIModelGet the list of search criteria in advanced mode- Specified by:
getAdvancedCriteriain interfaceSearchUIModel- Parameters:
contextualParameters- the contextual parameters- Returns:
- the list of search criteria in advanced mode
-
addAdvancedCriterion
Add an advanced criterion- Parameters:
criterion- the advanced criterion to add
-
setAdvancedCriteria
Set the advanced criteria- Parameters:
criteria- The list of advanced criterion
-
getPageSize
Description copied from interface:SearchUIModelGet the page size.- Specified by:
getPageSizein interfaceSearchUIModel- Parameters:
contextualParameters- the contextual parameters.- Returns:
- The page size, unlimited or default used when negative or 0.
-
setPageSize
Set the page size- Parameters:
pageSize- The page size to set. Set to negative or 0 for unlimited or default
-
getSearchUrl
Description copied from interface:SearchUIModelGet the URL for search- Specified by:
getSearchUrlin interfaceSearchUIModel- Parameters:
contextualParameters- the contextual parameters- Returns:
- the URL for search
-
setSearchUrl
Set the URL for search- Parameters:
searchUrl- The URL to set
-
getSearchUrlPlugin
Description copied from interface:SearchUIModelGet the plugin name for search- Specified by:
getSearchUrlPluginin interfaceSearchUIModel- Parameters:
contextualParameters- the contextual parameters- Returns:
- the plugin name for search
-
setSearchUrlPlugin
Set the plugin name for search- Parameters:
searchUrlPlugin- the plugin name to set
-
getExportCSVUrl
Description copied from interface:SearchUIModelGet the URL for CSV export of results- Specified by:
getExportCSVUrlin interfaceSearchUIModel- Parameters:
contextualParameters- the contextual parameters- Returns:
- the URL for CSV export
-
setExportCSVUrl
Set the URL for CSV export of results- Parameters:
exportCSVUrl- The URL to set
-
getExportCSVUrlPlugin
Description copied from interface:SearchUIModelGet the plugin name for CSV export of results- Specified by:
getExportCSVUrlPluginin interfaceSearchUIModel- Parameters:
contextualParameters- the contextual parameters- Returns:
- the plugin name for CSV export
-
setExportCSVUrlPlugin
Set the plugin name for CSV export of results- Parameters:
exportCSVUrlPlugin- the plugin name to set
-
getExportDOCUrl
Description copied from interface:SearchUIModelGet the URL for DOC export of results- Specified by:
getExportDOCUrlin interfaceSearchUIModel- Parameters:
contextualParameters- the contextual parameters- Returns:
- the URL for DOC export
-
setExportDOCUrl
Set the URL for Doc export of results- Parameters:
exportDOCUrl- The URL to set
-
getExportDOCUrlPlugin
Description copied from interface:SearchUIModelGet the plugin name for DOC export of results- Specified by:
getExportDOCUrlPluginin interfaceSearchUIModel- Parameters:
contextualParameters- the contextual parameters- Returns:
- the plugin name for DOC export
-
setExportDOCUrlPlugin
Set the plugin name for Doc export of results- Parameters:
exportDOCUrlPlugin- the plugin name to set
-
getExportXMLUrl
Description copied from interface:SearchUIModelGet the URL for XML export of results- Specified by:
getExportXMLUrlin interfaceSearchUIModel- Parameters:
contextualParameters- the contextual parameters- Returns:
- the URL for XML export
-
setExportXMLUrl
Set the URL for XML export of results- Parameters:
exportXMLUrl- The URL to set
-
getExportXMLUrlPlugin
Description copied from interface:SearchUIModelGet the plugin name for XML export of results- Specified by:
getExportXMLUrlPluginin interfaceSearchUIModel- Parameters:
contextualParameters- the contextual parameters- Returns:
- the plugin name for XML export
-
setExportXMLUrlPlugin
Set the plugin name for XML export of results- Parameters:
exportXMLUrlPlugin- the plugin name to set
-
getExportPDFUrl
Description copied from interface:SearchUIModelGet the URL for PDF export of results- Specified by:
getExportPDFUrlin interfaceSearchUIModel- Parameters:
contextualParameters- the contextual parameters- Returns:
- the URL for PDF export
-
setExportPDFUrl
Set the URL for PDF export of results- Parameters:
exportPDFUrl- The URL to set
-
getExportPDFUrlPlugin
Description copied from interface:SearchUIModelGet the plugin name for PDF export of results- Specified by:
getExportPDFUrlPluginin interfaceSearchUIModel- Parameters:
contextualParameters- the contextual parameters- Returns:
- the plugin name for PDF export
-
setExportPDFUrlPlugin
Set the plugin name for PDF export of results- Parameters:
exportPDFUrlPlugin- the plugin name to set
-
getPrintUrl
Description copied from interface:SearchUIModelGet the URL for print results- Specified by:
getPrintUrlin interfaceSearchUIModel- Parameters:
contextualParameters- the contextual parameters- Returns:
- the URL for print results
-
setPrintUrl
Set the URL for print results- Parameters:
printUrl- The URL to set
-
getPrintUrlPlugin
Description copied from interface:SearchUIModelGet the plugin name for print results- Specified by:
getPrintUrlPluginin interfaceSearchUIModel- Parameters:
contextualParameters- the contextual parameters- Returns:
- the plugin name for print results
-
setPrintUrlPlugin
Set the plugin name for print results- Parameters:
printUrlPlugin- the plugin name to set
-
getSummaryView
Description copied from interface:SearchUIModelGet the name of the view to use for summary of the content.- Specified by:
getSummaryViewin interfaceSearchUIModel- Returns:
- the name of the view to use for summary of the content. Can be null.
-
setSummaryView
Set The name of the view to use for summary of the content- Parameters:
summaryView- the name to set
-