|
BEA Systems, Inc. | ||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--theory.smart.foundation.BelongingImpl | +--theory.smart.ebusiness.order.OrderLineImpl
This class combines an item and a quantity. The item is a reference to an entity bean. This class is persisted inside an order.
OrderLine
,
OrderLineHome
, Serialized FormField Summary | |
SmartHandle |
item
item [OrderLine] <>------> [ theory.smart.ebusiness.item.Item ]
|
Price |
price
price [OrderLine] <*>------> [ theory.smart.axiom.units.Price ]
|
Quantity |
quantity
quantity [OrderLine] <*>------> [ theory.smart.axiom.units.Quantity ]
|
Constructor Summary | |
OrderLineImpl()
|
Method Summary | |
int |
compareTo(java.lang.Object o)
|
void |
correctPrice(Price newPrice)
Forcibly correct a price once it has been locked in. |
Item |
getItem()
Get the remote object reference of item |
Price |
getItemPrice(Customer customer)
Get the price for a single unit using the Item's price calculation policy. |
Price |
getLinePrice(Customer customer)
Get the value of the order by using the priceCalculationPolicy to determing the price and multiplying the price by the quantity. |
Price |
getPrice()
Get the value of price |
Quantity |
getQuantity()
Get the value of quantity |
void |
lockinPrice(Customer customer)
Freeze the price of the item by getting the Item price and storing a local copy of the value. |
void |
setItem(Item item)
Set the remote object reference of item |
void |
setPrice(Price price)
Set the value of price |
void |
setQuantity(Quantity quantity)
Set the value of quantity |
Belonging |
value()
|
Methods inherited from class theory.smart.foundation.BelongingImpl |
equals |
Methods inherited from class java.lang.Object |
getClass,
hashCode,
notify,
notifyAll,
toString,
wait,
wait,
wait |
Field Detail |
public SmartHandle item
item
[OrderLine] <>------> [theory.smart.ebusiness.item.Item
]
public Quantity quantity
quantity
[OrderLine] <*>------> [theory.smart.axiom.units.Quantity
]
public Price price
price
[OrderLine] <*>------> [theory.smart.axiom.units.Price
]
Constructor Detail |
public OrderLineImpl()
Method Detail |
public Item getItem() throws java.rmi.RemoteException
public void setItem(Item item) throws java.rmi.RemoteException
items
- item to be addedpublic Quantity getQuantity()
public void setQuantity(Quantity quantity)
quantity
- quantity to be addedpublic Price getPrice()
public void setPrice(Price price)
price
- price to be addedpublic Belonging value()
public int compareTo(java.lang.Object o)
public Price getLinePrice(Customer customer) throws java.rmi.RemoteException
public Price getItemPrice(Customer customer) throws java.rmi.RemoteException
public void lockinPrice(Customer customer) throws java.rmi.RemoteException
public void correctPrice(Price newPrice)
|
BEA Systems, Inc. | ||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |