Class ForwardingMap.StandardValues

    • Constructor Summary

      Constructors 
      Constructor Description
      StandardValues()
      Constructor for use by subclasses.
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      void clear()
      Removes all of the elements from this collection (optional operation).
      boolean contains​(java.lang.Object o)
      Returns true if this collection contains the specified element.
      boolean isEmpty()
      Returns true if this collection contains no elements.
      java.util.Iterator<V> iterator()
      Returns an iterator over the elements contained in this collection.
      boolean remove​(java.lang.Object o)
      Removes a single instance of the specified element from this collection, if it is present (optional operation).
      boolean removeAll​(java.util.Collection<?> c)
      Removes all of this collection's elements that are also contained in the specified collection (optional operation).
      boolean retainAll​(java.util.Collection<?> c)
      Retains only the elements in this collection that are contained in the specified collection (optional operation).
      int size()
      Returns the number of elements in this collection.
      • Methods inherited from class java.util.AbstractCollection

        add, addAll, containsAll, toArray, toArray, toString
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
      • Methods inherited from interface java.util.Collection

        equals, hashCode, parallelStream, removeIf, spliterator, stream, toArray
      • Methods inherited from interface java.lang.Iterable

        forEach
    • Constructor Detail

      • StandardValues

        public StandardValues()
        Constructor for use by subclasses.
    • Method Detail

      • iterator

        public java.util.Iterator<V> iterator()
        Description copied from class: java.util.AbstractCollection
        Returns an iterator over the elements contained in this collection.
        Specified by:
        iterator in interface java.util.Collection<K extends @Nullable java.lang.Object>
        Specified by:
        iterator in interface java.lang.Iterable<K extends @Nullable java.lang.Object>
        Specified by:
        iterator in class java.util.AbstractCollection<V extends @Nullable java.lang.Object>
        Returns:
        an iterator over the elements contained in this collection
      • remove

        public boolean remove​(@CheckForNull
                              java.lang.Object o)
        Description copied from class: java.util.AbstractCollection
        Removes a single instance of the specified element from this collection, if it is present (optional operation). More formally, removes an element e such that Objects.equals(o, e), if this collection contains one or more such elements. Returns true if this collection contained the specified element (or equivalently, if this collection changed as a result of the call).
        Specified by:
        remove in interface java.util.Collection<K extends @Nullable java.lang.Object>
        Overrides:
        remove in class java.util.AbstractCollection<V extends @Nullable java.lang.Object>
        Parameters:
        o - element to be removed from this collection, if present
        Returns:
        true if an element was removed as a result of this call
      • removeAll

        public boolean removeAll​(java.util.Collection<?> c)
        Description copied from class: java.util.AbstractCollection
        Removes all of this collection's elements that are also contained in the specified collection (optional operation). After this call returns, this collection will contain no elements in common with the specified collection.
        Specified by:
        removeAll in interface java.util.Collection<K extends @Nullable java.lang.Object>
        Overrides:
        removeAll in class java.util.AbstractCollection<V extends @Nullable java.lang.Object>
        Parameters:
        c - collection containing elements to be removed from this collection
        Returns:
        true if this collection changed as a result of the call
        See Also:
        AbstractCollection.remove(Object), AbstractCollection.contains(Object)
      • retainAll

        public boolean retainAll​(java.util.Collection<?> c)
        Description copied from class: java.util.AbstractCollection
        Retains only the elements in this collection that are contained in the specified collection (optional operation). In other words, removes from this collection all of its elements that are not contained in the specified collection.
        Specified by:
        retainAll in interface java.util.Collection<K extends @Nullable java.lang.Object>
        Overrides:
        retainAll in class java.util.AbstractCollection<V extends @Nullable java.lang.Object>
        Parameters:
        c - collection containing elements to be retained in this collection
        Returns:
        true if this collection changed as a result of the call
        See Also:
        AbstractCollection.remove(Object), AbstractCollection.contains(Object)
      • size

        public int size()
        Description copied from interface: java.util.Collection
        Returns the number of elements in this collection. If this collection contains more than Integer.MAX_VALUE elements, returns Integer.MAX_VALUE.
        Specified by:
        size in interface java.util.Collection<K extends @Nullable java.lang.Object>
        Specified by:
        size in class java.util.AbstractCollection<V extends @Nullable java.lang.Object>
        Returns:
        the number of elements in this collection
      • isEmpty

        public boolean isEmpty()
        Description copied from class: java.util.AbstractCollection
        Returns true if this collection contains no elements.
        Specified by:
        isEmpty in interface java.util.Collection<K extends @Nullable java.lang.Object>
        Overrides:
        isEmpty in class java.util.AbstractCollection<V extends @Nullable java.lang.Object>
        Returns:
        true if this collection contains no elements
      • contains

        public boolean contains​(@CheckForNull
                                java.lang.Object o)
        Description copied from class: java.util.AbstractCollection
        Returns true if this collection contains the specified element. More formally, returns true if and only if this collection contains at least one element e such that Objects.equals(o, e).
        Specified by:
        contains in interface java.util.Collection<K extends @Nullable java.lang.Object>
        Overrides:
        contains in class java.util.AbstractCollection<V extends @Nullable java.lang.Object>
        Parameters:
        o - element whose presence in this collection is to be tested
        Returns:
        true if this collection contains the specified element
      • clear

        public void clear()
        Description copied from class: java.util.AbstractCollection
        Removes all of the elements from this collection (optional operation). The collection will be empty after this method returns.
        Specified by:
        clear in interface java.util.Collection<K extends @Nullable java.lang.Object>
        Overrides:
        clear in class java.util.AbstractCollection<V extends @Nullable java.lang.Object>