Expression class
Represents expression object.
- getIndex
- getModel
- getParent
- getText
- hasText
- isEmpty
- loadFromData
- saveToData
- setContent
- setValue
- tryCopyValueFrom
Constructors
Section titled “Constructors”constructor
Section titled “constructor”The default constructor. ⊕ new Expression(parent: ExpressionParent): Expression
Parameters:
Section titled “Parameters:”- parent: ExpressionParent
Public Properties
Section titled “Public Properties”_isDefaultValue
Section titled “_isDefaultValue”● _isDefaultValue: boolean
= false
The list of arguments.
● args?: Expression[]
baseAttrId
Section titled “baseAttrId”The base attribute id.
● baseAttrId?: string
dataType
Section titled “dataType”The data type.
● dataType: DataType
= DataType.String
distinct
Section titled “distinct”The distinct option. (e.g SELECT DISTINCT
)
● distinct: boolean
= false
The function.
● func?: string
The data kind.
● kind: DataKind = DataKind.Scalar
The sql expression.
● sql?: string
subQuery
Section titled “subQuery”The query.
● subQuery?: Query
The tag.
● tag: ExprTag = ExprTag.Constant
Public Accessors
Section titled “Public Accessors”⇄ get value(): string
Returns string
Public Methods
Section titled “Public Methods”getIndex
Section titled “getIndex”▸ getIndex(): number
Returns number
getModel
Section titled “getModel”▸ getModel(): DataModel
Returns DataModel
getParent
Section titled “getParent”▸ getParent(): ExpressionParent
Returns ExpressionParent
getText
Section titled “getText”▸ getText(): any
Returns any
hasText
Section titled “hasText”▸ hasText(): boolean
Returns boolean
isEmpty
Section titled “isEmpty”▸ isEmpty(): boolean
Returns boolean
loadFromData
Section titled “loadFromData”Loads expression from its JSON representation object.
▸ loadFromData(model: DataModel,data: ExpressionData): void
Parameters:
Section titled “Parameters:”- model: DataModel - The Data Model.
- data: ExpressionData - The JSON representation object.
Returns void
saveToData
Section titled “saveToData”Saves expression from JSON representation object.
▸ saveToData(): ExpressionData
Returns ExpressionData - The JSON representation object.
setContent
Section titled “setContent”▸ setContent(val: string
,txt?: string
,silent?: boolean
): void
Parameters:
Section titled “Parameters:”- val:
string
- txt:
string
, Optional - silent:
boolean
, Default value =false
Returns void
setValue
Section titled “setValue”▸ setValue(val: string
,silent?: boolean
): void
Parameters:
Section titled “Parameters:”- val:
string
- silent:
boolean
, Default value =false
Returns void
tryCopyValueFrom
Section titled “tryCopyValueFrom”▸ tryCopyValueFrom(expr: Expression): void
Parameters:
Section titled “Parameters:”- expr: Expression
Returns void