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 for CustomerAddresss. Supported by CustomerAddressRepository.
    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.
      P readByIdAndCustomerId​(String id, String customerId, com.broadleafcommerce.data.tracking.core.context.ContextInfo contextInfo)
      Finds the CustomerAddress which 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
      • Methods inherited from interface com.broadleafcommerce.data.tracking.core.service.RsqlCrudEntityService

        readAll, readAll, readAll, readAll
    • 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 for
        filters - additional filters to apply in the query. Should be EmptyNode if no additional filters should be applied.
        page - the requested page of results from the database
        contextInfo - the context to query within
        Returns:
        the CustomerAddress relationships in the database that match the given customer context ID
      • readByIdAndCustomerId

        @NonNull
        P readByIdAndCustomerId​(@NonNull
                                String id,
                                @NonNull
                                String customerId,
                                com.broadleafcommerce.data.tracking.core.context.ContextInfo contextInfo)
        Finds the CustomerAddress which has the given ID and parent customer ID.
        Parameters:
        id - the context ID of the CustomerAddress
        customerId - the context ID of the parent Customer
        contextInfo - 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 such CustomerAddress was found