class ForeignIdColumnDefinition extends ColumnDefinition

Traits

Properties

static protected array $macros

The registered string macros.

from  Macroable
protected TValue> $attributes

All of the attributes set on the fluent instance.

from  Fluent
protected Blueprint $blueprint

The schema builder blueprint instance.

Methods

mixed
when(mixed $value = null, callable|null $callback = null, callable|null $default = null)

Apply the callback if the given "value" is (or resolves to) truthy.

mixed
unless(mixed $value = null, callable|null $callback = null, callable|null $default = null)

Apply the callback if the given "value" is (or resolves to) falsy.

array
all(mixed $keys = null)

Retrieve all data from the instance.

mixed
data(string|null $key = null, mixed $default = null)

Retrieve data from the instance.

bool
exists(array|string $key)

Determine if the data contains a given key.

bool
has(array|string $key)

Determine if the data contains a given key.

bool
hasAny(array|string $keys)

Determine if the instance contains any of the given keys.

mixed
whenHas(string $key, callable $callback, callable|null $default = null)

Apply the callback if the instance contains the given key.

bool
filled(array|string $key)

Determine if the instance contains a non-empty value for the given key.

bool
isNotFilled(array|string $key)

Determine if the instance contains an empty value for the given key.

bool
anyFilled(array|string $keys)

Determine if the instance contains a non-empty value for any of the given keys.

mixed
whenFilled(string $key, callable $callback, callable|null $default = null)

Apply the callback if the instance contains a non-empty value for the given key.

mixed
whenEnum(string $key, string $enumClass, callable $callback, callable|null $default = null)

Apply the callback if the instance contains a valid enum value for the given key.

bool
missing(array|string $key)

Determine if the instance is missing a given key.

mixed
whenMissing(string $key, callable $callback, callable|null $default = null)

Apply the callback if the instance is missing the given key.

bool
isEmptyString(string $key)

Determine if the given key is an empty string for "filled".

str(string $key, mixed $default = null)

Retrieve data from the instance as a Stringable instance.

string(string $key, mixed $default = null)

Retrieve data from the instance as a Stringable instance.

bool
boolean(string|null $key = null, bool $default = false)

Retrieve data as a boolean value.

int
integer(string $key, int $default = 0)

Retrieve data as an integer value.

float
float(string $key, float $default = 0.0)

Retrieve data as a float value.

int|float
clamp(string $key, int|float $min, int|float $max, int|float $default = 0)

Retrieve data clamped between min and max values.

CarbonInterface|null
date(string $key, string|null $format = null, UnitEnum|string|null $tz = null)

Retrieve data from the instance as a Carbon instance.

CarbonInterval|null
interval(string $key, Unit|string|null $unit = null)

Retrieve data from the instance as a CarbonInterval instance.

mixed
enum(string $key, string $enumClass, mixed $default = null)

Retrieve data from the instance as an enum.

array
enums(string $key, string $enumClass)

Retrieve data from the instance as an array of enums.

bool
isBackedEnum(string $enumClass)

Determine if the given enum class is backed.

int|string|null
normalizeEnumValue(string $enumClass, mixed $value)

Normalize enum input to a strict backed value.

string|null
enumBackingType(string $enumClass)

Resolve and cache the enum backing type for repeated lookups.

array
array(array|string|null $key = null)

Retrieve data from the instance as an array.

collect(array|string|null $key = null)

Retrieve data from the instance as a collection.

array
only(mixed $keys)

Get a subset containing the provided keys with values from the instance data.

array
except(mixed $keys)

Get all of the data except for a specified array of items.

static void
macro(string $name, callable|object $macro)

Register a custom macro.

static void
mixin(object $mixin, bool $replace = true)

Mix another object into the class.

static bool
hasMacro(string $name)

Check if macro is registered.

static void
flushMacros()

Flush the existing macros.

static mixed
__callStatic(string $method, array $parameters)

Dynamically handle calls to the class.

mixed
__call(string $method, array $parameters)

Dynamically handle calls to the class.

__construct(Blueprint $blueprint, array|object $attributes = [])

Create a new foreign ID column definition.

static Fluent
make(array|object $attributes = [])

Create a new fluent instance.

from  Fluent
mixed
get(string|null $key = null, mixed $default = null)

Get an attribute from the fluent instance using "dot" notation.

from  Fluent
set(string $key, mixed $value)

