class BlueprintState

Properties

protected Blueprint $blueprint

The blueprint instance.

protected Connection $connection

The connection instance.

Methods

__construct(Blueprint $blueprint, Connection $connection)

Create a new blueprint state instance.

getPrimaryKey()

Get the primary key.

array
getColumns()

Get the columns.

string
getTableSql()

Get the stored table definition.

array
getIndexes()

Get the indexes.

array
getForeignKeys()

Get the foreign keys.

void
update(Fluent $command)

Update the blueprint's state.

array
replaceColumn(array $columns, string $from, string $to)

Replace an exact column name in a projection.

Details

at line 60
__construct(Blueprint $blueprint, Connection $connection)

Create a new blueprint state instance.

Parameters

Blueprint $blueprint
Connection $connection

at line 139
IndexDefinition|null getPrimaryKey()

Get the primary key.

Return Value

IndexDefinition|null

at line 149
array getColumns()

Get the columns.

Return Value

array

at line 157
string getTableSql()

Get the stored table definition.

Return Value

string

at line 167
array getIndexes()

Get the indexes.

Return Value

array

at line 177
array getForeignKeys()

Get the foreign keys.

Return Value

array

at line 185
void update(Fluent $command)

Update the blueprint's state.

Parameters

Fluent $command

Return Value

void

at line 309
protected array replaceColumn(array $columns, string $from, string $to)

Replace an exact column name in a projection.

Parameters

array $columns
string $from
string $to

Return Value

array