public class ExpressionLanguage extends Object
| Modifier and Type | Method and Description |
|---|---|
static String |
channelFromFormula(String formula)
If the formula represents a single channels it returns the name,
null otherwise.
|
static DesiredRateReadWriteExpression<?,Object> |
formula(FormulaAst ast)
Returns the expression corresponding to the formula represented by the
given Abstract Syntax Tree.
|
static DesiredRateReadWriteExpression<?,Object> |
formula(String formula)
Returns the expression that will return the live value of the
given formula.
|
static <T> DesiredRateExpression<T> |
formula(String formula,
Class<T> readType)
An expression that returns the value of the formula making sure
it's of the given type.
|
static DesiredRateExpression<?> |
formulaArg(String formula)
An expression that returns the value of the formula and return null
for empty or null formula.
|
public static String channelFromFormula(String formula)
formula - the formula to parsepublic static DesiredRateReadWriteExpression<?,Object> formula(String formula)
formula - the formula to parsepublic static DesiredRateReadWriteExpression<?,Object> formula(FormulaAst ast)
ast - a formula abstract syntax treepublic static DesiredRateExpression<?> formulaArg(String formula)
Some expressions allow for null expression arguments to handle optional elements. In those cases, using this method makes undeclared arguments fall through.
formula - the formula, can be nullpublic static <T> DesiredRateExpression<T> formula(String formula, Class<T> readType)
T - the type to readformula - the formulareadType - the type to readCopyright © 2015. All rights reserved.