Interface CustomerAddressService<P extends CustomerAddress>
-
- All Superinterfaces:
com.broadleafcommerce.data.tracking.core.service.CrudEntityService<P>,com.broadleafcommerce.data.tracking.core.service.RsqlCrudEntityService<P>
- All Known Implementing Classes:
DefaultCustomerAddressService
public interface CustomerAddressService<P extends CustomerAddress> extends com.broadleafcommerce.data.tracking.core.service.RsqlCrudEntityService<P>Service API forCustomerAddresss. Supported byCustomerAddressRepository.- Author:
- Chris Kittrell (ckittrell)
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description org.springframework.data.domain.Page<P>readByCustomerContextId(String customerContextId, cz.jirutka.rsql.parser.ast.Node filters, org.springframework.data.domain.Pageable page, com.broadleafcommerce.data.tracking.core.context.ContextInfo contextInfo)Reads all of the CustomerAddress relationships in the database associated with the given customer context ID.List<P>readByCustomerIdIn(Set<String> customerIds, com.broadleafcommerce.data.tracking.core.context.ContextInfo contextInfo)Reads all customer addresses in the datastore associated with the given customer IDs.PreadByIdAndCustomerId(String id, String customerId, com.broadleafcommerce.data.tracking.core.context.ContextInfo contextInfo)Finds theCustomerAddresswhich has the given ID and parent customer ID.-
Methods 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, updateSort
-
-
-
-
Method Detail
-
readByCustomerContextId
@NonNull org.springframework.data.domain.Page<P> readByCustomerContextId(@NonNull String customerContextId, cz.jirutka.rsql.parser.ast.Node filters, org.springframework.data.domain.Pageable page, com.broadleafcommerce.data.tracking.core.context.ContextInfo contextInfo)
Reads all of the CustomerAddress relationships in the database associated with the given customer context ID.- Parameters:
customerContextId- the customer context ID to find the relationships forfilters- additional filters to apply in the query. Should beEmptyNodeif no additional filters should be applied.page- the requested page of results from the databasecontextInfo- the context to query within- Returns:
- the CustomerAddress relationships in the database that match the given customer context ID
-
readByCustomerIdIn
List<P> readByCustomerIdIn(@NonNull Set<String> customerIds, @Nullable com.broadleafcommerce.data.tracking.core.context.ContextInfo contextInfo)
Reads all customer addresses in the datastore associated with the given customer IDs.- Parameters:
customerIds- all customer IDs to find addresses forcontextInfo- context around multitenant state- Returns:
- a list of customer address relationships in the datastore matching the given customer IDs
- See Also:
CustomerAddress.getCustomerRef(),CustomerRef.getId()
-
readByIdAndCustomerId
@NonNull P readByIdAndCustomerId(@NonNull String id, @NonNull String customerId, com.broadleafcommerce.data.tracking.core.context.ContextInfo contextInfo)
Finds theCustomerAddresswhich has the given ID and parent customer ID.- Parameters:
id- the context ID of theCustomerAddresscustomerId- the context ID of the parentCustomercontextInfo- context surrounding sandboxing and multitenant state- Returns:
- the customer address that has the given ID and parent customer ID
- Throws:
com.broadleafcommerce.data.tracking.core.exception.EntityMissingException- if no suchCustomerAddresswas found
-
-