Tabnine Logo
IndirectList.hasAddedElements
Code IndexAdd Tabnine to your IDE (free)

How to use
hasAddedElements
method
in
org.eclipse.persistence.indirection.IndirectList

Best Java code snippets using org.eclipse.persistence.indirection.IndirectList.hasAddedElements (Showing top 12 results out of 315)

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

/**
 * INTERNAL:
 * Return if any elements that have been added or removed before instantiation.
 */
public boolean hasDeferredChanges() {
  return hasRemovedElements() || hasAddedElements();
}
 
origin: org.eclipse.persistence/org.eclipse.persistence.core

/**
 * INTERNAL:
 * Return if any elements that have been added or removed before instantiation.
 */
@Override
public boolean hasDeferredChanges() {
  return hasRemovedElements() || hasAddedElements();
}
origin: com.haulmont.thirdparty/eclipselink

/**
 * INTERNAL:
 * Return if any elements that have been added or removed before instantiation.
 */
@Override
public boolean hasDeferredChanges() {
  return hasRemovedElements() || hasAddedElements();
}

origin: org.eclipse.persistence/org.eclipse.persistence.core

/**
 * PUBLIC:
 * @see java.util.Vector#contains(java.lang.Object)
 */
@Override
public boolean contains(Object element) {
  // PERF: Avoid instantiation if not required.
  if (hasAddedElements()) {
    if (getAddedElements().contains(element)) {
      return true;
    }
  }
  if (hasRemovedElements()) {
    if (getRemovedElements().contains(element)) {
      return false;
    }
  }
  return getDelegate().contains(element);
}
origin: com.haulmont.thirdparty/eclipselink

/**
 * PUBLIC:
 * @see java.util.Vector#contains(java.lang.Object)
 */
@Override
public boolean contains(Object element) {
  // PERF: Avoid instantiation if not required.
  if (hasAddedElements()) {
    if (getAddedElements().contains(element)) {
      return true;
    }
  }
  if (hasRemovedElements()) {
    if (getRemovedElements().contains(element)) {
      return false;
    }
  }
  return getDelegate().contains(element);
}
origin: org.eclipse.persistence/com.springsource.org.eclipse.persistence

/**
 * PUBLIC:
 * @see java.util.Vector#contains(java.lang.Object)
 */
public boolean contains(Object element) {
  // PERF: Avoid instantiation if not required.
  if (hasAddedElements()) {
    if (getAddedElements().contains(element)) {
      return true;
    }
  }
  if (hasRemovedElements()) {
    if (getRemovedElements().contains(element)) {
      return false;
    }
  }
  return getDelegate().contains(element);
}
origin: org.eclipse.persistence/com.springsource.org.eclipse.persistence

/**
 * @see java.util.Vector#remove(java.lang.Object)
 */
public boolean remove(Object element) {
  if (!this.isRegistered) {
    return getDelegate().remove(element);
  }
  // PERF: If not instantiated just record the removal to avoid the instantiation.
  if (shouldAvoidInstantiation()) {
    if (hasAddedElements() && getAddedElements().contains(element)) {
      getAddedElements().remove(element);
    } else if (getRemovedElements().contains(element)) {
      // Must avoid recursion for relationship maintenance.
      return false;
    } else {
      getRemovedElements().add(element);
    }
    this.raiseRemoveChangeEvent(element, null);
    return true;
  } else { 
    int index = this.getDelegate().indexOf(element);
    if(index > -1) {
      this.getDelegate().remove(index);
      this.raiseRemoveChangeEvent(element, index);
      return true;
    }
  }  
  return false;
}
origin: org.eclipse.persistence/org.eclipse.persistence.core

/**
 * @see java.util.Vector#remove(java.lang.Object)
 */
@Override
public boolean remove(Object element) {
  if (!this.isRegistered) {
    return getDelegate().remove(element);
  }
  // PERF: If not instantiated just record the removal to avoid the instantiation.
  if (shouldAvoidInstantiation()) {
    if (hasAddedElements() && getAddedElements().contains(element)) {
      getAddedElements().remove(element);
    } else if (getRemovedElements().contains(element)) {
      // Must avoid recursion for relationship maintenance.
      return false;
    } else {
      getRemovedElements().add((E) element);
    }
    this.raiseRemoveChangeEvent(element, null);
    return true;
  } else {
    int index = this.getDelegate().indexOf(element);
    if(index > -1) {
      this.getDelegate().remove(index);
      this.raiseRemoveChangeEvent(element, index);
      return true;
    }
  }
  return false;
}
origin: com.haulmont.thirdparty/eclipselink

