Klasse AbstractObjectCollection<T>

java.lang.Object
java.util.AbstractCollection<T>
speiger.src.collections.objects.collections.AbstractObjectCollection<T>
Typparameter:
T - the keyType of elements maintained by this Collection
Alle implementierten Schnittstellen:
Iterable<T>, Collection<T>, ObjectCollection<T>, ObjectIterable<T>, ISizeProvider
Bekannte direkte Unterklassen:
AbstractObjectList, AbstractObjectSet, ObjectCollections.EmptyCollection

public abstract class AbstractObjectCollection<T> extends AbstractCollection<T> implements ObjectCollection<T>
Abstract Type Specific Collection that reduces boxing/unboxing
  • Konstruktordetails

    • AbstractObjectCollection

      public AbstractObjectCollection()
  • Methodendetails

    • iterator

      public abstract ObjectIterator<T> iterator()
      Beschreibung aus Schnittstelle kopiert: ObjectCollection
      Returns a Type-Specific Iterator to reduce (un)boxing
      Angegeben von:
      iterator in Schnittstelle Collection<T>
      Angegeben von:
      iterator in Schnittstelle Iterable<T>
      Angegeben von:
      iterator in Schnittstelle ObjectCollection<T>
      Angegeben von:
      iterator in Schnittstelle ObjectIterable<T>
      Angegeben von:
      iterator in Klasse AbstractCollection<T>
      Gibt zurück:
      a iterator of the collection
      Siehe auch:
    • addAll

      public boolean addAll(ObjectCollection<T> c)
      Beschreibung aus Schnittstelle kopiert: ObjectCollection
      A Type-Specific addAll function to reduce (un)boxing
      Angegeben von:
      addAll in Schnittstelle ObjectCollection<T>
      Parameter:
      c - the collection of elements that should be added
      Gibt zurück:
      true if elements were added into the collection
    • copy

      public ObjectCollection<T> copy()
      Beschreibung aus Schnittstelle kopiert: ObjectCollection
      A Function that does a shallow clone of the Collection itself. This function is more optimized then a copy constructor since the Collection does not have to be unsorted/resorted. It can be compared to Cloneable but with less exception risk
      Angegeben von:
      copy in Schnittstelle ObjectCollection<T>
      Gibt zurück:
      a Shallow Copy of the collection
    • containsAll

      public boolean containsAll(ObjectCollection<T> c)
      A Type-Specific implementation of containsAll. This implementation iterates over all elements and checks all elements are present in the other collection.
      Angegeben von:
      containsAll in Schnittstelle ObjectCollection<T>
      Parameter:
      c - the collection that should be checked if it contains all elements.
      Gibt zurück:
      true if all elements were found in the collection
      Löst aus:
      NullPointerException - if the collection is null
    • containsAll

      public boolean containsAll(Collection<?> c)
      Angegeben von:
      containsAll in Schnittstelle Collection<T>
      Setzt außer Kraft:
      containsAll in Klasse AbstractCollection<T>
    • containsAny

      public boolean containsAny(Collection<?> c)
      This implementation iterates over the elements of the collection and checks if they are stored in this collection
      Angegeben von:
      containsAny in Schnittstelle ObjectCollection<T>
      Parameter:
      c - the elements that should be checked for
      Gibt zurück:
      true if any element is in this collection
      Löst aus:
      NullPointerException - if the collection is null
    • containsAny

      public boolean containsAny(ObjectCollection<T> c)
      This implementation iterates over the elements of the collection and checks if they are stored in this collection.
      Angegeben von:
      containsAny in Schnittstelle ObjectCollection<T>
      Parameter:
      c - the elements that should be checked for
      Gibt zurück:
      true if any element is in this collection
      Löst aus:
      NullPointerException - if the collection is null
    • removeAll

      public boolean removeAll(ObjectCollection<T> c)
      A Type-Specific implementation of removeAll. This Implementation iterates over all elements and removes them as they were found in the other collection.
      Angegeben von:
      removeAll in Schnittstelle ObjectCollection<T>
      Parameter:
      c - the elements that should be deleted
      Gibt zurück:
      true if the collection was modified.
      Löst aus:
      NullPointerException - if the collection is null
      Siehe auch:
    • removeAll

      public boolean removeAll(ObjectCollection<T> c, Consumer<T> r)
      Beschreibung aus Schnittstelle kopiert: ObjectCollection
      A Type-Specific removeAll function that reduces (un)boxing. It also notifies the remover of which exact element is going to be removed.
      Angegeben von:
      removeAll in Schnittstelle ObjectCollection<T>
      Parameter:
      c - the collection of elements that should be removed
      r - elements that got removed
      Gibt zurück:
      true if any element was removed
      Siehe auch:
    • retainAll

      public boolean retainAll(ObjectCollection<T> c)
      A Type-Specific implementation of retainAll. This Implementation iterates over all elements and removes them as they were not found in the other collection.
      Angegeben von:
      retainAll in Schnittstelle ObjectCollection<T>
      Parameter:
      c - the elements that should be kept
      Gibt zurück:
      true if the collection was modified.
      Löst aus:
      NullPointerException - if the collection is null
      Siehe auch:
    • retainAll

      public boolean retainAll(ObjectCollection<T> c, Consumer<T> r)
      Beschreibung aus Schnittstelle kopiert: ObjectCollection
      A Type-Specific retainAll function that reduces (un)boxing. It also notifies the remover of which exact element is going to be removed.
      Angegeben von:
      retainAll in Schnittstelle ObjectCollection<T>
      Parameter:
      c - the collection of elements that should be kept
      r - elements that got removed
      Gibt zurück:
      true if any element was removed
      Siehe auch: