public class JRBshEvaluator extends JREvaluator
JRBshCompiler
Modifier and Type | Field and Description |
---|---|
static String |
EXCEPTION_MESSAGE_KEY_EXPRESSIONS_EVALUATING_ERROR |
static String |
EXCEPTION_MESSAGE_KEY_EXPRESSIONS_TESTING_ERROR |
static String |
EXCEPTION_MESSAGE_KEY_INITIALIZING_REPORT_CALCULATOR |
EXCEPTION_MESSAGE_KEY_RESOURCE_NOT_FOUND, PROPERTY_IGNORE_NPE
Constructor and Description |
---|
JRBshEvaluator(String bshScript) |
Modifier and Type | Method and Description |
---|---|
protected void |
customizedInit(Map<String,JRFillParameter> pars,
Map<String,JRFillField> fldsm,
Map<String,JRFillVariable> varsm)
Initializes the parameters, fields and variables of the evaluator.
|
protected Object |
evaluate(int id)
Evaluates an expression using current fields and variables values.
|
protected Object |
evaluateEstimated(int id)
Evaluates an expression using estimated variables values.
|
protected Object |
evaluateOld(int id)
Evaluates an expression using old fields and variables values.
|
<T> void |
verify(Collection<T> expressions) |
evaluate, evaluateEstimated, evaluateOld, getFunctionSupport, handleMissingResource, init, msg, msg, msg, msg, str
public static final String EXCEPTION_MESSAGE_KEY_INITIALIZING_REPORT_CALCULATOR
public static final String EXCEPTION_MESSAGE_KEY_EXPRESSIONS_EVALUATING_ERROR
public static final String EXCEPTION_MESSAGE_KEY_EXPRESSIONS_TESTING_ERROR
public JRBshEvaluator(String bshScript) throws JRException
JRException
public <T> void verify(Collection<T> expressions) throws JRException
JRException
protected void customizedInit(Map<String,JRFillParameter> pars, Map<String,JRFillField> fldsm, Map<String,JRFillVariable> varsm) throws JRException
JREvaluator
customizedInit
in class JREvaluator
pars
- the parameters indexed by namefldsm
- the fields indexed by namevarsm
- the variables indexed by nameJRException
protected Object evaluateOld(int id) throws Throwable
JREvaluator
evaluateOld
in class JREvaluator
id
- the expression idThrowable
JRExpression.EVALUATION_OLD
,
JRFillVariable.getOldValue()
,
JRFillField.getOldValue()
protected Object evaluateEstimated(int id) throws Throwable
JREvaluator
evaluateEstimated
in class JREvaluator
id
- the expression idThrowable
JRExpression.EVALUATION_ESTIMATED
,
JRFillVariable.getEstimatedValue()
protected Object evaluate(int id) throws Throwable
JREvaluator
evaluate
in class JREvaluator
id
- the expression idThrowable
JRExpression.EVALUATION_DEFAULT
,
JRFillVariable.getValue()
,
JRFillField.getValue()
Copyright © 2016. All rights reserved.