|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectcom.elasticpath.domain.impl.AbstractEpDomainImpl
com.elasticpath.domain.impl.AbstractPersistenceImpl
com.elasticpath.domain.impl.AbstractEntityImpl
com.elasticpath.domain.tax.impl.TaxJurisdictionImpl
public class TaxJurisdictionImpl
A TaxJurisdiction represents a geographic area that has it's own distinct set of TaxCategorys and TaxValues ie a
Country, a State, a City, a Municipal, or a County.
| Field Summary | |
|---|---|
static long |
serialVersionUID
Serial version id. |
| Fields inherited from interface com.elasticpath.domain.tax.TaxJurisdiction |
|---|
FIELD_MATCH_CITY, FIELD_MATCH_COUNTRY, FIELD_MATCH_NONE, FIELD_MATCH_SUBCOUNTRY, FIELD_MATCH_ZIP_POSTAL_CODE, PRICE_CALCULATION_EXCLUSIVE, PRICE_CALCULATION_INCLUSIVE |
| Constructor Summary | |
|---|---|
TaxJurisdictionImpl()
|
|
| Method Summary | |
|---|---|
int |
getFieldMatchType()
Retrieve the field match type for this TaxJurisdiction. |
java.util.Map |
getFullTaxValueMap()
Traverse the parent TaxJurisdiction and build up a map of taxValues, keyed by TaxCategory. |
TaxJurisdiction |
getParent()
Get the parent taxJurisdiction of this taxJurisdiction. |
java.lang.Boolean |
getPriceCalculationMethod()
Return the price calculation method of this TaxJurisdiction. |
java.lang.String |
getRegionCode()
Get the region code of the geographic area represented by the TaxJurisdiction. |
java.lang.String |
getRegionCodePathStr()
Retrieve the region path of this taxJurisdiction, i.e. |
java.lang.String |
getRegionCodePathStrWithoutCity()
Retrieve the region path of this taxJurisdiction, i.e. |
java.util.Map |
getTaxCategoryXMap()
Get the taxCategoryUid -> TaxJurisdictionCategoryX map. |
boolean |
isParent(TaxJurisdiction taxJurisdiction)
Check if this taxJurisdiction is the direct or indirect parent of the given taxJurisdiction. |
void |
setDefaultValues()
Set default values for those fields that need default values. |
void |
setFieldMatchType(int fieldMatchType)
Set the field match type for this TaxJurisdiction. |
void |
setParent(TaxJurisdiction parent)
Set the parent taxJurisdiction of this taxJurisdiction. |
void |
setPriceCalculationMethod(java.lang.Boolean priceCalculationMethod)
Set the price calculation method of this TaxJurisdiction. |
void |
setRegionCode(java.lang.String regionCode)
Set the region code of the geographic area represented by the TaxJurisdiction. |
void |
setTaxCategoryXMap(java.util.Map taxCategoryXMap)
Set the taxCategoryUid -> TaxJurisdictionCategoryX map. |
| Methods inherited from class com.elasticpath.domain.impl.AbstractEntityImpl |
|---|
convertAttributeGroupAttributes, getGuid, setGuid |
| Methods inherited from class com.elasticpath.domain.impl.AbstractPersistenceImpl |
|---|
executeBeforePersistAction, getUidPk, isPersistent, setUidPk |
| Methods inherited from class com.elasticpath.domain.impl.AbstractEpDomainImpl |
|---|
getElasticPath, setElasticPath |
| Methods inherited from class java.lang.Object |
|---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Methods inherited from interface com.elasticpath.domain.Entity |
|---|
getGuid, setGuid |
| Methods inherited from interface com.elasticpath.domain.Persistence |
|---|
executeBeforePersistAction, getUidPk, isPersistent, setUidPk |
| Methods inherited from interface com.elasticpath.domain.EpDomain |
|---|
getElasticPath, setElasticPath |
| Field Detail |
|---|
public static final long serialVersionUID
| Constructor Detail |
|---|
public TaxJurisdictionImpl()
| Method Detail |
|---|
public int getFieldMatchType()
TaxJurisdiction.
getFieldMatchType in interface TaxJurisdictionTaxJurisdiction.public java.util.Map getFullTaxValueMap()
TaxJurisdiction and build up a map of taxValues, keyed by TaxCategory. The
TaxValue specified at a lower taxJurisdiction level will be used. Since the tax value configuration should not be changed so
often, so it is cached.
getFullTaxValueMap in interface TaxJurisdictionpublic TaxJurisdiction getParent()
getParent in interface TaxJurisdictionpublic java.lang.Boolean getPriceCalculationMethod()
TaxJurisdiction. If this is not taxJurisdiction at the country level, get the
priceCalculationMethod from its country level parent.
getPriceCalculationMethod in interface TaxJurisdictionpublic java.lang.String getRegionCode()
TaxJurisdiction.
getRegionCode in interface TaxJurisdictionpublic java.lang.String getRegionCodePathStr()
getRegionCodePathStr in interface TaxJurisdictionpublic java.lang.String getRegionCodePathStrWithoutCity()
TaxJurisdiction's field match type is 3
(FIELD_MATCH_CITY).
getRegionCodePathStrWithoutCity in interface TaxJurisdictionpublic java.util.Map getTaxCategoryXMap()
TaxJurisdictionCategoryX map.
getTaxCategoryXMap in interface TaxJurisdictionTaxJurisdictionCategoryX map.public boolean isParent(TaxJurisdiction taxJurisdiction)
isParent in interface TaxJurisdictiontaxJurisdiction - the taxJurisdiction to be checked to see if it is the direct/indirect child.
public void setDefaultValues()
setDefaultValues in interface PersistencesetDefaultValues in class AbstractEntityImplpublic void setFieldMatchType(int fieldMatchType)
TaxJurisdiction.
setFieldMatchType in interface TaxJurisdictionfieldMatchType - the field match type.public void setParent(TaxJurisdiction parent)
setParent in interface TaxJurisdictionparent - - the parent taxJurisdiction.public void setPriceCalculationMethod(java.lang.Boolean priceCalculationMethod)
TaxJurisdiction. Only the priceCalculationMethod set at the country level
TaxJurisdiction will be used during tax/price calculation.
setPriceCalculationMethod in interface TaxJurisdictionpriceCalculationMethod - - the price calculation method to be set.public void setRegionCode(java.lang.String regionCode)
TaxJurisdiction.
setRegionCode in interface TaxJurisdictionregionCode - the parameter regionCodepublic void setTaxCategoryXMap(java.util.Map taxCategoryXMap)
TaxJurisdictionCategoryX map.
setTaxCategoryXMap in interface TaxJurisdictiontaxCategoryXMap - - the taxCategoryUid -> TaxJurisdictionCategoryX map.
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||