private function getTableStructure($tableName)
    {
        if (!$this->dumpSettings['no-create-info']) {
            $ret = '';
            if (!$this->dumpSettings['skip-comments']) {
                $ret = "--".PHP_EOL.
                    "-- Table structure for table `$tableName`".PHP_EOL.
                    "--".PHP_EOL.PHP_EOL;
            }
            $stmt = $this->typeAdapter->show_create_table($tableName);
            foreach ($this->dbHandler->query($stmt) as $r) {
                $this->compressManager->write($ret);
                if ($this->dumpSettings['add-drop-table']) {
                    $this->compressManager->write(
                        $this->typeAdapter->drop_table($tableName)
                    );
                }
                $this->compressManager->write(
                    $this->typeAdapter->create_table($r)
                );
                break;
            }
        }
        $this->tableColumnTypes[$tableName] = $this->getTableColumnTypes($tableName);
        return;
    }
private function getTableStructure($tableName)
    {
        if (!$this->dumpSettings['no-create-info']) {
            $ret = '';
            if (!$this->dumpSettings['skip-comments']) {
                $ret = "--".PHP_EOL.
                    "-- Table structure for table `$tableName`".PHP_EOL.
                    "--".PHP_EOL.PHP_EOL;
            }
            $stmt = $this->typeAdapter->show_create_table($tableName);
            foreach ($this->dbHandler->query($stmt) as $r) {
                $this->compressManager->write($ret);
                if ($this->dumpSettings['add-drop-table']) {
                    $this->compressManager->write(
                        $this->typeAdapter->drop_table($tableName)
                    );
                }
                $this->compressManager->write(
                    $this->typeAdapter->create_table($r)
                );
                break;
            }
        }
        $this->tableColumnTypes[$tableName] = $this->getTableColumnTypes($tableName);
        return;
    }
private function getTableStructure ( $ tableName ) { if ( ! $ this -> dumpSettings [ 'no-create-info' ] ) { $ ret = '' ; if ( ! $ this -> dumpSettings [ 'skip-comments' ] ) { $ ret = "--" . PHP_EOL . "-- Table structure for table `$tableName`" . PHP_EOL . "--" . PHP_EOL . PHP_EOL ; } $ stmt = $ this -> typeAdapter -> show_create_table ( $ tableName ) ; foreach ( $ this -> dbHandler -> query ( $ stmt ) as $ r ) { $ this -> compressManager -> write ( $ ret ) ; if ( $ this -> dumpSettings [ 'add-drop-table' ] ) { $ this -> compressManager -> write ( $ this -> typeAdapter -> drop_table ( $ tableName ) ) ; } $ this -> compressManager -> write ( $ this -> typeAdapter -> create_table ( $ r ) ) ; break ; } } $ this -> tableColumnTypes [ $ tableName ] = $ this -> getTableColumnTypes ( $ tableName ) ; return ; }
Table structure extractor

@todo move specific mysql code to typeAdapter
@param string $tableName  Name of table to export
@return null
Table structure extractor