Set an attribute on the fluent instance using "dot" notation.

from  Fluent
fill(array|object $attributes)

Fill the fluent instance with an array of attributes.

from  Fluent
mixed
value(string $key, mixed $default = null)

Get an attribute from the fluent instance.

from  Fluent
scope(string $key, mixed $default = null)

Get the value of the given key as a new Fluent instance.

from  Fluent
array
getAttributes()

Get the attributes from the fluent instance.

from  Fluent
array
toArray()

Convert the fluent instance to an array.

from  Fluent
array
jsonSerialize()

Convert the object into something JSON serializable.

from  Fluent
string
toJson(int $options = 0)

Convert the fluent instance to JSON.

from  Fluent
string
toPrettyJson(int $options = 0)

Convert the fluent instance to pretty print formatted JSON.

from  Fluent
bool
isEmpty()

Determine if the fluent instance is empty.

from  Fluent
bool
isNotEmpty()

Determine if the fluent instance is not empty.

from  Fluent
bool
offsetExists(mixed $offset)

Determine if the given offset exists.

from  Fluent
mixed
offsetGet(mixed $offset)

Get the value for a given offset.

from  Fluent
void
offsetSet(mixed $offset, mixed $value)

Set the value at the given offset.

from  Fluent
void
offsetUnset(mixed $offset)

Unset the value at the given offset.

from  Fluent
getIterator()

Get an iterator for the attributes.

from  Fluent
static void
flushState()

Flush all static state.

from  Fluent
mixed
__get(string $key)

Dynamically retrieve the value of an attribute.

from  Fluent
void
__set(string $key, mixed $value)

Dynamically set the value of an attribute.

from  Fluent
bool
__isset(string $key)

Dynamically check if an attribute is set.

from  Fluent
void
__unset(string $key)

Dynamically unset an attribute.

from  Fluent
$this
after(string $column) Place the column "after" another column (MySQL)

No description

$this
always(bool $value = 'true') Used as a modifier for generatedAs() (PostgreSQL)

No description

$this
autoIncrement() $et INTEGER columns as auto-increment (primary key)

No description

$this
change()

Change the column

$this
charset(string $charset) Specify a character set for the column (MySQL)

No description

$this
collation(string $collation)

Specify a collation for the column

$this
comment(string $comment) Add a comment to the column (MySQL/PostgreSQL)

No description

$this
default(mixed $value)

Specify a "default" value for the column

$this
first() $lace the column "first" in the table (MySQL)

No description

$this
from(int $startingValue) Set the starting value of an auto-incrementing field (MySQL / PostgreSQL)

No description

$this
fulltext(bool|string $indexName = 'null')

Add a fulltext index

$this
generatedAs(Expression $expression = 'null') Create a SQL compliant identity column (PostgreSQL)

No description

$this
instant() $pecify that algorithm = instant should be used for the column operation (MySQL)

No description

$this
index(bool|string $indexName = 'null')

Add an index

$this
invisible() $pecify that the column should be invisible to "SELECT *" (MySQL)

No description

$this
lock(string $value) Specify the DDL lock mode for the column operation (MySQL)

No description

$this
nullable(bool $value = 'true')

Allow NULL values to be inserted into the column

$this
persisted() $ark the computed generated column as persistent (SQL Server)

No description

$this
primary(bool $value = 'true')

Add a primary index

$this
spatialIndex(bool|string $indexName = 'null')

Add a spatial index

$this
vectorIndex(bool|string $indexName = 'null')

Add a vector index

$this
startingValue(int $startingValue) Set the starting value of an auto-incrementing field (MySQL/PostgreSQL)

No description

$this
storedAs(Expression|string $expression) Create a stored generated column (MySQL/PostgreSQL/SQLite)

No description

$this
type(string $type)

Specify a type for the column

$this
unique(bool|string $indexName = 'null')

Add a unique index

$this
unsigned() $et the INTEGER column as UNSIGNED (MySQL)

No description

$this
useCurrent()

Set the TIMESTAMP column to use CURRENT_TIMESTAMP as default value

$this
useCurrentOnUpdate() $et the TIMESTAMP column to use CURRENT_TIMESTAMP when updating (MySQL)

No description

$this
virtualAs(Expression|string $expression) Create a virtual generated column (MySQL/PostgreSQL/SQLite)

No description

constrained(string|null $table = null, string|null $column = null, string|null $indexName = null)

