@@ 428-445 (lines=18) @@ | ||
425 | private function getDatabaseStructure() |
|
426 | { |
|
427 | // Listing all tables from database |
|
428 | if (empty($this->dumpSettings['include-tables'])) { |
|
429 | // include all tables for now, blacklisting happens later |
|
430 | foreach ($this->dbHandler->query($this->typeAdapter->show_tables($this->dbName)) as $row) { |
|
431 | array_push($this->tables, current($row)); |
|
432 | } |
|
433 | } else { |
|
434 | // include only the tables mentioned in include-tables |
|
435 | foreach ($this->dbHandler->query($this->typeAdapter->show_tables($this->dbName)) as $row) { |
|
436 | if (in_array(current($row), $this->dumpSettings['include-tables'], true)) { |
|
437 | array_push($this->tables, current($row)); |
|
438 | $elem = array_search( |
|
439 | current($row), |
|
440 | $this->dumpSettings['include-tables'] |
|
441 | ); |
|
442 | unset($this->dumpSettings['include-tables'][$elem]); |
|
443 | } |
|
444 | } |
|
445 | } |
|
446 | ||
447 | // Listing all views from database |
|
448 | if (empty($this->dumpSettings['include-views'])) { |
|
@@ 448-465 (lines=18) @@ | ||
445 | } |
|
446 | ||
447 | // Listing all views from database |
|
448 | if (empty($this->dumpSettings['include-views'])) { |
|
449 | // include all views for now, blacklisting happens later |
|
450 | foreach ($this->dbHandler->query($this->typeAdapter->show_views($this->dbName)) as $row) { |
|
451 | array_push($this->views, current($row)); |
|
452 | } |
|
453 | } else { |
|
454 | // include only the tables mentioned in include-tables |
|
455 | foreach ($this->dbHandler->query($this->typeAdapter->show_views($this->dbName)) as $row) { |
|
456 | if (in_array(current($row), $this->dumpSettings['include-views'], true)) { |
|
457 | array_push($this->views, current($row)); |
|
458 | $elem = array_search( |
|
459 | current($row), |
|
460 | $this->dumpSettings['include-views'] |
|
461 | ); |
|
462 | unset($this->dumpSettings['include-views'][$elem]); |
|
463 | } |
|
464 | } |
|
465 | } |
|
466 | ||
467 | // Listing all triggers from database |
|
468 | if (false === $this->dumpSettings['skip-triggers']) { |