public abstract class AbstractObjectCollection<K> extends AbstractCollection<K> implements ObjectCollection<K>
In particular, this class provide iterator(), add(), AbstractCollection.remove(Object) and
AbstractCollection.contains(Object) methods that just call the type-specific counterpart.
| 修飾子 | コンストラクタと説明 |
|---|---|
protected |
AbstractObjectCollection() |
| 修飾子とタイプ | メソッドと説明 |
|---|---|
boolean |
add(K k) |
boolean |
addAll(Collection<? extends K> c)
Adds all elements of the given collection to this collection.
|
boolean |
containsAll(Collection<?> c)
Checks whether this collection contains all elements from the given collection.
|
boolean |
isEmpty() |
abstract ObjectIterator<K> |
iterator()
Returns a type-specific iterator on the elements of this collection.
|
ObjectIterator<K> |
objectIterator()
非推奨です。
|
boolean |
removeAll(Collection<?> c)
Remove from this collection all elements in the given collection.
|
boolean |
retainAll(Collection<?> c)
Retains in this collection only elements from the given collection.
|
Object[] |
toArray() |
<T> T[] |
toArray(T[] a)
Returns an containing the items of this collection;
the runtime type of the returned array is that of the specified array.
|
String |
toString() |
clear, contains, remove, sizeclone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitclear, contains, equals, hashCode, parallelStream, remove, removeIf, size, spliterator, streampublic Object[] toArray()
toArray インタフェース内 Collection<K>toArray クラス内 AbstractCollection<K>public <T> T[] toArray(T[] a)
ObjectCollectionWarning: Note that, contrarily to Collection.toArray(Object[]), this
methods just writes all elements of this collection: no special
value will be added after the last one.
toArray インタフェース内 ObjectCollection<K>toArray インタフェース内 Collection<K>toArray クラス内 AbstractCollection<K>a - if this array is big enough, it will be used to store this collection.Collection.toArray(Object[])public boolean addAll(Collection<? extends K> c)
addAll インタフェース内 Collection<K>addAll クラス内 AbstractCollection<K>c - a collection.true if this collection changed as a result of the call.public boolean add(K k)
add インタフェース内 Collection<K>add クラス内 AbstractCollection<K>@Deprecated public ObjectIterator<K> objectIterator()
objectIterator インタフェース内 ObjectCollection<K>ObjectCollection.iterator()public abstract ObjectIterator<K> iterator()
ObjectCollectionNote 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 インタフェース内 ObjectCollection<K>iterator インタフェース内 ObjectIterable<K>iterator インタフェース内 Iterable<K>iterator インタフェース内 Collection<K>iterator クラス内 AbstractCollection<K>public boolean containsAll(Collection<?> c)
containsAll インタフェース内 Collection<K>containsAll クラス内 AbstractCollection<K>c - a collection.true if this collection contains all elements of the argument.public boolean retainAll(Collection<?> c)
retainAll インタフェース内 Collection<K>retainAll クラス内 AbstractCollection<K>c - a collection.true if this collection changed as a result of the call.public boolean removeAll(Collection<?> c)
removeAll インタフェース内 Collection<K>removeAll クラス内 AbstractCollection<K>c - a collection.true if this collection changed as a result of the call.public boolean isEmpty()
isEmpty インタフェース内 Collection<K>isEmpty クラス内 AbstractCollection<K>public String toString()
toString クラス内 AbstractCollection<K>Copyright © 2011–2016. All rights reserved.