|
|||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--EDU.bmrb.starlibj.StarNode | +--EDU.bmrb.starlibj.LoopRowNode
A LoopRowNode is a single tuple of values for a loop, like a 'row' in a table. It behaves like a VectorCheckType class, implementing most of the same API as VectorCheckType.
VectorCheckType
Fields inherited from class EDU.bmrb.starlibj.StarNode |
colNum,
lineNum,
parent,
preComment |
Constructor Summary | |
LoopRowNode()
Default constructor |
|
LoopRowNode(LoopRowNode copyMe)
copy constructor |
Method Summary | |
void |
addElement(DataValueNode val)
Just like the Vector method of the same name, but It will refuse to work if this row is already inside a DataLoopNode, and it will generate an exception. |
int |
capacity()
Return the max number of characters that this row can hold before it needs to allocate a bigger chunk of heap memory. |
java.lang.Object |
clone()
clone - make a deep copy of me and return a reference to it. |
DataValueNode |
elementAt(int index)
Just like the Vector method of the same name. |
void |
ensureCapacity(int newCap)
Enlarge capacity of the stringbuffer so that it can hold newCap characters. |
DataValueNode |
firstElement()
Just like the Vector method of the same name. |
LoopTableNode |
getInnerLoop()
Returns a reference to the inner loop that is under this row. |
void |
insertElementAt(DataValueNode val,
int index)
Just like the Vector method of the same name, but It will refuse to work if this row is already inside a DataLoopNode, and it will generate an exception. |
boolean |
isEmpty()
Just like the Vector method of the same name. |
int |
isInLoop()
isInLoop: Returns >zero if this LoopRowNode is inside a DataLoopNode, or zero if it is not. |
DataValueNode |
lastElement()
Just like the Vector method of the same name. |
void |
removeElementAt(int index)
Similar to the Vector method of the same name, however It will refuse to work if this row is already inside a DataLoopNode, and it will generate an exception. |
void |
removeInnerLoop()
De-links the inner loop from this row. |
VectorCheckType |
searchForType(java.lang.Class type)
Find all values of the type given in this table - this is fairly nonsensical because all values in the table are of type DataValueNode, but this function is here for orthogonality with the base class StarNode. |
VectorCheckType |
searchForType(java.lang.Class type,
short delim)
Find the type given in this row - Return all the matching values that meet the criteria given in the parameters. |
void |
setElementAt(DataValueNode val,
int index)
Just like the Vector method of the same name. |
void |
setInnerLoop(LoopTableNode l)
Allows the user to set the inner loop under this row. |
int |
size()
Just like the Vector method of the same name. |
java.lang.String |
stringAt(int i)
return the element at the position given, but return the result as a simple string rather than as a DataValueNode. |
void |
Unparse(int indent)
Unparse prints the contents of the StarNode object out to the given stream. |
Methods inherited from class EDU.bmrb.starlibj.StarNode |
getColNum,
getLineNum,
getParallelCopy,
getParent,
getPreComment,
mySkips,
searchByName,
searchByTagValue,
searchForTypeByName,
searchForTypeByTagValue,
setColNum,
setLineNum,
setParent,
setPeer,
setPreComment |
Methods inherited from class java.lang.Object |
equals,
finalize,
getClass,
hashCode,
notify,
notifyAll,
toString,
wait,
wait,
wait |
Constructor Detail |
public LoopRowNode()
public LoopRowNode(LoopRowNode copyMe)
Method Detail |
public java.lang.Object clone()
public void ensureCapacity(int newCap)
public int capacity()
if( numberOfCharactersIKnowINeed > row.capacity() ) row.ensureCapacity( numberOfCharactersIKnowINeed );
public int size()
VectorCheckType.size
public boolean isEmpty()
VectorCheckType.isEmpty
public DataValueNode elementAt(int index)
VectorCheckType.elementAt
public java.lang.String stringAt(int i)
public DataValueNode firstElement()
VectorCheckType.firstElement
public DataValueNode lastElement()
VectorCheckType.lastElement
public void setElementAt(DataValueNode val, int index)
VectorCheckType.setElementAt
public void removeElementAt(int index) throws OperationCausesMismatchedLoopData
VectorCheckType.removeElementAt
public void insertElementAt(DataValueNode val, int index) throws OperationCausesMismatchedLoopData
VectorCheckType.insertElementAt
public void addElement(DataValueNode val) throws OperationCausesMismatchedLoopData
VectorCheckType.addElement
public int isInLoop()
The value returned is an integer. It is a count of how many nesting levels deep this is in the loop that it was found it. Thus if it is zero (false) it was not found in a loop, and if it is 1 then it was found in nesting level 1 of a loop, 2 = nesting level 2, etc.
Note that this is off-by-one with the index used in the [] operator, which starts counting at zero. This was done so that this method could be used like a boolean. (zero means not found, nonzero means found).
public LoopTableNode getInnerLoop()
public void setInnerLoop(LoopTableNode l) throws OperationCausesMismatchedLoopData
public void removeInnerLoop()
public VectorCheckType searchForType(java.lang.Class type)
type
- look for this type.public VectorCheckType searchForType(java.lang.Class type, short delim)
type
- look for this typedelim
- Look for this delimiter type.public void Unparse(int indent)
|
|||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |