if ($propertyName === 'id'
) { continue;
} if (!
$fields->
isAllowed($definition->
getEntityName(),
$propertyName)) { continue;
} /** @var ApiAware|null $flag */
$flag =
$field->
getFlag(ApiAware::
class);
if ($flag === null || !
$flag->
isBaseUrlAllowed($result->
getBaseUrl())) { continue;
} if ($field instanceof AssociationField
) { $isSingle =
$field instanceof ManyToOneAssociationField ||
$field instanceof OneToOneAssociationField;
$reference =
$field->
getReferenceDefinition();
if ($field instanceof ManyToManyAssociationField
) { $reference =
$field->
getToManyReferenceDefinition();
}