vendor/illuminate/database/Schema/Grammars/SQLiteGrammar.php
(开头部分) 22KB这里只显示每个文件的开头 60 行。登录后可以解锁完整代码。
<?php
namespace Illuminate\Database\Schema\Grammars;
use RuntimeException;
use Illuminate\Support\Arr;
use Illuminate\Support\Fluent;
use Doctrine\DBAL\Schema\Index;
use Illuminate\Database\Connection;
use Illuminate\Database\Schema\Blueprint;
class SQLiteGrammar extends Grammar
{
/**
* The possible column modifiers.
*
* @var array
*/
protected $modifiers = ['Nullable', 'Default', 'Increment'];
/**
* The columns available as serials.
*
* @var array
*/
protected $serials = ['bigInteger', 'integer', 'mediumInteger', 'smallInteger', 'tinyInteger'];
/**
* Compile the query to determine if a table exists.
*
* @return string
*/
public function compileTableExists()
{
return "select * from sqlite_master where type = 'table' and name = ?";
}
/**
* Compile the query to determine the list of columns.
*
* @param string $table
* @return string
*/
public function compileColumnListing($table)
{
return 'pragma table_info('.$this->wrap(str_replace('.', '__', $table)).')';
}
/**
* Compile a create table command.
*
* @param \Illuminate\Database\Schema\Blueprint $blueprint
* @param \Illuminate\Support\Fluent $command
* @return string
*/
public function compileCreate(Blueprint $blueprint, Fluent $command)
{
return sprintf('%s table %s (%s%s%s)',
$blueprint->temporary ? 'create temporary' : 'create',
$this->wrapTable($blueprint),
后面还有 800 行代码,购买后查看完整代码
24 小时内免费解锁 3 个项目,之后 1 积分/个。 规则说明
AI 解读
登录后可用,每次 10 积分,解读结果公开显示在下面。
还没有人解读过这个文件。
