Skip to main content
Version: 4.4

Class: EntityMetadata<T>#

core.EntityMetadata

Type parameters#

NameTypeDefault
TAnyEntity<T>any

Hierarchy#

  • EntityMetadata

Constructors#

constructor#

+ new EntityMetadata<T>(meta?: Partial<EntityMetadata<any>>): EntityMetadata<T>

Type parameters:#

NameTypeDefault
TAnyEntity<T>any

Parameters:#

NameTypeDefault value
metaPartial<EntityMetadata<any>>...

Returns: EntityMetadata<T>

Defined in: packages/core/src/typings.ts:191

Properties#

abstract#

abstract: boolean

Defined in: packages/core/src/typings.ts:307


class#

class: Constructor<T>

Defined in: packages/core/src/typings.ts:306


className#

className: string

Defined in: packages/core/src/typings.ts:279


collection#

collection: string

Defined in: packages/core/src/typings.ts:290


comment#

Optional comment: undefined | string

Defined in: packages/core/src/typings.ts:310


comparableProps#

comparableProps: EntityProperty<T>[]

Defined in: packages/core/src/typings.ts:299


compositePK#

compositePK: boolean

Defined in: packages/core/src/typings.ts:293


constructorParams#

constructorParams: string[]

Defined in: packages/core/src/typings.ts:286


customRepository#

customRepository: () => Constructor<EntityRepository<T>>

Defined in: packages/core/src/typings.ts:303


discriminatorColumn#

Optional discriminatorColumn: undefined | string

Defined in: packages/core/src/typings.ts:282


discriminatorMap#

Optional discriminatorMap: undefined | Dictionary<string>

Defined in: packages/core/src/typings.ts:284


discriminatorValue#

Optional discriminatorValue: undefined | string

Defined in: packages/core/src/typings.ts:283


embeddable#

embeddable: boolean

Defined in: packages/core/src/typings.ts:285


extends#

extends: string

Defined in: packages/core/src/typings.ts:289


filters#

filters: Dictionary<FilterDef<T>>

Defined in: packages/core/src/typings.ts:309


forceConstructor#

forceConstructor: boolean

Defined in: packages/core/src/typings.ts:287


hooks#

hooks: Partial<Record<onInit | beforeCreate | afterCreate | beforeUpdate | afterUpdate | beforeDelete | afterDelete | beforeFlush | onFlush | afterFlush | beforeTransactionStart | afterTransactionStart | beforeTransactionCommit | afterTransactionCommit | beforeTransactionRollback | afterTransactionRollback, string & keyof T[]>>

Defined in: packages/core/src/typings.ts:304


hydrateProps#

hydrateProps: EntityProperty<T>[]

Defined in: packages/core/src/typings.ts:300


indexes#

indexes: { name?: undefined | string ; options?: undefined | Dictionary<any> ; properties: keyof T & string | keyof T & string[] ; type?: undefined | string }[]

Defined in: packages/core/src/typings.ts:301


name#

Optional name: undefined | string

Defined in: packages/core/src/typings.ts:278


path#

path: string

Defined in: packages/core/src/typings.ts:291


pivotTable#

pivotTable: boolean

Defined in: packages/core/src/typings.ts:281


primaryKeys#

primaryKeys: keyof T & string[]

Defined in: packages/core/src/typings.ts:292


properties#

properties: { [K in string]: EntityProperty<T>}

Defined in: packages/core/src/typings.ts:296


propertyOrder#

Readonly propertyOrder: Map<string, number>

Defined in: packages/core/src/typings.ts:191


props#

props: EntityProperty<T>[]

Defined in: packages/core/src/typings.ts:297


prototype#

prototype: T

Defined in: packages/core/src/typings.ts:305


readonly#

Optional readonly: undefined | boolean

Defined in: packages/core/src/typings.ts:312


relations#

relations: EntityProperty<T>[]

Defined in: packages/core/src/typings.ts:298


root#

root: EntityMetadata<T>

Defined in: packages/core/src/typings.ts:313


selfReferencing#

Optional selfReferencing: undefined | boolean

Defined in: packages/core/src/typings.ts:311


serializedPrimaryKey#

serializedPrimaryKey: keyof T & string

Defined in: packages/core/src/typings.ts:295


tableName#

tableName: string

Defined in: packages/core/src/typings.ts:280


toJsonParams#

toJsonParams: string[]

Defined in: packages/core/src/typings.ts:288


uniques#

uniques: { name?: undefined | string ; options?: undefined | Dictionary<any> ; properties: keyof T & string | keyof T & string[] }[]

Defined in: packages/core/src/typings.ts:302


useCache#

useCache: boolean

Defined in: packages/core/src/typings.ts:308


versionProperty#

versionProperty: keyof T & string

Defined in: packages/core/src/typings.ts:294

Methods#

addProperty#

addProperty(prop: EntityProperty<T>, sync?: boolean): void

Parameters:#

NameTypeDefault value
propEntityProperty<T>-
syncbooleantrue

Returns: void

Defined in: packages/core/src/typings.ts:204


getPrimaryProps#

getPrimaryProps(): EntityProperty<T>[]

Returns: EntityProperty<T>[]

Defined in: packages/core/src/typings.ts:224


initIndexes#

PrivateinitIndexes(prop: EntityProperty<T>): void

Parameters:#

NameType
propEntityProperty<T>

Returns: void

Defined in: packages/core/src/typings.ts:247


removeProperty#

removeProperty(name: string, sync?: boolean): void

Parameters:#

NameTypeDefault value
namestring-
syncbooleantrue

Returns: void

Defined in: packages/core/src/typings.ts:214


sync#

sync(initIndexes?: boolean): void

Parameters:#

NameTypeDefault value
initIndexesbooleanfalse

Returns: void

Defined in: packages/core/src/typings.ts:228

Last updated on by Martin Adámek