Class ExternalCreditAccountTransactionExecutionProvider

java.lang.Object
com.broadleafcommerce.cartoperation.service.provider.external.AbstractExternalProvider
com.broadleafcommerce.cartoperation.service.provider.external.payments.ExternalCreditAccountTransactionExecutionProvider
All Implemented Interfaces:
CreditAccountTransactionExecutionProvider

public class ExternalCreditAccountTransactionExecutionProvider extends AbstractExternalProvider implements CreditAccountTransactionExecutionProvider
The default implementation for CreditAccountTransactionExecutionProvider.
Author:
Dima Myroniuk (dmyroniuk)
  • Constructor Details

    • ExternalCreditAccountTransactionExecutionProvider

      public ExternalCreditAccountTransactionExecutionProvider(org.springframework.web.reactive.function.client.WebClient webClient, com.fasterxml.jackson.databind.ObjectMapper objectMapper, com.broadleafcommerce.common.extension.TypeFactory typeFactory, ExternalCreditAccountProperties properties)
  • Method Details

    • readCustomerStoreCreditAccount

      public CreditAccount readCustomerStoreCreditAccount(@NonNull @NonNull String customerId, @NonNull @NonNull String creditAccountNumber, @Nullable com.broadleafcommerce.data.tracking.core.context.ContextInfo contextInfo)
      Description copied from interface: CreditAccountTransactionExecutionProvider
      Reads the credit account for the specified customer id and account number.
      Specified by:
      readCustomerStoreCreditAccount in interface CreditAccountTransactionExecutionProvider
      Parameters:
      customerId - the customer id
      creditAccountNumber - the credit account number
      contextInfo - Context information around sandbox and multitenant state.
      Returns:
      the credit account number
    • readCustomerStoreCreditAccounts

      public org.springframework.data.domain.Page<CreditAccount> readCustomerStoreCreditAccounts(String customerId, List<String> creditAccountNumbers, @Nullable com.broadleafcommerce.data.tracking.core.context.ContextInfo contextInfo)
      Description copied from interface: CreditAccountTransactionExecutionProvider
      Reads the credit account for the specified customer id and account numbers.
      Specified by:
      readCustomerStoreCreditAccounts in interface CreditAccountTransactionExecutionProvider
      Parameters:
      customerId - the customer id
      creditAccountNumbers - the credit account numbers
      contextInfo - Context information around sandbox and multitenant state.
      Returns:
      the credit accounts
    • readCreditAccounts

      public org.springframework.data.domain.Page<CreditAccount> readCreditAccounts(List<String> creditAccountNumbers, @Nullable com.broadleafcommerce.data.tracking.core.context.ContextInfo contextInfo)
      Description copied from interface: CreditAccountTransactionExecutionProvider
      Reads the credit account for the specified account numbers.
      Specified by:
      readCreditAccounts in interface CreditAccountTransactionExecutionProvider
      Parameters:
      creditAccountNumbers - the credit account numbers
      contextInfo - Context information around sandbox and multitenant state.
      Returns:
      the credit accounts
    • getBaseUri

      protected org.springframework.web.util.UriComponentsBuilder getBaseUri()
      Gets the base URI common to all requests this provider will make.
      Returns:
      a URI components builder with the base URI set up
    • getServiceClient

      protected String getServiceClient()
    • getProperties

      protected ExternalCreditAccountProperties getProperties()