Logical functions evaluate conditions and return Boolean results. Available functions: and, or, not, eq, ne, and null.
and
The following table describes the
and function.| Item | Description |
| Syntax | and(arg, ...) |
| Benefit |
|
| Parameter | One or more arguments of any type. |
| Return value | Returns true if all values evaluate to true and returns false if a value evaluates to false. |
| Example |
|
or
The following table describes the
or function.| Item | Description |
| Syntax | or(arg, ...). |
| Description |
|
| Parameter | One or more arguments of any type. |
| Return value | Returns true if any argument is true. Otherwise, returns false. |
| Example |
|
not
The following table describes the
not function.| Item | Description |
| Syntax | not(arg) |
| Description | Performs a logical NOT operation. undef and false evaluate to false. All other values evaluate to true. |
| Parameter | One argument of any type. |
| Return value |
|
| Example |
|
eq
The following table describes the
eq function.| Item | Description |
| Syntax | eq(arg1, arg2) |
| Description | Checks whether two values are equal. |
| Parameter |
|
| Return value | Returns true if the two values are equal and returns false if they are not equal. |
| Example |
|
ne
The following table describes the
ne function.| Item | Description |
| Syntax | ne(arg1, arg2) |
| Description | Checks whether two values are not equal. |
| Parameter |
|
| Return value | Returns true if the two values are not equal and returns false if they are equal. |
| Example |
|
null
The following table describes the
null function.| Item | Description |
| Syntax | null(v) |
| Benefit | Checks whether a data type is specified for EdgeScript (ES). |
| Filed | v: the parameter to pass. Data type: array, dictionary, or string. A value of false is returned for other data types. |
| Return value | Data type: Boolean.
|
| Examples | Output: |