Class TaxRateDraftImpl
- All Implemented Interfaces:
TaxRateDraft
,io.vrap.rmf.base.client.Draft<TaxRateDraft>
,io.vrap.rmf.base.client.ModelBase
-
Nested Class Summary
Nested classes/interfaces inherited from interface io.vrap.rmf.base.client.ModelBase
io.vrap.rmf.base.client.ModelBase.FilteredRecursiveToStringStyle
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionboolean
Tax rate.Country in which the tax rate is applied in ISO 3166-1 alpha-2 format.Iftrue
, tax is included in Embedded Prices or Standalone Prices, and thetaxedPrice
is present on LineItems.getKey()
User-defined unique identifier of the TaxRate.getName()
Name of the TaxRate.getState()
State within the country, such as Texas in the United States.Used to calculate the taxPortions field in a Cart or Order.int
hashCode()
void
Tax rate.void
setCountry
(String country) Country in which the tax rate is applied in ISO 3166-1 alpha-2 format.void
setIncludedInPrice
(Boolean includedInPrice) Iftrue
, tax is included in Embedded Prices or Standalone Prices, and thetaxedPrice
is present on LineItems.void
User-defined unique identifier of the TaxRate.void
Name of the TaxRate.void
State within the country, such as Texas in the United States.void
setSubRates
(SubRate... subRates) Used to calculate the taxPortions field in a Cart or Order.void
setSubRates
(List<SubRate> subRates) Used to calculate the taxPortions field in a Cart or Order.Methods inherited from class java.lang.Object
getClass, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface io.vrap.rmf.base.client.ModelBase
reflectionString, reflectionString
Methods inherited from interface com.commercetools.api.models.tax_category.TaxRateDraft
withTaxRateDraft
-
Constructor Details
-
TaxRateDraftImpl
public TaxRateDraftImpl()create empty instance
-
-
Method Details
-
getName
Name of the TaxRate.
- Specified by:
getName
in interfaceTaxRateDraft
- Returns:
- name
-
getAmount
Tax rate. Must be supplied if no
subRates
are specified. IfsubRates
are specified, this field can be omitted or it must be the sum of amounts of allsubRates
.- Specified by:
getAmount
in interfaceTaxRateDraft
- Returns:
- amount
-
getIncludedInPrice
If
true
, tax is included in Embedded Prices or Standalone Prices, and thetaxedPrice
is present on LineItems. In this case, thetotalNet
price on TaxedPrice includes the TaxRate.- Specified by:
getIncludedInPrice
in interfaceTaxRateDraft
- Returns:
- includedInPrice
-
getCountry
Country in which the tax rate is applied in ISO 3166-1 alpha-2 format.
- Specified by:
getCountry
in interfaceTaxRateDraft
- Returns:
- country
-
getState
State within the country, such as Texas in the United States.
- Specified by:
getState
in interfaceTaxRateDraft
- Returns:
- state
-
getSubRates
Used to calculate the taxPortions field in a Cart or Order. It is useful if the total tax of a country (such as the US) is a combination of multiple taxes (such as state and local taxes).
- Specified by:
getSubRates
in interfaceTaxRateDraft
- Returns:
- subRates
-
getKey
User-defined unique identifier of the TaxRate.
- Specified by:
getKey
in interfaceTaxRateDraft
- Returns:
- key
-
setName
Description copied from interface:TaxRateDraft
Name of the TaxRate.
- Specified by:
setName
in interfaceTaxRateDraft
- Parameters:
name
- value to be set
-
setAmount
Description copied from interface:TaxRateDraft
Tax rate. Must be supplied if no
subRates
are specified. IfsubRates
are specified, this field can be omitted or it must be the sum of amounts of allsubRates
.- Specified by:
setAmount
in interfaceTaxRateDraft
- Parameters:
amount
- value to be set
-
setIncludedInPrice
Description copied from interface:TaxRateDraft
If
true
, tax is included in Embedded Prices or Standalone Prices, and thetaxedPrice
is present on LineItems. In this case, thetotalNet
price on TaxedPrice includes the TaxRate.- Specified by:
setIncludedInPrice
in interfaceTaxRateDraft
- Parameters:
includedInPrice
- value to be set
-
setCountry
Description copied from interface:TaxRateDraft
Country in which the tax rate is applied in ISO 3166-1 alpha-2 format.
- Specified by:
setCountry
in interfaceTaxRateDraft
- Parameters:
country
- value to be set
-
setState
Description copied from interface:TaxRateDraft
State within the country, such as Texas in the United States.
- Specified by:
setState
in interfaceTaxRateDraft
- Parameters:
state
- value to be set
-
setSubRates
Description copied from interface:TaxRateDraft
Used to calculate the taxPortions field in a Cart or Order. It is useful if the total tax of a country (such as the US) is a combination of multiple taxes (such as state and local taxes).
- Specified by:
setSubRates
in interfaceTaxRateDraft
- Parameters:
subRates
- values to be set
-
setSubRates
Description copied from interface:TaxRateDraft
Used to calculate the taxPortions field in a Cart or Order. It is useful if the total tax of a country (such as the US) is a combination of multiple taxes (such as state and local taxes).
- Specified by:
setSubRates
in interfaceTaxRateDraft
- Parameters:
subRates
- values to be set
-
setKey
Description copied from interface:TaxRateDraft
User-defined unique identifier of the TaxRate.
- Specified by:
setKey
in interfaceTaxRateDraft
- Parameters:
key
- value to be set
-
equals
-
hashCode
-