Condition Relations
Every rule condition has a boolean “relation” between the attribute
and the set
. The following relations are defined.
(Non)Equivalence
When ==
or !=
are passed to relation
, these will check whether or not the value in the attribute exactly matches the value in the set
.
attribute |
relation |
set |
returns |
---|---|---|---|
"AE1" |
== |
"AE1" |
true |
"AE1" |
== |
"AE" |
false |
"EH1" |
!= |
"AE1" |
true |
"AE1" |
!= |
"AE1" |
false |
In, Not In, Contains, Excludes
The following relations can be passed to relation
to test containment relationships
in
: The value in theattribute
is in theset
not in
: The value in theattribute
is not in theset
contains
: The value in theattribute
contains the theset
excludes
: The value in theattribute
does not contain theset
attribute |
relation |
set |
returns |
---|---|---|---|
"AE1" |
in |
["AE1", "AE0", "AE2"] |
true |
"AE1" |
not in |
["AE1", "AE0", "AE2"] |
false |
"AE1" |
contains |
"AE" |
true |
"AE1" |
excludes |
"1" |
false |
Regex Matching
These relations test whether the value in attribute
is or is not a regex match for set
.
rematches
: Does the regex inset
match the value inattribute
reunmatches
: Does the regex inset
not match the value inattribute
attribute |
relation |
set |
returns |
---|---|---|---|
"AE1" |
rematches |
"[AEIOU]" |
true |
"AE1" |
rematches |
0 |
false |