atg.commerce.order
Class OrderServices

java.lang.Object
  extended by atg.nucleus.logging.VariableArgumentApplicationLoggingImpl
      extended by atg.nucleus.GenericService
          extended by atg.commerce.order.OrderServices
All Implemented Interfaces:
NameContextBindingListener, NameContextElement, NameResolver, AdminableService, ApplicationLogging, atg.nucleus.logging.ApplicationLoggingSender, atg.nucleus.logging.TraceApplicationLogging, VariableArgumentApplicationLogging, ComponentNameResolver, Service, ServiceListener, java.util.EventListener

public class OrderServices
extends GenericService

OrderServices contains the methods that implement conversational order management web services.


Field Summary
static java.lang.String CLASS_VERSION
          Class version string
static java.lang.String MSG_INVALID_PROFILE_ID
           
static java.lang.String MSG_NULL_ORDER_HOLDER
           
protected static java.util.ResourceBundle sResourceBundle
          Resource Bundle
 
Fields inherited from class atg.nucleus.GenericService
SERVICE_INFO_KEY
 
Fields inherited from interface atg.nucleus.logging.TraceApplicationLogging
DEFAULT_LOG_TRACE_STATUS
 
Fields inherited from interface atg.nucleus.logging.ApplicationLogging
DEFAULT_LOG_DEBUG_STATUS, DEFAULT_LOG_ERROR_STATUS, DEFAULT_LOG_INFO_STATUS, DEFAULT_LOG_WARNING_STATUS
 
Constructor Summary
OrderServices()
           
 
Method Summary
 java.lang.String addCreditCardToOrder(java.lang.String pOrderId, atg.payment.creditcard.BasicCreditCardInfoImpl pCreditCardInfo)
          Add the credit card to the order.
 java.lang.String addItemToOrder(java.lang.String pOrderId, java.lang.String pProductId, java.lang.String pSkuId, long pQuantity)
          Adds the given product/sku to the order.
 java.lang.String addItemToShippingGroup(java.lang.String pOrderId, java.lang.String pProductId, java.lang.String pSkuId, long pQuantity, java.lang.String pShippingGroupId)
          The same as AddItemToOrder but the item is also added to the given shipping group.
 java.lang.String addShippingAddressToOrder(java.lang.String pOrderId, ContactInfo pAddress)
          Add a shipping address to the order.
 java.lang.String createOrder(java.lang.String pOrderType)
          Creates a new order of the given type for the current user.
 java.lang.String createOrderForUser(java.lang.String pOrderType, java.lang.String pProfileId)
          Creates a new order of the given type for the given user.
 java.lang.String createOrderFromXML(java.lang.String pOrderAsXML, java.lang.String pProfileId)
          Converts the given XML document into a new order
 AddService getAddService()
          The AddService used by createOrderFromXML to convert xml strings to orders
protected  java.lang.String getCatalogKey()
          Gets the catalog key from the Locale.
 java.lang.String getCreditCardType()
          Gets the credit card payment group type.
 java.lang.String getCurrentOrderId()
          Return the id of the current users current order from the shopping cart.
 java.util.Locale getDefaultLocale()
          Gets the default locale for commerce opertations.
 java.lang.String getDefaultPaymentGroupId(java.lang.String pOrderId)
          Retrieves the first payment group id from the order.
 java.lang.String getDefaultShippingGroupId(java.lang.String pOrderId)
          Retrieves the first shipping group id from the order.
 GetService getGetService()
          The tool used to convert orders to xml in getOrderAsXML
 PurchaseProcessHelper getHelper()
          Gets the purchase process helper.
protected  java.util.Locale getLocale()
          Gets the Locale from the current request, the RequestLocale, or the VM.
 java.lang.String getOrderAsXML(java.lang.String pOrderId)
          Returns the given order as an xml string using the GetService.
 java.lang.String getOrderAsXML(java.lang.String pOrderId, java.lang.String pMappingFileName)
          Returns the given order as an xml string using the GetService.
 Order getOrderFromId(java.lang.String pOrderId)
          Gets the Order with the given id.
protected  OrderHolder getOrderHolder()
          Gets the OrderHolder component for the current session.
 java.lang.String getOrderHolderPath()
          Sets the Nucleus path of the OrderHolder (shipping cart) component.
 OrderManager getOrderManager()
          The OrderManager class that is used to manipulate order objects
 atg.commerce.order.status.OrderStatus getOrderStatus(java.lang.String pOrderId)
          Returns the status of the given order
 java.lang.String getOutboundOrderMappingFileName()
          The name of the mapping file used when converting orders to xml
 java.lang.String getPricingModelHolderPath()
          Gets the Nucleus path of the PricingModelHolder component.
 java.util.HashMap getProcessOrderMap(java.util.Locale pLocale)
          This method calls the OrderManager.getProcessOrderMap(pLocale, map) to get the process order map and adds sales channel to the map.
protected  RepositoryItem getProfile()
          Gets the Profile component for the current session.
 java.lang.String getProfilePath()
          Gets the Nucleus path of the Profile component.
 java.lang.String getSalesChannel()
          Returns the salesChannel.
protected  PricingModelHolder getUserPricingModels()
          Gets the PricingModelHolder component for the current session.
 boolean isUseRequestLocale()
          When set, allows the RequestLocale to be used by getLocale().
 boolean isValidateOrderXMLOnCreate()
          If this is true, the xml passed to createOrderFromXML will be validated against the schema The default value is false
 void moveItemBetweenShippingGroups(java.lang.String pOrderId, java.lang.String pCommerceItemId, long pQuantity, java.lang.String pSourceShippingGroupId, java.lang.String pTargetShippingGroupId)
          Move the given quantity of the commerce item from one shipping group into another.
protected  boolean processPipelineErrors(PipelineResult pResult, atg.commerce.util.PipelineErrorHandler pHandler)
          Examine the pipeline result looking for any error messages, creates DropletFormExceptions and adds them as form exceptions
 void removeCreditCardFromOrder(java.lang.String pOrderId, java.lang.String pCreditCardNumber)
          Remove the credit card with the given number from the order.
 void removeItemFromOrder(java.lang.String pOrderId, java.lang.String pCommerceItemId)
          Removes the given item from the order.
 void removeItemQuantityFromShippingGroup(java.lang.String pOrderId, java.lang.String pCommerceItemId, long pQuantity, java.lang.String pShippingGroupId)
          Remove the quantity of the given item from the shipping group.
 void removePaymentGroupFromOrder(java.lang.String pOrderId, java.lang.String pPaymentGroupId)
          Remove the given payment group from the order.
 void removeShippingGroupFromOrder(java.lang.String pOrderId, java.lang.String pShippingGroupId)
          Remove the given shipping group from the order.
 void setAddService(AddService pAddService)
           
 void setCreditCardType(java.lang.String pCreditCardType)
          Sets the credit card payment group type.
 void setDefaultLocale(java.util.Locale pDefaultLocale)
          Sets the default locale for commerce operations.
 void setGetService(GetService pGetService)
           
 void setHelper(PurchaseProcessHelper pHelper)
          Sets the purchase process helper.
 void setItemQuantity(java.lang.String pOrderId, java.lang.String pCommerceItemId, long pQuantity)
          Sets the item quantity for the given commerce item in the given shipping group.
 void setOrderAmountToPaymentGroup(java.lang.String pOrderId, java.lang.String pPaymentGroupId, double pAmount)
          Assigns the given amount to the given payment group.
 void setOrderHolderPath(java.lang.String pOrderHolderPath)
          Sets the Nucleus path of the OrderHolder (shopping cart) component.
 void setOrderManager(OrderManager pOrderManager)
           
 void setOutboundOrderMappingFileName(java.lang.String pOutboundOrderMappingFileName)
           
 void setPricingModelHolderPath(java.lang.String pPricingModelHolderPath)
          Sets the Nucleus path of the PricingModelHolder component.
 void setProfilePath(java.lang.String pProfilePath)
          Sets the Nucleus path of the Profile component.
 void setSalesChannel(java.lang.String pSalesChannel)
          Sets the salesChannel.
 void setUseRequestLocale(boolean pUseRequestLocale)
          When set, allows the RequestLocale to be used by getLocale().
 void setValidateOrderXMLOnCreate(boolean pValidateOrderXMLOnCreate)
           
 void submitOrder(java.lang.String pOrderId)
          Calls processOrder but converts the result from a PipelineResult to a SubmitOrderResult
 void submitOrderWithReprice(java.lang.String pOrderId, java.lang.String pLocale)
          Calls processOrderWithReprice but converts the result from a PipelineResult to a SubmitOrderResult
 
Methods inherited from class atg.nucleus.GenericService
addLogListener, createAdminServlet, doStartService, doStopService, getAbsoluteName, getAdminServlet, getLoggingForVlogging, getLogListenerCount, getLogListeners, getName, getNameContext, getNucleus, getRoot, getServiceConfiguration, getServiceInfo, isLoggingDebug, isLoggingError, isLoggingInfo, isLoggingTrace, isLoggingWarning, isRunning, logDebug, logDebug, logDebug, logError, logError, logError, logInfo, logInfo, logInfo, logTrace, logTrace, logTrace, logWarning, logWarning, logWarning, nameContextElementBound, nameContextElementUnbound, removeLogListener, reResolveThis, resolveName, resolveName, resolveName, resolveName, sendLogEvent, setLoggingDebug, setLoggingError, setLoggingInfo, setLoggingTrace, setLoggingWarning, setNucleus, setServiceInfo, startService, stopService
 
Methods inherited from class atg.nucleus.logging.VariableArgumentApplicationLoggingImpl
vlogDebug, vlogDebug, vlogDebug, vlogDebug, vlogError, vlogError, vlogError, vlogError, vlogInfo, vlogInfo, vlogInfo, vlogInfo, vlogTrace, vlogTrace, vlogTrace, vlogTrace, vlogWarning, vlogWarning, vlogWarning, vlogWarning
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

CLASS_VERSION

public static final java.lang.String CLASS_VERSION
Class version string

See Also:
Constant Field Values

MSG_INVALID_PROFILE_ID

public static final java.lang.String MSG_INVALID_PROFILE_ID
See Also:
Constant Field Values

MSG_NULL_ORDER_HOLDER

public static final java.lang.String MSG_NULL_ORDER_HOLDER
See Also:
Constant Field Values

sResourceBundle

protected static java.util.ResourceBundle sResourceBundle
Resource Bundle

Constructor Detail

OrderServices

public OrderServices()
Method Detail

getSalesChannel

public java.lang.String getSalesChannel()
Returns the salesChannel. Returns the sales channel which is used to submit the order. This could be "Web", "Call Center", or "Scheduled Orders". These values are defined in the order repository.

Returns:
salesChannel

setSalesChannel

public void setSalesChannel(java.lang.String pSalesChannel)
Sets the salesChannel. Sets the sales channel which is used to submit the order. This could be "Web", "Call Center", or "Scheduled Orders". These values are defined in the order repository.

Parameters:
pSalesChannel -

setHelper

public void setHelper(PurchaseProcessHelper pHelper)
Sets the purchase process helper.


getHelper

public PurchaseProcessHelper getHelper()
Gets the purchase process helper.


setUseRequestLocale

public void setUseRequestLocale(boolean pUseRequestLocale)
When set, allows the RequestLocale to be used by getLocale().


isUseRequestLocale

public boolean isUseRequestLocale()
When set, allows the RequestLocale to be used by getLocale().


