EvaluationContext class
Provides the necessary context for evaluating expressions : variables, constants and functions.
Constructors
-
EvaluationContext({Map<
String, Object?> constants = defaultConstants, List<EvaluableFunction> functions = defaultFunctions}) - Creates a new evaluation context instance.
Properties
- hashCode → int
-
The hash code for this object.
no setterinherited
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
Methods
-
clearIdentifiersValues(
) → void - Clears all identifiers values.
-
getIdentifierValue(
String identifier) → Object? -
Returns an
identifiervalue. -
hasIdentifierValue(
String identifier) → bool - Checks if the context has the corresponding value.
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
removeIdentifierValue(
String identifier) → Object? -
Removes an
identifiervalue. -
setIdentifierValue(
String identifier, Object? value, {bool constant = false}) → Object? -
Sets an
identifiervalue. -
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited
Static Methods
-
isVariableValueValid(
Object? value) → bool - Checks if a variable value can be used.
Constants
-
defaultConstants
→ const Map<
String, Object?> - The default constants.
-
defaultFunctions
→ const List<
EvaluableFunction> - The default functions.