|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object atg.nucleus.logging.VariableArgumentApplicationLoggingImpl atg.nucleus.GenericService atg.commerce.pricing.TaxProcessorTaxCalculator atg.commerce.pricing.AddressVerificationTaxProcessorTaxCalculator
public class AddressVerificationTaxProcessorTaxCalculator
An extension of the TaxProcessorTaxCalculator
which optionally verifies
the shipping address about to be taxed, the billing address about to be taxed,
or both. In determining whether shipping and billing addresses are valid,
The AddressVerificationTaxProcessorTaxCalculator
tests to see whether there is any
billing/shipping address at all, and then whether any of the required properties
(as defined in requiredBillingAddressProperties
and
requiredShippingAddressProperties
) is null.
An AddressVerificationTaxProcessorTaxCalculator defines the following properties:
Field Summary | |
---|---|
static java.lang.String |
CLASS_VERSION
Class version string |
Fields inherited from class atg.commerce.pricing.TaxProcessorTaxCalculator |
---|
DETAILED_ITEM_PRICE_TAX_PROPERTY |
Fields inherited from class atg.nucleus.GenericService |
---|
SERVICE_INFO_KEY |
Fields inherited from interface atg.nucleus.logging.TraceApplicationLogging |
---|
DEFAULT_LOG_TRACE_STATUS |
Fields inherited from interface atg.nucleus.logging.ApplicationLogging |
---|
DEFAULT_LOG_DEBUG_STATUS, DEFAULT_LOG_ERROR_STATUS, DEFAULT_LOG_INFO_STATUS, DEFAULT_LOG_WARNING_STATUS |
Constructor Summary | |
---|---|
AddressVerificationTaxProcessorTaxCalculator()
|
Method Summary | |
---|---|
protected void |
calculateTax(TaxRequestInfo pTRI,
TaxPriceInfo pPriceQuote,
Order pOrder,
RepositoryItem pPricingModel,
java.util.Locale pLocale,
RepositoryItem pProfile,
java.util.Map pExtraParameters)
Given the input TaxRequestInfo object, modify the input pPriceQuote object to reflect the current tax. |
protected void |
calculateTaxByShipping(TaxRequestInfo pTRI,
TaxPriceInfo pPriceQuote,
Order pOrder,
RepositoryItem pPricingModel,
java.util.Locale pLocale,
RepositoryItem pProfile,
java.util.Map pExtraParameters)
Given the input TaxRequestInfo object, modify the input pPriceQuote object to reflect the current tax. |
java.lang.String[] |
getRequiredBillingAddressProperties()
the properties of a billing address which are required to not be null |
java.lang.String[] |
getRequiredShippingAddressProperties()
the properties of a shipping address which are required to not be null |
boolean |
getThrowVerificationException()
flag that determines whether this calculator should throw a descriptive exception upon address verification failure. |
boolean |
isThrowVerificationException()
Test property ThrowVerificationException |
boolean |
isVerifyBillingAddress()
Test property VerifyBillingAddress |
boolean |
isVerifyShippingAddress()
Test property VerifyShippingAddress |
void |
setRequiredBillingAddressProperties(java.lang.String[] pRequiredBillingAddressProperties)
the properties of a billing address which are required to not be null |
void |
setRequiredShippingAddressProperties(java.lang.String[] pRequiredShippingAddressProperties)
the properties of a shipping address which are required to not be null |
void |
setThrowVerificationException(boolean pThrowVerificationException)
flag that determines whether this calculator should throw a descriptive exception upon address verification failure. |
void |
setVerifyBillingAddress(boolean pVerifyBillingAddress)
flag that determines whether this calculator should verify the billing address before asking the taxprocessor to tax it. |
void |
setVerifyShippingAddress(boolean pVerifyShippingAddress)
flag that determines whether this calculator should verify the shipping address before asking the taxprocessor to tax it. |
protected boolean |
verifyBillingAddress(TaxRequestInfo pTRI)
verifies that the billing address is not null, and that no crucial properties of the billing address are null. |
protected boolean |
verifyShippingAddress(TaxRequestInfo pTRI)
verifies that each shipping address is not null, and that no crucial properties of any shipping address are null. |
Methods inherited from class atg.nucleus.logging.VariableArgumentApplicationLoggingImpl |
---|
vlogDebug, vlogDebug, vlogDebug, vlogDebug, vlogError, vlogError, vlogError, vlogError, vlogInfo, vlogInfo, vlogInfo, vlogInfo, vlogTrace, vlogTrace, vlogTrace, vlogTrace, vlogWarning, vlogWarning, vlogWarning, vlogWarning |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static java.lang.String CLASS_VERSION
Constructor Detail |
---|
public AddressVerificationTaxProcessorTaxCalculator()
Method Detail |
---|
public void setVerifyBillingAddress(boolean pVerifyBillingAddress)
pVerifyBillingAddress
- new value to setpublic boolean isVerifyBillingAddress()
public void setVerifyShippingAddress(boolean pVerifyShippingAddress)
pVerifyShippingAddress
- new value to setpublic boolean isVerifyShippingAddress()
public void setThrowVerificationException(boolean pThrowVerificationException)
pThrowVerificationException
- new value to setpublic boolean getThrowVerificationException()
public boolean isThrowVerificationException()
public void setRequiredBillingAddressProperties(java.lang.String[] pRequiredBillingAddressProperties)
pRequiredBillingAddressProperties
- new value to setpublic java.lang.String[] getRequiredBillingAddressProperties()
public void setRequiredShippingAddressProperties(java.lang.String[] pRequiredShippingAddressProperties)
pRequiredShippingAddressProperties
- new value to setpublic java.lang.String[] getRequiredShippingAddressProperties()
protected void calculateTax(TaxRequestInfo pTRI, TaxPriceInfo pPriceQuote, Order pOrder, RepositoryItem pPricingModel, java.util.Locale pLocale, RepositoryItem pProfile, java.util.Map pExtraParameters) throws PricingException
super.calculateTax()
calculateTax
in class TaxProcessorTaxCalculator
pTRI
- the TaxRequestInfo object which represents a request from a TaxProcessor
for a tax calculation. Required.pPriceQuote
- the TaxPriceInfo to modify to reflect the calculated tax. Required.pOrder
- the order for which tax is being calculated. Optional.pPricingModel
- the pricing model which is modifying the tax total. Optional.
Not used in DCS at this time.pLocale
- the local in which the tax should be calculated. Optional.pProfile
- the person for whom the tax is being calculated. Optional.pExtraParameters
- any extra information needed to calculate tax. Optional.
PricingException
- if there was a problem determining the taxprotected void calculateTaxByShipping(TaxRequestInfo pTRI, TaxPriceInfo pPriceQuote, Order pOrder, RepositoryItem pPricingModel, java.util.Locale pLocale, RepositoryItem pProfile, java.util.Map pExtraParameters) throws PricingException
super.calculateTaxByShipping()
calculateTaxByShipping
in class TaxProcessorTaxCalculator
pTRI
- the TaxRequestInfo object which represents a request from a TaxProcessor
for a tax calculation. Required.pPriceQuote
- the TaxPriceInfo to modify to reflect the calculated tax. Required.pOrder
- the order for which tax is being calculated. Optional.pPricingModel
- the pricing model which is modifying the tax total. Optional.
Not used in DCS at this time.pLocale
- the local in which the tax should be calculated. Optional.pProfile
- the person for whom the tax is being calculated. Optional.pExtraParameters
- any extra information needed to calculate tax. Optional.
PricingException
protected boolean verifyBillingAddress(TaxRequestInfo pTRI) throws PricingException
pTRI
- the TaxRequestInfo containing the billing address to verify
PricingException
- if there was a problem verifying the billing addressprotected boolean verifyShippingAddress(TaxRequestInfo pTRI) throws PricingException
pTRI
- the TaxRequestInfo containing the shipping address to verify
PricingException
- if there was a problem verifying the shipping address
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |