Class JpaCustomizedPromotionalCategoryProductRepository<D extends JpaPromotionalCategoryProduct>
java.lang.Object
com.broadleafcommerce.catalog.provider.jpa.repository.JpaCustomizedPromotionalCategoryProductRepository<D>
- All Implemented Interfaces:
CustomizedPromotionalCategoryProductRepository<D>
,org.springframework.beans.factory.InitializingBean
public class JpaCustomizedPromotionalCategoryProductRepository<D extends JpaPromotionalCategoryProduct>
extends Object
implements CustomizedPromotionalCategoryProductRepository<D>, org.springframework.beans.factory.InitializingBean
- Author:
- Samarth Dhruva (samarthd)
-
Constructor Summary
ConstructorDescriptionJpaCustomizedPromotionalCategoryProductRepository
(com.broadleafcommerce.data.tracking.core.TrackableBehaviorUtil behaviorUtil, com.broadleafcommerce.data.tracking.jpa.filtering.fetch.rsql.JpaFiltersCriteriaBuilder catalogFilterRuleCriteriaBuilder, com.broadleafcommerce.common.jpa.RepositoryEntityTypeManager repositoryEntityTypeManager) -
Method Summary
Modifier and TypeMethodDescriptionvoid
protected jakarta.persistence.criteria.Predicate
buildCategoryContextIdFilter
(String categoryContextId, jakarta.persistence.criteria.Root<D> promotionalCategoryProductEntity, jakarta.persistence.criteria.CriteriaBuilder criteriaBuilder, Map<String, Object> parameterValues) findByCategoryContextId
(String categoryContextId, com.broadleafcommerce.data.tracking.core.context.ContextInfo contextInfo) Finds all of the PromotionalCategoryProduct relationships in the database associated with the given category context ID.void
setRepository
(PromotionalCategoryProductRepository<D> repository)
-
Constructor Details
-
JpaCustomizedPromotionalCategoryProductRepository
public JpaCustomizedPromotionalCategoryProductRepository(com.broadleafcommerce.data.tracking.core.TrackableBehaviorUtil behaviorUtil, com.broadleafcommerce.data.tracking.jpa.filtering.fetch.rsql.JpaFiltersCriteriaBuilder catalogFilterRuleCriteriaBuilder, com.broadleafcommerce.common.jpa.RepositoryEntityTypeManager repositoryEntityTypeManager)
-
-
Method Details
-
afterPropertiesSet
public void afterPropertiesSet()- Specified by:
afterPropertiesSet
in interfaceorg.springframework.beans.factory.InitializingBean
-
setRepository
-
findByCategoryContextId
@Policy(operationTypes=READ) @NonNull public Stream<D> findByCategoryContextId(@NonNull String categoryContextId, @Nullable com.broadleafcommerce.data.tracking.core.context.ContextInfo contextInfo) Description copied from interface:CustomizedPromotionalCategoryProductRepository
Finds all of the PromotionalCategoryProduct relationships in the database associated with the given category context ID.- Specified by:
findByCategoryContextId
in interfaceCustomizedPromotionalCategoryProductRepository<D extends JpaPromotionalCategoryProduct>
- Parameters:
categoryContextId
- the category context ID to find the relationships forcontextInfo
- context surrounding sandboxing and multitenant state- Returns:
- the PromotionalCategoryProduct relationships in the database that match the given category context ID
-
buildCategoryContextIdFilter
-