Skip to main content
Skip to main content

TreeRepositoryService

Data access layer (DAL) interface to implements for any repository service. This layer helps to separate the business logic (service layer) from accessing the ORM directly and allows to switch to another ORM without changing the business logic.

Type parameters

TobjectRequired

Methods

create

Parameters

dataunknownRequired
contextContext

Returns

PromisePromise<T>Required

delete

Parameters

idstringRequired
contextContext

Returns

PromisePromise<void>Required

find

Parameters

optionsFindOptions<T>
contextContext

Returns

PromisePromise<T[]>Required

findAndCount

Parameters

optionsFindOptions<T>
contextContext

Returns

PromisePromise<[T[], number]>Required

getActiveManager

Returns


getFreshManager

Returns


serialize

Parameters

dataanyRequired
optionsany

Returns

PromisePromise<TOutput>Required

transaction

Parameters

task(transactionManager: TManager) => Promise<any>Required
contextobject
context.enableNestedTransactionsboolean
context.isolationLevelstring
context.transactionTManager

Returns

PromisePromise<any>Required
Was this section helpful?