Skip to content
1 min read · 208 words

Class: ParamRef

Defined in: src/batteries/orchestration/encoding.ts:107

A hole in a template's staged values, substituted at instantiation. A CLASS for the same reason NodeRef is: a look-alike record must not be mistaken for a hole.

Constructors

Constructor

ts
new ParamRef(path: string): ParamRef;

Defined in: src/batteries/orchestration/encoding.ts:116

Construct a ParamRef.

Parameters

ParameterTypeDescription
pathstringThe declared template params entry this hole names.

Returns

ParamRef

Properties

PropertyTypeDescriptionDefined in
pathstringMust name a declared template params entry (checked at construction).src/batteries/orchestration/encoding.ts:109

Methods

[ENCODE_METHOD]()

ts
ENCODE_METHOD: Record<string, unknown>;

Defined in: src/batteries/orchestration/encoding.ts:126

Emit a plain snapshot of the fields for the encoder.

Returns

Record<string, unknown>


[DECODE_METHOD]()

ts
static DECODE_METHOD: ParamRef;

Defined in: src/batteries/orchestration/encoding.ts:131

Rebuild an instance from a ParamRef.[ENCODE_METHOD] snapshot.

Parameters

ParameterType
dataunknown

Returns

ParamRef


isParamRef()

ts
static isParamRef(v: unknown): v is ParamRef;

Defined in: src/batteries/orchestration/encoding.ts:121

instanceof guard — a look-alike record cannot pass.

Parameters

ParameterType
vunknown

Returns

v is ParamRef