ptolemy.data.expr
Class ASTPtMatrixConstructNode

java.lang.Object
  extended by ptolemy.data.expr.ASTPtRootNode
      extended by ptolemy.data.expr.ASTPtMatrixConstructNode
All Implemented Interfaces:
java.lang.Cloneable, Node

public class ASTPtMatrixConstructNode
extends ASTPtRootNode

The parse tree created from the expression string consists of a hierarchy of node objects. This class represents matrix construction using Matlab like expressions.

Since:
Ptolemy II 0.3
Version:
$Id: ASTPtMatrixConstructNode.java 38798 2005-07-08 20:00:01Z cxh $
Author:
Xiaojun Liu
See Also:
ASTPtRootNode, PtParser, Token
Accepted Rating:
Red (cxh)
Proposed Rating:
Yellow (nsmyth)

Field Summary
protected  int _form
          The form of the matrix construction.
protected  int _nColumns
          The number of columns of the matrix construction.
protected  int _nRows
          The number of rows of the matrix construction.
 
Fields inherited from class ptolemy.data.expr.ASTPtRootNode
_children, _id, _isConstant, _parent, _ptToken, _ptType
 
Constructor Summary
ASTPtMatrixConstructNode(int id)
           
ASTPtMatrixConstructNode(PtParser p, int id)
           
 
Method Summary
 int getColumnCount()
           
 int getForm()
           
 int getRowCount()
           
 void visit(ParseTreeVisitor visitor)
          Traverse this node with the given visitor.
 
Methods inherited from class ptolemy.data.expr.ASTPtRootNode
clone, displayParseTree, evaluateParseTree, getToken, getType, isCongruent, isConstant, isEvaluated, jjtAddChild, jjtClose, jjtGetChild, jjtGetNumChildren, jjtGetParent, jjtOpen, jjtSetParent, setConstant, setToken, setType, toString, toString
 
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

_nRows

protected int _nRows
The number of rows of the matrix construction.


_nColumns

protected int _nColumns
The number of columns of the matrix construction.


_form

protected int _form
The form of the matrix construction. _form is 1 when the matrix construction gives all elements. _form is 2 when using regularly spaced vector construction.

Constructor Detail

ASTPtMatrixConstructNode

public ASTPtMatrixConstructNode(int id)

ASTPtMatrixConstructNode

public ASTPtMatrixConstructNode(PtParser p,
                                int id)
Method Detail

getColumnCount

public int getColumnCount()

getForm

public int getForm()

getRowCount

public int getRowCount()

visit

public void visit(ParseTreeVisitor visitor)
           throws IllegalActionException
Traverse this node with the given visitor.

Overrides:
visit in class ASTPtRootNode
Throws:
IllegalActionException