Expressions

Expressions in the exotool activity language yield data values. Like statements, expressions may evaluate on either the client or the server, depending on what is needed and/or possible. Expressions may be enclosed in parenthesis to enforce specific precedence. )

Format Expression Type Examples
-[expression] Arthmetic negate -23
-alpha
-(a+b)
![expression] Logical inverse !alpha
([expression]) Parenthesis enclosed expression (a+b)
[expresssion] [binop] [expression]
[number] Numeric constant. see Numbers 145
0.23
45.3
"string" String constant. see Strings "This is a string"
"Line 1\nLine 2"
[special constant] Special constant. see Special Constants true
false
null
[expresssion] [operator] [expression] Binary Expression. [operator] can be:
Operator Description
+Addition
-Subtraction
*Multiplication
/Division
&&Logical AND
||Logical OR
<Less than
>Greater than
<=Less than or equal to
>=Greater than or equal to
==Equals
!=Not equal
&Bitwise AND
|Bitwise OR
a + b
a - b
a * b
a / b
a && b
a || b
a < b
a <= b
a > b
a >= b
a == b
a != b
a & b
a | b
[Variable reference] Reference to a variable or a component of a variable's value. see Variables myvar
item.price
items[4]
JS<...>JS
JS<P...>JS
Explicit Javascript expression. see Explicit Client-Side Code (Javascript) JS<Date.now()>JS
JS<P Promise.resolve(time()) >JS
PHP<....>PHP Explicit PHP expression. see Explicit Server-Side Code (PHP) PHP< return $args->a + $args->b; >PHP