Class DefaultModelLoader
java.lang.Object
de.hybris.platform.solrfacetsearch.loader.impl.DefaultModelLoader
- All Implemented Interfaces:
ModelLoader<Object>
ModelLoader implementation for
Gets information on ProductModels from given collection of
ProductModel. Gets information on ProductModels from given collection of
SolrDocuments-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected StringgetModelAttribute(String attribute, Object model, PK pk) protected PKgetPKFromDocument(org.apache.solr.common.SolrDocument doc) loadCodes(Collection<org.apache.solr.common.SolrDocument> documents) Retrieves codes of items contained within the collection ofSolrDocumentsloadModels(Collection<org.apache.solr.common.SolrDocument> documents) Retrieves information on models that are contained within the collection ofSolrDocumentsvoidsetModelService(ModelService modelService)
-
Constructor Details
-
DefaultModelLoader
public DefaultModelLoader()
-
-
Method Details
-
loadModels
public List<Object> loadModels(Collection<org.apache.solr.common.SolrDocument> documents) throws ModelLoadingException Description copied from interface:ModelLoaderRetrieves information on models that are contained within the collection ofSolrDocuments- Specified by:
loadModelsin interfaceModelLoader<Object>- Throws:
ModelLoadingException
-
loadCodes
public List<String> loadCodes(Collection<org.apache.solr.common.SolrDocument> documents) throws ModelLoadingException Description copied from interface:ModelLoaderRetrieves codes of items contained within the collection ofSolrDocuments- Specified by:
loadCodesin interfaceModelLoader<Object>- Returns:
- Codes of items as Strings
- Throws:
ModelLoadingException
-
getModelAttribute
protected String getModelAttribute(String attribute, Object model, PK pk) throws ModelLoadingException - Parameters:
attribute-model-pk-- Returns:
- string
- Throws:
ModelLoadingException
-
getPKFromDocument
protected PK getPKFromDocument(org.apache.solr.common.SolrDocument doc) throws ModelLoadingException - Parameters:
doc-- Returns:
- PK
- Throws:
ModelLoadingException
-
setModelService
-