Class DefaultCustomerAddressService<P extends CustomerAddress>
- java.lang.Object
 - 
- com.broadleafcommerce.data.tracking.core.service.BaseCrudEntityService<P>
 - 
- com.broadleafcommerce.data.tracking.core.service.BaseRsqlCrudEntityService<P>
 - 
- com.broadleafcommerce.customer.service.DefaultCustomerAddressService<P>
 
 
 
 
- 
- All Implemented Interfaces:
 CustomerAddressService<P>,com.broadleafcommerce.data.tracking.core.service.CrudEntityService<P>,com.broadleafcommerce.data.tracking.core.service.RsqlCrudEntityService<P>
public class DefaultCustomerAddressService<P extends CustomerAddress> extends com.broadleafcommerce.data.tracking.core.service.BaseRsqlCrudEntityService<P> implements CustomerAddressService<P>
- Author:
 - Samarth Dhruva (samarthd)
 
 
- 
- 
Constructor Summary
Constructors Constructor Description DefaultCustomerAddressService(CustomerAddressRepository<com.broadleafcommerce.data.tracking.core.Trackable> repository, com.broadleafcommerce.data.tracking.core.service.RsqlCrudEntityHelper helper) 
- 
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description Pcreate(P customerAddress, com.broadleafcommerce.data.tracking.core.context.ContextInfo context)protected CustomerAddressRepository<com.broadleafcommerce.data.tracking.core.Trackable>getRepository()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.PreadByIdAndCustomerId(@NonNull String id, @NonNull String customerId, com.broadleafcommerce.data.tracking.core.context.ContextInfo contextInfo)Finds theCustomerAddresswhich has the given ID and parent customer ID.Preplace(@NonNull String customerAddressId, P customerAddress, com.broadleafcommerce.data.tracking.core.context.ContextInfo context)- 
Methods inherited from class com.broadleafcommerce.data.tracking.core.service.BaseRsqlCrudEntityService
getRsqlHelper, readAll, readAll, readAll, readAll 
- 
Methods inherited from class com.broadleafcommerce.data.tracking.core.service.BaseCrudEntityService
convertFromPersistentDomain, convertToPersistentDomain, createAll, createAllAllowingPartialSuccess, delete, getHelper, getSortPositionStrategy, readAll, readAll, readAll, readAllByContextId, readByContextId, replaceAll, replaceAllAllowingPartialSuccess, setSortPositionStrategy, update, updateAll, updateAllAllowingPartialSuccess, updateSort 
- 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait 
- 
Methods inherited from interface com.broadleafcommerce.data.tracking.core.service.CrudEntityService
createAll, createAllAllowingPartialSuccess, delete, readAll, readAll, readAll, readAllByContextId, readByContextId, replaceAll, replaceAllAllowingPartialSuccess, update, updateAll, updateAllAllowingPartialSuccess, updateSort 
 - 
 
 - 
 
- 
- 
Constructor Detail
- 
DefaultCustomerAddressService
public DefaultCustomerAddressService(CustomerAddressRepository<com.broadleafcommerce.data.tracking.core.Trackable> repository, com.broadleafcommerce.data.tracking.core.service.RsqlCrudEntityHelper helper)
 
 - 
 
- 
Method Detail
- 
create
@Transactional("customerTransactionManager") public P create(@NonNull P customerAddress, @Nullable com.broadleafcommerce.data.tracking.core.context.ContextInfo context)- Specified by:
 createin interfacecom.broadleafcommerce.data.tracking.core.service.CrudEntityService<P extends CustomerAddress>- Overrides:
 createin classcom.broadleafcommerce.data.tracking.core.service.BaseCrudEntityService<P extends CustomerAddress>
 
- 
replace
@Transactional("customerTransactionManager") public P replace(@NonNull @NonNull String customerAddressId, @NonNull P customerAddress, @Nullable com.broadleafcommerce.data.tracking.core.context.ContextInfo context)- Specified by:
 replacein interfacecom.broadleafcommerce.data.tracking.core.service.CrudEntityService<P extends CustomerAddress>- Overrides:
 replacein classcom.broadleafcommerce.data.tracking.core.service.BaseCrudEntityService<P extends CustomerAddress>
 
- 
readByCustomerContextId
public org.springframework.data.domain.Page<P> readByCustomerContextId(@NonNull @NonNull String customerContextId, @Nullable cz.jirutka.rsql.parser.ast.Node filters, @Nullable org.springframework.data.domain.Pageable page, @Nullable com.broadleafcommerce.data.tracking.core.context.ContextInfo contextInfo)
Description copied from interface:CustomerAddressServiceReads all of the CustomerAddress relationships in the database associated with the given customer context ID.- Specified by:
 readByCustomerContextIdin interfaceCustomerAddressService<P extends CustomerAddress>- 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
 
 
- 
readByIdAndCustomerId
public P readByIdAndCustomerId(@NonNull @NonNull String id, @NonNull @NonNull String customerId, @Nullable com.broadleafcommerce.data.tracking.core.context.ContextInfo contextInfo)
Description copied from interface:CustomerAddressServiceFinds theCustomerAddresswhich has the given ID and parent customer ID.- Specified by:
 readByIdAndCustomerIdin interfaceCustomerAddressService<P extends CustomerAddress>- 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
 
 
- 
getRepository
@NonNull protected CustomerAddressRepository<com.broadleafcommerce.data.tracking.core.Trackable> getRepository()
- Overrides:
 getRepositoryin classcom.broadleafcommerce.data.tracking.core.service.BaseCrudEntityService<P extends CustomerAddress>
 
 - 
 
 -