public static class CharCollections.UnmodifiableCollection extends java.lang.Object implements CharCollection
| Modifier and Type | Method and Description |
|---|---|
boolean |
add(char o)
A Type-Specific add function to reduce (un)boxing
|
boolean |
addAll(char[] e,
int offset,
int length)
A Type-Specific Array based addAll method to reduce the amount of Wrapping
|
boolean |
addAll(CharCollection c)
A Type-Specific addAll function to reduce (un)boxing
|
boolean |
addAll(java.util.Collection<? extends java.lang.Character> c) |
void |
clear() |
boolean |
contains(char o)
A Type-Specific contains function to reduce (un)boxing
|
boolean |
containsAll(CharCollection c)
A Type-Specific containsAll function to reduce (un)boxing
|
boolean |
containsAll(java.util.Collection<?> c)
Deprecated.
|
boolean |
containsAny(CharCollection c)
A Type-Specific containsAny function to reduce (un)boxing
|
boolean |
containsAny(java.util.Collection<?> c)
Deprecated.
|
CharCollection |
copy()
A Function that does a shallow clone of the Collection itself.
|
int |
count(Char2BooleanFunction filter)
Helper function to reduce stream usage that allows to count the valid elements.
|
boolean |
equals(java.lang.Object obj) |
char |
findFirst(Char2BooleanFunction filter)
Helper function to reduce stream usage that allows to filter for the first match.
|
void |
forEach(CharConsumer action)
A Type Specific foreach function that reduces (un)boxing
|
void |
forEach(java.util.function.Consumer<? super java.lang.Character> action)
Deprecated.
|
<E> void |
forEach(E input,
ObjectCharConsumer<E> action)
Helper function to reduce Lambda usage and allow for more method references, since these are faster/cleaner.
|
int |
hashCode() |
boolean |
isEmpty() |
CharIterator |
iterator()
Returns a Type-Specific Iterator to reduce (un)boxing
|
boolean |
matchesAll(Char2BooleanFunction filter)
Helper function to reduce stream usage that allows to filter for all matches.
|
boolean |
matchesAny(Char2BooleanFunction filter)
Helper function to reduce stream usage that allows to filter for any matches.
|
boolean |
matchesNone(Char2BooleanFunction filter)
Helper function to reduce stream usage that allows to filter for no matches.
|
char |
reduce(char identity,
CharCharUnaryOperator operator)
Performs a reduction on the
elements of this Iterable
|
char |
reduce(CharCharUnaryOperator operator)
Performs a reduction on the
elements of this Iterable
|
boolean |
remChar(char o)
A Type-Specific remove function that reduces (un)boxing.
|
boolean |
remIf(java.util.function.IntPredicate filter)
A Type-Specific removeIf function to reduce (un)boxing.
|
boolean |
remove(java.lang.Object o)
Deprecated.
|
boolean |
removeAll(CharCollection c)
A Type-Specific removeAll function that reduces (un)boxing.
|
boolean |
removeAll(CharCollection c,
CharConsumer r)
A Type-Specific removeAll function that reduces (un)boxing.
|
boolean |
removeAll(java.util.Collection<?> c)
Deprecated.
|
boolean |
removeIf(java.util.function.Predicate<? super java.lang.Character> filter)
Deprecated.
|
boolean |
retainAll(CharCollection c)
A Type-Specific retainAll function that reduces (un)boxing.
|
boolean |
retainAll(CharCollection c,
CharConsumer r)
A Type-Specific retainAll function that reduces (un)boxing.
|
boolean |
retainAll(java.util.Collection<?> c)
Deprecated.
|
int |
size() |
java.lang.Object[] |
toArray() |
<T> T[] |
toArray(T[] a) |
char[] |
toCharArray()
A Type-Specific toArray function that delegates to
CharCollection.toCharArray(char[]) with a newly created array. |
char[] |
toCharArray(char[] a)
A Type-Specific toArray function that reduces (un)boxing.
|
java.lang.String |
toString() |
add, addAll, addAll, contains, parallelPrimitiveStream, pour, primitiveStream, spliterator, synchronize, synchronize, unmodifiablearrayflatMap, asAsync, distinct, filter, flatMap, limit, map, peek, pourAsList, pourAsSet, sortedpublic boolean add(char o)
CharCollectionadd in interface CharCollectiono - the element that should be addedpublic boolean addAll(java.util.Collection<? extends java.lang.Character> c)
addAll in interface java.util.Collection<java.lang.Character>public boolean addAll(CharCollection c)
CharCollectionaddAll in interface CharCollectionc - the collection of elements that should be addedpublic boolean addAll(char[] e,
int offset,
int length)
CharCollectionaddAll in interface CharCollectione - the elements that should be addedoffset - where to start within the arraylength - how many elements of the array should be addedpublic boolean contains(char o)
CharCollectioncontains in interface CharCollectiono - the element that is checked forpublic boolean containsAll(CharCollection c)
CharCollectioncontainsAll in interface CharCollectionc - the collection of elements that should be tested forpublic boolean containsAny(CharCollection c)
CharCollectioncontainsAny in interface CharCollectionc - the collection of elements that should be tested for@Deprecated public boolean containsAny(java.util.Collection<?> c)
CharCollectioncontainsAny in interface CharCollectionc - the collection of elements that should be tested for@Deprecated public boolean containsAll(java.util.Collection<?> c)
containsAll in interface java.util.Collection<java.lang.Character>public int size()
size in interface java.util.Collection<java.lang.Character>public boolean isEmpty()
isEmpty in interface java.util.Collection<java.lang.Character>public CharIterator iterator()
CharCollectioniterator in interface java.lang.Iterable<java.lang.Character>iterator in interface java.util.Collection<java.lang.Character>iterator in interface CharCollectioniterator in interface CharIterableCollection.iterator()public CharCollection copy()
CharCollectioncopy in interface CharCollection@Deprecated public boolean remove(java.lang.Object o)
CharCollectionThis default implementation delegates to the corresponding type-specific function.
remove in interface java.util.Collection<java.lang.Character>remove in interface CharCollection@Deprecated public boolean removeAll(java.util.Collection<?> c)
removeAll in interface java.util.Collection<java.lang.Character>@Deprecated public boolean retainAll(java.util.Collection<?> c)
retainAll in interface java.util.Collection<java.lang.Character>@Deprecated public boolean removeIf(java.util.function.Predicate<? super java.lang.Character> filter)
CharCollectionThis default implementation delegates to the corresponding type-specific function.
removeIf in interface java.util.Collection<java.lang.Character>removeIf in interface CharCollectionpublic boolean remChar(char o)
CharCollectionremChar in interface CharCollectiono - the element that should be removedCollection.remove(Object)public boolean removeAll(CharCollection c)
CharCollectionremoveAll in interface CharCollectionc - the collection of elements that should be removedCollection.removeAll(Collection)public boolean removeAll(CharCollection c, CharConsumer r)
CharCollectionremoveAll in interface CharCollectionc - the collection of elements that should be removedr - elements that got removedCollection.removeAll(Collection)public boolean retainAll(CharCollection c)
CharCollectionretainAll in interface CharCollectionc - the collection of elements that should be keptCollection.retainAll(Collection)public boolean retainAll(CharCollection c, CharConsumer r)
CharCollectionretainAll in interface CharCollectionc - the collection of elements that should be keptr - elements that got removedCollection.retainAll(Collection)public boolean remIf(java.util.function.IntPredicate filter)
CharCollectionRemoves elements that were selected by the filter
remIf in interface CharCollectionfilter - Filters the elements that should be removedCollection.removeIf(Predicate)public void clear()
clear in interface java.util.Collection<java.lang.Character>public java.lang.Object[] toArray()
toArray in interface java.util.Collection<java.lang.Character>public <T> T[] toArray(T[] a)
toArray in interface java.util.Collection<java.lang.Character>public char[] toCharArray()
CharCollectionCharCollection.toCharArray(char[]) with a newly created array.toCharArray in interface CharCollectionCollection.toArray()public char[] toCharArray(char[] a)
CharCollectiontoCharArray in interface CharCollectiona - array that the elements should be injected to. If null or to small a new array with the right size is createdCollection.toArray(Object[])public void forEach(CharConsumer action)
CharIterableforEach in interface CharIterableaction - The action to be performed for each elementIterable.forEach(Consumer)@Deprecated public void forEach(java.util.function.Consumer<? super java.lang.Character> action)
CharIterableThis default implementation delegates to the corresponding type-specific function.
forEach in interface java.lang.Iterable<java.lang.Character>forEach in interface CharIterablepublic int hashCode()
hashCode in interface java.util.Collection<java.lang.Character>hashCode in class java.lang.Objectpublic boolean equals(java.lang.Object obj)
equals in interface java.util.Collection<java.lang.Character>equals in class java.lang.Objectpublic java.lang.String toString()
toString in class java.lang.Objectpublic <E> void forEach(E input,
ObjectCharConsumer<E> action)
CharIterableforEach in interface CharIterableE - the generic type of the Objectinput - the object that should be includedaction - The action to be performed for each elementpublic boolean matchesAny(Char2BooleanFunction filter)
CharIterablematchesAny in interface CharIterablefilter - that should be appliedpublic boolean matchesNone(Char2BooleanFunction filter)
CharIterablematchesNone in interface CharIterablefilter - that should be appliedpublic boolean matchesAll(Char2BooleanFunction filter)
CharIterablematchesAll in interface CharIterablefilter - that should be appliedpublic char reduce(char identity,
CharCharUnaryOperator operator)
CharIterablereduce in interface CharIterableidentity - the start valueoperator - the operation that should be appliedpublic char reduce(CharCharUnaryOperator operator)
CharIterablereduce in interface CharIterableoperator - the operation that should be appliedpublic char findFirst(Char2BooleanFunction filter)
CharIterablefindFirst in interface CharIterablefilter - that should be appliedpublic int count(Char2BooleanFunction filter)
CharIterablecount in interface CharIterablefilter - that should be applied