Create a foreign key constraint on this column referencing the "id" column of the conventionally related table.

references(string $column, string|null $indexName = null)

Specify which column this foreign ID references on another table.

Details

in Conditionable at line 23
mixed when(mixed $value = null, callable|null $callback = null, callable|null $default = null)

Apply the callback if the given "value" is (or resolves to) truthy.

Parameters

mixed $value
callable|null $callback
callable|null $default

Return Value

mixed

in Conditionable at line 56
mixed unless(mixed $value = null, callable|null $callback = null, callable|null $default = null)

Apply the callback if the given "value" is (or resolves to) falsy.

Parameters

mixed $value
callable|null $callback
callable|null $default

Return Value

mixed

in InteractsWithData at line 30
abstract array all(mixed $keys = null)

Retrieve all data from the instance.

Parameters

mixed $keys

Return Value

array

in InteractsWithData at line 35
abstract protected mixed data(string|null $key = null, mixed $default = null)

Retrieve data from the instance.

Parameters

string|null $key
mixed $default

Return Value

mixed

in InteractsWithData at line 40
bool exists(array|string $key)

Determine if the data contains a given key.

Parameters

array|string $key

Return Value

bool

in InteractsWithData at line 48
bool has(array|string $key)

Determine if the data contains a given key.

Parameters

array|string $key

Return Value

bool

in InteractsWithData at line 66
bool hasAny(array|string $keys)

Determine if the instance contains any of the given keys.

Parameters

array|string $keys

Return Value

bool

in InteractsWithData at line 80
mixed whenHas(string $key, callable $callback, callable|null $default = null)

Apply the callback if the instance contains the given key.

Parameters

string $key
callable $callback
callable|null $default

Return Value

mixed

in InteractsWithData at line 96
bool filled(array|string $key)

Determine if the instance contains a non-empty value for the given key.

Parameters

array|string $key

Return Value

bool

in InteractsWithData at line 112
bool isNotFilled(array|string $key)

Determine if the instance contains an empty value for the given key.

Parameters

array|string $key

Return Value

bool

in InteractsWithData at line 128
bool anyFilled(array|string $keys)

Determine if the instance contains a non-empty value for any of the given keys.

Parameters

array|string $keys

Return Value

bool

in InteractsWithData at line 146
mixed whenFilled(string $key, callable $callback, callable|null $default = null)

Apply the callback if the instance contains a non-empty value for the given key.

Parameters

string $key
callable $callback
callable|null $default

Return Value

mixed

in InteractsWithData at line 168
mixed whenEnum(string $key, string $enumClass, callable $callback, callable|null $default = null)

Apply the callback if the instance contains a valid enum value for the given key.

Parameters

string $key
string $enumClass
callable $callback
callable|null $default

Return Value

mixed

in InteractsWithData at line 188
bool missing(array|string $key)

Determine if the instance is missing a given key.

Parameters

array|string $key

Return Value

bool

in InteractsWithData at line 198
mixed whenMissing(string $key, callable $callback, callable|null $default = null)

Apply the callback if the instance is missing the given key.

Parameters

string $key
callable $callback
callable|null $default

Return Value

mixed

in InteractsWithData at line 214
protected bool isEmptyString(string $key)

Determine if the given key is an empty string for "filled".

Parameters

string $key

Return Value

bool

in InteractsWithData at line 224
Stringable str(string $key, mixed $default = null)

Retrieve data from the instance as a Stringable instance.

Parameters

string $key
mixed $default

Return Value

Stringable

in InteractsWithData at line 232
Stringable string(string $key, mixed $default = null)

Retrieve data from the instance as a Stringable instance.

Parameters

string $key
mixed $default

Return Value

Stringable

in InteractsWithData at line 242
bool boolean(string|null $key = null, bool $default = false)

Retrieve data as a boolean value.

Returns true when value is "1", "true", "on", and "yes". Otherwise, returns false.

Parameters

string|null $key
bool $default

Return Value

bool

in InteractsWithData at line 250
int integer(string $key, int $default = 0)

Retrieve data as an integer value.

Parameters

string $key
int $default

Return Value

int

in InteractsWithData at line 258
float float(string $key, float $default = 0.0)

Retrieve data as a float value.

Parameters

string $key
float $default

Return Value

float

in InteractsWithData at line 266
int|float clamp(string $key, int|float $min, int|float $max, int|float $default = 0)

