|
JADE Java Persistence API 1.0 |
||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectcom.jadeworld.jade.rootschema.Object
com.jadeworld.jade.rootschema.Collection<M>
com.jadeworld.jade.rootschema.Array<M>
public abstract class Array<M>
Superclass of all JADE Array classes. Implements the Java List interface plus JADE-specific methods.
| Field Summary |
|---|
| Fields inherited from class com.jadeworld.jade.rootschema.Object |
|---|
oid |
| Constructor Summary | |
|---|---|
Array()
|
|
| Method Summary | |
|---|---|
void |
add(int index,
M element)
Places an entry in the array of the object specified in the element parameter at the position specified by the index parameter. |
boolean |
add(M element)
Adds an entry to the end of the array. |
boolean |
addAll(int index,
java.util.Collection<? extends M> c)
Inserts all of the elements in the specified collection into this list at the specified position (optional operation). |
M |
at(int index)
Returns a reference to the entry in the array at the position specified by the index parameter; for example: |
void |
atPut(int index,
M element)
The atPut method of the Array class places an entry in the array of the object specified in the value parameter at the position specified by the index parameter. |
M |
get(int index)
Returns a reference to the entry in the array at the position specified by the index parameter; for example: |
int |
indexOf(java.lang.Object o)
Returns the index of the entry specified in the value parameter if it exists in the array or it returns zero (0) if it does not exist. |
int |
lastIndexOf(java.lang.Object o)
Returns the index of the last occurrence of the specified element in this list, or -1 if this list does not contain the element. |
java.util.ListIterator<M> |
listIterator()
|
java.util.ListIterator<M> |
listIterator(int index)
|
M |
remove(int index)
Removes an entry from an array at the position specified in the index parameter and moves all entries at a higher index down one slot to fill the gap. |
boolean |
remove(Object o)
Removes the entry specified in the value parameter from an array. |
void |
replace(int index,
M element)
Replaces an existing entry in an array at the position specified by the index parameter with the entry specified in the value parameter. |
M |
set(int index,
M element)
Replaces an existing entry in an array at the position specified by the index parameter with the entry specified in the value parameter. |
java.util.List<M> |
subList(int from,
int to)
|
java.lang.Object[] |
toArray()
Returns an Object array containing all of this collection's items in the order specified by the collection iterator. |
java.lang.Object[] |
toArray(java.lang.Object[] a)
Not yet implemented |
| Methods inherited from class com.jadeworld.jade.rootschema.Collection |
|---|
addAll, clear, contains, containsAll, copy, countOf, createIterator, deleteIfEmpty, first, getOwner, getStatistics, instantiate, isEmpty, iterator, last, maxSize, purge, remove, removeAll, retainAll, setBlockSize, size, toString |
| Methods inherited from class java.lang.Object |
|---|
equals, getClass, notify, notifyAll, wait, wait, wait |
| Methods inherited from interface java.util.List |
|---|
addAll, clear, contains, containsAll, equals, hashCode, isEmpty, iterator, remove, removeAll, retainAll, size |
| Constructor Detail |
|---|
public Array()
| Method Detail |
|---|
public boolean add(M element)
add in interface java.util.Collection<M>add in interface java.util.List<M>add in class Collection<M>element - The object to add to the array.
Collection.add(M)).
public void add(int index,
M element)
add in interface java.util.List<M>element - The object to add to the array.index - The index at which to insert the object.
public boolean addAll(int index,
java.util.Collection<? extends M> c)
addAll in interface java.util.List<M>index - Index at which to insert the first element from the
specified collectionc - Collection containing elements to be added to this list
public M get(int index)
firstCustomer = currentList.get(0);
If there is no entry at the specified index, an exception is raised.
get in interface java.util.List<M>index - Index of the item to return.
public M set(int index,
M element)
set in interface java.util.List<M>index - Index of the element to replace.element - Element to be stored at the specified position.
public int lastIndexOf(java.lang.Object o)
lastIndexOf in interface java.util.List<M>o - The object to check for.
public int indexOf(java.lang.Object o)
indexOf in interface java.util.List<M>indexOf in class Collection<M>o - The object to check for.
public M remove(int index)
remove in interface java.util.List<M>index - Index of the element to remove.
public boolean remove(Object o)
o - The element to remove.
public java.lang.Object[] toArray()
toArray in interface java.util.Collection<M>toArray in interface java.util.List<M>toArray in class Collection<M>public java.lang.Object[] toArray(java.lang.Object[] a)
toArray in interface java.util.Collection<M>toArray in interface java.util.List<M>toArray in class Collection<M>
public java.util.List<M> subList(int from,
int to)
subList in interface java.util.List<M>public java.util.ListIterator<M> listIterator()
listIterator in interface java.util.List<M>public java.util.ListIterator<M> listIterator(int index)
listIterator in interface java.util.List<M>public M at(int index)
firstCustomer = currentList.at(0);
If there is no entry at the specified index, an exception is raised.
JADE-only method, the JADE version of get(int).
index - Index of the item to return.
public void atPut(int index,
M element)
element - The object to add to the array.index - The index at which to insert the object.
public void replace(int index,
M element)
set(int, M) in that it does not return the previous value. The set method implements the
java.util.List behavior and the replace methods implements the JADE behavior.
index - Index of the element to replace.element - Element to be stored at the specified position.
|
JADE Java Persistence API 1.0 |
||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||