public function compare(Table $oldTable, Table $newTable)
    {
        $createdColumns = $this->getCreatedColumns($oldTable, $newTable);
        $alteredColumns = $this->getAlteredColumns($oldTable, $newTable);
        $droppedColumns = $this->getDroppedColumns($oldTable, $newTable);

        $this->detectRenamedColumns($createdColumns, $droppedColumns, $alteredColumns);

        return new TableDiff(
            $oldTable,
            $newTable,
            $createdColumns,
            $alteredColumns,
            $droppedColumns,
            $this->getCreatedPrimaryKey($oldTable, $newTable),
            $this->getDroppedPrimaryKey($oldTable, $newTable),
            $this->getCreatedForeignKeys($oldTable, $newTable),
            $this->getDroppedForeignKeys($oldTable, $newTable),
            $this->getCreatedIndexes($oldTable, $newTable),
            $this->getDroppedIndexes($oldTable, $newTable),
            $this->getCreatedChecks($oldTable, $newTable),
            $this->getDroppedChecks($oldTable, $newTable)
        );
    }
public function compare(Table $oldTable, Table $newTable)
    {
        $createdColumns = $this->getCreatedColumns($oldTable, $newTable);
        $alteredColumns = $this->getAlteredColumns($oldTable, $newTable);
        $droppedColumns = $this->getDroppedColumns($oldTable, $newTable);

        $this->detectRenamedColumns($createdColumns, $droppedColumns, $alteredColumns);

        return new TableDiff(
            $oldTable,
            $newTable,
            $createdColumns,
            $alteredColumns,
            $droppedColumns,
            $this->getCreatedPrimaryKey($oldTable, $newTable),
            $this->getDroppedPrimaryKey($oldTable, $newTable),
            $this->getCreatedForeignKeys($oldTable, $newTable),
            $this->getDroppedForeignKeys($oldTable, $newTable),
            $this->getCreatedIndexes($oldTable, $newTable),
            $this->getDroppedIndexes($oldTable, $newTable),
            $this->getCreatedChecks($oldTable, $newTable),
            $this->getDroppedChecks($oldTable, $newTable)
        );
    }
public function compare ( Table $ oldTable , Table $ newTable ) { $ createdColumns = $ this -> getCreatedColumns ( $ oldTable , $ newTable ) ; $ alteredColumns = $ this -> getAlteredColumns ( $ oldTable , $ newTable ) ; $ droppedColumns = $ this -> getDroppedColumns ( $ oldTable , $ newTable ) ; $ this -> detectRenamedColumns ( $ createdColumns , $ droppedColumns , $ alteredColumns ) ; return new TableDiff ( $ oldTable , $ newTable , $ createdColumns , $ alteredColumns , $ droppedColumns , $ this -> getCreatedPrimaryKey ( $ oldTable , $ newTable ) , $ this -> getDroppedPrimaryKey ( $ oldTable , $ newTable ) , $ this -> getCreatedForeignKeys ( $ oldTable , $ newTable ) , $ this -> getDroppedForeignKeys ( $ oldTable , $ newTable ) , $ this -> getCreatedIndexes ( $ oldTable , $ newTable ) , $ this -> getDroppedIndexes ( $ oldTable , $ newTable ) , $ this -> getCreatedChecks ( $ oldTable , $ newTable ) , $ this -> getDroppedChecks ( $ oldTable , $ newTable ) ) ; }
Compares two tables.

@param \Fridge\DBAL\Schema\Table $oldTable The old table.
@param \Fridge\DBAL\Schema\Table $newTable The new table.

@return \Fridge\DBAL\Schema\Diff\TableDiff The difference between the two tables.
Compares two tables .