Code Coverage |
||||||||||
Lines |
Functions and Methods |
Classes and Traits |
||||||||
| Total | n/a |
0 / 0 |
n/a |
0 / 0 |
CRAP | n/a |
0 / 0 |
|||
| 1 | <?php |
| 2 | |
| 3 | /** |
| 4 | * This program is free software; you can redistribute it and/or |
| 5 | * modify it under the terms of the GNU General Public License |
| 6 | * as published by the Free Software Foundation; under version 2 |
| 7 | * of the License (non-upgradable). |
| 8 | * |
| 9 | * This program is distributed in the hope that it will be useful, |
| 10 | * but WITHOUT ANY WARRANTY; without even the implied warranty of |
| 11 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
| 12 | * GNU General Public License for more details. |
| 13 | * |
| 14 | * You should have received a copy of the GNU General Public License |
| 15 | * along with this program; if not, write to the Free Software |
| 16 | * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. |
| 17 | * |
| 18 | * Copyright (c) 2013 (original work) Open Assessment Technologies SA (under the project TAO-PRODUCT); |
| 19 | * |
| 20 | * @author "Lionel Lecaque, <lionel@taotesting.com>" |
| 21 | * @license GPLv2 |
| 22 | * @package generis |
| 23 | * |
| 24 | */ |
| 25 | interface common_persistence_sql_Driver extends common_persistence_Driver |
| 26 | { |
| 27 | public function query($statement, $params, array $types = []); |
| 28 | |
| 29 | public function exec($statement, $params, array $types = []); |
| 30 | |
| 31 | /** |
| 32 | * Insert a single row into the database. |
| 33 | * |
| 34 | * column names and values will be encoded |
| 35 | * |
| 36 | * @param string $tableName name of the table |
| 37 | * @param array $data An associative array containing column-value pairs. |
| 38 | * @param array $types |
| 39 | * @return integer The number of affected rows. |
| 40 | */ |
| 41 | public function insert($tableName, array $data, array $types = []); |
| 42 | |
| 43 | public function insertMultiple($tableName, array $data); |
| 44 | |
| 45 | /** |
| 46 | * @param string $tableName |
| 47 | * @param array $data |
| 48 | * @return bool |
| 49 | * @throws Exception |
| 50 | */ |
| 51 | public function updateMultiple($tableName, array $data); |
| 52 | |
| 53 | public function getSchemaManager(); |
| 54 | |
| 55 | /** |
| 56 | * @return common_persistence_sql_Platform |
| 57 | */ |
| 58 | public function getPlatForm(); |
| 59 | |
| 60 | public function lastInsertId($name = null); |
| 61 | |
| 62 | public function quote($parameter, $parameter_type = PDO::PARAM_STR); |
| 63 | |
| 64 | /** |
| 65 | * @return \Doctrine\DBAL\Connection |
| 66 | */ |
| 67 | public function getDbalConnection(); |
| 68 | } |