setDefaultLocale

public void setDefaultLocale(java.util.Locale pDefaultLocale)
Sets the default locale for commerce operations.


getDefaultLocale

public java.util.Locale getDefaultLocale()
Gets the default locale for commerce opertations. If not explicity set, returns the default Locale for the VM.


setOrderHolderPath

public void setOrderHolderPath(java.lang.String pOrderHolderPath)
Sets the Nucleus path of the OrderHolder (shopping cart) component.


getOrderHolderPath

public java.lang.String getOrderHolderPath()
Sets the Nucleus path of the OrderHolder (shipping cart) component.


setProfilePath

public void setProfilePath(java.lang.String pProfilePath)
Sets the Nucleus path of the Profile component.


getProfilePath

public java.lang.String getProfilePath()
Gets the Nucleus path of the Profile component.


setPricingModelHolderPath

public void setPricingModelHolderPath(java.lang.String pPricingModelHolderPath)
Sets the Nucleus path of the PricingModelHolder component.


getPricingModelHolderPath

public java.lang.String getPricingModelHolderPath()
Gets the Nucleus path of the PricingModelHolder component.


setCreditCardType

public void setCreditCardType(java.lang.String pCreditCardType)
Sets the credit card payment group type.

See Also:
OrderTools.getPaymentTypeClassMap()

getCreditCardType

public java.lang.String getCreditCardType()
Gets the credit card payment group type.


setOrderManager

public void setOrderManager(OrderManager pOrderManager)

getOrderManager

public OrderManager getOrderManager()
The OrderManager class that is used to manipulate order objects


setAddService

public void setAddService(AddService pAddService)

getAddService

public AddService getAddService()
The AddService used by createOrderFromXML to convert xml strings to orders


setValidateOrderXMLOnCreate

public void setValidateOrderXMLOnCreate(boolean pValidateOrderXMLOnCreate)

isValidateOrderXMLOnCreate

public boolean isValidateOrderXMLOnCreate()
If this is true, the xml passed to createOrderFromXML will be validated against the schema The default value is false


setGetService

public void setGetService(GetService pGetService)

getGetService

public GetService getGetService()
The tool used to convert orders to xml in getOrderAsXML


setOutboundOrderMappingFileName

public void setOutboundOrderMappingFileName(java.lang.String pOutboundOrderMappingFileName)

getOutboundOrderMappingFileName

public java.lang.String getOutboundOrderMappingFileName()
The name of the mapping file used when converting orders to xml


getOrderFromId

public Order getOrderFromId(java.lang.String pOrderId)
                     throws CommerceException
Gets the Order with the given id.

Parameters:
pOrderId - The id of the order to retrieve
Returns:
the Order with the given id.
Throws:
CommerceException - if an error occurs while loading the Order.

getOrderHolder

protected OrderHolder getOrderHolder()
Gets the OrderHolder component for the current session.

Returns:
the OrderHolder component for the current session.

getProfile

protected RepositoryItem getProfile()
Gets the Profile component for the current session.

Returns:
the Profile component for the current session.

getUserPricingModels

protected PricingModelHolder getUserPricingModels()
Gets the PricingModelHolder component for the current session.

Returns:
the PricingModelHolder component for the current session.

getLocale

protected java.util.Locale getLocale()
Gets the Locale from the current request, the RequestLocale, or the VM.

Returns:
the Locale from the current request, the RequestLocale, or the VM.

getCatalogKey

protected java.lang.String getCatalogKey()
Gets the catalog key from the Locale.

Returns:
the catalog key from the Locale, or null.

getCurrentOrderId

public java.lang.String getCurrentOrderId()
                                   throws CommerceException
Return the id of the current users current order from the shopping cart. If there is no order in the shopping cart on then, null is returned.

Returns:
The id of the current order, null if there isn't one.
Throws:
CommerceException - If there is a problem getting the current order

