OptionalBackReference

class OptionalBackReference<ParentID : Any, out Parent : Entity<ParentID>, ChildID : Any, in Child : Entity<ChildID>, REF>(reference: Column<REF?>, factory: EntityClass<ParentID, Parent>, references: Map<Column<*>, Column<*>>? = null) : ReadOnlyProperty<Child, Parent?>

Class responsible for implementing property delegates of the read-only properties involved in an optional table relation between two Entity classes, which retrieves the child entity that optionally references the parent entity.

Parameters

reference

The nullable reference column defined on the child entity's associated table.

factory

The EntityClass associated with the child entity that optionally references the parent entity.

Constructors

Link copied to clipboard
constructor(reference: Column<REF?>, factory: EntityClass<ParentID, Parent>, references: Map<Column<*>, Column<*>>? = null)

Functions

Link copied to clipboard
open operator override fun getValue(thisRef: Child, property: KProperty<*>): Parent?