|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.opensourcephysics.numerics.MathExpParser
public abstract class MathExpParser
MathExpParser defines an abstract super class for mathematical expression parsers.
Field Summary | |
---|---|
static int |
NO_ERROR
No error. |
static int |
SYNTAX_ERROR
Syntax error. |
Constructor Summary | |
---|---|
MathExpParser()
|
Method Summary | |
---|---|
static MathExpParser |
createParser()
|
abstract java.lang.String |
getFunction()
Gets the function string. |
abstract java.lang.String[] |
getFunctionNames()
Returns names of functions recognized by the parser. |
abstract void |
setFunction(java.lang.String funcStr)
Parses the function string using existing variable names. |
abstract void |
setFunction(java.lang.String funcStr,
java.lang.String[] vars)
Parses the function string using existing variable names. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Methods inherited from interface org.opensourcephysics.numerics.Function |
---|
evaluate |
Methods inherited from interface org.opensourcephysics.numerics.MultiVarFunction |
---|
evaluate |
Field Detail |
---|
public static final int NO_ERROR
public static final int SYNTAX_ERROR
Constructor Detail |
---|
public MathExpParser()
Method Detail |
---|
public abstract void setFunction(java.lang.String funcStr) throws ParserException
funcStr
- the function to be parsed
ParserException
public abstract void setFunction(java.lang.String funcStr, java.lang.String[] vars) throws ParserException
funcStr
- the function to be parsedvars
- the function's variables
ParserException
public abstract java.lang.String getFunction()
public static MathExpParser createParser()
public abstract java.lang.String[] getFunctionNames()
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |