Class: FilterExpression

ListQuery~FilterExpression(requestnullable)

Filter Expresion

Constructor

new FilterExpression(requestnullable)

FilterExpression Constructor.

FilterExpression Constructor.

Parameters:
Name Type Attributes Default Description
request Request <nullable>
null
Source:
See:

Members

Source:

(static, constant) FILTER_SEARCH_AND

Source:

(static, constant) FILTER_SEARCH_OR

Source:

(static, constant) OPERATOR_CO

Source:

(static, constant) OPERATOR_EQ

Source:

(static, constant) OPERATOR_FALSE

Source:

(static, constant) OPERATOR_GE

Source:

(static, constant) OPERATOR_GT

Source:

(static, constant) OPERATOR_IN

Source:

(static, constant) OPERATOR_LE

Source:

(static, constant) OPERATOR_LIKE

Source:

(static, constant) OPERATOR_LT

Source:

(static, constant) OPERATOR_NC

Source:

(static, constant) OPERATOR_NE

Source:

(static, constant) OPERATOR_NOT_IN

Source:

(static, constant) OPERATOR_NOTLIKE

Source:

(static, constant) OPERATOR_NULL

Source:

(static, constant) OPERATOR_SUBWHERE

Source:

(static, constant) OPERATOR_TRUE

Source:

Methods

add(field, operator, value, type) → {FilterExpression}

Add a search filter.

Add a search filter.

Parameters:
Name Type Description
field string
operator string
value *
type string
Source:
Returns:
Type
FilterExpression

andContains(field, value) → {FilterExpression}

Add a contains (AND x CO y) filter for specified field.

Add a contains (AND x CO y) filter for specified field.

Parameters:
Name Type Description
field string
value string
Source:
Returns:
Type
FilterExpression

andDoesNotContain(field, value) → {FilterExpression}

Add a does not contains (AND x NC y) filter for specified field.

Add a does not contains (AND x NC y) filter for specified field.

Parameters:
Name Type Description
field string
value string
Source:
Returns:
Type
FilterExpression

andEqual(field, value) → {FilterExpression}

Add a equal (AND x EQ y) filter for specified field.

Add a equal (AND x EQ y) filter for specified field.

Parameters:
Name Type Description
field string
value string | number
Source:
Returns:
Type
FilterExpression

andGreaterThan(field, value) → {FilterExpression}

Add a greater than (AND x GT y) filter for specified field.

Add a greater than (AND x GT y) filter for specified field.

Parameters:
Name Type Description
field string
value string
Source:
Returns:
Type
FilterExpression

andGreaterThanEqual(field, value) → {FilterExpression}

Add a greater than or equal (AND x GE y) filter for specified field.

Add a greater than or equal (AND x GE y) filter for specified field.

Parameters:
Name Type Description
field string
value number
Source:
Returns:
Type
FilterExpression

andIsFalse(field) → {FilterExpression}

Add a false (AND x == false) filter for specified field.

Add a false (AND x == false) filter for specified field.

Parameters:
Name Type Description
field string
Source:
Returns:
Type
FilterExpression

andIsIn(field, values) → {FilterExpression}

