コード例 #1
0
ファイル: MigrationSchema.php プロジェクト: jivoo/jivoo
 /**
  * Construct migration schema.
  * @param MigratableDatabase The database to migrate.
  */
 public function __construct(MigratableDatabase $db)
 {
     $this->db = $db;
     $this->targetSchema = $db->getSchema();
     $db->refreshSchema();
     $current = $db->getSchema();
     foreach ($current->getTables() as $table) {
         $this->tables[] = $table;
         $this->schemas[$table] = $current->getSchema($table);
     }
     $db->setSchema($this);
 }