$referenceDefinition =
$field->
getReferenceDefinition();
if (!\
is_array($value)) { throw new ExpectedArrayException($path);
} foreach ($value as $languageId =>
$translation) { $clonedParams =
$parameters->
cloneForSubresource( $referenceDefinition,
$path . '/' .
$languageId );
$clonedParams->
setCurrentWriteLanguageId($languageId);
$this->writeExtractor->
extract($translation,
$clonedParams);
} // the validation is only required for new entities
if ($existence->
exists()) { return;
} $languageIds =
array_keys($value);
// the translation in the system language is always required for new entities,