comparison vendor/symfony/serializer/Normalizer/DenormalizerInterface.php @ 12:7a779792577d

Update Drupal core to v8.4.5 (via Composer)
author Chris Cannam
date Fri, 23 Feb 2018 15:52:07 +0000
parents 4c8ae668cc8c
children 1fec387a4317
comparison
equal deleted inserted replaced
11:bfffd8d7479a 12:7a779792577d
8 * For the full copyright and license information, please view the LICENSE 8 * For the full copyright and license information, please view the LICENSE
9 * file that was distributed with this source code. 9 * file that was distributed with this source code.
10 */ 10 */
11 11
12 namespace Symfony\Component\Serializer\Normalizer; 12 namespace Symfony\Component\Serializer\Normalizer;
13
14 use Symfony\Component\Serializer\Exception\BadMethodCallException;
15 use Symfony\Component\Serializer\Exception\ExtraAttributesException;
16 use Symfony\Component\Serializer\Exception\InvalidArgumentException;
17 use Symfony\Component\Serializer\Exception\LogicException;
18 use Symfony\Component\Serializer\Exception\RuntimeException;
19 use Symfony\Component\Serializer\Exception\UnexpectedValueException;
13 20
14 /** 21 /**
15 * Defines the interface of denormalizers. 22 * Defines the interface of denormalizers.
16 * 23 *
17 * @author Jordi Boggiano <j.boggiano@seld.be> 24 * @author Jordi Boggiano <j.boggiano@seld.be>
25 * @param string $class the expected class to instantiate 32 * @param string $class the expected class to instantiate
26 * @param string $format format the given data was extracted from 33 * @param string $format format the given data was extracted from
27 * @param array $context options available to the denormalizer 34 * @param array $context options available to the denormalizer
28 * 35 *
29 * @return object 36 * @return object
37 *
38 * @throws BadMethodCallException Occurs when the normalizer is not called in an expected context
39 * @throws InvalidArgumentException Occurs when the arguments are not coherent or not supported
40 * @throws UnexpectedValueException Occurs when the item cannot be hydrated with the given data
41 * @throws ExtraAttributesException Occurs when the item doesn't have attribute to receive given data
42 * @throws LogicException Occurs when the normalizer is not supposed to denormalize
43 * @throws RuntimeException Occurs if the class cannot be instantiated
30 */ 44 */
31 public function denormalize($data, $class, $format = null, array $context = array()); 45 public function denormalize($data, $class, $format = null, array $context = array());
32 46
33 /** 47 /**
34 * Checks whether the given class is supported for denormalization by this normalizer. 48 * Checks whether the given class is supported for denormalization by this normalizer.