com.ibm.commerce.giftregistry.commands

Class GiftRegistryExtOrderCopyCmdImpl

  • All Implemented Interfaces:
    com.ibm.commerce.command.CacheableECCommand, ECCommand, ECTargetableCommand, TaskCommand, ExtOrderCopyCmd, com.ibm.websphere.cache.Sizeable, com.ibm.websphere.command.CacheableCommand, com.ibm.websphere.command.Command, com.ibm.websphere.command.CommandCaller, com.ibm.websphere.command.TargetableCommand, java.io.Serializable


    public class GiftRegistryExtOrderCopyCmdImpl
    extends ExtOrderCopyCmdImpl
    implements ExtOrderCopyCmd
    This class extends ExtOrderCopyCmdImpl. It adds logic to save the orderItemGift relationship of new orderItems which are copied from one gift registryorderItem. For every copied orderItem, if it has a relationship with a gift registry, this command:

  • Creates a relationship between new orderItem, which is copied from that copied orderItem, and the gift registry.
  • Copies all information from orderItem gift relationship of the copied orderItemto new created relationship.
  • Removes the gift relationship of the copied orderItem.
See Also:
Serialized Form
    • Field Detail

      • COPYRIGHT

        public static final java.lang.String COPYRIGHT
        IBM copyright notice field.
        See Also:
        Constant Field Values
    • Constructor Detail

      • GiftRegistryExtOrderCopyCmdImpl

        public GiftRegistryExtOrderCopyCmdImpl()
    • Method Detail

      • setCopiedOrderItems

        public void setCopiedOrderItems(java.util.HashMap ahshCopiedOrderItems)
        Sets the copied orderItems.

        The key (that is, enumeration group) can be used to correlate a new orderItem with a source (that is, copied) orderItem.

        A new orderItem may be created from input parameters only (that is, not copied from a source orderItem). In such cases, the enumeration group for the new orderItem will not be found in the copied orderItem hash map.

        The OrderItemAccessBeans may reference orderItems that have since been deleted. Use the set provided by ExtOrderCopyCmd.setDeletedOrderItemIds(Set) to determine if an OrderItemAccessBean has been deleted.

        The OrderItemAccessBeans contain information obtained from the database before any modifications were made. Use OrderItemAccessBean#refreshCopyHelper() to obtain the updated OrderItemAccessBean information.
        Specified by:
        setCopiedOrderItems in interface ExtOrderCopyCmd
        Overrides:
        setCopiedOrderItems in class ExtOrderCopyCmdImpl
        Parameters:
        ahshCopiedOrderItems - the copied orderItems.
      • Key: enumeration group (Integer).
      • Value: copied orderItem (OrderItemAccessBean).
      • setNewOrderItems

        public void setNewOrderItems(java.util.HashMap ahshNewOrderItems)
        Sets the new orderItems.

        The key (that is, enumeration group) can be used to correlate a new orderItem with a source (that is, copied) orderItem.

        A new orderItem may be created from input parameters only (that is, not copied from a source orderItem). In such cases, the enumeration group for the new orderItem will not be found in the copied orderItem hash map.
        Specified by:
        setNewOrderItems in interface ExtOrderCopyCmd
        Overrides:
        setNewOrderItems in class ExtOrderCopyCmdImpl
        Parameters:
        ahshNewOrderItems - the new OrderItems.
      • Key: enumeration group (Integer).
      • Value: new orderItem (OrderItemAccessBean).