DekGenius.com
[ Team LiB ] Previous Section Next Section

15.3 Deleting Instances

A persistent-nontransactional instance transitions to persistent-deleted if it is a parameter of deletePersistent( ). The values of the fields of the instance in memory are unchanged but are saved for verification during commit. To minimize the possibility of a conflict at commit, you can load fresh values from the datastore by calling refresh( ) or refreshAll( ) with the instance as a parameter.

A hollow instance transitions to persistent-deleted if it is a parameter of deletePersistent( ). Since there is no state loaded into the instance, the instance will not be verified during commit. To force verification at commit, you should first call refresh( ) or refreshAll( ) with the instance as a parameter.

    [ Team LiB ] Previous Section Next Section