1
|
<?php
|
2
|
|
3
|
namespace Illuminate\Database;
|
4
|
|
5
|
use Illuminate\Database\Query\Processors\SQLiteProcessor;
|
6
|
use Doctrine\DBAL\Driver\PDOSqlite\Driver as DoctrineDriver;
|
7
|
use Illuminate\Database\Query\Grammars\SQLiteGrammar as QueryGrammar;
|
8
|
use Illuminate\Database\Schema\Grammars\SQLiteGrammar as SchemaGrammar;
|
9
|
|
10
|
class SQLiteConnection extends Connection
|
11
|
{
|
12
|
/**
|
13
|
* Get the default query grammar instance.
|
14
|
*
|
15
|
* @return \Illuminate\Database\Query\Grammars\SQLiteGrammar
|
16
|
*/
|
17
|
protected function getDefaultQueryGrammar()
|
18
|
{
|
19
|
return $this->withTablePrefix(new QueryGrammar);
|
20
|
}
|
21
|
|
22
|
/**
|
23
|
* Get the default schema grammar instance.
|
24
|
*
|
25
|
* @return \Illuminate\Database\Schema\Grammars\SQLiteGrammar
|
26
|
*/
|
27
|
protected function getDefaultSchemaGrammar()
|
28
|
{
|
29
|
return $this->withTablePrefix(new SchemaGrammar);
|
30
|
}
|
31
|
|
32
|
/**
|
33
|
* Get the default post processor instance.
|
34
|
*
|
35
|
* @return \Illuminate\Database\Query\Processors\SQLiteProcessor
|
36
|
*/
|
37
|
protected function getDefaultPostProcessor()
|
38
|
{
|
39
|
return new SQLiteProcessor;
|
40
|
}
|
41
|
|
42
|
/**
|
43
|
* Get the Doctrine DBAL driver.
|
44
|
*
|
45
|
* @return \Doctrine\DBAL\Driver\PDOSqlite\Driver
|
46
|
*/
|
47
|
protected function getDoctrineDriver()
|
48
|
{
|
49
|
return new DoctrineDriver;
|
50
|
}
|
51
|
}
|