createOrderFromXML

public java.lang.String createOrderFromXML(java.lang.String pOrderAsXML,
                                           java.lang.String pProfileId)
                                    throws CommerceException
Converts the given XML document into a new order

Parameters:
pOrderAsXML - THe XML document representating the entire order
Returns:
The order id of the newly created order
Throws:
AddException
CommerceException

createOrder

public java.lang.String createOrder(java.lang.String pOrderType)
                             throws CommerceException
Creates a new order of the given type for the current user. If orderType is null, create an order of the default order type.

Parameters:
pOrderType - the type of order to create. null indicates the default order type.
Returns:
the order id of the new order.
Throws:
CommerceException - if there is an error creating the order.

createOrderForUser

public java.lang.String createOrderForUser(java.lang.String pOrderType,
                                           java.lang.String pProfileId)
                                    throws CommerceException
Creates a new order of the given type for the given user. If orderType is null, create an order of the default order type. This operation is intended to be used by applications that need to create orders on behalf of another user, such as a CSR application.

Parameters:
pProfileId - the user who will own the order
pOrderType - the type of order to create. null indicates the default order type.
Returns:
the order id of the new order.
Throws:
CommerceException - if there is an error creating the order.

submitOrder

public void submitOrder(java.lang.String pOrderId)
                 throws CommerceException
Calls processOrder but converts the result from a PipelineResult to a SubmitOrderResult

Parameters:
pOrderId - The id of the order to be submitted
Throws:
CommerceException

submitOrderWithReprice

public void submitOrderWithReprice(java.lang.String pOrderId,
                                   java.lang.String pLocale)
                            throws CommerceException
Calls processOrderWithReprice but converts the result from a PipelineResult to a SubmitOrderResult

Parameters:
pOrderId - The id of the order to be submitted
pLocale - The locale to use. This may be null
Throws:
CommerceException

getOrderStatus

public atg.commerce.order.status.OrderStatus getOrderStatus(java.lang.String pOrderId)
                                                     throws CommerceException
Returns the status of the given order

Parameters:
pOrderId - The id of the order whose status is returned
Returns:
A complete status object
Throws:
CommerceException

getOrderAsXML

public java.lang.String getOrderAsXML(java.lang.String pOrderId)
                               throws CommerceException,
                                      GetException
Returns the given order as an xml string using the GetService. The mapping file used is the outboundOrderMappingFileName

Parameters:
pOrderId -
Returns:
An XML string valid against the schema described by outboundOrderMappingFileName
Throws:
CommerceException
GetException

getOrderAsXML

public java.lang.String getOrderAsXML(java.lang.String pOrderId,
                                      java.lang.String pMappingFileName)
                               throws CommerceException,
                                      GetException
Returns the given order as an xml string using the GetService. The mapping file used is the given mapping file name

Parameters:
pOrderId -
Returns:
An XML string valid against the schema described by outboundOrderMappingFileName
Throws:
CommerceException
GetException

addItemToOrder

public java.lang.String addItemToOrder(java.lang.String pOrderId,
                                       java.lang.String pProductId,
                                       java.lang.String pSkuId,
                                       long pQuantity)
                                throws CommerceException
Adds the given product/sku to the order. If the product/sku already exists, the quantity is increased accordingly. Note, this API has no facility for creating a commerce item whose type is not the default commerce item type. This may be addressed in a future release. The new item is placed in the dafault shipping group.

Parameters:
pOrderId - the id of the order to which the item will be added.
pProductId - the product id of the item.
pSkuId - the SKU id of the item.
pQuantity - the quantity of item to add.
Returns:
the commerce id of the new item.
Throws:
CommerceException - if there is an error adding the item to the order.

removeItemFromOrder

public void removeItemFromOrder(java.lang.String pOrderId,
                                java.lang.String pCommerceItemId)
                         throws CommerceException
Removes the given item from the order.

