class DataDefinitionUndefinedNormalizer in JSON:API Schema 8
Data definition normalizer.
Hierarchy
- class \Drupal\serialization\Normalizer\NormalizerBase implements \Symfony\Component\Serializer\SerializerAwareInterface, CacheableNormalizerInterface uses \Symfony\Component\Serializer\SerializerAwareTrait
- class \Drupal\jsonapi_schema\Normalizer\DataDefinitionNormalizer
- class \Drupal\jsonapi_schema\Normalizer\DataDefinitionUndefinedNormalizer
- class \Drupal\jsonapi_schema\Normalizer\DataDefinitionNormalizer
Expanded class hierarchy of DataDefinitionUndefinedNormalizer
1 string reference to 'DataDefinitionUndefinedNormalizer'
1 service uses DataDefinitionUndefinedNormalizer
File
- src/
Normalizer/ DataDefinitionUndefinedNormalizer.php, line 10
Namespace
Drupal\jsonapi_schema\NormalizerView source
class DataDefinitionUndefinedNormalizer extends DataDefinitionNormalizer {
/**
* {@inheritdoc}
*/
protected $supportedDataTypes = [
'undefined',
];
/**
* {@inheritdoc}
*/
protected function extractPropertyData(DataDefinitionInterface $property, array $context = []) {
return isset($context['name']) ? (object) [
'title' => $context['name'],
] : (object) [];
}
}