ForeignKeyDeclaration

org.squeryl.ForeignKeyDeclaration
class ForeignKeyDeclaration(val idWithinSchema: Int, val foreignKeyColumnName: String, val referencedPrimaryKey: String)

ForeignKeyDeclaration are to be manipulated only during the Schema definition (this is why all public methods have the implicit arg (implicit ev: Schema))

Attributes

Source
KeyedEntity.scala
Graph
Supertypes
class Object
trait Matchable
class Any

Members list

Value members

Concrete methods

def constrainReference()(implicit ev: Schema): Unit

Will cause a foreign key constraint to be created at schema creation time : alter table add foreign key ( ) references ( )

Will cause a foreign key constraint to be created at schema creation time : alter table add foreign key ( ) references ( )

Attributes

Source
KeyedEntity.scala
def constrainReference(a1: ReferentialAction)(implicit ev: Schema): Unit

Does the same as constrainReference, plus adds a ReferentialAction (ex.: foreignKeyDeclaration.constrainReference(onDelete cascade))

Does the same as constrainReference, plus adds a ReferentialAction (ex.: foreignKeyDeclaration.constrainReference(onDelete cascade))

Attributes

Source
KeyedEntity.scala
def constrainReference(a1: ReferentialAction, a2: ReferentialAction)(implicit ev: Schema): Unit

Does the same as constrainReference, plus adds two ReferentialActions (ex.: foreignKeyDeclaration.constrainReference(onDelete cascade, onUpdate restrict))

Does the same as constrainReference, plus adds two ReferentialActions (ex.: foreignKeyDeclaration.constrainReference(onDelete cascade, onUpdate restrict))

Attributes

Source
KeyedEntity.scala
def unConstrainReference()(implicit ev: Schema): Unit

Causes the foreign key to have no constraint

Causes the foreign key to have no constraint

Attributes

Source
KeyedEntity.scala

Concrete fields

val foreignKeyColumnName: String

Attributes

Source
KeyedEntity.scala
val idWithinSchema: Int

Attributes

Source
KeyedEntity.scala
val referencedPrimaryKey: String

Attributes

Source
KeyedEntity.scala