-
Notifications
You must be signed in to change notification settings - Fork 3.4k
/
Driver.php
42 lines (35 loc) · 882 Bytes
/
Driver.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
37
38
39
40
41
42
<?php
namespace Cake\Model\Datasource\Database;
/**
* Represents a database diver containing all specificities for
* a database engine including its SQL dialect
*
**/
abstract class Driver {
/**
* Establishes a conenction to the databse server
*
* @param array $config configuretion to be used for creating connection
* @return boolean true con success
**/
public abstract function connect(array $config);
/**
* Disconnects from database server
*
* @return void
**/
public abstract function disconnect();
/**
* Returns wheter php is able to use this driver for connecting to database
*
* @return boolean true if it is valid to use this driver
**/
public abstract function enabled();
/**
* Prepares a sql statement to be executed
*
* @param string $sql
* @return Cake\Model\Datasource\Database\Statement
**/
public abstract function prepare($sql);
}