Class MatrixCmp
- java.lang.Object
-
- com.singularsys.jep.functions.PostfixMathCommand
-
- com.singularsys.jep.functions.BinaryFunction
-
- com.singularsys.jep.functions.Comparative
-
- com.singularsys.extensions.matrix.functions.MatrixCmp
-
- All Implemented Interfaces:
MatrixFunctionI,PostfixMathCommandI,java.io.Serializable
public class MatrixCmp extends Comparative implements MatrixFunctionI
Compare two elements using a MatrixField.- See Also:
- Serialized Form
-
-
Field Summary
-
Fields inherited from class com.singularsys.jep.functions.PostfixMathCommand
curNumberOfParameters, name, NaN, numberOfParameters
-
-
Constructor Summary
Constructors Constructor Description MatrixCmp(MatrixFieldI mfact, int id_in)MatrixCmp(MatrixFieldI mfact, int id, double tolerance)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description DimensionscalcDims(Dimensions... inDims)Attempts to calculate the dimensions of a result of a PostfixMathCommand.booleaneq(java.lang.Object l, java.lang.Object r)booleange(java.lang.Object l, java.lang.Object r)booleangt(java.lang.Object l, java.lang.Object r)booleanle(java.lang.Object l, java.lang.Object r)booleanlt(java.lang.Object l, java.lang.Object r)booleanne(java.lang.Object l, java.lang.Object r)-
Methods inherited from class com.singularsys.jep.functions.Comparative
compare, eval, getId, getTolerance, setTolerance
-
Methods inherited from class com.singularsys.jep.functions.BinaryFunction
instanceOf, instanceOf, run
-
Methods inherited from class com.singularsys.jep.functions.PostfixMathCommand
asArray, asBool, asDouble, asInt, asLong, asStrictInt, asString, checkNumberOfParameters, getName, getNumberOfParameters, setCurNumberOfParameters, setName, toString, toString
-
-
-
-
Constructor Detail
-
MatrixCmp
public MatrixCmp(MatrixFieldI mfact, int id, double tolerance)
- Parameters:
id-tolerance-
-
MatrixCmp
public MatrixCmp(MatrixFieldI mfact, int id_in)
- Parameters:
id_in-
-
-
Method Detail
-
eq
public boolean eq(java.lang.Object l, java.lang.Object r) throws EvaluationException- Overrides:
eqin classComparative- Throws:
EvaluationException
-
ne
public boolean ne(java.lang.Object l, java.lang.Object r) throws EvaluationException- Overrides:
nein classComparative- Throws:
EvaluationException
-
ge
public boolean ge(java.lang.Object l, java.lang.Object r) throws EvaluationException- Overrides:
gein classComparative- Throws:
EvaluationException
-
gt
public boolean gt(java.lang.Object l, java.lang.Object r) throws EvaluationException- Overrides:
gtin classComparative- Throws:
EvaluationException
-
le
public boolean le(java.lang.Object l, java.lang.Object r) throws EvaluationException- Overrides:
lein classComparative- Throws:
EvaluationException
-
lt
public boolean lt(java.lang.Object l, java.lang.Object r) throws EvaluationException- Overrides:
ltin classComparative- Throws:
EvaluationException
-
calcDims
public Dimensions calcDims(Dimensions... inDims) throws ParseException
Description copied from interface:MatrixFunctionIAttempts to calculate the dimensions of a result of a PostfixMathCommand.- Specified by:
calcDimsin interfaceMatrixFunctionI- Parameters:
inDims- the dimensions of each argument- Returns:
- the dimension of the result or null if can be calculated
- Throws:
ParseException- if there is a parse error
-
-