|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectetomica.atom.iterator.ApiInterArrayList
public class ApiInterArrayList
Returns all pairs formed from two different untabbed lists of atoms. Incorrect behavior will result if both lists refer to the same instance.
| Constructor Summary | |
|---|---|
ApiInterArrayList()
Construct iterator with an empty lists. |
|
ApiInterArrayList(IAtomList outerList,
IAtomList innerList)
Constructs iterator to return pairs from the given lists. |
|
| Method Summary | |
|---|---|
IAtomList |
getInnerList()
Returns the inner list used to generate the pairs. |
IAtomList |
getOuterList()
Returns the outer list used to generate the pairs. |
int |
nBody()
Returns 2, indicating that this is a pair iterator |
IAtomList |
next()
Returns the next iterate pair. |
void |
reset()
Sets iterator in condition to begin iteration. |
void |
setInnerList(IAtomList newList)
Sets the list that will be used to generate the pairs. |
void |
setOuterList(IAtomList newList)
Sets the list that will be used to generate the pairs. |
int |
size()
Returns the number of iterates, which is list.size*(list.size-1)/2 |
void |
unset()
Sets iterator such that hasNext is false. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public ApiInterArrayList()
public ApiInterArrayList(IAtomList outerList,
IAtomList innerList)
IllegalArgumentException - if both lists refer to the same instance| Method Detail |
|---|
public void reset()
reset in interface AtomsetIteratorIllegalStateException - if outer and inner lists have been set to the same instancepublic void unset()
unset in interface AtomsetIteratorpublic IAtomList next()
next in interface AtomLeafsetIteratorpublic int size()
size in interface AtomsetIteratorpublic int nBody()
nBody in interface AtomsetIteratorpublic void setOuterList(IAtomList newList)
atomList - the new atom list for iterationpublic void setInnerList(IAtomList newList)
atomList - the new atom list for iterationpublic IAtomList getOuterList()
public IAtomList getInnerList()
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||