|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object java.util.AbstractCollection<E> java.util.AbstractList<E> java.util.ArrayList com.opensymphony.xwork2.util.XWorkList
public class XWorkList
A simple list that guarantees that inserting and retrieving objects will always work regardless
of the current size of the list. Upon insertion, type conversion is also performed if necessary.
Empty beans will be created to fill the gap between the current list size and the requested index
using ObjectFactory's buildBean
method.
Field Summary |
---|
Fields inherited from class java.util.AbstractList |
---|
modCount |
Constructor Summary | |
---|---|
XWorkList(ObjectFactory fac,
XWorkConverter conv,
Class clazz)
|
|
XWorkList(ObjectFactory fac,
XWorkConverter conv,
Class clazz,
int initialCapacity)
|
Method Summary | |
---|---|
void |
add(int index,
Object element)
Inserts the specified element at the specified position in this list. |
boolean |
add(Object element)
Appends the specified element to the end of this list. |
boolean |
addAll(Collection c)
Appends all of the elements in the specified Collection to the end of this list, in the order that they are returned by the specified Collection's Iterator. |
boolean |
addAll(int index,
Collection c)
Inserts all of the elements in the specified Collection into this list, starting at the specified position. |
boolean |
contains(Object element)
|
Object |
get(int index)
Returns the element at the specified position in this list. |
Object |
set(int index,
Object element)
Replaces the element at the specified position in this list with the specified element. |
Methods inherited from class java.util.ArrayList |
---|
clear, clone, ensureCapacity, indexOf, isEmpty, lastIndexOf, remove, remove, removeRange, size, toArray, toArray, trimToSize |
Methods inherited from class java.util.AbstractList |
---|
equals, hashCode, iterator, listIterator, listIterator, subList |
Methods inherited from class java.util.AbstractCollection |
---|
containsAll, removeAll, retainAll, toString |
Methods inherited from class java.lang.Object |
---|
finalize, getClass, notify, notifyAll, wait, wait, wait |
Methods inherited from interface java.util.List |
---|
containsAll, equals, hashCode, iterator, listIterator, listIterator, removeAll, retainAll, subList |
Constructor Detail |
---|
public XWorkList(ObjectFactory fac, XWorkConverter conv, Class clazz)
public XWorkList(ObjectFactory fac, XWorkConverter conv, Class clazz, int initialCapacity)
Method Detail |
---|
public void add(int index, Object element)
add
in interface List
add
in class ArrayList
index
- index at which the specified element is to be inserted.element
- element to be inserted.public boolean add(Object element)
add
in interface Collection
add
in interface List
add
in class ArrayList
element
- element to be appended to this list.
public boolean addAll(Collection c)
addAll
in interface Collection
addAll
in interface List
addAll
in class ArrayList
c
- the elements to be inserted into this list.
NullPointerException
- if the specified collection is null.public boolean addAll(int index, Collection c)
addAll
in interface List
addAll
in class ArrayList
index
- index at which to insert first element from the specified collection.c
- elements to be inserted into this list.
public Object get(int index)
get
in interface List
get
in class ArrayList
index
- index of element to return.
public Object set(int index, Object element)
set
in interface List
set
in class ArrayList
index
- index of element to replace.element
- element to be stored at the specified position.
public boolean contains(Object element)
contains
in interface Collection
contains
in interface List
contains
in class ArrayList
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |