E
- 要素型 public class AutoPopulatingList<E> extends ObjectSE implements ListSE<E>, SerializableSE
List
SE ラッパークラス。リクエストに応じて、要素を自動的に入力できます。これは、Lists
SE へのデータバインディングに特に役立ち、要素を「ジャストインタイム」で作成して List
SE に追加できます。 メモ: このクラスはスレッドセーフではありません。スレッドセーフバージョンを作成するには、Collections.synchronizedList(java.util.List<T>)
SE ユーティリティメソッドを使用します。
Commons Collections の LazyList
に触発されました。
修飾子と型 | クラスと説明 |
---|---|
static interface | AutoPopulatingList.ElementFactory<E> List SE などのインデックスベースのアクセスデータ構造の要素を作成するためのファクトリインターフェース。 |
static class | AutoPopulatingList.ElementInstantiationException ElementFactory からスローされる例外。 |
コンストラクターと説明 |
---|
AutoPopulatingList(AutoPopulatingList.ElementFactory<E> elementFactory) 標準の ArrayList SE に基づく新しい AutoPopulatingList を作成し、提供された AutoPopulatingList.ElementFactory を使用してオンデマンドで新しい要素を作成します。 |
AutoPopulatingList(ClassSE<? extends E> elementClass) 標準の ArrayList SE によってサポートされる新しい AutoPopulatingList を作成し、提供された element Class SE の新しいインスタンスをオンデマンドでバッキング List SE に追加します。 |
AutoPopulatingList(ListSE<E> backingList, AutoPopulatingList.ElementFactory<E> elementFactory) 提供された List SE によってサポートされる新しい AutoPopulatingList を作成し、提供された AutoPopulatingList.ElementFactory を使用してオンデマンドで新しい要素を作成します。 |
AutoPopulatingList(ListSE<E> backingList, ClassSE<? extends E> elementClass) 提供された List SE によってサポートされる新しい AutoPopulatingList を作成し、オンデマンドで提供された element Class SE の新しいインスタンスをバッキング List SE に追加します。 |
修飾子と型 | メソッドと説明 |
---|---|
boolean | add(E o) |
void | add(int index, E element) |
boolean | addAll(CollectionSE<? extends E> c) |
boolean | addAll(int index, CollectionSE<? extends E> c) |
void | clear() |
boolean | contains(ObjectSE o) |
boolean | containsAll(CollectionSE<?> c) |
boolean | equals(ObjectSE other) |
E | get(int index) 指定されたインデックスの要素を取得し、そのインデックスに要素がない場合は作成します。 |
int | hashCode() |
int | indexOf(ObjectSE o) |
boolean | isEmpty() |
IteratorSE<E> | iterator() |
int | lastIndexOf(ObjectSE o) |
ListIteratorSE<E> | listIterator() |
ListIteratorSE<E> | listIterator(int index) |
E | remove(int index) |
boolean | remove(ObjectSE o) |
boolean | removeAll(CollectionSE<?> c) |
boolean | retainAll(CollectionSE<?> c) |
E | set(int index, E element) |
int | size() |
ListSE<E> | subList(int fromIndex, int toIndex) |
ObjectSE[] | toArray() |
<T> T[] | toArray(T[] a) |
cloneSE, finalizeSE, getClassSE, notifySE, notifyAllSE, toStringSE, waitSE, waitSE, waitSE
replaceAllSE, sortSE, spliteratorSE
parallelStreamSE, removeIfSE, streamSE
forEachSE
public AutoPopulatingList(ClassSE<? extends E> elementClass)
ArrayList
SE によってサポートされる新しい AutoPopulatingList
を作成し、提供された element Class
SE の新しいインスタンスをオンデマンドでバッキング List
SE に追加します。public AutoPopulatingList(ListSE<E> backingList, ClassSE<? extends E> elementClass)
List
SE によってサポートされる新しい AutoPopulatingList
を作成し、オンデマンドで提供された element Class
SE の新しいインスタンスをバッキング List
SE に追加します。public AutoPopulatingList(AutoPopulatingList.ElementFactory<E> elementFactory)
ArrayList
SE に基づく新しい AutoPopulatingList
を作成し、提供された AutoPopulatingList.ElementFactory
を使用してオンデマンドで新しい要素を作成します。public AutoPopulatingList(ListSE<E> backingList, AutoPopulatingList.ElementFactory<E> elementFactory)
List
SE によってサポートされる新しい AutoPopulatingList
を作成し、提供された AutoPopulatingList.ElementFactory
を使用してオンデマンドで新しい要素を作成します。public boolean addAll(CollectionSE<? extends E> c)
public boolean addAll(int index, CollectionSE<? extends E> c)
public void clear()
public boolean contains(ObjectSE o)
CollectionSE<E>
の containsSE
ListSE<E>
の containsSE
public boolean containsAll(CollectionSE<?> c)
CollectionSE<E>
の containsAllSE
ListSE<E>
の containsAllSE
public E get(int index)
public boolean isEmpty()
public IteratorSE<E> iterator()
IterableSE<E>
の iteratorSE
CollectionSE<E>
の iteratorSE
ListSE<E>
の iteratorSE
public int lastIndexOf(ObjectSE o)
ListSE<E>
の lastIndexOfSE
public ListIteratorSE<E> listIterator()
ListSE<E>
の listIteratorSE
public ListIteratorSE<E> listIterator(int index)
ListSE<E>
の listIteratorSE
public boolean remove(ObjectSE o)
public boolean removeAll(CollectionSE<?> c)
CollectionSE<E>
の removeAllSE
ListSE<E>
の removeAllSE
public boolean retainAll(CollectionSE<?> c)
CollectionSE<E>
の retainAllSE
ListSE<E>
の retainAllSE
public ObjectSE[] toArray()
public <T> T[] toArray(T[] a)
public int hashCode()
CollectionSE<E>
の hashCodeSE
ListSE<E>
の hashCodeSE
ObjectSE
の hashCodeSE