Package oracle.toplink.essentials.internal.descriptors

Examples of oracle.toplink.essentials.internal.descriptors.OptimisticLockingPolicy.updateRowAndObjectForUpdate()


            if (getDescriptor().usesOptimisticLocking()) {
                OptimisticLockingPolicy policy = getDescriptor().getOptimisticLockingPolicy();
                policy.addLockValuesToTranslationRow(writeQuery);

                // update the row with newer lock value   
                policy.updateRowAndObjectForUpdate(writeQuery, object);              
            }

            // PERF: Avoid events if no listeners.
            if (getDescriptor().getEventManager().hasAnyEventListeners()) {
                DescriptorEvent event = new DescriptorEvent(DescriptorEventManager.AboutToUpdateEvent, writeQuery);
View Full Code Here


                OptimisticLockingPolicy policy = getDescriptor().getOptimisticLockingPolicy();
                policy.addLockValuesToTranslationRow(writeQuery);

                if (!getModifyRow().isEmpty() || (shouldModifyVersionField.booleanValue() && policy instanceof VersionLockingPolicy)) {
                    // update the row with newer lock value   
                    policy.updateRowAndObjectForUpdate(writeQuery, object);
                } else if (!shouldModifyVersionField.booleanValue() && policy instanceof VersionLockingPolicy) {
                    ((VersionLockingPolicy)policy).writeLockValueIntoRow(writeQuery, object);
                }
            }
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.