CodeExplorer filterHydrateForeignKeyData example
if ($constraint->
getForeignTableName() !==
$foreignTable) { return false;
} return \
count(array_diff($constraint->
getForeignColumns(),
$foreignFieldNames)) === 0;
} private function hydrateForeignKeyData(array
$data, string
$keyColumnName): array
{ $hydratedData =
$this->
mapHydrateForeignKeyData($data);
return $this->
filterHydrateForeignKeyData($hydratedData,
$keyColumnName);
} private function mapHydrateForeignKeyData(array
$data): array
{ $hydratedData =
[];
foreach ($data as $entry) { $constraintName =
$entry['CONSTRAINT_NAME'
];
if (!
isset($hydratedData[$constraintName])) { $hydratedData[$constraintName] =
[