|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectcom.azalient.api.a.store.ListAdapter<T>
T - the class of the objects in the array or listpublic class ListAdapter<T>
An adapter to allow a List, an ArrayList or an array of objects to expose an IList interface
| Constructor Summary | |
|---|---|
ListAdapter(ArrayList<T> a)
Create an adapter based on the given ArrayList. |
|
ListAdapter(List<T> a)
Create an adapter based on the given List of objects. |
|
ListAdapter(T[] a)
Create an adapter based on the given array of objects. |
|
| Method Summary | |
|---|---|
Collection<T> |
collection()
Return the objects as a collection |
T |
get(int index)
The index'th element in the list |
Iterator<T> |
iterator()
Returns an iterator over a set of elements of type I. |
int |
size()
The number of elements in the list |
T[] |
toArray(T[] ta)
Convert the list to an array. |
| Methods inherited from class java.lang.Object |
|---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public ListAdapter(ArrayList<T> a)
public ListAdapter(List<T> a)
public ListAdapter(T[] a)
Arrays.asList(Object...)
| Method Detail |
|---|
public Iterator<T> iterator()
iterator in interface Iterable<T>public int size()
IList
size in interface IList<T>public T get(int index)
IList
get in interface IList<T>public T[] toArray(T[] ta)
IList
toArray in interface IList<T>public Collection<T> collection()
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||