atg.commerce.pricing
Class AmountInfo

java.lang.Object
  extended by atg.commerce.pricing.AmountInfo
All Implemented Interfaces:
java.io.Serializable
Direct Known Subclasses:
DetailedItemPriceInfo, ItemPriceInfo, OrderPriceInfo, ShippingPriceInfo, TaxPriceInfo

public class AmountInfo
extends java.lang.Object
implements java.io.Serializable

Represents price information about an object. In DCS, a price is more than just a number. In addition to the actual amount, AmountInfo also stores information about how to interpret that amount, and how the current price was calculated.

Properties

See Also:
PricingAdjustment, Serialized Form

Field Summary
static java.lang.String CLASS_VERSION
          Class version string
 
Constructor Summary
AmountInfo()
           
 
Method Summary
 java.util.List getAdjustments()
          A list of PricingAdjustment objects which record an audit trail of changes that have happened to the amount in this AmountInfo
 double getAmount()
          the raw number about which this AmountInfo stores interpretive information
 java.util.List getClosenessQualifiers()
          A list of closenessQualifiers that this order/item satisfies.
 java.lang.String getCurrencyCode()
          the currency code for the price that this AmountInfo represents
 boolean isAmountIsFinal()
          If this flag is true, this amount info should never be changed.
 boolean isDiscounted()
          Test property Discounted
 void markAsFinal()
          This method will mark this AmountInfo as final.
 void markAsFinal(java.lang.String pReason)
          This method will mark this AmountInfo as final.
 void setAmount(double pAmount)
          the raw number about which this AmountInfo stores interpretive information
 void setAmountIsFinal(boolean pAmountIsFinal)
          If true, this amountInfo will not be recalculated If you want a PricingAdjustment to be created that reflects this change, then use markAsFinal instead.
 void setClosenessQualifiers(java.util.List pClosenessQualifiers)
          A list of closenessQualifiers that this order/item satisfies.
 void setCurrencyCode(java.lang.String pCurrencyCode)
          the currency code for the price that this AmountInfo represents
 void setDiscounted(boolean pDiscounted)
          Flag that states whether or not this AmountInfo has been discounted
 java.lang.String toString()
          Produces a String representation for this AmountInfo
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

CLASS_VERSION

public static java.lang.String CLASS_VERSION
Class version string

Constructor Detail

AmountInfo

public AmountInfo()
Method Detail

setCurrencyCode

public void setCurrencyCode(java.lang.String pCurrencyCode)
the currency code for the price that this AmountInfo represents

Parameters:
pCurrencyCode - new value to set

getCurrencyCode

public java.lang.String getCurrencyCode()
the currency code for the price that this AmountInfo represents

Returns:
property CurrencyCode

setAmount

public void setAmount(double pAmount)
the raw number about which this AmountInfo stores interpretive information

Parameters:
pAmount - new value to set

getAmount

public double getAmount()
the raw number about which this AmountInfo stores interpretive information

Returns:
property Amount

setDiscounted

public void setDiscounted(boolean pDiscounted)
Flag that states whether or not this AmountInfo has been discounted

Parameters:
pDiscounted - new value to set

isDiscounted

public boolean isDiscounted()
Test property Discounted

Returns:
Discounted

getAdjustments

public java.util.List getAdjustments()
A list of PricingAdjustment objects which record an audit trail of changes that have happened to the amount in this AmountInfo

Returns:
property Adjustments

setAmountIsFinal

public void setAmountIsFinal(boolean pAmountIsFinal)
If true, this amountInfo will not be recalculated If you want a PricingAdjustment to be created that reflects this change, then use markAsFinal instead.

Parameters:
pAmountIsFinal - the new value

isAmountIsFinal

public boolean isAmountIsFinal()
If this flag is true, this amount info should never be changed.

Returns:
property amountIsFinal

setClosenessQualifiers

public void setClosenessQualifiers(java.util.List pClosenessQualifiers)
A list of closenessQualifiers that this order/item satisfies.

Parameters:
pClosenessQualifiers - the new value

getClosenessQualifiers

public java.util.List getClosenessQualifiers()
A list of closenessQualifiers that this order/item satisfies.

Returns:
property closenessQualifiers

markAsFinal

public void markAsFinal()
This method will mark this AmountInfo as final. This means that throughout subsequent pricing operations, this AmountInfo will remain unchanged. The provided string will be added to the PricingAdjustment.


markAsFinal

public void markAsFinal(java.lang.String pReason)
This method will mark this AmountInfo as final. This means that throughout subsequent pricing operations, this AmountInfo will remain unchanged. The provided string will be added to the PricingAdjustment.

Parameters:
pReason - A string that explains why the AmountInfo was marked final.

toString

public java.lang.String toString()
Produces a String representation for this AmountInfo

Overrides:
toString in class java.lang.Object
Returns:
a String representation for this AmountInfo