Class DelayedPriorityQueueProxy

  • All Implemented Interfaces:
    java.io.Serializable, java.lang.Iterable, java.util.Collection, java.util.Queue, Proxy, DelayedProxy, ProxyCollection

    public class DelayedPriorityQueueProxy
    extends java.util.PriorityQueue
    implements ProxyCollection, DelayedProxy
    PriorityQueue proxy with delay loading capability. Allows non-indexed add and remove operations to occur on an unloaded collection. Operations that require a load will trigger a load.
    See Also:
    Serialized Form
    • Constructor Detail

      • DelayedPriorityQueueProxy

        public DelayedPriorityQueueProxy​(int paramInt)
      • DelayedPriorityQueueProxy

        public DelayedPriorityQueueProxy​(int paramInt,
                                         java.util.Comparator paramComparator)
      • DelayedPriorityQueueProxy

        public DelayedPriorityQueueProxy​(java.util.Collection paramCollection)
      • DelayedPriorityQueueProxy

        public DelayedPriorityQueueProxy​(java.util.PriorityQueue paramPriorityQueue)
      • DelayedPriorityQueueProxy

        public DelayedPriorityQueueProxy​(java.util.SortedSet paramSortedSet)
      • DelayedPriorityQueueProxy

        public DelayedPriorityQueueProxy()
    • Method Detail

      • setOwner

        public void setOwner​(OpenJPAStateManager paramOpenJPAStateManager,
                             int paramInt)
        Description copied from interface: Proxy
        Reset the state of the proxy, and set the owning instance of the proxy and the name of the field it is assigned to. Set to null to indicate that the proxy is no longer managed.
        Specified by:
        setOwner in interface Proxy
      • getOwnerField

        public int getOwnerField()
        Description copied from interface: Proxy
        Return the owning field index.
        Specified by:
        getOwnerField in interface Proxy
      • clone

        public java.lang.Object clone()
                               throws java.lang.CloneNotSupportedException
        Overrides:
        clone in class java.lang.Object
        Throws:
        java.lang.CloneNotSupportedException
      • getChangeTracker

        public ChangeTracker getChangeTracker()
        Description copied from interface: Proxy
        Return the change tracker for this proxy, or null if none.
        Specified by:
        getChangeTracker in interface Proxy
      • copy

        public java.lang.Object copy​(java.lang.Object paramObject)
        Description copied from interface: Proxy
        Return an unproxied copy of the given instance. This method is used by proxy managers to create backup values for use in rollback.
        Specified by:
        copy in interface Proxy
      • setElementType

        protected void setElementType​(java.lang.Class<?> elemType)
      • newInstance

        public ProxyCollection newInstance​(java.lang.Class paramClass,
                                           java.util.Comparator paramComparator,
                                           boolean paramBoolean1,
                                           boolean paramBoolean2)
        Description copied from interface: ProxyCollection
        Create a new instance of this proxy type.
        Specified by:
        newInstance in interface ProxyCollection
      • add

        public boolean add​(java.lang.Object paramObject)
        Specified by:
        add in interface java.util.Collection
        Specified by:
        add in interface java.util.Queue
        Overrides:
        add in class java.util.PriorityQueue
      • clear

        public void clear()
        Specified by:
        clear in interface java.util.Collection
        Overrides:
        clear in class java.util.PriorityQueue
      • iterator

        public java.util.Iterator iterator()
        Specified by:
        iterator in interface java.util.Collection
        Specified by:
        iterator in interface java.lang.Iterable
        Overrides:
        iterator in class java.util.PriorityQueue
      • remove

        public boolean remove​(java.lang.Object paramObject)
        Specified by:
        remove in interface java.util.Collection
        Overrides:
        remove in class java.util.PriorityQueue
      • poll

        public java.lang.Object poll()
        Specified by:
        poll in interface java.util.Queue
        Overrides:
        poll in class java.util.PriorityQueue
      • offer

        public boolean offer​(java.lang.Object paramObject)
        Specified by:
        offer in interface java.util.Queue
        Overrides:
        offer in class java.util.PriorityQueue
      • addAll

        public boolean addAll​(java.util.Collection paramCollection)
        Specified by:
        addAll in interface java.util.Collection
        Overrides:
        addAll in class java.util.AbstractQueue
      • remove

        public java.lang.Object remove()
        Specified by:
        remove in interface java.util.Queue
        Overrides:
        remove in class java.util.AbstractQueue
      • removeAll

        public boolean removeAll​(java.util.Collection paramCollection)
        Specified by:
        removeAll in interface java.util.Collection
        Overrides:
        removeAll in class java.util.PriorityQueue
      • retainAll

        public boolean retainAll​(java.util.Collection paramCollection)
        Specified by:
        retainAll in interface java.util.Collection
        Overrides:
        retainAll in class java.util.PriorityQueue
      • writeReplace

        protected java.lang.Object writeReplace()
                                         throws java.io.ObjectStreamException
        Throws:
        java.io.ObjectStreamException
      • size

        public int size()
        Specified by:
        size in interface java.util.Collection
        Overrides:
        size in class java.util.PriorityQueue
      • isEmpty

        public boolean isEmpty()
        Specified by:
        isEmpty in interface java.util.Collection
        Overrides:
        isEmpty in class java.util.AbstractCollection
      • contains

        public boolean contains​(java.lang.Object object)
        Specified by:
        contains in interface java.util.Collection
        Overrides:
        contains in class java.util.PriorityQueue
      • toArray

        public java.lang.Object[] toArray()
        Specified by:
        toArray in interface java.util.Collection
        Overrides:
        toArray in class java.util.PriorityQueue
      • toArray

        public java.lang.Object[] toArray​(java.lang.Object[] array)
        Specified by:
        toArray in interface java.util.Collection
        Overrides:
        toArray in class java.util.PriorityQueue
      • toArray

        public java.lang.Object[] toArray​(java.util.function.IntFunction generator)
        Specified by:
        toArray in interface java.util.Collection
      • containsAll

        public boolean containsAll​(java.util.Collection c)
        Specified by:
        containsAll in interface java.util.Collection
        Overrides:
        containsAll in class java.util.AbstractCollection
      • element

        public java.lang.Object element()
        Specified by:
        element in interface java.util.Queue
        Overrides:
        element in class java.util.AbstractQueue
      • peek

        public java.lang.Object peek()
        Specified by:
        peek in interface java.util.Queue
        Overrides:
        peek in class java.util.PriorityQueue
      • equals

        public boolean equals​(java.lang.Object paramObject)
        Specified by:
        equals in interface java.util.Collection
        Overrides:
        equals in class java.lang.Object
      • hashCode

        public int hashCode()
        Specified by:
        hashCode in interface java.util.Collection
        Overrides:
        hashCode in class java.lang.Object
      • getDelayedField

        public int getDelayedField()
        Description copied from interface: DelayedProxy
        Returns the expected field index even if this collection was detached.
        Specified by:
        getDelayedField in interface DelayedProxy
      • isDirectAccess

        public boolean isDirectAccess()
        Description copied from interface: DelayedProxy
        Returns whether the caller has direct-call access to the proxied object. Direct access allows calls to be made on the object without triggering a load or proxy state tracking callbacks.
        Specified by:
        isDirectAccess in interface DelayedProxy
      • setDirectAccess

        public void setDirectAccess​(boolean direct)
        Description copied from interface: DelayedProxy
        Sets whether the caller has direct-call access to the proxied object. Direct access allows calls to be made on the object without triggering a load or proxy state tracking callbacks.
        Specified by:
        setDirectAccess in interface DelayedProxy
      • load

        public void load()
        Description copied from interface: DelayedProxy
        Load the proxy if it was delay-loaded.
        Specified by:
        load in interface DelayedProxy
      • closeBroker

        public void closeBroker()
        Description copied from interface: DelayedProxy
        Close the broker that is used to service this proxy.
        Specified by:
        closeBroker in interface DelayedProxy
      • isDetached

        public boolean isDetached()
        Description copied from interface: DelayedProxy
        Returns whether the proxy is detached.
        Specified by:
        isDetached in interface DelayedProxy
      • isDelayLoad

        public boolean isDelayLoad()