Skip to main content
Version: 4.4

Interface: NamingStrategy#

core.NamingStrategy

Hierarchy#

  • NamingStrategy

Implemented by#

Methods#

classToMigrationName#

classToMigrationName(timestamp: string): string

Return a migration name. This name should allow ordering.

Parameters:#

NameType
timestampstring

Returns: string

Defined in: packages/core/src/naming-strategy/NamingStrategy.ts:16


classToTableName#

classToTableName(entityName: string): string

Return a table name for an entity class

Parameters:#

NameType
entityNamestring

Returns: string

Defined in: packages/core/src/naming-strategy/NamingStrategy.ts:11


getClassName#

getClassName(file: string, separator?: string): string

Return a name of the class based on its file name

Parameters:#

NameType
filestring
separator?string

Returns: string

Defined in: packages/core/src/naming-strategy/NamingStrategy.ts:6


joinColumnName#

joinColumnName(propertyName: string): string

Return a join column name for a property

Parameters:#

NameType
propertyNamestring

Returns: string

Defined in: packages/core/src/naming-strategy/NamingStrategy.ts:31


joinKeyColumnName#

joinKeyColumnName(entityName: string, referencedColumnName?: string, composite?: boolean): string

Return the foreign key column name for the given parameters

Parameters:#

NameType
entityNamestring
referencedColumnName?string
composite?boolean

Returns: string

Defined in: packages/core/src/naming-strategy/NamingStrategy.ts:41


joinTableName#

joinTableName(sourceEntity: string, targetEntity: string, propertyName: string): string

Return a join table name

Parameters:#

NameType
sourceEntitystring
targetEntitystring
propertyNamestring

Returns: string

Defined in: packages/core/src/naming-strategy/NamingStrategy.ts:36


propertyToColumnName#

propertyToColumnName(propertyName: string): string

Return a column name for a property

Parameters:#

NameType
propertyNamestring

Returns: string

Defined in: packages/core/src/naming-strategy/NamingStrategy.ts:21


referenceColumnName#

referenceColumnName(): string

Return the default reference column name

Returns: string

Defined in: packages/core/src/naming-strategy/NamingStrategy.ts:26

Last updated on by renovate[bot]