Class SimpleTaxProvider<T1 extends TaxRequest,​T2 extends TaxResponse>

  • All Implemented Interfaces:
    TaxProvider<T1,​T2>

    public class SimpleTaxProvider<T1 extends TaxRequest,​T2 extends TaxResponse>
    extends Object
    implements TaxProvider<T1,​T2>
    Simple implementation of TaxProvider primarily used for estimating taxes, but can be used for providing full taxes for implementors without complex tax needs. Otherwise, a TaxProvider integrated with a 3rd party, such as Avalara, is preferred. If this simple provider is intended to be used in a live production environment, the implementor must be aware that they own the consequences of tax law and must maintain the tax configuration details.

    This takes in a SimpleTaxConfig provided by SimpleTaxProperties.getConfigPath(). This property can be configured with Spring Config Server, including Broadleaf's own implementation. This will allow changes to the property value to be reinitialized by this provider, as long as the declaring bean for this provider is annotated with RefreshScope.

    Author:
    Chad Harchar (charchar)