Add a in (AND x IN y,z,..

Add a in (AND x IN y,z,.. ) filter for specified field.

Parameters:
Name Type Description
field string
values Array | string
Source:
Returns:
Type
FilterExpression

andIsNull(field) → {FilterExpression}

Add a is null (AND x == null) filter for specified field.

Add a is null (AND x == null) filter for specified field.

Parameters:
Name Type Description
field string
Source:
Returns:
Type
FilterExpression

andIsTrue(field) → {FilterExpression}

Add a true (AND x == true) filter for specified field.

Add a true (AND x == true) filter for specified field.

Parameters:
Name Type Description
field string
Source:
Returns:
Type
FilterExpression

andLessThan(field, value) → {FilterExpression}

Add a less than (AND x LT y) filter for specified field.

Add a less than (AND x LT y) filter for specified field.

Parameters:
Name Type Description
field string
value number
Source:
Returns:
Type
FilterExpression

andLessThanEqual(field, value) → {FilterExpression}

Add a less than or equal (AND x LE y) filter for specified field.

Add a less than or equal (AND x LE y) filter for specified field.

Parameters:
Name Type Description
field string
value number
Source:
Returns:
Type
FilterExpression

andLike(field, value) → {FilterExpression}

Add a like (AND x LIKE y) filter for specified field.

Add a like (AND x LIKE y) filter for specified field.

Parameters:
Name Type Description
field string
value string
Source:
Returns:
Type
FilterExpression

andNotEqual(field, value) → {FilterExpression}

Add a not equal (AND x NE y) filter for specified field.

Add a not equal (AND x NE y) filter for specified field.

Parameters:
Name Type Description
field string
value string | number
Source:
Returns:
Type
FilterExpression

andNotIn(field, values) → {FilterExpression}

Add a not in (AND x NOTIN y,z,..

Add a not in (AND x NOTIN y,z,.. ) filter for specified field.

Parameters:
Name Type Description
field string
values Array | string
Source:
Returns:
Type
FilterExpression

andNotLike(field, value) → {FilterExpression}

Add a not like (AND x NOTLIKE y) filter for specified field.

Add a not like (AND x NOTLIKE y) filter for specified field.

Parameters:
Name Type Description
field string
value string
Source:
Returns:
Type
FilterExpression

andX(expression) → {FilterExpression}

Add a AND expression.

Add a AND expression.

Parameters:
Name Type Description
expression FilterExpression
Source:
Throws:
Error
Returns:
Type
FilterExpression

childDepth() → {number}

Get the child depth.

Get the child depth.

Source:
Returns:
Type
number

contains(field, value) → {FilterExpression}

Add a contains (x CO y) filter for specified field.

Add a contains (x CO y) filter for specified field.

Parameters:
Name Type Description
field string
value string
Source:
Returns:
Type
FilterExpression

doesNotContain(field, value) → {FilterExpression}

Add a does not contains (x NC y) filter for specified field.

Add a does not contains (x NC y) filter for specified field.

Parameters:
Name Type Description
field string
value string
Source:
Returns:
Type
FilterExpression

equal(field, value) → {FilterExpression}

Add a equal (x EQ y) filter for specified field.

Add a equal (x EQ y) filter for specified field.

Parameters:
Name Type Description
field string
value string | number
Source:
Returns:
Type
FilterExpression

expr()

Create a new expression instance.

Create a new expression instance.

Source:
Returns:

FilterExpression

getParent() → (nullable) {FilterExpression}

Get the parent expression.

Get the parent expression.

Source:
Returns:
Type
FilterExpression

greaterThan(field, value) → {FilterExpression}

Add a greater than (x GT y) filter for specified field.

Add a greater than (x GT y) filter for specified field.

Parameters:
Name Type Description
field string
value number
Source:
Returns:
Type
FilterExpression

greaterThanEqual(field, value) → {FilterExpression}

Add a greater than or equal (x GE y) filter for specified field.

Add a greater than or equal (x GE y) filter for specified field.

Parameters:
Name Type Description
field string
value number
Source:
Returns:
Type
FilterExpression

isChild() → {boolean}

Check if this expression is a child of another.

Check if this expression is a child of another.

Source:
Returns:
Type
boolean

isFalse(field) → {FilterExpression}

Add a false (x == false) filter for specified field.

Add a false (x == false) filter for specified field.

Parameters:
Name Type Description
field string
Source:
Returns:
Type
FilterExpression

isIn(field, values) → {FilterExpression}

Add a in (x IN y,z,..

Add a in (x IN y,z,.. ) filter for specified field.

Parameters:
Name Type Description
field string
values Array | string
Source:
Returns:
Type
FilterExpression

isNull(field) → {FilterExpression}

Add a is null (x == null) filter for specified field.

Add a is null (x == null) filter for specified field.

Parameters:
Name Type Description
field string
Source:
Returns:
Type
FilterExpression

isTrue(field) → {FilterExpression}

Add a true (x == true) filter for specified field.

Add a true (x == true) filter for specified field.

Parameters:
Name Type Description
field string
Source:
Returns:
Type
FilterExpression

lessThan(field, value) → {FilterExpression}

Add a less than (x LT y) filter for specified field.

Add a less than (x LT y) filter for specified field.

Parameters:
Name Type Description
field string
value string
Source:
Returns:
Type
FilterExpression

lessThanEqual(field, value) → {FilterExpression}

Add a less than or equal (x LE y) filter for specified field.

Add a less than or equal (x LE y) filter for specified field.

Parameters:
Name Type Description
field string
value number
Source:
Returns:
Type
FilterExpression

like(field, value) → {FilterExpression}

Add a like (x LIKE y) filter for specified field.

Add a like (x LIKE y) filter for specified field.

Parameters:
Name Type Description
field string
value string
Source:
Returns:
Type
FilterExpression

notEqual(field, value) → {FilterExpression}

Add a not equal (x NE y) filter for specified field.

Add a not equal (x NE y) filter for specified field.

Parameters:
Name Type Description
field string
value string | number
Source:
Returns:
Type
FilterExpression

notIn(field, values) → {FilterExpression}

Add a not in (x NOTIN y,z,..

Add a not in (x NOTIN y,z,.. ) filter for specified field.

Parameters:
Name Type Description
field string
values Array | string
Source:
Returns:
Type
FilterExpression

notLike(field, value) → {FilterExpression}

Add a not like (x NOTLIKE y) filter for specified field.

Add a not like (x NOTLIKE y) filter for specified field.

Parameters:
Name Type Description
field string
value string
Source:
Returns:
Type
FilterExpression

orContains(field, value) → {FilterExpression}

Add a contains (OR x CO y) filter for specified field.

Add a contains (OR x CO y) filter for specified field.

Parameters:
Name Type Description
field string
value string
Source:
Returns:
Type
FilterExpression

orDoesNotContain(field, value) → {FilterExpression}

Add a does not contains (OR x NC y) filter for specified field.

Add a does not contains (OR x NC y) filter for specified field.

Parameters:
Name Type Description
field string
value string
Source:
Returns:
Type
FilterExpression

orEqual(field, value) → {FilterExpression}

Add a equal (OR x EQ y) filter for specified field.

Add a equal (OR x EQ y) filter for specified field.

Parameters:
Name Type Description
field string
value string | number
Source:
Returns:
Type
FilterExpression

orGreaterThan(field, value) → {FilterExpression}

Add a greater than (OR x GT y) filter for specified field.

Add a greater than (OR x GT y) filter for specified field.

Parameters:
Name Type Description
field string
value number
Source:
Returns:
Type
FilterExpression

orGreaterThanEqual(field, value) → {FilterExpression}

Add a greater than or equal (OR x GE y) filter for specified field.

Add a greater than or equal (OR x GE y) filter for specified field.

Parameters:
Name Type Description
field string
value number
Source:
Returns:
Type
FilterExpression

orIsFalse(field) → {FilterExpression}

Add a false (OR x == false) filter for specified field.

Add a false (OR x == false) filter for specified field.

Parameters:
Name Type Description
field string
Source:
Returns:
Type
FilterExpression

orIsIn(field, values) → {FilterExpression}

Add a in (OR x IN y,z,..

Add a in (OR x IN y,z,.. ) filter for specified field.

Parameters:
Name Type Description
field string
values Array | string
Source:
Returns:
Type
FilterExpression

orIsNull(field) → {FilterExpression}

Add a is null (OR x == null) filter for specified field.

Add a is null (OR x == null) filter for specified field.

Parameters:
Name Type Description
field string
Source:
Returns:
Type
FilterExpression

orIsTrue(field) → {FilterExpression}

Add a true (OR x == true) filter for specified field.

Add a true (OR x == true) filter for specified field.

Parameters:
Name Type Description
field string
Source:
Returns:
Type
FilterExpression

orLessThan(field, value) → {FilterExpression}

Add a less than (OR x LT y) filter for specified field.

Add a less than (OR x LT y) filter for specified field.

Parameters:
Name Type Description
field string
value number
Source:
Returns:
Type
FilterExpression

orLessThanEqual(field, value) → {FilterExpression}

Add a less than or equal (OR x LE y) filter for specified field.

Add a less than or equal (OR x LE y) filter for specified field.

Parameters:
Name Type Description
field string
value number
Source:
Returns:
Type
FilterExpression

orLike(field, value) → {FilterExpression}

Add a like (OR x LIKE y) filter for specified field.

Add a like (OR x LIKE y) filter for specified field.

Parameters:
Name Type Description
field string
value string
Source:
Returns:
Type
FilterExpression

orNotEqual(field, value) → {FilterExpression}

Add a not equal (OR x NE y) filter for specified field.

Add a not equal (OR x NE y) filter for specified field.

Parameters:
Name Type Description
field string
value string | number
Source:
Returns:
Type
FilterExpression

orNotIn(field, values) → {FilterExpression}

Add a not in (OR x NOTIN y,z,..

Add a not in (OR x NOTIN y,z,.. ) filter for specified field.

Parameters:
Name Type Description
field string
values Array | string
Source:
Returns:
Type
FilterExpression

orNotLike(field, value) → {FilterExpression}

Add a not like (OR x NOTLIKE y) filter for specified field.

Add a not like (OR x NOTLIKE y) filter for specified field.

Parameters:
Name Type Description
field string
value string
Source:
Returns:
Type
FilterExpression

orX(expression) → {FilterExpression}

Add a OR expression.

Add a OR expression.

Parameters:
Name Type Description
expression FilterExpression
Source:
Throws:
Error
Returns:
Type
FilterExpression

setParent(parentnullable) → {FilterExpression}

Set the parent expression.

Set the parent expression.

Parameters:
Name Type Attributes Default Description
parent FilterExpression <nullable>
null
Source:
Returns:
Type
FilterExpression

toArray() → {Array}

Reduce the built expression(s) to an array.

Reduce the built expression(s) to an array.

Source:
Returns:
Type
Array