Class: ReferenceDescriptor

ReferenceDescriptor

Describes a reference in BookshelfMapping


new ReferenceDescriptor()

Properties:
Name Type Argument Default Description
mapping string

Describes Referenced Entity or ValueObject

type Class <optional>
Object

Referenced Entities or ValueObjects are instances of this type

mappedBy string <optional>
relation.name + _id

FK name

identifies string <optional>
identifiedBy

By default takes the identifiedBy column of referenced entity and applies discriminators
together with harmonisation condition. If set to some column name then discriminators are omitted what may be used to create relation to
a unique revision of referenced entity

orphanRemoval boolean <optional>
false

Remove all orphans upon save/remove

cascade boolean <optional>
false

Save/remove objects of this relation

saveSequential boolean <optional>
false

Force sequential saving of this relation objects.
Useful e.g. when dealing with foreign table wrapper tables to avoid transaction errors.

Source: