ConditionDefinition class
Represents a condition definition. A condition definition is a set of operands and an operator that can be used to evaluate a condition.
A condition definition has the following properties:
- operator: The operator to be used to evaluate the condition.
- operands: A list of operands to be used in the evaluation.
The operator property can be one of the following built-in operators or any user-defined operator:
==
: Equal to!=
: Not equal to>
: Greater than>=
: Greater than or equal to<
: Less than<=
: Less than or equal to!
: Negation of the operandall
: All operands must be trueany
: Any operand must be truenone
: None of the operands must be truecontains
: The first operand must contain the second operandstartsWith
: The first operand must start with the second operandendsWith
: The first operand must end with the second operandmatches
: The first operand must match the regular expression in the second operandexpression
: The first operand must evaluate to true using the expression in the second operand
Constructors
- ConditionDefinition.new({required String operator, required List operands})
Properties
Methods
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
toJson(
) → Map< String, dynamic> - Creates a ConditionDefinition object from a JSON object.
-
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited
Static Methods
-
fromJson(
Map< String, dynamic> json) → ConditionDefinition - Converts the ConditionDefinition object to a JSON object.