ObjectCollection<K>, ObjectIterable<K>, java.lang.Iterable<K>, java.util.Collection<K>ObjectBigLists.EmptyBigList, ObjectLists.EmptyList, ObjectSets.EmptySetpublic abstract static class ObjectCollections.EmptyCollection<K> extends AbstractObjectCollection<K>
This class may be useful to implement your own in case you subclass a type-specific collection.
| Modifier and Type | Method | Description |
|---|---|---|
boolean |
addAll(java.util.Collection<? extends K> c) |
|
void |
clear() |
|
boolean |
contains(java.lang.Object k) |
|
boolean |
equals(java.lang.Object o) |
|
int |
hashCode() |
|
ObjectBidirectionalIterator<K> |
iterator() |
Returns a type-specific iterator on the elements of this collection.
|
boolean |
removeAll(java.util.Collection<?> c) |
|
boolean |
retainAll(java.util.Collection<?> c) |
|
int |
size() |
|
java.lang.Object[] |
toArray() |
add, containsAll, isEmpty, remove, toArraytoStringpublic boolean contains(java.lang.Object k)
public java.lang.Object[] toArray()
public ObjectBidirectionalIterator<K> iterator()
ObjectCollection
Note that this specification strengthens the one given in
Iterable.iterator(), which was already strengthened in the
corresponding type-specific class, but was weakened by the fact that this
interface extends Collection.
iterator in interface java.util.Collection<K>iterator in interface java.lang.Iterable<K>iterator in interface ObjectCollection<K>iterator in interface ObjectIterable<K>iterator in class AbstractObjectCollection<K>Iterable.iterator()public int size()
public void clear()
public int hashCode()
hashCode in interface java.util.Collection<K>hashCode in class java.lang.Objectpublic boolean equals(java.lang.Object o)
equals in interface java.util.Collection<K>equals in class java.lang.Objectpublic boolean addAll(java.util.Collection<? extends K> c)
public boolean removeAll(java.util.Collection<?> c)