|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.abr.calculator.BaseExpression
com.abr.calculator.VariableExpression
public class VariableExpression
VariableExpression - A value that must be extracted from a data source at run time.
Field Summary |
---|
Fields inherited from class com.abr.calculator.BaseExpression |
---|
m_embeddedExpr, m_master, m_nExpressionNumber, m_nGlobalExpressionNumber, m_objVariableResolutionData, m_strExpression |
Fields inherited from interface com.abr.calculator.IExpression |
---|
OPERATOR_ADD, OPERATOR_COLON, OPERATOR_COMMA, OPERATOR_DIV, OPERATOR_EXP, OPERATOR_MOD, OPERATOR_MULT, OPERATOR_NONE, OPERATOR_QUESTION, OPERATOR_SUB |
Constructor Summary | |
---|---|
VariableExpression(MasterExpression master,
java.lang.String strExpression)
|
Method Summary | |
---|---|
protected java.lang.String |
getInvalidChars()
DERIVED CLASSES: Override this method to customize the set of invalid characters. |
int |
getLogicalValueCount(IDataSource dataSource,
ExpressionError error)
Get the number of times that a caller must call this function to get all the possible data values. |
double |
getValue(int index,
IDataSource dataSource,
ExpressionError error)
Get the value associated with this expression. |
int |
getValueCount(IDataSource dataSource,
ExpressionError error)
Get the number of values associated with an expression. |
java.util.Vector |
getVariables()
Return a list of IExpression objects that correspond to the variable expressions for this expression. |
boolean |
parse(Parser parser,
ExpressionError error)
Parse this expression. |
boolean |
resolveVariables(IVariableResolver variableResolver)
Resolve any variable names within this expression. |
java.lang.String |
toString()
|
Methods inherited from class com.abr.calculator.BaseExpression |
---|
getEmbeddedExpressions, getExpression, getExpressionID, getMaster, getName, getVariableResolutionData, getVariables, setEmbeddedExpression, setExpression, updateMaster |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
---|
public VariableExpression(MasterExpression master, java.lang.String strExpression)
Method Detail |
---|
public boolean parse(Parser parser, ExpressionError error)
IExpression
parser
- - parsing object to useerror
- - error object for the expression to use
public boolean resolveVariables(IVariableResolver variableResolver)
IExpression
resolveVariables
in interface IExpression
resolveVariables
in class BaseExpression
variableResolver
- - object that can supply resolution
data for a given variable name
public java.util.Vector getVariables()
IExpression
getVariables
in interface IExpression
getVariables
in class BaseExpression
public double getValue(int index, IDataSource dataSource, ExpressionError error)
IExpression
index
- - index to use to extract data from data sourcedataSource
- - where can we extract variable data?error
- - used to store error results
public int getValueCount(IDataSource dataSource, ExpressionError error)
IExpression
dataSource
- - where can we extract variable data?error
- - used to store error results
public int getLogicalValueCount(IDataSource dataSource, ExpressionError error)
IExpression
public java.lang.String toString()
toString
in class java.lang.Object
protected java.lang.String getInvalidChars()
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |