public abstract class AbstractCloseableIteratorCollection<O,K,V> extends AbstractCollection<O> implements CloseableIteratorCollection<O>
Collection.contains(Object)
, Collection.remove(Object)
and
CloseableIteratorCollection.iterator()
. The Collection.add(Object)
by default will throw an
UnsupportedOperationException
.
Constructor and Description |
---|
AbstractCloseableIteratorCollection(Cache<K,V> cache) |
Modifier and Type | Method and Description |
---|---|
void |
clear() |
abstract boolean |
contains(Object o) |
boolean |
isEmpty() |
abstract CloseableIterator<O> |
iterator() |
abstract boolean |
remove(Object o) |
boolean |
removeAll(Collection<?> c) |
boolean |
retainAll(Collection<?> c) |
int |
size() |
abstract CloseableSpliterator<O> |
spliterator() |
Object[] |
toArray() |
<T> T[] |
toArray(T[] a) |
add, addAll, containsAll, toString
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
parallelStream, stream
add, addAll, containsAll, equals, hashCode, removeIf
public abstract CloseableIterator<O> iterator()
CloseableIteratorCollection
This iterator should be explicitly closed when iteration upon it is completed. Failure to do so could cause resources to not be freed properly
iterator
in interface Iterable<O>
iterator
in interface Collection<O>
iterator
in interface CloseableIteratorCollection<O>
iterator
in class AbstractCollection<O>
public abstract CloseableSpliterator<O> spliterator()
CloseableIteratorCollection
This spliterator should be explicitly closed after it has been used. Failure to do so could cause resources to not be freed properly
spliterator
in interface Iterable<O>
spliterator
in interface Collection<O>
spliterator
in interface CloseableIteratorCollection<O>
public abstract boolean contains(Object o)
contains
in interface Collection<O>
contains
in class AbstractCollection<O>
public abstract boolean remove(Object o)
remove
in interface Collection<O>
remove
in class AbstractCollection<O>
public int size()
size
in interface Collection<O>
size
in class AbstractCollection<O>
public boolean isEmpty()
isEmpty
in interface Collection<O>
isEmpty
in class AbstractCollection<O>
public Object[] toArray()
toArray
in interface Collection<O>
toArray
in class AbstractCollection<O>
public <T> T[] toArray(T[] a)
toArray
in interface Collection<O>
toArray
in class AbstractCollection<O>
public boolean removeAll(Collection<?> c)
removeAll
in interface Collection<O>
removeAll
in class AbstractCollection<O>
public boolean retainAll(Collection<?> c)
retainAll
in interface Collection<O>
retainAll
in class AbstractCollection<O>
public void clear()
clear
in interface Collection<O>
clear
in class AbstractCollection<O>
Copyright © 2021 JBoss by Red Hat. All rights reserved.