XFA Specification
Chapter 23, FormCalc Specification
Grammar and Syntax
814
If both operands are string valued, then a locale-sensitive lexicographic string comparison is performed on
the operands. Otherwise, if not both null, the operands are promoted to numeric values, and a numeric
comparison is performed.
The EqualityOperators '==' and 'eq', both denote the equality operator. The equality operator returns the
boolean result true, represented by the numeric value 1, whenever both operands compare identically
and returns the boolean result false, represented by the numeric value 0, otherwise.
The EqualityOperators '<>' and 'ne', both denote the inequality operator. The inequality operator returns
the boolean result true, represented by the numeric value 1, whenever both operands compare differently
and returns the boolean result false, represented by the numeric value 0, otherwise.
Relational Expressions
74 RelationalExpression ::= AdditiveExpression |
RelationalExpression RelationalOperator AdditiveExpression
75 RelationalOperator ::= '<=' | '>=' | '<' | '>' | 'le' | 'ge' | 'lt' | 'gt'
A RelationalExpression
74
If either operand is null valued, then a null comparison is performed. Null valued operands compare
identically whenever both operands are null and the relational operator is less-than-or-equal or
greater-than-or-equal, and compare differently otherwise.
If both operands are string valued, then a locale-sensitive lexicographic string comparison is performed on
the operands. Otherwise, if not both null, the operands are promoted to numeric values, and a numeric
comparison is performed.
The RelationalOperators '<' and 'lt', both denote the same less-than operator. The less-than-or-equal
relational operator returns the boolean result true, represented by the numeric value 1, whenever the first
operand is less than the second operand, and returns the boolean result false, represented by the numeric
value 0, otherwise.
The RelationalOperators '<=' and 'le', both denote the less-than-or-equal operator. The less-than-or-equal
relational operator returns the boolean result true, represented by the numeric value 1, whenever the first
operand is less than or equal to the second operand, and returns the boolean result false, represented by
the numeric value 0, otherwise.
The RelationalOperators '>' and 'gt', both denote the same greater-than operator. The greater-than
relational operator returns the boolean result true, represented by the numeric value 1, whenever the first
operand is greater than the second operand, and returns the boolean result false, represented by the
numeric value 0, otherwise.
The RelationalOperators '>=' and 'ge', both denote the greater-than-or-equal operator. The
greater-than-or-equal relational operator returns the boolean result true, represented by the numeric
value 1, whenever the first operand is greater than or equal to the second operand, and returns the
boolean result false, represented by the numeric value 0, otherwise.
Additive Expressions
76 AdditiveExpression ::= MultiplicativeExpression |
AdditiveExpression AdditiveOperator MultiplicativeExpression
77 AdditiveOperator ::= '+' | '-'