public interface ItemListAccessRuleProvider<P extends com.broadleafcommerce.cart.client.domain.ItemListAccessRule>
| Modifier and Type | Method and Description |
|---|---|
P |
createItemListAccessRule(P rule,
com.broadleafcommerce.data.tracking.core.context.ContextInfo context)
Create an item list access rule.
|
List<P> |
createItemListAccessRules(String itemListId,
List<P> rules,
com.broadleafcommerce.data.tracking.core.context.ContextInfo context)
Creates item list access rules.
|
void |
deleteItemListAccessRule(String itemListId,
String ruleId,
com.broadleafcommerce.data.tracking.core.context.ContextInfo context)
Deletes an item list access rule by ID.
|
void |
deleteItemListAccessRules(String itemListId,
Set<String> ruleIds,
com.broadleafcommerce.data.tracking.core.context.ContextInfo context)
Deletes item list access rules by IDs.
|
Optional<P> |
getItemListAccessRuleForCustomerAndItemList(com.broadleafcommerce.cart.client.domain.CustomerRef customerRef,
String itemListId,
com.broadleafcommerce.data.tracking.core.context.ContextInfo context)
Get an item list access rule for a customer for specific list.
|
org.springframework.data.domain.Page<P> |
getItemListAccessRulesForCustomer(com.broadleafcommerce.cart.client.domain.CustomerRef customerRef,
org.springframework.data.domain.Pageable pageable,
com.broadleafcommerce.data.tracking.core.context.ContextInfo context)
Get item list access rules by customer.
|
P |
replaceItemListAccessRule(String itemListId,
P rule,
com.broadleafcommerce.data.tracking.core.context.ContextInfo context)
Replaces an item list access rule.
|
P |
updateItemListAccessRule(String itemListId,
P rule,
com.broadleafcommerce.data.tracking.core.context.ContextInfo context)
Updates an item list access rule.
|
com.broadleafcommerce.cart.client.domain.ItemListAccessResponse |
validateCustomerAccess(com.broadleafcommerce.cart.client.domain.CustomerRef customerRef,
Set<String> itemListIds,
Set<String> roles,
com.broadleafcommerce.data.tracking.core.context.ContextInfo context)
Checks item list access rules for a list of item list ids based on the given customer ref and
role
|
org.springframework.data.domain.Page<P> getItemListAccessRulesForCustomer(com.broadleafcommerce.cart.client.domain.CustomerRef customerRef, @Nullable org.springframework.data.domain.Pageable pageable, @Nullable com.broadleafcommerce.data.tracking.core.context.ContextInfo context)
customerRef - the reference to the customer for which to find rules forpageable - the requested page of access rulescontext - the context of the requestcom.broadleafcommerce.cart.client.domain.ItemListAccessResponse validateCustomerAccess(com.broadleafcommerce.cart.client.domain.CustomerRef customerRef,
Set<String> itemListIds,
Set<String> roles,
@Nullable
com.broadleafcommerce.data.tracking.core.context.ContextInfo context)
customerRef - the customer to check access foritemListIds - the list of item list ids to checkroles - the access roles we want to verifycontext - the context of the requestOptional<P> getItemListAccessRuleForCustomerAndItemList(com.broadleafcommerce.cart.client.domain.CustomerRef customerRef, String itemListId, @Nullable com.broadleafcommerce.data.tracking.core.context.ContextInfo context)
customerRef - the reference to the customer for which to find the rule foritemListId - the ID of the item list to find the rule forcontext - the context of the requestP createItemListAccessRule(P rule, @Nullable com.broadleafcommerce.data.tracking.core.context.ContextInfo context)
rule - the rule to create (must contain item list ID)context - the context of the requestList<P> createItemListAccessRules(String itemListId, List<P> rules, @Nullable com.broadleafcommerce.data.tracking.core.context.ContextInfo context)
itemListId - the item list IDrules - the rules to create (must belong to the same item list)context - the context of the requestP updateItemListAccessRule(String itemListId, P rule, @Nullable com.broadleafcommerce.data.tracking.core.context.ContextInfo context)
itemListId - the item list IDrule - the rule to update with (must include ID)context - the context of the requestP replaceItemListAccessRule(String itemListId, P rule, @Nullable com.broadleafcommerce.data.tracking.core.context.ContextInfo context)
itemListId - the item list IDrule - the rule to replace with (must include ID)context - the context of the requestvoid deleteItemListAccessRule(String itemListId, String ruleId, @Nullable com.broadleafcommerce.data.tracking.core.context.ContextInfo context)
itemListId - the ID of the item list to delete fromruleId - the ID of the access rulecontext - the context of the requestvoid deleteItemListAccessRules(String itemListId, Set<String> ruleIds, @Nullable com.broadleafcommerce.data.tracking.core.context.ContextInfo context)
itemListId - the ID of the item list to delete fromruleIds - the IDs of the rules to deletecontext - the context of the requestCopyright © 2021. All rights reserved.