final class ForeignKeyBlueprint (View source)

Collects the referenced table, columns, and actions for a table-level foreign key.

Methods

__construct(array $columns, string|null $referencedTable = null, array $referencedColumns = ['id'], string|null $name = null, ForeignKeyAction|null $onUpdate = null, ForeignKeyAction|null $onDelete = null)
on(string $table)

Provides this part of the database contract while preserving the object's current state and driver semantics.

name(string $name)

Provides this part of the database contract while preserving the object's current state and driver semantics.

onUpdate(ForeignKeyAction $action)

Provides this part of the database contract while preserving the object's current state and driver semantics.

onDelete(ForeignKeyAction $action)

Provides this part of the database contract while preserving the object's current state and driver semantics.

Provides this part of the database contract while preserving the object's current state and driver semantics.

Provides this part of the database contract while preserving the object's current state and driver semantics.

Provides this part of the database contract while preserving the object's current state and driver semantics.

Provides this part of the database contract while preserving the object's current state and driver semantics.

Provides this part of the database contract while preserving the object's current state and driver semantics.

Provides this part of the database contract while preserving the object's current state and driver semantics.

Details

__construct

__construct(array $columns, string|null $referencedTable = null, array $referencedColumns = ['id'], string|null $name = null, ForeignKeyAction|null $onUpdate = null, ForeignKeyAction|null $onDelete = null)

No description

Parameters

array $columns
string|null $referencedTable
array $referencedColumns
string|null $name
ForeignKeyAction|null $onUpdate
ForeignKeyAction|null $onDelete

references

ForeignKeyBlueprint references(string|array $columns)

No description

Parameters

string|array $columns

Return Value

ForeignKeyBlueprint

on

ForeignKeyBlueprint on(string $table)

Provides this part of the database contract while preserving the object's current state and driver semantics.

Parameters

string $table

Return Value

ForeignKeyBlueprint

name

ForeignKeyBlueprint name(string $name)

Provides this part of the database contract while preserving the object's current state and driver semantics.

Parameters

string $name

Return Value

ForeignKeyBlueprint

onUpdate

ForeignKeyBlueprint onUpdate(ForeignKeyAction $action)

Provides this part of the database contract while preserving the object's current state and driver semantics.

Parameters

ForeignKeyAction $action

Return Value

ForeignKeyBlueprint

onDelete

ForeignKeyBlueprint onDelete(ForeignKeyAction $action)

Provides this part of the database contract while preserving the object's current state and driver semantics.

Parameters

ForeignKeyAction $action

Return Value

ForeignKeyBlueprint

cascadeOnUpdate

ForeignKeyBlueprint cascadeOnUpdate()

Provides this part of the database contract while preserving the object's current state and driver semantics.

Return Value

ForeignKeyBlueprint

cascadeOnDelete

ForeignKeyBlueprint cascadeOnDelete()

Provides this part of the database contract while preserving the object's current state and driver semantics.

Return Value

ForeignKeyBlueprint

restrictOnUpdate

ForeignKeyBlueprint restrictOnUpdate()

Provides this part of the database contract while preserving the object's current state and driver semantics.

Return Value

ForeignKeyBlueprint

restrictOnDelete

ForeignKeyBlueprint restrictOnDelete()

Provides this part of the database contract while preserving the object's current state and driver semantics.

Return Value

ForeignKeyBlueprint

nullOnDelete

Provides this part of the database contract while preserving the object's current state and driver semantics.

Return Value

ForeignKeyBlueprint

definition

Provides this part of the database contract while preserving the object's current state and driver semantics.

Return Value

ForeignKeyDefinition