Interface GuestCartTokenValidator

  • All Known Implementing Classes:
    DefaultGuestCartTokenValidator

    public interface GuestCartTokenValidator
    Validator interface used for validating a guest token for a Cart.
    Author:
    Nick Crum (ncrum)
    • Method Detail

      • validateGuestTokenForCheckout

        void validateGuestTokenForCheckout​(String cartId,
                                           @Nullable
                                           String guestToken,
                                           @Nullable
                                           com.broadleafcommerce.data.tracking.core.context.ContextInfo contextInfo)
        Validates the provided guest token string for the given cart ID during checkout. This method will throw a runtime exception if the guest token is found to be invalid. Typically, this method will require the guest token to be non-null and valid.
        Parameters:
        cartId - the cart ID
        guestToken - the guest token
        contextInfo - the context info
      • validateGuestTokenForOperation

        void validateGuestTokenForOperation​(String cartId,
                                            @Nullable
                                            String guestToken,
                                            @Nullable
                                            com.broadleafcommerce.data.tracking.core.context.ContextInfo contextInfo)
        Validates the provided guest token string for the given cart ID during a cart operation. This method will throw a runtime exception if the guest token is found to be invalid. Typically, this method will treat a null guest token as valid.
        Parameters:
        cartId - the cart ID
        guestToken - the guest token
        contextInfo - the context info