if (hasAddedElements()) {
  int size = getAddedElements().size();
  for (int index = 0; index < size; index++) {
origin: com.haulmont.thirdparty/eclipselink

/**
 * @see java.util.Vector#remove(java.lang.Object)
 */
@Override
public boolean remove(Object element) {
  if (!this.isRegistered) {
    return getDelegate().remove(element);
  }
  // PERF: If not instantiated just record the removal to avoid the instantiation.
  if (shouldAvoidInstantiation()) {
    if (hasAddedElements() && getAddedElements().contains(element)) {
      getAddedElements().remove(element);
    } else if (getRemovedElements().contains(element)) {
      // Must avoid recursion for relationship maintenance.
      return false;
    } else {
      getRemovedElements().add(element);
    }
    this.raiseRemoveChangeEvent(element, null);
    return true;
  } else { 
    int index = this.getDelegate().indexOf(element);
    if(index > -1) {
      this.getDelegate().remove(index);
      this.raiseRemoveChangeEvent(element, index);
      return true;
    }
  }  
  return false;
}
origin: org.eclipse.persistence/com.springsource.org.eclipse.persistence

if (hasAddedElements()) {
  int size = getAddedElements().size();
  for (int index = 0; index < size; index++) {
origin: org.eclipse.persistence/org.eclipse.persistence.core

if (hasAddedElements()) {
  for (E element: getAddedElements()) {
org.eclipse.persistence.indirectionIndirectListhasAddedElements

Javadoc

INTERNAL: Return if any elements that have been added before instantiation.

Popular methods of IndirectList

  • <init>
    PUBLIC: Construct an IndirectList containing the elements of the specified collection, in the order
  • _persistence_getPropertyChangeListener
    INTERNAL: Return the property change listener for change tracking.
  • add
  • buildDelegate
    INTERNAL: Return the freshly-built delegate.
  • getAddedElements
    INTERNAL: Return the elements that have been added before instantiation.
  • getDelegate
    INTERNAL: Check whether the contents have been read from the database. If they have not, read them a
  • getRemovedElements
    INTERNAL: Return the elements that have been removed before instantiation.
  • getTrackedAttributeName
    INTERNAL: Return the mapping attribute name, used to raise change events.
  • getValueHolder
    INTERNAL: Return the valueHolder. This method used to be synchronized, which caused deadlock.
  • hasBeenRegistered
    INTERNAL: return whether this IndirectList has been registered with the UnitOfWork
  • hasRemovedElements
    INTERNAL: Return if any elements that have been removed before instantiation.
  • hasTrackedPropertyChangeListener
    INTERNAL: Return if the collection has a property change listener for change tracking.
  • hasRemovedElements,
  • hasTrackedPropertyChangeListener,
  • isInstantiated,
  • isListOrderBrokenInDb,
  • iterator,
  • listIterator,
  • raiseAddChangeEvent,
  • raiseRemoveChangeEvent,
  • remove

Popular in Java

  • Running tasks concurrently on multiple threads
  • scheduleAtFixedRate (ScheduledExecutorService)
  • getResourceAsStream (ClassLoader)
  • getSupportFragmentManager (FragmentActivity)
  • EOFException (java.io)
    Thrown when a program encounters the end of a file or stream during an input operation.
  • MessageFormat (java.text)
    Produces concatenated messages in language-neutral way. New code should probably use java.util.Forma
  • GregorianCalendar (java.util)
    GregorianCalendar is a concrete subclass of Calendarand provides the standard calendar used by most
  • Stack (java.util)
    Stack is a Last-In/First-Out(LIFO) data structure which represents a stack of objects. It enables u
  • ConcurrentHashMap (java.util.concurrent)
    A plug-in replacement for JDK1.5 java.util.concurrent.ConcurrentHashMap. This version is based on or
  • IsNull (org.hamcrest.core)
    Is the value null?
  • Top Vim plugins
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