Skip to main content
Version: 6.4

EntitySchema <Entity, Base>

Index

Constructors

constructor

Properties

staticREGISTRY

REGISTRY: Map<Partial<any>, EntitySchema<any, never>> = ...

When schema links the entity class via class option, this registry allows the lookup from opposite side, so we can use the class in entities option just like the EntitySchema instance.

Accessors

meta

name

Methods

addEmbedded

  • addEmbedded(name, options): void

addEnum

  • addEnum(name, type, options): void
  • Parameters

    Returns void

addIndex

  • addIndex(options): void

addManyToMany

  • addManyToMany(name, type, options): void

addManyToOne

  • addManyToOne(name, type, options): void

addOneToMany

  • addOneToMany(name, type, options): void

addOneToOne

  • addOneToOne(name, type, options): void

addPrimaryKey

  • addPrimaryKey(name, type, options): void

addProperty

  • addProperty(name, type, options): void

addSerializedPrimaryKey

  • addSerializedPrimaryKey(name, type, options): void

addUnique

  • addUnique(options): void

addVersion

  • addVersion(name, type, options): void

setClass

  • setClass(proto): void

setCustomRepository

  • setCustomRepository(repository): void

setExtends

  • setExtends(base): void
  • Parameters

    Returns void

staticfromMetadata