Skip to main content

loadModelLink

@webda/core


Function: loadModelLink()

loadModelLink<T>(reference, context?): Promise<T>

Defined in: packages/core/src/models/polymorphic.ts:16

Resolve an opaque reference against the active application, checking the caller's read permission. Unknown, missing, deleted and unreadable targets all answer like an ordinary missing object.

Type Parameters​

T​

T extends Storable<any, any> = Storable<any, any>

Parameters​

reference​

ModelLinkData

canonical model identifier and primary key

context?​

IOperationContext = ...

current caller by default

Returns​

Promise<T>

the readable target (never cached)