Options
All
  • Public
  • Public/Protected
  • All
Menu

Class ModuleRef

Hierarchy

  • ModuleRef

Index

Constructors

constructor

  • Parameters

    • container: any

    Returns ModuleRef

Properties

Private _instanceLinksHost

_instanceLinksHost: InstanceLinksHost

Protected Readonly container

container: NestContainer

Private Readonly injector

injector: Injector = new Injector()

Accessors

instanceLinksHost

  • get instanceLinksHost(): InstanceLinksHost

Methods

Abstract create

  • create<T>(type: Type<T>): Promise<T>

find

  • find(typeOrToken: any, contextModule: any): any
  • Parameters

    • typeOrToken: any
    • contextModule: any

    Returns any

Abstract get

  • get<TInput, TResult>(typeOrToken: Type<TInput> | string | symbol, options?: { strict: boolean }): TResult
  • Type parameters

    • TInput = any

    • TResult = TInput

    Parameters

    • typeOrToken: Type<TInput> | string | symbol
    • Optional options: { strict: boolean }
      • strict: boolean

    Returns TResult

instantiateClass

  • instantiateClass(type: any, moduleRef: any): Promise<any>
  • Parameters

    • type: any
    • moduleRef: any

    Returns Promise<any>

introspect

  • introspect(token: any): { scope: Scope }
  • Parameters

    • token: any

    Returns { scope: Scope }

registerRequestByContextId

  • registerRequestByContextId(request: any, contextId: any): void
  • Parameters

    • request: any
    • contextId: any

    Returns void

Abstract resolve

  • resolve<TInput, TResult>(typeOrToken: Type<TInput> | string | symbol, contextId?: ContextId, options?: { strict: boolean }): Promise<TResult>
  • Type parameters

    • TInput = any

    • TResult = TInput

    Parameters

    • typeOrToken: Type<TInput> | string | symbol
    • Optional contextId: ContextId
    • Optional options: { strict: boolean }
      • strict: boolean

    Returns Promise<TResult>

resolvePerContext

  • resolvePerContext(typeOrToken: any, contextModule: any, contextId: any, options: any): Promise<any>
  • Parameters

    • typeOrToken: any
    • contextModule: any
    • contextId: any
    • options: any

    Returns Promise<any>

Generated using TypeDoc