public class ChangeGiftListPurchaseRecordPartMediator extends AbstractChangeGiftListPartMediator
Constructor and Description |
---|
ChangeGiftListPurchaseRecordPartMediator() |
Modifier and Type | Method and Description |
---|---|
void |
applyChanges()
This method applies all the changes made to the entity objects stored by
this physical data container.
|
void |
create(java.lang.Object aNoun,
java.lang.Object aNounPart)
This method creates the appropriate physical SDO and adds it to the
physical data container.
|
void |
delete(java.lang.Object aNoun,
java.lang.Object aNounPart)
This method updates purchase record status to 1 (Marked for Delete) by appropriately updating the
physical SDO from the physical data container.
|
java.lang.Object |
findPhysicalEntity(java.lang.Object noun,
java.lang.Object nounPart)
Finds a physical purchase record entity from the initialized physical data
container.
|
java.lang.String[] |
getNounPartXPaths()
This method gets the xpath for the noun part.
|
void |
update(java.lang.Object aNoun,
java.lang.Object aNounPart)
This method updates the physical data container with the modified
physical SDO object.
|
java.util.List |
validateChange(java.lang.Object aNoun,
java.lang.Object aNounPart)
This method checks if the noun part can be updated.
|
java.util.List |
validateCreate(java.lang.Object aNoun,
java.lang.Object aNounPart)
This method checks if the noun part can be created.
|
java.util.List |
validateDelete(java.lang.Object aNoun,
java.lang.Object aNounPart)
This method checks if the noun part can be deleted.
|
createAddress, findGiftListPhysicalEntity, updateAddress
convertToBigDecimal, convertToDate, convertToDouble, convertToInteger, convertToLong, getNounParts, getParentPhysicalDataContainer, getPhysicalDataContainer, initialize
getUpdateAccessProfile, setUpdateAccessProfile
initializeConfig
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
getUpdateAccessProfile, setUpdateAccessProfile
initializeConfig
public ChangeGiftListPurchaseRecordPartMediator()
public void create(java.lang.Object aNoun, java.lang.Object aNounPart) throws AbstractApplicationException
aNoun
- The logical GiftListType
SDO business object.aNounPart
- The logical GiftListType
SDO business object.AbstractApplicationException
public void update(java.lang.Object aNoun, java.lang.Object aNounPart) throws AbstractApplicationException
Database table column | XPath |
GRPURREC.REGISTRANTMEMO | GiftList/PurchaseRecord/RegistrantMemo |
GRPURREC.ISNOTESENT | GiftList/PurchaseRecord/NoteSent |
GRPURREC.PURCHASEQUANTITY | GiftList/PurchaseRecord/PurchaseItemDetails/Quantity |
registrant
or co-registrants
are given access to update the first two attributes
where as the third one I.e PURCHASEQUANTITY
can be performed only by administrators.aNoun
- The logical GiftListType
SDO business object to
update.aNounPart
- The logical PurchaseRecordType
SDO business
object to update.AbstractApplicationException
- GiftCenterClientApplicationMessageKeys._ERR_DELETE_OR_UPDATE_NON_EXIST_PURCHASE_RECORD
public void delete(java.lang.Object aNoun, java.lang.Object aNounPart) throws AbstractApplicationException
aNoun
- The logical GiftListType
SDO business object.aNounPart
- The logical GiftListPurchaseRecordType
SDO business object.AbstractApplicationException
- thrown when specified a non-existing
purchase record or when the specified purchase record is of status is already in Marked
for Delete status (1).
GiftCenterClientApplicationMessageKeys._ERR_PURCHASE_RECORD_ALREADY_DELETED
GiftCenterClientApplicationMessageKeys._ERR_DELETE_OR_UPDATE_NON_EXIST_PURCHASE_RECORD
public java.lang.String[] getNounPartXPaths()
public java.util.List validateCreate(java.lang.Object aNoun, java.lang.Object aNounPart) throws AbstractApplicationException
validateCreate
in interface ChangeBusinessObjectPartMediator
validateCreate
in class AbstractChangeGiftListPartMediator
aNoun
- The logical GiftListType
SDO business object.aNounPart
- The logical PurchaseRecordType
SDO business
object.ApplicationError
if
there are any errors, otherwise the list will be empty.
By default an empty list is returned.AbstractApplicationException
public java.util.List validateChange(java.lang.Object aNoun, java.lang.Object aNounPart) throws AbstractApplicationException
validateChange
in interface ChangeBusinessObjectPartMediator
validateChange
in class AbstractChangeGiftListPartMediator
aNoun
- The logical GiftListType
SDO business object to
validate.aNounPart
- The logical PurchaseRecordType
SDO business
object.ApplicationError
if
there are any errors, otherwise the list will be empty.AbstractApplicationException
public java.util.List validateDelete(java.lang.Object aNoun, java.lang.Object aNounPart) throws AbstractApplicationException
validateDelete
in interface ChangeBusinessObjectPartMediator
validateDelete
in class AbstractChangeGiftListPartMediator
aNoun
- The logical GiftListType
SDO business object.aNounPart
- The logical PurchaseRecordType
SDO business
object.ApplicationError
if
there are any errors, otherwise the list will be empty.
By default an empty list is returned.AbstractApplicationException
public java.lang.Object findPhysicalEntity(java.lang.Object noun, java.lang.Object nounPart) throws AbstractApplicationException
noun
- - The gift list noun object.nounPart
- - The purchase record to be resolved.null
.AbstractApplicationException
- - when an exception occurspublic void applyChanges() throws AbstractApplicationException
giftItemContainer
to save any changes done of gift list items.applyChanges
in interface ChangeBusinessObjectPartMediator
applyChanges
in class AbstractChangeBusinessObjectPartMediatorImpl
AbstractApplicationException
AbstractChangeBusinessObjectPartMediatorImpl.applyChanges()