Retrieve data clamped between min and max values.

Parameters

string $key
int|float $min
int|float $max
int|float $default

Return Value

int|float

in InteractsWithData at line 283
CarbonInterface|null date(string $key, string|null $format = null, UnitEnum|string|null $tz = null)

Retrieve data from the instance as a Carbon instance.

Parameters

string $key
string|null $format
UnitEnum|string|null $tz

Return Value

CarbonInterface|null

Exceptions

InvalidFormatException

in InteractsWithData at line 301
CarbonInterval|null interval(string $key, Unit|string|null $unit = null)

Retrieve data from the instance as a CarbonInterval instance.

Parameters

string $key
Unit|string|null $unit

Return Value

CarbonInterval|null

in InteractsWithData at line 327
mixed enum(string $key, string $enumClass, mixed $default = null)

Retrieve data from the instance as an enum.

Parameters

string $key
string $enumClass
mixed $default

Return Value

mixed

in InteractsWithData at line 350
array enums(string $key, string $enumClass)

Retrieve data from the instance as an array of enums.

Parameters

string $key
string $enumClass

Return Value

array

in InteractsWithData at line 369
protected bool isBackedEnum(string $enumClass)

Determine if the given enum class is backed.

Parameters

string $enumClass

Return Value

bool

in InteractsWithData at line 377
protected int|string|null normalizeEnumValue(string $enumClass, mixed $value)

Normalize enum input to a strict backed value.

Parameters

string $enumClass
mixed $value

Return Value

int|string|null

in InteractsWithData at line 422
protected string|null enumBackingType(string $enumClass)

Resolve and cache the enum backing type for repeated lookups.

Parameters

string $enumClass

Return Value

string|null

in InteractsWithData at line 433
array array(array|string|null $key = null)

Retrieve data from the instance as an array.

Parameters

array|string|null $key

Return Value

array

in InteractsWithData at line 441
Collection collect(array|string|null $key = null)

Retrieve data from the instance as a collection.

Parameters

array|string|null $key

Return Value

Collection

in InteractsWithData at line 451
array only(mixed $keys)

Get a subset containing the provided keys with values from the instance data.

Parameters

mixed $keys

Return Value

array

in InteractsWithData at line 475
array except(mixed $keys)

Get all of the data except for a specified array of items.

Parameters

mixed $keys

Return Value

array

in Macroable at line 28
static void macro(string $name, callable|object $macro)

Register a custom macro.

Boot-only. Macros persist in a static property for the worker lifetime and apply to every subsequent call on the macroable class.

Parameters

string $name
callable|object $macro

Return Value

void

in Macroable at line 41
static void mixin(object $mixin, bool $replace = true)

Mix another object into the class.

Boot-only. Delegates to macro() for each method; registered macros persist in a static property for the worker lifetime.

Parameters

object $mixin
bool $replace

Return Value

void

Exceptions

ReflectionException

in Macroable at line 57
static bool hasMacro(string $name)

Check if macro is registered.

Parameters

string $name

Return Value

bool

in Macroable at line 68
static void flushMacros()

Flush the existing macros.

Boot or tests only. Clears worker-wide macros; concurrent coroutines may resolve different methods depending on timing.

Return Value

void

in Macroable at line 78
static mixed __callStatic(string $method, array $parameters)

Dynamically handle calls to the class.

Parameters

string $method
array $parameters

Return Value

mixed

Exceptions

BadMethodCallException

in Macroable at line 103
mixed __call(string $method, array $parameters)

Dynamically handle calls to the class.

Parameters

string $method
array $parameters

Return Value

mixed

Exceptions

BadMethodCallException

at line 19
__construct(Blueprint $blueprint, array|object $attributes = [])

Create a new foreign ID column definition.

Parameters

Blueprint $blueprint
array|object $attributes

in Fluent at line 54
static Fluent make(array|object $attributes = [])

Create a new fluent instance.

Parameters

array|object $attributes

Return Value

Fluent

in Fluent at line 67
mixed get(string|null $key = null, mixed $default = null)

Get an attribute from the fluent instance using "dot" notation.

Parameters

string|null $key
mixed $default

Return Value

mixed

in Fluent at line 75
Fluent set(string $key, mixed $value)

Set an attribute on the fluent instance using "dot" notation.

Parameters

string $key
mixed $value

Return Value

Fluent

