IBM SG24-6320-00 Marine Radio User Manual


 
6320ch_DEV_post_migration.fm Draft Document for Review July 28, 2004 7:33 pm
142 Keeping Commerce Applications Updated WebSphere Commerce 5.1 to 5.6 Migration Guide
Table 8-2 Mapping from use of the OrderItemAccessBean to the Item envelope class
Tip: Mapping OrderItemAccessBean to Item considerations:
If an accessor is not available in the interface to Item, it is possible to
access the underlying OrderItemAccessBean using the following method:
public OrderItemAccessBean getOrderItem()
This should be avoided, if at all possible.
Table 8-2 shows only the accessors that directly map between
OrderItemAccessBean and Item. If, for example, the WebSphere
Commerce Suite V5.1 code contains the line:
String strQuantity = oiab.getQuantity()
Then this could be migrated into the following line:
String strQuantity = item.getOrderItem().getQuantity()
But most likely, the code should be rewritten to use the getQuantity
method of the Item class, using BigDecimal objects instead strings to hold
the order quantity.
If any of the setter methods on the Item class are used, the commit method
should be used to commit the changes to the underlying
OrderItemAccessBean:
item.setShippingTaxTotal(bdTaxTotal);
item.setShippingTotal(bdTotal);
item.commit();
If it cannot be avoided to modify values directly in the
OrderItemAccessBean, the envelope Item bean should be refreshed in
addition calling commitCopyHelper:
OrderItemAccessBean oiab = item.getOrderItem();
oiab.setShippingTaxTotal(“22”);
oiab.setShippingTotal(“220”);
oiab.commitCopyHelper();
item.refresh();
Accessing OrderItemAccessBean Accessing Item
getStoreIdInEJBType()
setStoreId(lStoreId)
getStoreEntityId()
setStoreEntityId(lStoreId)
getStatus()
setStatus()
getStatus()
setStatus()
getCatalogEntryIdInEJBType()
setCatalogEntryId(lCatEntId)
getCatalogEntryId()
setCatalogEntryId(lCatEntId)