Parameters:
pOrderId - the id of the order from which the item will be removed.
pCommerceItemId - the id of the item to remove.
Throws:
CommerceException - if an error occurs while removing an item.

setItemQuantity

public void setItemQuantity(java.lang.String pOrderId,
                            java.lang.String pCommerceItemId,
                            long pQuantity)
                     throws CommerceException
Sets the item quantity for the given commerce item in the given shipping group. The default shipping group is used if the shipping group id argument is null. If the quantity is set to zero, the item is removed from the shipping group, and the order if the item is part of only one shipping group.

Parameters:
pOrderId - the id of the order containing the item.
pCommerceItemId - the id of the item whose quntity will be modified.
pQuantity - the new quantity of the item.
Throws:
CommerceException - if there is an error setting the quantity.

addCreditCardToOrder

public java.lang.String addCreditCardToOrder(java.lang.String pOrderId,
                                             atg.payment.creditcard.BasicCreditCardInfoImpl pCreditCardInfo)
                                      throws CommerceException
Add the credit card to the order. If the given order contains only one payment group, and that payment group does not have a credit card defined on it yet, then this credit card information is added to the existing payment group. In all other cases, a new payment group is created.

Parameters:
pOrderId - the id of the order to which the credit card will be added.
pCreditCardInfo - the credit card data.
Returns:
the id of the payment group that contains the credit card information
Throws:
CommerceException - if there is an error creating or adding the credit card.
See Also:
PurchaseProcessHelper.copyCreditCardInfo(atg.payment.creditcard.BasicCreditCardInfo, atg.commerce.order.CreditCard), atg.commerce.order.purchase.PurchaseProcessHelper#addCreditCardToORder

addShippingAddressToOrder

public java.lang.String addShippingAddressToOrder(java.lang.String pOrderId,
                                                  ContactInfo pAddress)
                                           throws CommerceException
Add a shipping address to the order. If the given order contains only one shipping group, and that shipping group does not have an address yet, then this address is added to the existing shipping group. In all other cases, a new shipping group is created.

Parameters:
pOrderId - the id of the order to which the address will be added.
pAddress - the address to add to the order.
Returns:
the id of the shipping group that contains the address
Throws:
CommerceException - if there is an error creating or adding the address.
See Also:
PurchaseProcessHelper.addShippingAddressToOrder(atg.commerce.order.Order, atg.core.util.Address)

removePaymentGroupFromOrder

public void removePaymentGroupFromOrder(java.lang.String pOrderId,
                                        java.lang.String pPaymentGroupId)
                                 throws CommerceException
Remove the given payment group from the order.

Parameters:
pOrderId - the id of the order from which the payment group will be removed.
pPaymentGroupId - the id of the payment group to remove.
Throws:
CommerceException - if an error occurs while removing the payment group.

removeCreditCardFromOrder

public void removeCreditCardFromOrder(java.lang.String pOrderId,
                                      java.lang.String pCreditCardNumber)
                               throws CommerceException
Remove the credit card with the given number from the order.

Parameters:
pOrderId - the id of the order from which the credit card will be removed.
pCreditCardNumber - the number of the credit card to remove.
Throws:
CommerceException - if an error occurs.
java.lang.IllegalArgumentException - if the credit card is not found.

removeShippingGroupFromOrder

public void removeShippingGroupFromOrder(java.lang.String pOrderId,
                                         java.lang.String pShippingGroupId)
                                  throws CommerceException
Remove the given shipping group from the order. The items within the shipping group are moved to the default shipping group. If the default shipping group is removed, the next group becomes default. An attempt to remove the only shipping group in the order will result in a CommerceException.

Parameters:
pOrderId - the id of the order from which the shipping group will be removed.
pShippingGroupId - the id of the shipping group to remove.
Throws:
CommerceException - if an error occurs while removing the shipping group

addItemToShippingGroup

