JFIFxxC      C  " }!1AQa"q2#BR$3br %&'()*456789:CDEFGHIJSTUVWXYZcdefghijstuvwxyz w!1AQaq"2B #3RbrnormalizeTable($oldTable), $this->normalizeTable($newTable), ); } private function normalizeTable(Table $table): Table { $charset = $table->getOption('charset'); $collation = $table->getOption('collation'); if ($charset === null && $collation !== null) { $charset = $this->collationMetadataProvider->getCollationCharset($collation); } elseif ($charset !== null && $collation === null) { $collation = $this->charsetMetadataProvider->getDefaultCharsetCollation($charset); } elseif ($charset === null && $collation === null) { $charset = $this->defaultTableOptions->getCharset(); $collation = $this->defaultTableOptions->getCollation(); } $tableOptions = [ 'charset' => $charset, 'collation' => $collation, ]; $table = clone $table; foreach ($table->getColumns() as $column) { $originalOptions = $column->getPlatformOptions(); $normalizedOptions = $this->normalizeOptions($originalOptions); $overrideOptions = array_diff_assoc($normalizedOptions, $tableOptions); if ($overrideOptions === $originalOptions) { continue; } $column->setPlatformOptions($overrideOptions); } return $table; } /** * @param array $options * * @return array */ private function normalizeOptions(array $options): array { if (isset($options['charset']) && ! isset($options['collation'])) { $options['collation'] = $this->charsetMetadataProvider->getDefaultCharsetCollation($options['charset']); } elseif (isset($options['collation']) && ! isset($options['charset'])) { $options['charset'] = $this->collationMetadataProvider->getCollationCharset($options['collation']); } return $options; } }