class Schema

The migration API that delegates table creation and modifications to the Blueprint class.

Methods

static void
create(string $table, callable $callback)

Create a new table.

static void
dropIfExists(string $table)

Drop a table if it exists.

static void
rename(string $from, string $to)

Renames a table

static void
table(string $table, callable $callback)

Modify an existing table.

Details

at line 19
static void create(string $table, callable $callback)

Create a new table.

Parameters

string $table

The name of the table.

callable $callback

The callback function.

Return Value

void

at line 31
static void dropIfExists(string $table)

Drop a table if it exists.

Parameters

string $table

The name of the table.

Return Value

void

at line 43
static void rename(string $from, string $to)

Renames a table

Parameters

string $from

The original table's name.

string $to

The new table name.

Return Value

void

at line 55
static void table(string $table, callable $callback)

Modify an existing table.

Parameters

string $table

The name of the table.

callable $callback

The callback function.

Return Value

void