UNPKG

@entity-factory/typeorm

Version:
16 lines (15 loc) 838 B
import { Adapter, BlueprintOptions, DeepEntityPartial } from '@entity-factory/core'; import { TypeormAdapterOptions } from './TypeormAdapterOptions'; import { TypeormBlueprintOptions } from './TypeormBlueprintOptions'; export declare class TypeormAdapter implements Adapter<TypeormBlueprintOptions> { private readonly options?; private connection; constructor(options?: TypeormAdapterOptions | undefined); make<Entity>(objects: Array<DeepEntityPartial<Entity>>, context: BlueprintOptions<TypeormBlueprintOptions>): Promise<Entity[]>; create<Entity>(objects: Entity[], context: BlueprintOptions<TypeormBlueprintOptions>): Promise<Entity[]>; getManager(): import("typeorm").EntityManager; dispose(): Promise<void>; private getConnection; private createNewConnection; private getExistingConnection; }