Skip to content

Abstract Class: Bind

Defined in: packages/core/src/bind/bind.ts:18

A Bind retrieves the values of the Element from their source.

Concrete implementations should expose a static async create(options): Promise<BindSubclass> factory rather than a public constructor. This ensures a uniform creation pattern across all binds regardless of whether initialisation is sync or async.

Extended by

Constructors

Constructor

ts
new Bind(name): Bind;

Defined in: packages/core/src/bind/bind.ts:21

Parameters

ParameterType
nameBindName

Returns

Bind

Properties

PropertyModifierTypeDefined in
namereadonlyBindNamepackages/core/src/bind/bind.ts:19

Methods

get()

ts
get<T>(sectionName, elementName): Promise<T | undefined>;

Defined in: packages/core/src/bind/bind.ts:38

Gets the value from the bind for a specific element

Type Parameters

Type Parameter
T

Parameters

ParameterTypeDescription
sectionNamestringThe name of the Section
elementNamestringThe name of the Element

Returns

Promise<T | undefined>

The value of the element


retrieve()

ts
abstract retrieve<T>(elementName): Promise<T | undefined>;

Defined in: packages/core/src/bind/bind.ts:30

Retrieves the value of the Bind.

Type Parameters

Type Parameter
T

Parameters

ParameterTypeDescription
elementNamestringThe name of the Element

Returns

Promise<T | undefined>

The value of the element