in Fluent at line 87
Fluent fill(array|object $attributes)

Fill the fluent instance with an array of attributes.

Parameters

array|object $attributes

Return Value

Fluent

in Fluent at line 99
mixed value(string $key, mixed $default = null)

Get an attribute from the fluent instance.

Parameters

string $key
mixed $default

Return Value

mixed

in Fluent at line 111
Fluent scope(string $key, mixed $default = null)

Get the value of the given key as a new Fluent instance.

Parameters

string $key
mixed $default

Return Value

Fluent

in Fluent at line 151
array getAttributes()

Get the attributes from the fluent instance.

Return Value

array

in Fluent at line 161
array toArray()

Convert the fluent instance to an array.

Return Value

array

in Fluent at line 171
array jsonSerialize()

Convert the object into something JSON serializable.

Return Value

array

in Fluent at line 179
string toJson(int $options = 0)

Convert the fluent instance to JSON.

Parameters

int $options

Return Value

string

in Fluent at line 187
string toPrettyJson(int $options = 0)

Convert the fluent instance to pretty print formatted JSON.

Parameters

int $options

Return Value

string

in Fluent at line 195
bool isEmpty()

Determine if the fluent instance is empty.

Return Value

bool

in Fluent at line 203
bool isNotEmpty()

Determine if the fluent instance is not empty.

Return Value

bool

in Fluent at line 213
bool offsetExists(mixed $offset)

Determine if the given offset exists.

Parameters

mixed $offset

Return Value

bool

in Fluent at line 224
mixed offsetGet(mixed $offset)

Get the value for a given offset.

Parameters

mixed $offset

Return Value

mixed

in Fluent at line 235
void offsetSet(mixed $offset, mixed $value)

Set the value at the given offset.

Parameters

mixed $offset
mixed $value

Return Value

void

in Fluent at line 245
void offsetUnset(mixed $offset)

Unset the value at the given offset.

Parameters

mixed $offset

Return Value

void

in Fluent at line 255
Traversable getIterator()

Get an iterator for the attributes.

Return Value

Traversable

in Fluent at line 263
static void flushState()

Flush all static state.

Return Value

void

in Fluent at line 289
mixed __get(string $key)

Dynamically retrieve the value of an attribute.

Parameters

string $key

Return Value

mixed

in Fluent at line 297
void __set(string $key, mixed $value)

Dynamically set the value of an attribute.

Parameters

string $key
mixed $value

Return Value

void

in Fluent at line 305
bool __isset(string $key)

Dynamically check if an attribute is set.

Parameters

string $key

Return Value

bool

in Fluent at line 313
void __unset(string $key)

Dynamically unset an attribute.

Parameters

string $key

Return Value

void

in ColumnDefinition at line 40
$this after(string $column) Place the column "after" another column (MySQL)

No description

Parameters

string $column) Place the column "after" another column (MySQL

Return Value

$this

in ColumnDefinition at line 40
$this always(bool $value = 'true') Used as a modifier for generatedAs() (PostgreSQL)

No description

Parameters

bool $value

Return Value

$this

in ColumnDefinition at line 40
$this autoIncrement() $et INTEGER columns as auto-increment (primary key)

No description

Parameters

) $et INTEGER columns as auto-increment (primary key

Return Value

$this

in ColumnDefinition at line 40
$this change()

Change the column

Return Value

$this

in ColumnDefinition at line 40
$this charset(string $charset) Specify a character set for the column (MySQL)

No description

Parameters

string $charset) Specify a character set for the column (MySQL

Return Value

$this

in ColumnDefinition at line 40
$this collation(string $collation)

Specify a collation for the column

Parameters

string $collation

Return Value

$this

in ColumnDefinition at line 40
$this comment(string $comment) Add a comment to the column (MySQL/PostgreSQL)

No description

Parameters

string $comment) Add a comment to the column (MySQL/PostgreSQL

Return Value

$this

in ColumnDefinition at line 40
$this default(mixed $value)

Specify a "default" value for the column

Parameters

mixed $value

Return Value

$this

in ColumnDefinition at line 40
$this first() $lace the column "first" in the table (MySQL)

No description

Parameters

) $lace the column "first" in the table (MySQL

Return Value

$this

in ColumnDefinition at line 40
$this from(int $startingValue) Set the starting value of an auto-incrementing field (MySQL / PostgreSQL)

No description

Parameters

int $startingValue) Set the starting value of an auto-incrementing field (MySQL / PostgreSQL

Return Value

$this

in ColumnDefinition at line 40
$this fulltext(bool|string $indexName = 'null')

Add a fulltext index

Parameters

bool|string $indexName

Return Value

$this

in ColumnDefinition at line 40
$this generatedAs(Expression $expression = 'null') Create a SQL compliant identity column (PostgreSQL)

No description

Parameters

Expression $expression

Return Value

$this

in ColumnDefinition at line 40
$this instant() $pecify that algorithm = instant should be used for the column operation (MySQL)

No description

Parameters

) $pecify that algorithm

