|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.xins.common.types.ItemList
Item in a list or a set type.
List
Constructor Summary | |
ItemList()
Creates a new ItemList . |
|
ItemList(boolean setType)
Creates a new ItemList . |
Method Summary | |
protected void |
addItem(Object value)
Adds an item to the list. |
protected Object |
getItem(int index)
Gets the item at the specified index as an Object . |
int |
getSize()
Gets the number of items included in the list. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
public ItemList()
ItemList
.
The list will be able to contain several instances of an object.
public ItemList(boolean setType)
ItemList
.
setType
- if true
an object can be added only once in the list,
if false
an object can be added several times in the list.Method Detail |
protected final void addItem(Object value) throws IllegalArgumentException
value
- the value of the item to add in the list, cannot be null
.
IllegalArgumentException
- if value == null
.protected final Object getItem(int index)
Object
.
index
- the position of the required item, it should be >= 0 and < getSize().
null
.public int getSize()
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |