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 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 interface org.springframework.beans.factory.InitializingBean
    • setRepository

      @Autowired @Lazy public void setRepository(PromotionalCategoryProductRepository<D> repository)
    • 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 interface CustomizedPromotionalCategoryProductRepository<D extends JpaPromotionalCategoryProduct>
      Parameters:
      categoryContextId - the category context ID to find the relationships for
      contextInfo - context surrounding sandboxing and multitenant state
      Returns:
      the PromotionalCategoryProduct relationships in the database that match the given category context ID
    • buildCategoryContextIdFilter

      protected jakarta.persistence.criteria.Predicate buildCategoryContextIdFilter(String categoryContextId, jakarta.persistence.criteria.Root<D> promotionalCategoryProductEntity, jakarta.persistence.criteria.CriteriaBuilder criteriaBuilder, Map<String,Object> parameterValues)