minor #39170 Improve return value for phpdoc of Normalizer (VincentLanglet)
This PR was merged into the 4.4 branch.
Discussion
----------
Improve return value for phpdoc of Normalizer
| Q | A
| ------------- | ---
| Branch? | 4.4
| Bug fix? | Phpdoc
| New feature? | no
| Deprecations? | no
| License | MIT
The inheritdoc return type is too large.
The return type type can be more precise for lot of Normalizer.
Commits
-------
f2713d6580
Improve return phpdoc for Normalizer
This commit is contained in:
commit
fb161ec0ee
@ -35,6 +35,8 @@ class ArrayDenormalizer implements ContextAwareDenormalizerInterface, Serializer
|
|||||||
* {@inheritdoc}
|
* {@inheritdoc}
|
||||||
*
|
*
|
||||||
* @throws NotNormalizableValueException
|
* @throws NotNormalizableValueException
|
||||||
|
*
|
||||||
|
* @return array
|
||||||
*/
|
*/
|
||||||
public function denormalize($data, $type, $format = null, array $context = [])
|
public function denormalize($data, $type, $format = null, array $context = [])
|
||||||
{
|
{
|
||||||
|
@ -40,6 +40,8 @@ class ConstraintViolationListNormalizer implements NormalizerInterface, Cacheabl
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
* {@inheritdoc}
|
* {@inheritdoc}
|
||||||
|
*
|
||||||
|
* @return array
|
||||||
*/
|
*/
|
||||||
public function normalize($object, $format = null, array $context = [])
|
public function normalize($object, $format = null, array $context = [])
|
||||||
{
|
{
|
||||||
|
@ -61,6 +61,8 @@ class DataUriNormalizer implements NormalizerInterface, DenormalizerInterface, C
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
* {@inheritdoc}
|
* {@inheritdoc}
|
||||||
|
*
|
||||||
|
* @return string
|
||||||
*/
|
*/
|
||||||
public function normalize($object, $format = null, array $context = [])
|
public function normalize($object, $format = null, array $context = [])
|
||||||
{
|
{
|
||||||
@ -102,6 +104,8 @@ class DataUriNormalizer implements NormalizerInterface, DenormalizerInterface, C
|
|||||||
*
|
*
|
||||||
* @throws InvalidArgumentException
|
* @throws InvalidArgumentException
|
||||||
* @throws NotNormalizableValueException
|
* @throws NotNormalizableValueException
|
||||||
|
*
|
||||||
|
* @return \SplFileInfo
|
||||||
*/
|
*/
|
||||||
public function denormalize($data, $type, $format = null, array $context = [])
|
public function denormalize($data, $type, $format = null, array $context = [])
|
||||||
{
|
{
|
||||||
|
@ -46,6 +46,8 @@ class DateIntervalNormalizer implements NormalizerInterface, DenormalizerInterfa
|
|||||||
* {@inheritdoc}
|
* {@inheritdoc}
|
||||||
*
|
*
|
||||||
* @throws InvalidArgumentException
|
* @throws InvalidArgumentException
|
||||||
|
*
|
||||||
|
* @return string
|
||||||
*/
|
*/
|
||||||
public function normalize($object, $format = null, array $context = [])
|
public function normalize($object, $format = null, array $context = [])
|
||||||
{
|
{
|
||||||
@ -77,6 +79,8 @@ class DateIntervalNormalizer implements NormalizerInterface, DenormalizerInterfa
|
|||||||
*
|
*
|
||||||
* @throws InvalidArgumentException
|
* @throws InvalidArgumentException
|
||||||
* @throws UnexpectedValueException
|
* @throws UnexpectedValueException
|
||||||
|
*
|
||||||
|
* @return \DateInterval
|
||||||
*/
|
*/
|
||||||
public function denormalize($data, $type, $format = null, array $context = [])
|
public function denormalize($data, $type, $format = null, array $context = [])
|
||||||
{
|
{
|
||||||
|
@ -57,6 +57,8 @@ class DateTimeNormalizer implements NormalizerInterface, DenormalizerInterface,
|
|||||||
* {@inheritdoc}
|
* {@inheritdoc}
|
||||||
*
|
*
|
||||||
* @throws InvalidArgumentException
|
* @throws InvalidArgumentException
|
||||||
|
*
|
||||||
|
* @return string
|
||||||
*/
|
*/
|
||||||
public function normalize($object, $format = null, array $context = [])
|
public function normalize($object, $format = null, array $context = [])
|
||||||
{
|
{
|
||||||
@ -87,6 +89,8 @@ class DateTimeNormalizer implements NormalizerInterface, DenormalizerInterface,
|
|||||||
* {@inheritdoc}
|
* {@inheritdoc}
|
||||||
*
|
*
|
||||||
* @throws NotNormalizableValueException
|
* @throws NotNormalizableValueException
|
||||||
|
*
|
||||||
|
* @return \DateTimeInterface
|
||||||
*/
|
*/
|
||||||
public function denormalize($data, $type, $format = null, array $context = [])
|
public function denormalize($data, $type, $format = null, array $context = [])
|
||||||
{
|
{
|
||||||
|
@ -25,6 +25,8 @@ class DateTimeZoneNormalizer implements NormalizerInterface, DenormalizerInterfa
|
|||||||
* {@inheritdoc}
|
* {@inheritdoc}
|
||||||
*
|
*
|
||||||
* @throws InvalidArgumentException
|
* @throws InvalidArgumentException
|
||||||
|
*
|
||||||
|
* @return string
|
||||||
*/
|
*/
|
||||||
public function normalize($object, $format = null, array $context = [])
|
public function normalize($object, $format = null, array $context = [])
|
||||||
{
|
{
|
||||||
@ -47,6 +49,8 @@ class DateTimeZoneNormalizer implements NormalizerInterface, DenormalizerInterfa
|
|||||||
* {@inheritdoc}
|
* {@inheritdoc}
|
||||||
*
|
*
|
||||||
* @throws NotNormalizableValueException
|
* @throws NotNormalizableValueException
|
||||||
|
*
|
||||||
|
* @return \DateTimeZone
|
||||||
*/
|
*/
|
||||||
public function denormalize($data, $type, $format = null, array $context = [])
|
public function denormalize($data, $type, $format = null, array $context = [])
|
||||||
{
|
{
|
||||||
|
@ -37,6 +37,8 @@ class ProblemNormalizer implements NormalizerInterface, CacheableSupportsMethodI
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
* {@inheritdoc}
|
* {@inheritdoc}
|
||||||
|
*
|
||||||
|
* @return array
|
||||||
*/
|
*/
|
||||||
public function normalize($exception, $format = null, array $context = [])
|
public function normalize($exception, $format = null, array $context = [])
|
||||||
{
|
{
|
||||||
|
Reference in New Issue
Block a user