Package ptolemy.data.expr
Class ConcreteMatrixToken
- java.lang.Object
-
- ptolemy.data.Token
-
- ptolemy.data.MatrixToken
-
- ptolemy.data.expr.ConcreteMatrixToken
-
public class ConcreteMatrixToken extends MatrixToken
A token that represents an empty matrix, with no element type. This is instantiated by the Constants class with name "matrix".- Since:
- Ptolemy II 2.0
- Version:
- $Id$
- Author:
- Edward A. Lee
- See Also:
Constants- Pt.AcceptedRating:
- Yellow (wbwu)
- Pt.ProposedRating:
- Yellow (yuhong)
-
-
Field Summary
-
Fields inherited from class ptolemy.data.MatrixToken
_nils, DO_COPY, DO_NOT_COPY
-
-
Constructor Summary
Constructors Constructor Description ConcreteMatrixToken()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description intgetColumnCount()Return the number of columns of the contained matrix.TokengetElementAsToken(int row, int column)Throw an ArrayIndexOutOfBoundsException.TypegetElementType()Return the Type of the tokens contained in this matrix token.intgetRowCount()Return the number of rows of the contained matrix.TypegetType()Return the type of this token.-
Methods inherited from class ptolemy.data.MatrixToken
_add, _addElement, _divideElement, _elementIsNil, _isCloseTo, _isEqualTo, _moduloElement, _multiply, _multiplyElement, _subtract, _subtractElement, _subtractElementReverse, add, addReverse, arrayToMatrix, arrayToMatrix, arrayToMatrixReturnType, booleanMatrix, complexMatrix, create, createSequence, createSequenceReturnType, createTokenSequence, crop, determineSequenceLength, divide, divideReverse, doubleMatrix, fixMatrix, intMatrix, isCloseTo, isEqualTo, join, longMatrix, matrixToArray, matrixToArrayReturnType, modulo, moduloReverse, multiply, multiplyReverse, oneRight, split, subtract, subtractReverse, toArray, toArrayColumnMajor, toArrayReturnType, toString
-
Methods inherited from class ptolemy.data.Token
isCloseTo, isNil, notSupportedConversionMessage, notSupportedIncomparableConversionMessage, notSupportedIncomparableMessage, notSupportedMessage, notSupportedNullNilStringMessage, one, pow, zero, zeroReturnType
-
-
-
-
Method Detail
-
getColumnCount
public int getColumnCount()
Return the number of columns of the contained matrix.- Specified by:
getColumnCountin classMatrixToken- Returns:
- Zero.
-
getElementAsToken
public Token getElementAsToken(int row, int column) throws java.lang.ArrayIndexOutOfBoundsException
Throw an ArrayIndexOutOfBoundsException.- Specified by:
getElementAsTokenin classMatrixToken- Parameters:
row- The row index of the desired element.column- The column index of the desired element.- Returns:
- An exception.
- Throws:
java.lang.ArrayIndexOutOfBoundsException- Always thrown.
-
getElementType
public Type getElementType()
Return the Type of the tokens contained in this matrix token.- Specified by:
getElementTypein classMatrixToken- Returns:
- A Type.
-
getRowCount
public int getRowCount()
Return the number of rows of the contained matrix.- Specified by:
getRowCountin classMatrixToken- Returns:
- Zero.
-
-