java.lang.Object | +--MonetaryAmountDataBean | +--com.ibm.commerce.price.beans.CategorizedMonetaryAmountsDataBean
This DataBean is a formatter bean for formatting multiple monetary amounts that are of different categories. One example that will use this formatter will be the taxation that can be composed of several tax categories (e.g. GST, PST).
Constructor Summary | |
---|---|
CategorizedMonetaryAmountsDataBean() CategorizedMonetaryAmountFormatter constructor. | |
CategorizedMonetaryAmountsDataBean(com.ibm.commerce.price.utils.MonetaryAmount aMonetaryAmount,
StoreAccessBean aStoreAccessBean,
java.lang.Integer aLangId, java.lang.String aCategoryName) CategorizedMonetaryAmountFormatter constructor. | |
CategorizedMonetaryAmountsDataBean(com.ibm.commerce.price.utils.MonetaryAmount aMonetaryAmount,
StoreAccessBean aStoreAccessBean,
java.lang.Integer aLangId, java.lang.String aCategoryName,
java.util.Hashtable aDescHash, java.util.Hashtable aAmountHash,
java.util.Hashtable aAmountDBHash) CategorizedMonetaryAmountFormatter constructor. |
Method Summary | |
---|---|
java.lang.String |
getACategorizedAmountWithName(java.lang.String aCategory) Return the monetary amount and name of a particular category. |
java.lang.String |
getACategorizedValueWithName(java.lang.String aCategory) Return the monetary value and name of a particular category. |
java.lang.String |
getAllCategorizedAmountsWithNames() Return all of the categorized monetary amounts and names. |
java.lang.String |
getAllCategorizedValuesWithNames() Return all of the categorized monetary values and names. |
java.util.Hashtable |
getCategorizedAmountsAndNames() Get the categorized names and monetary amounts hashtable. |
java.util.Hashtable |
getCategorizedAmountsDBAndNames() Get the categorized names and MonetaryAmountDataBean hashtable. |
java.util.Hashtable |
getCategorizedDescriptionsAndNames() Get the categorized descriptions and names hashtable. |
java.math.BigDecimal |
getCategoryAmount() Get the category monetary value. |
java.lang.String |
getCategoryName() Get the category name. |
CommandContext |
getCommandContext() Get the command context. |
java.lang.String |
getCurrency() Get the monetary currency. |
int |
getNoOfCategories() Return the total number of categories. |
TypedProperty |
getRequestProperties() Get the request properties. |
java.lang.String |
getTotalCategorizedAmount() Return the total of all the categorized amounts. |
java.lang.String |
getTotalCategorizedValue() Return the total of all the categorized amount values. |
void |
populate() Create the hashtable that contains the categories and their corresponding monetary amounts. |
void |
setCategorizedAmountsAndNames(java.util.Hashtable aCategorizedAmounts) Set the categorized names and monetary amounts hashtable. |
void |
setCategorizedAmountsDBAndNames(java.util.Hashtable aCategorizedAmountsDB) Set the categorized names and MonetaryAmountDataBean hashtable. |
void |
setCategorizedDescriptionsAndNames(java.util.Hashtable aCategorizedDescriptionsAndNames) Set the categorized descriptions and names hashtable. |
void |
setCategorizedValuesAndNames(java.util.Hashtable aCategorizedValues) Set the categorized values and names hashtable. |
void |
setCategoryAmount(java.math.BigDecimal aCategoryAmount) Set the category value. |
void |
setCategoryName(java.lang.String aCgryName) Set the category name. |
void |
setCommandContext(
CommandContext commandContext) Set the command context. |
void |
setCurrency(java.lang.String aCurrency) Set the monetary currency. |
void |
setRequestProperties(
TypedProperty param) Set the request properties. |
java.lang.String |
toString() Returns all of the categorized monetary amounts or monetary values and their corresponding category names. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait,
wait, wait |
Constructor Detail |
---|
public CategorizedMonetaryAmountsDataBean()
public CategorizedMonetaryAmountsDataBean(com.ibm.commerce.price.utils.MonetaryAmount aMonetaryAmount, StoreAccessBean aStoreAccessBean, java.lang.Integer aLangId, java.lang.String aCategoryName)
aStoreAccessBean
-aLangId
-aCategoryName
-aMonetaryAmount
-
com.ibm.commerce.price.utils.MonetaryAmountpublic CategorizedMonetaryAmountsDataBean(com.ibm.commerce.price.utils.MonetaryAmount aMonetaryAmount, StoreAccessBean aStoreAccessBean, java.lang.Integer aLangId, java.lang.String aCategoryName, java.util.Hashtable aDescHash, java.util.Hashtable aAmountHash, java.util.Hashtable aAmountDBHash)
aStoreAccessBean
-aLangId
-aCategoryName
-aDescHash
-aAmountHash
-aAmountDBHash
-aMonetaryAmount
-
com.ibm.commerce.price.utils.MonetaryAmountMethod Detail |
---|
public java.lang.String getACategorizedAmountWithName(java.lang.String aCategory)
aCategory
- - the categoryString
representing monetary amount and the corresponding
name of a particular category.public java.lang.String getACategorizedValueWithName(java.lang.String aCategory)
aCategory
- - the categoryString
representing monetary value and the corresponding
name of a particular category.public java.lang.String getAllCategorizedAmountsWithNames()
String
representing all of the categorized monetary
amounts and the corresponding category names.public java.lang.String getAllCategorizedValuesWithNames()
String
representing all of the categorized monetary values
and the corresponding category names.public java.util.Hashtable getCategorizedAmountsAndNames()
Hashtable
containing the categorized names and monetary
amounts.public java.util.Hashtable getCategorizedAmountsDBAndNames()
Hashtable
containing the categorized names and
MonetaryAmountDataBean.public java.util.Hashtable getCategorizedDescriptionsAndNames()
Hashtable
containing the categorized descriptions and
names.public java.math.BigDecimal getCategoryAmount()
BigDecimal
containing the monetary
value.public java.lang.String getCategoryName()
String
containing the category name.public CommandContext getCommandContext()
com.ibm.commerce.command.CommandContext
.public java.lang.String getCurrency()
String
representing the monetary
currency.public int getNoOfCategories()
int
containing the total numbers of
categories.public TypedProperty getRequestProperties()
com.ibm.commerce.datatype.TypedProperty
containing the
request properties.public java.lang.String getTotalCategorizedAmount()
String
representing the total monetary
amount.public java.lang.String getTotalCategorizedValue()
String
representing the total monetary
value.public void populate() throws java.lang.Exception
java.lang.Exception
public void setCategorizedAmountsAndNames(java.util.Hashtable aCategorizedAmounts)
aCategorizedAmounts
-public void setCategorizedAmountsDBAndNames(java.util.Hashtable aCategorizedAmountsDB)
aCategorizedAmountsDB
- the categorized amounts databean and
names hashtable.public void setCategorizedDescriptionsAndNames(java.util.Hashtable aCategorizedDescriptionsAndNames)
aCategorizedDescriptionsAndNames
-public void setCategorizedValuesAndNames(java.util.Hashtable aCategorizedValues)
aCategorizedValues
-public void setCategoryAmount(java.math.BigDecimal aCategoryAmount)
aCategoryAmount
- the category value.public void setCategoryName(java.lang.String aCgryName)
aCgryName
- the category name.public void setCommandContext(CommandContext commandContext)
commandContext
-
com.ibm.commerce.command.CommandContext.public void setCurrency(java.lang.String aCurrency)
aCurrency
- the monetary currency.public void setRequestProperties(TypedProperty param) throws java.lang.Exception
param
- com.ibm.commerce.datatype.TypedProperty.java.lang.Exception
public java.lang.String toString()
String
representing all of the categorized monetary
amounts or monetary values and their corresponding category
names.