1 | <?php |
||
14 | class CodeIgniterDriver implements DriverInterface |
||
15 | { |
||
16 | /** |
||
17 | * @var \Rougin\Describe\Driver\DriverInterface|null |
||
18 | */ |
||
19 | protected $driver = null; |
||
20 | |||
21 | /** |
||
22 | * Gets the specified driver from the specified database connection. |
||
23 | * |
||
24 | * @param array $database |
||
25 | */ |
||
26 | 24 | public function __construct(array $database) |
|
35 | |||
36 | /** |
||
37 | * Returns a listing of columns from the specified table. |
||
38 | * |
||
39 | * @param string $tableName |
||
40 | * @return array |
||
41 | * @throws \Rougin\Describe\Exceptions\TableNameNotFoundException |
||
42 | */ |
||
43 | 15 | public function getColumns($tableName) |
|
47 | |||
48 | /** |
||
49 | * Returns a listing of columns from the specified table. |
||
50 | * NOTE: To be removed in v2.0.0. |
||
51 | * |
||
52 | * @return array |
||
53 | */ |
||
54 | 15 | public function getTable($tableName) |
|
58 | |||
59 | /** |
||
60 | * Returns a listing of tables from the specified database. |
||
61 | * |
||
62 | * @return array |
||
63 | */ |
||
64 | 6 | public function getTableNames() |
|
68 | |||
69 | /** |
||
70 | * Shows the list of tables. |
||
71 | * NOTE: To be removed in v2.0.0. |
||
72 | * |
||
73 | * @return array |
||
74 | */ |
||
75 | 6 | public function showTables() |
|
79 | |||
80 | /** |
||
81 | * Returns the driver to be used. |
||
82 | * |
||
83 | * @param array $database |
||
84 | * @return \Rougin\Describe\Driver\DriverInterface|null |
||
85 | * @throws \Rougin\Describe\Exceptions\DatabaseDriverNotFoundException |
||
86 | */ |
||
87 | 24 | protected function getDriver(array $database) |
|
107 | } |
||
108 |