-
Notifications
You must be signed in to change notification settings - Fork 11.1k
/
Schema.php
executable file
·36 lines (33 loc) · 1.07 KB
/
Schema.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
<?php
namespace Illuminate\Support\Facades;
/**
* @method static \Illuminate\Database\Schema\Builder create(string $table, \Closure $callback)
* @method static \Illuminate\Database\Schema\Builder drop(string $table)
* @method static \Illuminate\Database\Schema\Builder dropIfExists(string $table)
* @method static \Illuminate\Database\Schema\Builder table(string $table, \Closure $callback)
* @method static void defaultStringLength(int $length)
*
* @see \Illuminate\Database\Schema\Builder
*/
class Schema extends Facade
{
/**
* Get a schema builder instance for a connection.
*
* @param string $name
* @return \Illuminate\Database\Schema\Builder
*/
public static function connection($name)
{
return static::$app['db']->connection($name)->getSchemaBuilder();
}
/**
* Get a schema builder instance for the default connection.
*
* @return \Illuminate\Database\Schema\Builder
*/
protected static function getFacadeAccessor()
{
return static::$app['db']->connection()->getSchemaBuilder();
}
}