Total Complexity | 3 |
Total Lines | 52 |
Duplicated Lines | 0 % |
Changes | 1 | ||
Bugs | 0 | Features | 0 |
1 | <?php |
||
12 | abstract class AbstractTable implements ArrayAccess { |
||
13 | |||
14 | /** |
||
15 | * @var DB |
||
16 | */ |
||
17 | protected $db; |
||
18 | |||
19 | /** |
||
20 | * @param DB $db |
||
21 | */ |
||
22 | public function __construct (DB $db) { |
||
24 | } |
||
25 | |||
26 | /** |
||
27 | * Returns the SQL reference qualifier (i.e. the table name) |
||
28 | * |
||
29 | * @return string |
||
30 | */ |
||
31 | abstract public function __toString (); |
||
32 | |||
33 | /** |
||
34 | * @param string $name |
||
35 | * @return bool |
||
36 | */ |
||
37 | abstract public function offsetExists ($name): bool; |
||
38 | |||
39 | /** |
||
40 | * @param string $name |
||
41 | * @return Column |
||
42 | */ |
||
43 | abstract public function offsetGet ($name); |
||
44 | |||
45 | /** |
||
46 | * Throws. |
||
47 | * |
||
48 | * @param void $name |
||
49 | * @param void $value |
||
50 | * @throws Exception |
||
51 | */ |
||
52 | final public function offsetSet ($name, $value): void { |
||
54 | } |
||
55 | |||
56 | /** |
||
57 | * Throws. |
||
58 | * |
||
59 | * @param void $name |
||
60 | * @throws Exception |
||
61 | */ |
||
62 | final public function offsetUnset ($name): void { |
||
64 | } |
||
65 | } |