function EntityDenormalizerBase::prepareInput

Same name in other branches
  1. 9 core/modules/jsonapi/src/Normalizer/EntityDenormalizerBase.php \Drupal\jsonapi\Normalizer\EntityDenormalizerBase::prepareInput()
  2. 8.9.x core/modules/jsonapi/src/Normalizer/EntityDenormalizerBase.php \Drupal\jsonapi\Normalizer\EntityDenormalizerBase::prepareInput()
  3. 10 core/modules/jsonapi/src/Normalizer/EntityDenormalizerBase.php \Drupal\jsonapi\Normalizer\EntityDenormalizerBase::prepareInput()

Prepares the input data to create the entity.

Parameters

array $data: The input data to modify.

\Drupal\jsonapi\ResourceType\ResourceType $resource_type: Contains the info about the resource type.

string $format: Format the given data was extracted from.

array $context: Options available to the denormalizer.

Return value

array The modified input data.

1 call to EntityDenormalizerBase::prepareInput()
EntityDenormalizerBase::denormalize in core/modules/jsonapi/src/Normalizer/EntityDenormalizerBase.php
2 methods override EntityDenormalizerBase::prepareInput()
ConfigEntityDenormalizer::prepareInput in core/modules/jsonapi/src/Normalizer/ConfigEntityDenormalizer.php
ContentEntityDenormalizer::prepareInput in core/modules/jsonapi/src/Normalizer/ContentEntityDenormalizer.php
Prepares the input data to create the entity.

File

core/modules/jsonapi/src/Normalizer/EntityDenormalizerBase.php, line 117

Class

EntityDenormalizerBase
Converts the Drupal entity object to a JSON:API array structure.

Namespace

Drupal\jsonapi\Normalizer

Code

protected abstract function prepareInput(array $data, ResourceType $resource_type, $format, array $context);

Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.