Interface PersistGiftRegistryItemPurchaseRecordCmd

  • All Superinterfaces:
    BusinessObjectDocumentCmd,,,,, ECCommand,,, TaskCommand
    All Known Implementing Classes:

    public interface PersistGiftRegistryItemPurchaseRecordCmd
    extends BusinessObjectDocumentCmd
    This commands persists the nouns(represented by value objects) in a given request business object document. The rule of persistence is as follows:
    • A value object field is corresponding to a database column. The corresponding database column of a value object field will either be changed or created.
    • A value object is corresponding to one or more rows in database. The data in a value object will be persisted into database by creating a new row only if there is no corresponding row in database yet. Otherwise, the existing row will be updated. The following protocol will be used to determine if a row has been created for a value object:
      • If a value object has its corresponding row's unique identifier, the corresponding row has been created in the database. For simplicity, the default implementation assumes primary key will be used as the unique identifier, expect for GiftRegistryVO, which uses exteranlId as its unique identifier.
      • If a corresponding row of a value object has only compound primary key, a corresponding row is already created. If both the parent node (the containing value object) has its corresponding row created and the value object's primary key can be found in database. This implies that all the containment relations are compositions. That is, a child node does not exist if its parent does not exist.
      • Otherwise, a value object does not have a corresponding row in database yet.
    How the updates are done:
    1. If now corresponding row is found for a value object, new row(s) will be created. Otherwise, the row(s) will be updated with the values in the value object if the values are not null.
    2. All the fields indicated in the Verb will be written to database regardless of whether the indicated value is null or not.
    • Field Detail


        static final java.lang.String COPYRIGHT
        The internal copyright field.
        See Also:
        Constant Field Values
      • NAME

        static final java.lang.String NAME
        The name of this interface
      • defaultCommandClassName

        static final java.lang.String defaultCommandClassName
        The default implementation class