Options
All
  • Public
  • Public/Protected
  • All
Menu

Interface ModelSpecificInstanceConstructor<TDocument, TInstance>

The interface to which a prepared instance constructor should conform. When called with a document object, it should instantiate a new instance of type TInstance which is associated with its parent model.

This is primarily used internally for prepared model instance constructors.

internal

Type parameters

  • TDocument

    The interface used to describe the structure of the documents found in the database collection.

  • TInstance

    The interface or class used to wrap the documents returned from the database.

Hierarchy

  • ModelSpecificInstanceConstructor

Index

Constructors

Constructors

constructor

  • new ModelSpecificInstanceConstructor(doc: TDocument, isNew?: undefined | true | false, isPartial?: undefined | true | false): TInstance
  • Parameters

    • doc: TDocument
    • Optional isNew: undefined | true | false
    • Optional isPartial: undefined | true | false

    Returns TInstance

Generated using TypeDoc