Interface CartsConfiguration


public interface CartsConfiguration
CartsConfiguration
Example to create an instance using the builder pattern

     CartsConfiguration cartsConfiguration = CartsConfiguration.builder()
             .build()
 
  • Method Details

    • getDeleteDaysAfterLastModification

      Long getDeleteDaysAfterLastModification()

      Default value for the deleteDaysAfterLastModification parameter of the CartDraft and MyCartDraft. If a ChangeSubscription for Carts exists, a ResourceDeletedDeliveryPayload is sent upon deletion of a Cart.

      This field may not be present on Projects created before January 2020.

      Returns:
      deleteDaysAfterLastModification
    • getCountryTaxRateFallbackEnabled

      Boolean getCountryTaxRateFallbackEnabled()

      Indicates if country - no state Tax Rate fallback should be used when a shipping address state is not explicitly covered in the rates lists of all Tax Categories of a Cart Line Items. This field may not be present on Projects created before June 2020.

      Returns:
      countryTaxRateFallbackEnabled
    • getPriceRoundingMode

      RoundingMode getPriceRoundingMode()

      Default value for the priceRoundingMode parameter of the CartDraft. Indicates how the total prices on LineItems and CustomLineItems are rounded when calculated.

      Returns:
      priceRoundingMode
    • getTaxRoundingMode

      RoundingMode getTaxRoundingMode()

      Default value for the taxRoundingMode parameter of the CartDraft. Indicates how monetary values are rounded when calculating taxes for taxedPrice.

      Returns:
      taxRoundingMode
    • setDeleteDaysAfterLastModification

      void setDeleteDaysAfterLastModification(Long deleteDaysAfterLastModification)

      Default value for the deleteDaysAfterLastModification parameter of the CartDraft and MyCartDraft. If a ChangeSubscription for Carts exists, a ResourceDeletedDeliveryPayload is sent upon deletion of a Cart.

      This field may not be present on Projects created before January 2020.

      Parameters:
      deleteDaysAfterLastModification - value to be set
    • setCountryTaxRateFallbackEnabled

      void setCountryTaxRateFallbackEnabled(Boolean countryTaxRateFallbackEnabled)

      Indicates if country - no state Tax Rate fallback should be used when a shipping address state is not explicitly covered in the rates lists of all Tax Categories of a Cart Line Items. This field may not be present on Projects created before June 2020.

      Parameters:
      countryTaxRateFallbackEnabled - value to be set
    • setPriceRoundingMode

      void setPriceRoundingMode(RoundingMode priceRoundingMode)

      Default value for the priceRoundingMode parameter of the CartDraft. Indicates how the total prices on LineItems and CustomLineItems are rounded when calculated.

      Parameters:
      priceRoundingMode - value to be set
    • setTaxRoundingMode

      void setTaxRoundingMode(RoundingMode taxRoundingMode)

      Default value for the taxRoundingMode parameter of the CartDraft. Indicates how monetary values are rounded when calculating taxes for taxedPrice.

      Parameters:
      taxRoundingMode - value to be set
    • of

      static CartsConfiguration of()
      factory method
      Returns:
      instance of CartsConfiguration
    • of

      static CartsConfiguration of(CartsConfiguration template)
      factory method to create a shallow copy CartsConfiguration
      Parameters:
      template - instance to be copied
      Returns:
      copy instance
    • copyDeep

      CartsConfiguration copyDeep()
    • deepCopy

      @Nullable static CartsConfiguration deepCopy(@Nullable CartsConfiguration template)
      factory method to create a deep copy of CartsConfiguration
      Parameters:
      template - instance to be copied
      Returns:
      copy instance
    • builder

      static CartsConfigurationBuilder builder()
      builder factory method for CartsConfiguration
      Returns:
      builder
    • builder

      static CartsConfigurationBuilder builder(CartsConfiguration template)
      create builder for CartsConfiguration instance
      Parameters:
      template - instance with prefilled values for the builder
      Returns:
      builder
    • withCartsConfiguration

      default <T> T withCartsConfiguration(Function<CartsConfiguration,T> helper)
      accessor map function
      Type Parameters:
      T - mapped type
      Parameters:
      helper - function to map the object
      Returns:
      mapped value
    • typeReference

      static com.fasterxml.jackson.core.type.TypeReference<CartsConfiguration> typeReference()
      gives a TypeReference for usage with Jackson DataBind
      Returns:
      TypeReference