Return Value

$this

in ColumnDefinition at line 40
$this index(bool|string $indexName = 'null')

Add an index

Parameters

bool|string $indexName

Return Value

$this

in ColumnDefinition at line 40
$this invisible() $pecify that the column should be invisible to "SELECT *" (MySQL)

No description

Parameters

) $pecify that the column should be invisible to "SELECT *" (MySQL

Return Value

$this

in ColumnDefinition at line 40
$this lock(string $value) Specify the DDL lock mode for the column operation (MySQL)

No description

Parameters

string $value) Specify the DDL lock mode for the column operation (MySQL

Return Value

$this

in ColumnDefinition at line 40
$this nullable(bool $value = 'true')

Allow NULL values to be inserted into the column

Parameters

bool $value

Return Value

$this

in ColumnDefinition at line 40
$this persisted() $ark the computed generated column as persistent (SQL Server)

No description

Parameters

) $ark the computed generated column as persistent (SQL Server

Return Value

$this

in ColumnDefinition at line 40
$this primary(bool $value = 'true')

Add a primary index

Parameters

bool $value

Return Value

$this

in ColumnDefinition at line 40
$this spatialIndex(bool|string $indexName = 'null')

Add a spatial index

Parameters

bool|string $indexName

Return Value

$this

in ColumnDefinition at line 40
$this vectorIndex(bool|string $indexName = 'null')

Add a vector index

Parameters

bool|string $indexName

Return Value

$this

in ColumnDefinition at line 40
$this startingValue(int $startingValue) Set the starting value of an auto-incrementing field (MySQL/PostgreSQL)

No description

Parameters

int $startingValue) Set the starting value of an auto-incrementing field (MySQL/PostgreSQL

Return Value

$this

in ColumnDefinition at line 40
$this storedAs(Expression|string $expression) Create a stored generated column (MySQL/PostgreSQL/SQLite)

No description

Parameters

Expression|string $expression) Create a stored generated column (MySQL/PostgreSQL/SQLite

Return Value

$this

in ColumnDefinition at line 40
$this type(string $type)

Specify a type for the column

Parameters

string $type

Return Value

$this

in ColumnDefinition at line 40
$this unique(bool|string $indexName = 'null')

Add a unique index

Parameters

bool|string $indexName

Return Value

$this

in ColumnDefinition at line 40
$this unsigned() $et the INTEGER column as UNSIGNED (MySQL)

No description

Parameters

) $et the INTEGER column as UNSIGNED (MySQL

Return Value

$this

in ColumnDefinition at line 40
$this useCurrent()

Set the TIMESTAMP column to use CURRENT_TIMESTAMP as default value

Return Value

$this

in ColumnDefinition at line 40
$this useCurrentOnUpdate() $et the TIMESTAMP column to use CURRENT_TIMESTAMP when updating (MySQL)

No description

Parameters

) $et the TIMESTAMP column to use CURRENT_TIMESTAMP when updating (MySQL

Return Value

$this

in ColumnDefinition at line 40
$this virtualAs(Expression|string $expression) Create a virtual generated column (MySQL/PostgreSQL/SQLite)

No description

Parameters

Expression|string $expression) Create a virtual generated column (MySQL/PostgreSQL/SQLite

Return Value

$this

at line 29
ForeignKeyDefinition constrained(string|null $table = null, string|null $column = null, string|null $indexName = null)

Create a foreign key constraint on this column referencing the "id" column of the conventionally related table.

Parameters

string|null $table
string|null $column
string|null $indexName

Return Value

ForeignKeyDefinition

at line 40
ForeignKeyDefinition references(string $column, string|null $indexName = null)

Specify which column this foreign ID references on another table.

Parameters

string $column
string|null $indexName

Return Value

ForeignKeyDefinition