Tabnine Logo
EISOneToManyMappingHelper.buildAddedElementFromChangeSet
Code IndexAdd Tabnine to your IDE (free)

How to use
buildAddedElementFromChangeSet
method
in
org.eclipse.persistence.eis.mappings.EISOneToManyMappingHelper

Best Java code snippets using org.eclipse.persistence.eis.mappings.EISOneToManyMappingHelper.buildAddedElementFromChangeSet (Showing top 6 results out of 315)

origin: org.eclipse.persistence/com.springsource.org.eclipse.persistence

/**
 * Merge changes from the source to the target object.
 * Simply replace the entire target collection.
 */
private void mergeChangesIntoObjectWithOrder(Object target, ChangeRecord changeRecord, Object source, MergeManager mergeManager) {
  ContainerPolicy cp = this.getContainerPolicy();
  AbstractSession session = mergeManager.getSession();
  Vector changes = ((EISOrderedCollectionChangeRecord)changeRecord).getNewCollection();
  Object targetCollection = cp.containerInstance(changes.size());
  for (Enumeration stream = changes.elements(); stream.hasMoreElements();) {
    Object targetElement = this.buildAddedElementFromChangeSet(stream.nextElement(), mergeManager);
    cp.addInto(targetElement, targetCollection, session);
  }
  // reset the attribute to allow for set method to re-morph changes if the collection is not being stored directly
  this.setRealAttributeValueInObject(target, targetCollection);
}
origin: org.eclipse.persistence/org.eclipse.persistence.core

/**
 * Merge changes from the source to the target object.
 * Simply replace the entire target collection.
 */
private void mergeChangesIntoObjectWithOrder(Object target, ChangeRecord changeRecord, Object source, MergeManager mergeManager, AbstractSession targetSession) {
  ContainerPolicy cp = this.getContainerPolicy();
  AbstractSession session = mergeManager.getSession();
  List changes = ((EISOrderedCollectionChangeRecord)changeRecord).getNewCollection();
  Object targetCollection = cp.containerInstance(changes.size());
  for (Object changed : changes) {
    Object targetElement = buildAddedElementFromChangeSet(changed, mergeManager, targetSession);
    cp.addInto(targetElement, targetCollection, session);
  }
  // reset the attribute to allow for set method to re-morph changes if the collection is not being stored directly
  this.setRealAttributeValueInObject(target, targetCollection);
}
origin: com.haulmont.thirdparty/eclipselink

/**
 * Merge changes from the source to the target object.
 * Simply replace the entire target collection.
 */
private void mergeChangesIntoObjectWithOrder(Object target, ChangeRecord changeRecord, Object source, MergeManager mergeManager, AbstractSession targetSession) {
  ContainerPolicy cp = this.getContainerPolicy();
  AbstractSession session = mergeManager.getSession();
  List changes = ((EISOrderedCollectionChangeRecord)changeRecord).getNewCollection();
  Object targetCollection = cp.containerInstance(changes.size());
  for (Object changed : changes) {
    Object targetElement = buildAddedElementFromChangeSet(changed, mergeManager, targetSession);
    cp.addInto(targetElement, targetCollection, session);
  }
  // reset the attribute to allow for set method to re-morph changes if the collection is not being stored directly
  this.setRealAttributeValueInObject(target, targetCollection);
}
origin: org.eclipse.persistence/com.springsource.org.eclipse.persistence

Object addElement = this.buildAddedElementFromChangeSet(stream.nextElement(), mergeManager);
cp.addInto(addElement, targetCollection, session);
Object changedMapKeyElement = this.buildAddedElementFromChangeSet(stream.nextElement(), mergeManager);
Object originalElement = ((UnitOfWorkImpl)session).getOriginalVersionOfObject(changedMapKeyElement);
cp.removeFrom(originalElement, targetCollection, session);
origin: org.eclipse.persistence/org.eclipse.persistence.core

Object addElement = buildAddedElementFromChangeSet(added, mergeManager, targetSession);
cp.addInto(addElement, targetCollection, session);
Object changedMapKeyElement = buildAddedElementFromChangeSet(changed, mergeManager, targetSession);
Object originalElement = ((UnitOfWorkImpl)session).getOriginalVersionOfObject(changedMapKeyElement);
cp.removeFrom(originalElement, targetCollection, session);
origin: com.haulmont.thirdparty/eclipselink

Object addElement = buildAddedElementFromChangeSet(added, mergeManager, targetSession);
cp.addInto(addElement, targetCollection, session);
Object changedMapKeyElement = buildAddedElementFromChangeSet(changed, mergeManager, targetSession);
Object originalElement = ((UnitOfWorkImpl)session).getOriginalVersionOfObject(changedMapKeyElement);
cp.removeFrom(originalElement, targetCollection, session);
org.eclipse.persistence.eis.mappingsEISOneToManyMappingHelperbuildAddedElementFromChangeSet

Javadoc

Convenience method.

Popular methods of EISOneToManyMappingHelper

  • <init>
    Constructor.
  • buildChangeSet
    Convenience method.
  • buildElementFromElement
    Convenience method.
  • buildRemovedElementFromChangeSet
    Convenience method.
  • compareAttributeValues
    Compare the attributes. Return true if they are alike. Assume the passed-in attributes are non-null.
  • compareAttributeValuesForChangeWithOrder
    Build and return the change record that results from comparing the two collection attributes. The or
  • compareAttributeValuesForChangeWithoutOrder
    Build and return the change record that results from comparing the two collection attributes. Ignore
  • compareAttributeValuesWithOrder
    Compare the attributes. Return true if they are alike. The order of the elements is significant.
  • compareAttributeValuesWithoutOrder
    Compare the attributes. Return true if they are alike. Ignore the order of the elements.
  • compareElements
    Convenience method. Check for null values before delegating to the mapping.
  • compareElementsForChange
    Convenience method. Check for null values before delegating to the mapping.
  • compareForChange
    INTERNAL: Build and return the change record that results from comparing the two collection attribut
  • compareElementsForChange,
  • compareForChange,
  • compareObjects,
  • getAttributeName,
  • getContainerPolicy,
  • getDatabaseMapping,
  • getMapping,
  • getRealCollectionAttributeValueFromObject,
  • mapKeyHasChanged

Popular in Java

  • Running tasks concurrently on multiple threads
  • onRequestPermissionsResult (Fragment)
  • getSharedPreferences (Context)
  • addToBackStack (FragmentTransaction)
  • GridLayout (java.awt)
    The GridLayout class is a layout manager that lays out a container's components in a rectangular gri
  • MalformedURLException (java.net)
    This exception is thrown when a program attempts to create an URL from an incorrect specification.
  • ConcurrentHashMap (java.util.concurrent)
    A plug-in replacement for JDK1.5 java.util.concurrent.ConcurrentHashMap. This version is based on or
  • JarFile (java.util.jar)
    JarFile is used to read jar entries and their associated data from jar files.
  • ZipFile (java.util.zip)
    This class provides random read access to a zip file. You pay more to read the zip file's central di
  • Logger (org.apache.log4j)
    This is the central class in the log4j package. Most logging operations, except configuration, are d
  • Top plugins for Android Studio
Tabnine Logo
  • Products

    Search for Java codeSearch for JavaScript code
  • IDE Plugins

    IntelliJ IDEAWebStormVisual StudioAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimGoLandRubyMineEmacsJupyter NotebookJupyter LabRiderDataGripAppCode
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogTabnine AcademyTerms of usePrivacy policyJava Code IndexJavascript Code Index
Get Tabnine for your IDE now