ModelRelations
Interface: ModelRelations
Defined in: packages/content-mapper/src/module-discovery.ts:664
Relations recorded for a model.
Properties
behaviors?
optionalbehaviors?:object[]
Defined in: packages/content-mapper/src/module-discovery.ts:680
Behaviour-typed attributes.
attribute
attribute:
string
behavior
behavior:
string
children?
optionalchildren?:string[]
Defined in: packages/content-mapper/src/module-discovery.ts:682
Models declaring this model as their parent, filled by backfillModelRelations.
dependents?
optionaldependents?:RelationDependent[]
Defined in: packages/content-mapper/src/module-discovery.ts:684
Relations targeting this model with a delete policy, filled by backfillModelRelations.
links?
optionallinks?:object[]
Defined in: packages/content-mapper/src/module-discovery.ts:674
Outgoing links, from the ModelLink* family.
model is absent when the target is a type parameter, as on a generic
base class — the link is still real and is recorded without it.
onDelete is absent for the default NONE; ownership marks a Contains.
attribute
attribute:
string
model?
optionalmodel?:string
onDelete?
optionalonDelete?:"CASCADE"|"RESTRICT"|"SET_NULL"|"NONE"
ownership?
optionalownership?:"CONTAINS"
type
type:
string
parent?
optionalparent?:object
Defined in: packages/content-mapper/src/module-discovery.ts:666
Owning model, from a ModelParent<T> attribute, and the policy applied to the model when it is deleted.
attribute
attribute:
string
model
model:
string
onDelete
onDelete:
"CASCADE"|"RESTRICT"|"SET_NULL"|"NONE"
polymorphicLinks?
optionalpolymorphicLinks?:object[]
Defined in: packages/content-mapper/src/module-discovery.ts:676
Polymorphic references, optionally constrained to exact model identifiers.
attribute
attribute:
string
models?
optionalmodels?:string[]
queries?
optionalqueries?:object[]
Defined in: packages/content-mapper/src/module-discovery.ts:678
Reverse lookups, from ModelRelated<T, U, "attr">.
attribute
attribute:
string
model
model:
string
targetAttribute?
optionaltargetAttribute?:string