Class EolCollection<T>

  • Type Parameters:
    T - Type of elements.
    All Implemented Interfaces:
    java.lang.Iterable<T>, java.util.Collection<T>
    Direct Known Subclasses:
    EolBag, EolConcurrentBag, EolConcurrentSet, EolOrderedSet, EolSequence, EolSet

    public abstract class EolCollection<T>
    extends java.lang.Object
    implements java.util.Collection<T>
    Base class for all EOL collections.
    Since:
    1.6
    Author:
    Sina Madani
    • Field Summary

      Fields 
      Modifier and Type Field Description
      protected java.util.Collection<T> wrapped  
    • Constructor Summary

      Constructors 
      Modifier Constructor Description
      protected EolCollection​(java.util.Collection<T> delegate)  
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      boolean add​(T e)  
      boolean addAll​(java.util.Collection<? extends T> c)  
      void clear()  
      boolean contains​(java.lang.Object o)  
      boolean containsAll​(java.util.Collection<?> c)  
      boolean equals​(java.lang.Object obj)  
      void forEach​(java.util.function.Consumer<? super T> action)  
      int hashCode()  
      boolean isEmpty()  
      java.util.Iterator<T> iterator()  
      java.util.stream.Stream<T> parallelStream()  
      boolean remove​(java.lang.Object o)  
      boolean removeAll​(java.util.Collection<?> c)  
      boolean removeIf​(java.util.function.Predicate<? super T> filter)  
      boolean retainAll​(java.util.Collection<?> c)  
      int size()  
      java.util.Spliterator<T> spliterator()  
      java.util.stream.Stream<T> stream()  
      java.lang.Object[] toArray()  
      java.lang.Object[] toArray​(java.lang.Object[] a)  
      java.lang.String toString()  
      • Methods inherited from class java.lang.Object

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

        toArray
    • Field Detail

      • wrapped

        protected java.util.Collection<T> wrapped
    • Constructor Detail

      • EolCollection

        protected EolCollection​(java.util.Collection<T> delegate)
    • Method Detail

      • equals

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

        public int hashCode()
        Specified by:
        hashCode in interface java.util.Collection<T>
        Overrides:
        hashCode in class java.lang.Object
      • toString

        public java.lang.String toString()
        Overrides:
        toString in class java.lang.Object
      • add

        public boolean add​(T e)
        Specified by:
        add in interface java.util.Collection<T>
      • addAll

        public boolean addAll​(java.util.Collection<? extends T> c)
        Specified by:
        addAll in interface java.util.Collection<T>
      • clear

        public void clear()
        Specified by:
        clear in interface java.util.Collection<T>
      • contains

        public boolean contains​(java.lang.Object o)
        Specified by:
        contains in interface java.util.Collection<T>
      • containsAll

        public boolean containsAll​(java.util.Collection<?> c)
        Specified by:
        containsAll in interface java.util.Collection<T>
      • isEmpty

        public boolean isEmpty()
        Specified by:
        isEmpty in interface java.util.Collection<T>
      • iterator

        public java.util.Iterator<T> iterator()
        Specified by:
        iterator in interface java.util.Collection<T>
        Specified by:
        iterator in interface java.lang.Iterable<T>
      • remove

        public boolean remove​(java.lang.Object o)
        Specified by:
        remove in interface java.util.Collection<T>
      • removeAll

        public boolean removeAll​(java.util.Collection<?> c)
        Specified by:
        removeAll in interface java.util.Collection<T>
      • retainAll

        public boolean retainAll​(java.util.Collection<?> c)
        Specified by:
        retainAll in interface java.util.Collection<T>
      • size

        public int size()
        Specified by:
        size in interface java.util.Collection<T>
      • toArray

        public java.lang.Object[] toArray()
        Specified by:
        toArray in interface java.util.Collection<T>
      • toArray

        public java.lang.Object[] toArray​(java.lang.Object[] a)
        Specified by:
        toArray in interface java.util.Collection<T>
      • forEach

        public void forEach​(java.util.function.Consumer<? super T> action)
        Specified by:
        forEach in interface java.lang.Iterable<T>
      • removeIf

        public boolean removeIf​(java.util.function.Predicate<? super T> filter)
        Specified by:
        removeIf in interface java.util.Collection<T>
      • parallelStream

        public java.util.stream.Stream<T> parallelStream()
        Specified by:
        parallelStream in interface java.util.Collection<T>
      • stream

        public java.util.stream.Stream<T> stream()
        Specified by:
        stream in interface java.util.Collection<T>
      • spliterator

        public java.util.Spliterator<T> spliterator()
        Specified by:
        spliterator in interface java.util.Collection<T>
        Specified by:
        spliterator in interface java.lang.Iterable<T>