Methods summary
public static
|
#
macro( string $name, Closure $macro )
Registers a custom macro.
Registers a custom macro.
Parameters
- $name
string $name
- $macro
Closure
$macro
|
public
|
#
__construct( string $name )
Create a new schema table instance.
Create a new schema table instance.
Parameters
|
public
Laravel\Fluent
|
#
create( )
Indicate that the table should be created.
Indicate that the table should be created.
Returns
|
public
Laravel\Fluent
|
#
primary( string|array $columns, string $name = null )
Create a new primary key on the table.
Create a new primary key on the table.
Parameters
- $columns
string|array $columns
- $name
string $name
Returns
|
public
Laravel\Fluent
|
#
unique( string|array $columns, string $name = null )
Create a new unique index on the table.
Create a new unique index on the table.
Parameters
- $columns
string|array $columns
- $name
string $name
Returns
|
public
Laravel\Fluent
|
#
fulltext( string|array $columns, string $name = null )
Create a new full-text index on the table.
Create a new full-text index on the table.
Parameters
- $columns
string|array $columns
- $name
string $name
Returns
|
public
Laravel\Fluent
|
#
index( string|array $columns, string $name = null )
Create a new index on the table.
Create a new index on the table.
Parameters
- $columns
string|array $columns
- $name
string $name
Returns
|
public
Laravel\Fluent
|
#
foreign( string|array $columns, string $name = null )
Add a foreign key constraint to the table.
Add a foreign key constraint to the table.
Parameters
- $columns
string|array $columns
- $name
string $name
Returns
|
public
Laravel\Fluent
|
#
key( string $type, string|array $columns, string $name )
Create a command for creating any index.
Create a command for creating any index.
Parameters
- $type
string $type
- $columns
string|array $columns
- $name
string $name
Returns
|
public
Laravel\Fluent
|
#
rename( string $name )
Rename the database table.
Rename the database table.
Parameters
Returns
|
public
Laravel\Fluent
|
#
drop( )
Drop the database table.
Returns
|
public
|
#
drop_column( string|array $columns )
Drop a column from the table.
Drop a column from the table.
Parameters
- $columns
string|array $columns
|
public
|
#
drop_primary( string $name = null )
Drop a primary key from the table.
Drop a primary key from the table.
Parameters
|
public
|
#
drop_unique( string $name )
Drop a unique index from the table.
Drop a unique index from the table.
Parameters
|
public
|
#
drop_fulltext( string $name )
Drop a full-text index from the table.
Drop a full-text index from the table.
Parameters
|
public
|
#
drop_index( string $name )
Drop an index from the table.
Drop an index from the table.
Parameters
|
public
|
#
drop_foreign( string $name )
Drop a foreign key constraint from the table.
Drop a foreign key constraint from the table.
Parameters
|
protected
Laravel\Fluent
|
#
drop_key( string $type, string $name )
Create a command to drop any type of index.
Create a command to drop any type of index.
Parameters
- $type
string $type
- $name
string $name
Returns
|
public
Laravel\Fluent
|
#
increments( string $name )
Add an auto-incrementing integer to the table.
Add an auto-incrementing integer to the table.
Parameters
Returns
|
public
Laravel\Fluent
|
#
string( string $name, integer $length = 200 )
Add a string column to the table.
Add a string column to the table.
Parameters
- $name
string $name
- $length
integer $length
Returns
|
public
Laravel\Fluent
|
#
integer( string $name, boolean $increment = false )
Add an integer column to the table.
Add an integer column to the table.
Parameters
- $name
string $name
- $increment
boolean $increment
Returns
|
public
Laravel\Fluent
|
#
float( string $name )
Add a float column to the table.
Add a float column to the table.
Parameters
Returns
|
public
Laravel\Fluent
|
#
decimal( string $name, integer $precision, integer $scale )
Add a decimal column to the table.
Add a decimal column to the table.
Parameters
- $name
string $name
- $precision
integer $precision
- $scale
integer $scale
Returns
|
public
Laravel\Fluent
|
#
boolean( string $name )
Add a boolean column to the table.
Add a boolean column to the table.
Parameters
Returns
|
public
|
#
timestamps( )
Create date-time columns for creation and update timestamps.
Create date-time columns for creation and update timestamps.
|
public
Laravel\Fluent
|
#
date( string $name )
Add a date-time column to the table.
Add a date-time column to the table.
Parameters
Returns
|
public
Laravel\Fluent
|
#
timestamp( string $name )
Add a timestamp column to the table.
Add a timestamp column to the table.
Parameters
Returns
|
public
Laravel\Fluent
|
#
text( string $name )
Add a text column to the table.
Add a text column to the table.
Parameters
Returns
|
public
Laravel\Fluent
|
#
blob( string $name )
Add a blob column to the table.
Add a blob column to the table.
Parameters
Returns
|
public
|
#
on( string $connection )
Set the database connection for the table operation.
Set the database connection for the table operation.
Parameters
- $connection
string $connection
|
public
boolean
|
#
creating( )
Determine if the schema table has a creation command.
Determine if the schema table has a creation command.
Returns
boolean
|
protected
Laravel\Fluent
|
#
command( string $type, array $parameters = array() )
Create a new fluent command instance.
Create a new fluent command instance.
Parameters
- $type
string $type
- $parameters
array $parameters
Returns
|
protected
Laravel\Fluent
|
#
column( string $type, array $parameters = array() )
Create a new fluent column instance.
Create a new fluent column instance.
Parameters
- $type
string $type
- $parameters
array $parameters
Returns
|
public
mixed
|
#
__call( string $method, array $parameters )
Dynamically handle calls to custom macros.
Dynamically handle calls to custom macros.
Parameters
- $method
string $method
- $parameters
array $parameters
Returns
mixed
|