Skip to main content
Version: 4.4

Interface: IWrappedEntity<T, PK, P>#

core.IWrappedEntity

Type parameters#

NameTypeDefault
TAnyEntity<T>-
PKkeyof T-
PPopulate<T> | unknownunknown

Hierarchy#

  • IWrappedEntity

Implemented by#

Methods#

assign#

assign(data: any, options?: boolean | AssignOptions): T

Parameters:#

NameType
dataany
options?boolean | AssignOptions

Returns: T

Defined in: packages/core/src/typings.ts:87


init#

init<P>(populated?: boolean, populate?: P, lockMode?: NONE | OPTIMISTIC | PESSIMISTIC_READ | PESSIMISTIC_WRITE): Promise<T>

Type parameters:#

NameTypeDefault
PPopulate<T>Populate<T\>

Parameters:#

NameType
populated?boolean
populate?P
lockMode?NONE | OPTIMISTIC | PESSIMISTIC_READ | PESSIMISTIC_WRITE

Returns: Promise<T>

Defined in: packages/core/src/typings.ts:82


isInitialized#

isInitialized(): boolean

Returns: boolean

Defined in: packages/core/src/typings.ts:80


populated#

populated(populated?: boolean): void

Parameters:#

NameType
populated?boolean

Returns: void

Defined in: packages/core/src/typings.ts:81


toJSON#

toJSON(...args: any[]): Dictionary<any>

Parameters:#

NameType
...argsany[]

Returns: Dictionary<any>

Defined in: packages/core/src/typings.ts:85


toObject#

toObject(ignoreFields?: string[]): Dictionary<any>

Parameters:#

NameType
ignoreFields?string[]

Returns: Dictionary<any>

Defined in: packages/core/src/typings.ts:84


toPOJO#

toPOJO(): EntityData<T>

Returns: EntityData<T>

Defined in: packages/core/src/typings.ts:86


toReference#

toReference<PK2, P2>(): IdentifiedReference<T, PK2> & LoadedReference<T, P2>

Type parameters:#

NameTypeDefault
PK2unknownPrimaryProperty<T\>
P2unknownunknown

Returns: IdentifiedReference<T, PK2> & LoadedReference<T, P2>

Defined in: packages/core/src/typings.ts:83

Last updated on by Martin Adámek