Skip to main content

DataConnection

Represents a data connection

Extends

Constructors

new DataConnection()

new DataConnection(dart): DataConnection

Parameters

ParameterType
dartany

Returns

DataConnection

Overrides

Entity . constructor

Constructs

DataConnection

Source

src/entities.ts:563

Properties

PropertyModifierTypeInherited from
dartpublicanyEntity.dart
parameterspublicany-

Accessors

author

get author(): User

Who created entity *

Returns

User

Source

src/entities.ts:108


createdOn

get createdOn(): Dayjs

Time when entity was created *

Returns

Dayjs

Source

src/entities.ts:99


credentials

get credentials(): Credentials

Returns

Credentials

Source

src/entities.ts:568


friendlyName

get friendlyName(): string

Entity friendly name

set friendlyName(x): void

Parameters

ParameterType
xstring

Returns

string

Source

src/entities.ts:85


id

get id(): string

Entity ID (GUID)

set id(x): void

Parameters

ParameterType
xstring

Returns

string

Source

src/entities.ts:77


name

get name(): string

Entity short name

set name(x): void

Parameters

ParameterType
xstring

Returns

string

Source

src/entities.ts:89


nqName

get nqName(): string

Entity full-qualified name

Returns

string

Source

src/entities.ts:93


path

get path(): string

Entity path

Returns

string

Source

src/entities.ts:96


updatedOn

get updatedOn(): null | Dayjs

Time when entity was updated *

Returns

null | Dayjs

Source

src/entities.ts:102

Methods

getProperties()

getProperties(): Promise<object>

Gets entity properties

Returns

Promise<object>

Inherited from

Entity . getProperties

Source

src/entities.ts:111


hasTag()

hasTag(tag): boolean

Parameters

ParameterType
tagstring

Returns

boolean

Inherited from

Entity . hasTag

Source

src/entities.ts:123


newId()

newId(): void

Generates new id for this entity.

Returns

void

Inherited from

Entity . newId

Source

src/entities.ts:81


query()

query(name, sql): DataQuery

Creates DataQuery using this connection. Can be used only with database connections.

Parameters

ParameterTypeDescription
namestringname of the query
sqlstringtext of the query

Returns

DataQuery

Source

src/entities.ts:586


setProperties()

setProperties(props): Promise<any>

Sets entity properties

Parameters

ParameterType
propsobject

Returns

Promise<any>

Inherited from

Entity . setProperties

Source

src/entities.ts:116


tag()

tag(tag): boolean

Adds a specified tag

Parameters

ParameterType
tagstring

Returns

boolean

Inherited from

Entity . tag

Source

src/entities.ts:126


test()

test(): Promise<string>

Tests the connection, returns "ok" on success or an error message on error

Returns

Promise<string>

Source

src/entities.ts:577


toString()

toString(): string

Returns a string representing the object

Returns

string

Inherited from

Entity . toString

Source

src/entities.ts:121


unTag()

unTag(tag): boolean

Removes a specified tag

Parameters

ParameterType
tagstring

Returns

boolean

Inherited from

Entity . unTag

Source

src/entities.ts:129


create()

static create(name, parameters): DataConnection

Creates a data connection. Note that in order to be used, it has to be saved first using DataConnectionsDataSource

Parameters

ParameterTypeDescription
namestringConnection name
parametersDataConnectionPropertiesConnection properties

Returns

DataConnection

Source

src/entities.ts:595