Class DefaultFacetGroupService<P extends com.broadleafcommerce.search.api.domain.FacetGroup>
java.lang.Object
com.broadleafcommerce.data.tracking.core.service.BaseCrudEntityService<P>
com.broadleafcommerce.data.tracking.core.service.BaseRsqlCrudEntityService<P>
com.broadleafcommerce.search.core.service.facetgroup.DefaultFacetGroupService<P>
- All Implemented Interfaces:
com.broadleafcommerce.data.tracking.core.service.CrudEntityService<P>,com.broadleafcommerce.data.tracking.core.service.RsqlCrudEntityService<P>,FacetGroupService<P>
public class DefaultFacetGroupService<P extends com.broadleafcommerce.search.api.domain.FacetGroup>
extends com.broadleafcommerce.data.tracking.core.service.BaseRsqlCrudEntityService<P>
implements FacetGroupService<P>
-
Field Summary
Fields -
Constructor Summary
ConstructorsConstructorDescriptionDefaultFacetGroupService(FacetGroupRepository<com.broadleafcommerce.data.tracking.core.Trackable> repository, com.broadleafcommerce.data.tracking.core.service.RsqlCrudEntityHelper helper, com.broadleafcommerce.common.extension.cache.CacheStateManager cacheStateManager) -
Method Summary
Modifier and TypeMethodDescriptionprotected com.broadleafcommerce.common.extension.cache.CacheStateManagerprotected FacetGroupRepository<com.broadleafcommerce.data.tracking.core.Trackable>Returns the name of the repository domain corresponding to the projection domain.org.springframework.data.domain.Page<P>readAllByName(String name, cz.jirutka.rsql.parser.ast.Node filters, org.springframework.data.domain.Pageable page, com.broadleafcommerce.data.tracking.core.context.ContextInfo context) Retrieves a page of facets by namereadByContextIdAndNotArchived(String contextId, com.broadleafcommerce.data.tracking.core.context.ContextInfo contextInfo) Reads the non-archived facet group by its context IDMethods inherited from class com.broadleafcommerce.data.tracking.core.service.BaseRsqlCrudEntityService
getRsqlHelper, readAll, readAll, readAll, readAllMethods inherited from class com.broadleafcommerce.data.tracking.core.service.BaseCrudEntityService
convertFromPersistentDomain, convertToPersistentDomain, create, createAll, createAllAllowingPartialSuccess, delete, getHelper, getSortPositionStrategy, readAll, readAll, readAll, readAllByContextId, readByContextId, replace, replaceAll, replaceAllAllowingPartialSuccess, setSortPositionStrategy, update, updateAll, updateAllAllowingPartialSuccess, updateSortMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface com.broadleafcommerce.data.tracking.core.service.CrudEntityService
create, createAll, createAllAllowingPartialSuccess, delete, readAll, readAll, readAll, readAllByContextId, readByContextId, replace, replaceAll, replaceAllAllowingPartialSuccess, update, updateAll, updateAllAllowingPartialSuccess, updateSortMethods inherited from interface com.broadleafcommerce.data.tracking.core.service.RsqlCrudEntityService
readAll, readAll, readAll, readAll
-
Field Details
-
CACHE_FACET_GROUP_BY_CONTEXT_ID
- See Also:
-
-
Constructor Details
-
DefaultFacetGroupService
public DefaultFacetGroupService(FacetGroupRepository<com.broadleafcommerce.data.tracking.core.Trackable> repository, com.broadleafcommerce.data.tracking.core.service.RsqlCrudEntityHelper helper, com.broadleafcommerce.common.extension.cache.CacheStateManager cacheStateManager)
-
-
Method Details
-
readAllByName
public org.springframework.data.domain.Page<P> readAllByName(@Nullable String name, @Nullable cz.jirutka.rsql.parser.ast.Node filters, @Nullable org.springframework.data.domain.Pageable page, @Nullable com.broadleafcommerce.data.tracking.core.context.ContextInfo context) Description copied from interface:FacetGroupServiceRetrieves a page of facets by name- Specified by:
readAllByNamein interfaceFacetGroupService<P extends com.broadleafcommerce.search.api.domain.FacetGroup>- Parameters:
name- the label field being queriedfilters- additional filters to apply in the query.page- describes the page of results to returncontext- context information around sandbox and multitenant state- Returns:
- a paged list of facets matching the label string
-
readByContextIdAndNotArchived
public Optional<P> readByContextIdAndNotArchived(String contextId, @Nullable com.broadleafcommerce.data.tracking.core.context.ContextInfo contextInfo) Description copied from interface:FacetGroupServiceReads the non-archived facet group by its context ID- Specified by:
readByContextIdAndNotArchivedin interfaceFacetGroupService<P extends com.broadleafcommerce.search.api.domain.FacetGroup>- Parameters:
contextId- the contextId to filter oncontextInfo- context information around sandbox and multitenant state- Returns:
- the non-archived facet group, if it exists
-
getRepositoryDomain
Description copied from interface:FacetGroupServiceReturns the name of the repository domain corresponding to the projection domain.- Specified by:
getRepositoryDomainin interfaceFacetGroupService<P extends com.broadleafcommerce.search.api.domain.FacetGroup>- Returns:
- The name of the repository domain corresponding to the projection domain.
-
getRepository
- Overrides:
getRepositoryin classcom.broadleafcommerce.data.tracking.core.service.BaseCrudEntityService<P extends com.broadleafcommerce.search.api.domain.FacetGroup>
-
getCacheStateManager
@Nullable protected com.broadleafcommerce.common.extension.cache.CacheStateManager getCacheStateManager()
-