Class DeepImmutableCollection<E>
java.lang.Object
java.util.AbstractCollection<E>
de.cronn.reflection.util.immutable.collection.DeepImmutableCollection<E>
- All Implemented Interfaces:
Immutable,Serializable,Iterable<E>,Collection<E>
- Direct Known Subclasses:
DeepImmutableList,DeepImmutableSet
public class DeepImmutableCollection<E>
extends AbstractCollection<E>
implements Collection<E>, Immutable, Serializable
- See Also:
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbooleanbooleanaddAll(@NotNull Collection<? extends E> c) voidclear()booleanbooleancontainsAll(@NotNull Collection<?> c) booleaninthashCode()booleanisEmpty()iterator()booleanbooleanremoveAll(@NotNull Collection<?> c) booleanretainAll(@NotNull Collection<?> c) intsize()Methods inherited from class java.util.AbstractCollection
toArray, toArray, toStringMethods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, waitMethods inherited from interface java.util.Collection
parallelStream, removeIf, spliterator, stream, toArray, toArray, toArray
-
Constructor Details
-
DeepImmutableCollection
-
-
Method Details
-
size
public int size()- Specified by:
sizein interfaceCollection<E>- Specified by:
sizein classAbstractCollection<E>
-
isEmpty
public boolean isEmpty()- Specified by:
isEmptyin interfaceCollection<E>- Overrides:
isEmptyin classAbstractCollection<E>
-
contains
- Specified by:
containsin interfaceCollection<E>- Overrides:
containsin classAbstractCollection<E>
-
iterator
- Specified by:
iteratorin interfaceCollection<E>- Specified by:
iteratorin interfaceIterable<E>- Specified by:
iteratorin classAbstractCollection<E>
-
containsAll
- Specified by:
containsAllin interfaceCollection<E>- Overrides:
containsAllin classAbstractCollection<E>
-
equals
- Specified by:
equalsin interfaceCollection<E>- Overrides:
equalsin classObject
-
hashCode
public int hashCode()- Specified by:
hashCodein interfaceCollection<E>- Overrides:
hashCodein classObject
-
add
- Specified by:
addin interfaceCollection<E>- Overrides:
addin classAbstractCollection<E>
-
remove
- Specified by:
removein interfaceCollection<E>- Overrides:
removein classAbstractCollection<E>
-
addAll
- Specified by:
addAllin interfaceCollection<E>- Overrides:
addAllin classAbstractCollection<E>
-
removeAll
- Specified by:
removeAllin interfaceCollection<E>- Overrides:
removeAllin classAbstractCollection<E>
-
retainAll
- Specified by:
retainAllin interfaceCollection<E>- Overrides:
retainAllin classAbstractCollection<E>
-
clear
public void clear()- Specified by:
clearin interfaceCollection<E>- Overrides:
clearin classAbstractCollection<E>
-