#exists
Returns true if the provided value is not null, false otherwise.
#exists(value)Parameters
Section titled “Parameters”| Name | Type | Description |
|---|---|---|
value |
path | value |
The value to test. |
Returns
Section titled “Returns”boolean
Examples
Section titled “Examples”Null and non-null values
Section titled “Null and non-null values”{ "a": null, "b": 1}{ "aExists": "#exists($.a)", "bExists": "#exists($.b)", "cExists": "#exists($.c)"}{ "aExists": true, "bExists": true, "cExists": false}