public function ImageEntityNormalizer::normalize in Consumer Image Styles 8
Same name and namespace in other branches
- 8.2 src/Normalizer/ImageEntityNormalizer.php \Drupal\consumer_image_styles\Normalizer\ImageEntityNormalizer::normalize()
Overrides EntityNormalizer::normalize
File
- src/
Normalizer/ ImageEntityNormalizer.php, line 103
Class
Namespace
Drupal\consumer_image_styles\NormalizerCode
public function normalize($entity, $format = NULL, array $context = []) {
$file_entity_values = parent::normalize($entity, $format, $context);
$variants = $this
->buildVariantValues($entity, $context);
return new ImageNormalizerValue($variants, $file_entity_values);
}