Class CatalogDocumentBuilderImpl
java.lang.Object
org.broadleafcommerce.core.search.service.solr.indexer.CatalogDocumentBuilderImpl
- All Implemented Interfaces:
CatalogDocumentBuilder,DocumentBuilder
@Component("blCatalogDocumentBuilder")
public class CatalogDocumentBuilderImpl
extends Object
implements CatalogDocumentBuilder
- Author:
- Kelly Tisdell
-
Field Summary
FieldsModifier and TypeFieldDescriptionprotected SolrIndexServiceExtensionManagerprotected SandBoxHelperprotected SolrHelperServiceprotected SolrConfiguration -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected voidattachAdditionalDocumentFields(Indexable indexable, org.apache.solr.common.SolrInputDocument document) protected voidattachBasicDocumentFields(Indexable indexable, org.apache.solr.common.SolrInputDocument document) protected voidattachIndexableDocumentFields(org.apache.solr.common.SolrInputDocument document, Indexable indexable, List<IndexField> fields, List<Locale> locales) org.apache.solr.common.SolrInputDocumentbuildDocument(Indexable indexable, List<IndexField> fields, List<Locale> locales) protected voidbuildFullCategoryHierarchy(org.apache.solr.common.SolrInputDocument document, CatalogStructure cache, Long categoryId, Set<Long> indexedParents) protected LongconvertDisplayOrderToLong(CatalogStructure cache, String displayOrderKey) We multiply the BigDecimal by 1,000,000 to maintain any possible decimals in use the displayOrder value.protected voidmodifyDocument(Indexable indexable, List<IndexField> fields, List<Locale> locales) This is a simple hook point to allow implementors to override and modify the documents after the default functionality has created them.
-
Field Details
-
shs
-
extensionManager
-
solrConfiguration
@Qualifier("blCatalogSolrConfiguration") @Autowired(required=false) protected SolrConfiguration solrConfiguration -
sandBoxHelper
-
-
Constructor Details
-
CatalogDocumentBuilderImpl
public CatalogDocumentBuilderImpl()
-
-
Method Details
-
buildDocument
public org.apache.solr.common.SolrInputDocument buildDocument(Indexable indexable, List<IndexField> fields, List<Locale> locales) - Specified by:
buildDocumentin interfaceDocumentBuilder
-
attachIndexableDocumentFields
protected void attachIndexableDocumentFields(org.apache.solr.common.SolrInputDocument document, Indexable indexable, List<IndexField> fields, List<Locale> locales) -
attachAdditionalDocumentFields
protected void attachAdditionalDocumentFields(Indexable indexable, org.apache.solr.common.SolrInputDocument document) -
attachBasicDocumentFields
protected void attachBasicDocumentFields(Indexable indexable, org.apache.solr.common.SolrInputDocument document) -
buildFullCategoryHierarchy
protected void buildFullCategoryHierarchy(org.apache.solr.common.SolrInputDocument document, CatalogStructure cache, Long categoryId, Set<Long> indexedParents) -
getPropertyValues
protected Map<String,Object> getPropertyValues(Indexable indexedItem, Field field, FieldType fieldType, List<Locale> locales) throws IllegalAccessException, InvocationTargetException, NoSuchMethodException -
convertDisplayOrderToLong
We multiply the BigDecimal by 1,000,000 to maintain any possible decimals in use the displayOrder value.- Parameters:
cache-displayOrderKey-- Returns:
-
modifyDocument
This is a simple hook point to allow implementors to override and modify the documents after the default functionality has created them.- Parameters:
indexable-fields-locales-
-