Skip to main content

@webda/coreReadme | API


Class: PartialComparisonExpression<T>

Comparison expression

Extends

Type parameters

T extends ComparisonOperator = ComparisonOperator

Constructors

new PartialComparisonExpression(builder, op, attribute, value)

new PartialComparisonExpression<T>(builder, op, attribute, value): PartialComparisonExpression<T>

Parameters

builder: PartialExpressionBuilder

op: T

attribute: string

value: any

Returns

PartialComparisonExpression<T>

Overrides

ComparisonExpression.constructor

Source

packages/core/src/stores/webdaql/query.ts:728

Properties

attribute

attribute: string[]

Attribute to read from the object (split by .)

Inherited from

ComparisonExpression.attribute

Source

packages/core/src/stores/webdaql/query.ts:348


builder

protected builder: PartialExpressionBuilder

Source

packages/core/src/stores/webdaql/query.ts:729


operator

operator: T

Inherited from

ComparisonExpression.operator

Source

packages/core/src/stores/webdaql/query.ts:318


value

value: value | value[]

Right side of the comparison

Inherited from

ComparisonExpression.value

Source

packages/core/src/stores/webdaql/query.ts:344

Methods

eval()

eval(target): boolean

Override the eval to check if the attribute is present if not and we are in partial mode, return true

Parameters

target: any

Returns

boolean

Overrides

ComparisonExpression.eval

Source

packages/core/src/stores/webdaql/query.ts:744


setAttributeValue()

setAttributeValue(target): void

Set the value of the attribute based on the assignment

If used as a Set expression

Parameters

target: any

Returns

void

Inherited from

ComparisonExpression.setAttributeValue

Source

packages/core/src/stores/webdaql/query.ts:401


toString()

toString(): string

Returns

string

Inherited from

ComparisonExpression.toString

Source

packages/core/src/stores/webdaql/query.ts:483


toStringAttribute()

toStringAttribute(): string

Allow subclass to create different display

Returns

string

Inherited from

ComparisonExpression.toStringAttribute

Source

packages/core/src/stores/webdaql/query.ts:469


toStringOperator()

toStringOperator(): T

Allow subclass to create different display

Returns

T

Inherited from

ComparisonExpression.toStringOperator

Source

packages/core/src/stores/webdaql/query.ts:476


toStringValue()

toStringValue(value): string

Return a string represantation of a value

Parameters

value: value | value[]

Returns

string

Inherited from

ComparisonExpression.toStringValue

Source

packages/core/src/stores/webdaql/query.ts:453


getAttributeValue()

static getAttributeValue(target, attribute): any

Read the value from the object

Parameters

target: any

attribute: string[]

Returns

any

Inherited from

ComparisonExpression.getAttributeValue

Source

packages/core/src/stores/webdaql/query.ts:387


likeToRegex()

static likeToRegex(like): RegExp

Parameters

like: string

Returns

RegExp

Inherited from

ComparisonExpression.likeToRegex

Source

packages/core/src/stores/webdaql/query.ts:361