Class ExpressionTransformParseContext
java.lang.Object
com.inductiveautomation.perspective.gateway.expression.AbstractExpressionParseContext
com.inductiveautomation.perspective.gateway.binding.expression.ExpressionBindingParseContext
com.inductiveautomation.perspective.gateway.binding.transforms.expression.ExpressionTransformParseContext
- All Implemented Interfaces:
ExpressionParseContext
An
ExpressionBindingParseContext
which additionally wraps a ConstantExpression
and a
Predicate
which returns true if the path in the bound Expression
should delegate to the
ConstantExpression. If the Predicate is false, this class will delegate to
ExpressionBindingParseContext.createBoundExpression(String)
. Also exposes a method
onValueChanged(QualifiedValue)
to update the
underlying ConstantExpression's internal QualifiedValue
.-
Field Summary
Fields inherited from class com.inductiveautomation.perspective.gateway.expression.AbstractExpressionParseContext
context, INITIAL_TAG_VALUE
-
Method Summary
Modifier and TypeMethodDescriptioncreateBoundExpression
(String path) Returns an internalConstantExpression
if the injectedPredicate.test(Object)
returns true for the given path input.Methods inherited from class com.inductiveautomation.perspective.gateway.binding.expression.ExpressionBindingParseContext
getReferences
Methods inherited from class com.inductiveautomation.perspective.gateway.expression.AbstractExpressionParseContext
createExpressionForTagReference, getFunctionFactory
-
Method Details
-
createBoundExpression
Returns an internalConstantExpression
if the injectedPredicate.test(Object)
returns true for the given path input. If the predicate returns false, this method delegates toExpressionBindingParseContext.createBoundExpression(String)
.- Specified by:
createBoundExpression
in interfaceExpressionParseContext
- Overrides:
createBoundExpression
in classExpressionBindingParseContext
- Parameters:
path
- the text content inside the braces.- Throws:
RuntimeException
- because the CUP parser doesn't have a throws on the function that calls this inside the parser
-