public java.lang.String addItemToShippingGroup(java.lang.String pOrderId,
                                               java.lang.String pProductId,
                                               java.lang.String pSkuId,
                                               long pQuantity,
                                               java.lang.String pShippingGroupId)
                                        throws CommerceException
The same as AddItemToOrder but the item is also added to the given shipping group.

Parameters:
pOrderId - the id of the order to which the item will be added.
pProductId - the product id of the item.
pSkuId - the SKU id of the item.
pQuantity - the quantity of item to add.
pShippingGroupId - the id of the shipping group to which the item will be added.
Returns:
the commerce id of the new item.
Throws:
CommerceException - if there is an error adding the item to the order.

moveItemBetweenShippingGroups

public void moveItemBetweenShippingGroups(java.lang.String pOrderId,
                                          java.lang.String pCommerceItemId,
                                          long pQuantity,
                                          java.lang.String pSourceShippingGroupId,
                                          java.lang.String pTargetShippingGroupId)
                                   throws CommerceException
Move the given quantity of the commerce item from one shipping group into another.

Parameters:
pOrderId - the id of the order containing the item to move.
pCommerceItemId - the id of the item to move.
pQuantity - the quantity of item to move.
pSourceShippingGroupId - the id of the source shipping group.
pTargetShippingGroupId - the id of the target shipping group.
Throws:
CommerceException - if there is an error moving the item.

removeItemQuantityFromShippingGroup

public void removeItemQuantityFromShippingGroup(java.lang.String pOrderId,
                                                java.lang.String pCommerceItemId,
                                                long pQuantity,
                                                java.lang.String pShippingGroupId)
                                         throws CommerceException
Remove the quantity of the given item from the shipping group. If the quantity to be removed is greater than or equal to the quantity of the item within the shipping group, the item is removed from the shipping group.

Parameters:
pOrderId - the id of the order containing the shipping group.
pCommerceItemId - the id of the item to be removed.
pQuantity - the quantity of item to remove.
pShippingGroupId - the id of the shipping group from which the item will be removed.
Throws:
CommerceException - if an error occurs.

setOrderAmountToPaymentGroup

public void setOrderAmountToPaymentGroup(java.lang.String pOrderId,
                                         java.lang.String pPaymentGroupId,
                                         double pAmount)
                                  throws CommerceException
Assigns the given amount to the given payment group.

Parameters:
pOrderId - the id of the order whose order amount will be assigned.
pPaymentGroupId - the payment group to modify.
pAmount - the new amount to assign.
Throws:
CommerceException - if an error occurs.

getDefaultShippingGroupId

public java.lang.String getDefaultShippingGroupId(java.lang.String pOrderId)
                                           throws CommerceException
Retrieves the first shipping group id from the order.

Parameters:
pOrderId - the id of the order from which the default shipping group id will be retrieved.
Returns:
the default shipping group id.
Throws:
CommerceException - if an error occurs while retrieving the shipping group.

getDefaultPaymentGroupId

public java.lang.String getDefaultPaymentGroupId(java.lang.String pOrderId)
                                          throws CommerceException
Retrieves the first payment group id from the order.

Parameters:
pOrderId - the id of the order from which the default payment group id will be retrieved.
Returns:
the default payment group id.
Throws:
CommerceException - if an error occurs while retrieving the payment group.

processPipelineErrors

protected boolean processPipelineErrors(PipelineResult pResult,
                                        atg.commerce.util.PipelineErrorHandler pHandler)
Examine the pipeline result looking for any error messages, creates DropletFormExceptions and adds them as form exceptions

Parameters:
pResult - a PipelineResult value
Returns:
true if errors were found

getProcessOrderMap

public java.util.HashMap getProcessOrderMap(java.util.Locale pLocale)
                                     throws CommerceException
This method calls the OrderManager.getProcessOrderMap(pLocale, map) to get the process order map and adds sales channel to the map.

Returns:
Throws:
CommerceException