1 | <?php |
||
14 | class TableDumperCollection extends ArrayObject |
||
15 | { |
||
16 | /** |
||
17 | * {@inheritDoc} |
||
18 | */ |
||
19 | 15 | public function append($value) |
|
29 | |||
30 | /** |
||
31 | * {@inheritDoc} |
||
32 | */ |
||
33 | 66 | public function offsetSet($index, $newval) |
|
43 | |||
44 | |||
45 | /** |
||
46 | * @param Table|string Adds a table, either by name, or by Table instance, to the collection |
||
47 | * |
||
48 | * @return TableDumper Retruns a TableDumper of the table that was just added |
||
49 | */ |
||
50 | 51 | public function addTable($table): TableDumper |
|
69 | |||
70 | |||
71 | /** |
||
72 | * @param TableDumperCollection|array<TableDumper|Table|string> Adds a list of tables, either by passing TableDumperCollection, or an array containing either TableDumper objects, Table objects or table naes |
||
73 | * |
||
74 | * @return TableDumperCollection Returns a TableDumperCollection of the list of tables that was just added |
||
75 | */ |
||
76 | 27 | public function addListTables($listTables): TableDumperCollection |
|
104 | |||
105 | /** |
||
106 | * Writes all DROP statements to the dump stream |
||
107 | * |
||
108 | * @param resource $stream Stream to write the dump to |
||
109 | * |
||
110 | * @return void |
||
111 | */ |
||
112 | public function dumpDropStatements($stream): void |
||
120 | |||
121 | /** |
||
122 | * Writes all INSERT statements to the dump stream |
||
123 | * |
||
124 | * @param PDO $db PDO instance to use for DB queries |
||
125 | * @param resource $stream Stream to write the dump to |
||
126 | * |
||
127 | * @return void |
||
128 | */ |
||
129 | public function dumpInsertStatements(PDO $db, $stream): void |
||
137 | |||
138 | /** |
||
139 | * Writes all the SQL statements of this dumper to the dump stream |
||
140 | * |
||
141 | * @param PDO $db PDO instance to use for DB queries |
||
142 | * @param resource $stream Stream to write the dump to |
||
143 | * @param boolean $groupDrops Determines if DROP statements will be grouped |
||
144 | * @param boolean $groupInserts Determines if INSERT statements will be grouped |
||
145 | * |
||
146 | * @return void |
||
147 | */ |
||
148 | 21 | public function dump(PDO $db, $stream, bool $groupDrops = false, bool $groupInserts = false): void |
|
172 | |||
173 | |||
174 | 6 | public function __call(string $name, array $arguments) |
|
183 | } |