Class AbstractSpecialisedImmutableSet<K>
java.lang.Object
java.util.AbstractCollection<K>
java.util.AbstractSet<K>
io.usethesource.capsule.util.collection.AbstractImmutableSet<K>
io.usethesource.capsule.util.collection.AbstractSpecialisedImmutableSet<K>
- All Implemented Interfaces:
Set<K>
,Set.Immutable<K>
,SetEq<K>
,SetEq.Immutable<K>
,Serializable
,Cloneable
,Iterable<K>
,Collection<K>
,Set<K>
public abstract class AbstractSpecialisedImmutableSet<K>
extends AbstractImmutableSet<K>
implements Set.Immutable<K>, Cloneable, Serializable
- See Also:
-
Nested Class Summary
Nested classes/interfaces inherited from interface io.usethesource.capsule.Set
Set.Immutable<K>, Set.Transient<K>
Nested classes/interfaces inherited from interface io.usethesource.capsule.SetEq
SetEq.Immutable<K>, SetEq.Transient<K>
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescription__insertAll
(Set<? extends K> set) __insertAllEquivalent
(Set<? extends K> set, EqualityComparator<Object> cmp) __removeAll
(Set<? extends K> set) __removeAllEquivalent
(Set<? extends K> set, EqualityComparator<Object> cmp) __retainAll
(Set<? extends K> set) __retainAllEquivalent
(Set.Transient<? extends K> set, EqualityComparator<Object> cmp) boolean
boolean
addAll
(Collection<? extends K> c) void
clear()
clone()
boolean
boolean
equivalent
(Object other, EqualityComparator<Object> cmp) boolean
isEmpty()
boolean
iterator()
private static <K> Set.Immutable
<K> of()
boolean
boolean
removeAll
(Collection<?> c) boolean
retainAll
(Collection<?> c) static <K> Set.Immutable
<K> setOf()
static <K> Set.Immutable
<K> static <K> Set.Immutable
<K> setOf
(K key1) static <K> Set.Immutable
<K> setOf
(K key1, K key2) static <K> Set.Immutable
<K> setOf
(K key1, K key2, K key3) static <K> Set.Immutable
<K> setOf
(K key1, K key2, K key3, K key4) static <K> Set.Immutable
<K> setOf
(K key1, K key2, K key3, K key4, K key5) static <K> Set.Immutable
<K> setOf
(K key1, K key2, K key3, K key4, K key5, K key6) Methods inherited from class io.usethesource.capsule.util.collection.AbstractImmutableSet
asTransient, containsAll, containsAllEquivalent
Methods inherited from class java.util.AbstractSet
hashCode
Methods inherited from class java.util.AbstractCollection
contains, size, toArray, toArray, toString
Methods inherited from class java.lang.Object
finalize, getClass, notify, notifyAll, wait, wait, wait
Methods inherited from interface java.util.Collection
parallelStream, removeIf, stream, toArray
Methods inherited from interface io.usethesource.capsule.Set
contains, containsAll, findFirst, get, hashCode, keyIterator, size
Methods inherited from interface java.util.Set
spliterator, toArray, toArray
Methods inherited from interface io.usethesource.capsule.Set.Immutable
__insert, __remove, asTransient, intersect, subtract, union
Methods inherited from interface io.usethesource.capsule.SetEq
containsAllEquivalent, containsEquivalent, getEquivalent
Methods inherited from interface io.usethesource.capsule.SetEq.Immutable
__insertEquivalent, __removeEquivalent
-
Field Details
-
EMPTY_SET
-
-
Constructor Details
-
AbstractSpecialisedImmutableSet
public AbstractSpecialisedImmutableSet()
-
-
Method Details
-
of
-
setOf
-
setOf
-
setOf
-
setOf
-
setOf
-
setOf
-
setOf
-
setOf
-
add
- Specified by:
add
in interfaceCollection<K>
- Specified by:
add
in interfaceSet<K>
- Overrides:
add
in classAbstractImmutableSet<K>
-
remove
- Specified by:
remove
in interfaceCollection<K>
- Specified by:
remove
in interfaceSet<K>
- Overrides:
remove
in classAbstractImmutableSet<K>
-
addAll
- Specified by:
addAll
in interfaceCollection<K>
- Specified by:
addAll
in interfaceSet<K>
- Overrides:
addAll
in classAbstractImmutableSet<K>
-
removeAll
- Specified by:
removeAll
in interfaceCollection<K>
- Specified by:
removeAll
in interfaceSet<K>
- Overrides:
removeAll
in classAbstractImmutableSet<K>
-
retainAll
- Specified by:
retainAll
in interfaceCollection<K>
- Specified by:
retainAll
in interfaceSet<K>
- Overrides:
retainAll
in classAbstractImmutableSet<K>
-
clear
public void clear()- Specified by:
clear
in interfaceCollection<K>
- Specified by:
clear
in interfaceSet<K>
- Overrides:
clear
in classAbstractImmutableSet<K>
-
isEmpty
public boolean isEmpty() -
iterator
-
equals
-
equivalent
- Specified by:
equivalent
in interfaceSetEq<K>
-
clone
- Overrides:
clone
in classObject
- Throws:
CloneNotSupportedException
-
isTransientSupported
public boolean isTransientSupported()- Specified by:
isTransientSupported
in interfaceSet.Immutable<K>
- Overrides:
isTransientSupported
in classAbstractImmutableSet<K>
-
__insertAll
- Specified by:
__insertAll
in interfaceSet.Immutable<K>
-
__insertAllEquivalent
- Specified by:
__insertAllEquivalent
in interfaceSetEq.Immutable<K>
-
__retainAll
- Specified by:
__retainAll
in interfaceSet.Immutable<K>
-
__retainAllEquivalent
public Set.Immutable<K> __retainAllEquivalent(Set.Transient<? extends K> set, EqualityComparator<Object> cmp) - Specified by:
__retainAllEquivalent
in interfaceSetEq.Immutable<K>
-
__removeAll
- Specified by:
__removeAll
in interfaceSet.Immutable<K>
-
__removeAllEquivalent
- Specified by:
__removeAllEquivalent
in interfaceSetEq.Immutable<K>
-