Symfony\Component\Serializer\Serializer::deserialize PHP Method

deserialize() final public method

final public deserialize ( $data, $type, $format )
    public final function deserialize($data, $type, $format)
    {
        if (!$this->supportsDeserialization($format)) {
            throw new UnexpectedValueException('Deserialization for the format '.$format.' is not supported');
        }

        $data = $this->decode($data, $format);

        return $this->denormalize($data, $type, $format);
    }

Usage Example

Esempio n. 1
0
 public function deserialize($data, $type, $format, array $context = array())
 {
     if (!$type) {
         $temp = $this->serializer->decode($data, $format, $context);
         $type = isset($this->map[$temp['type']]) ? $this->map[$temp['type']] : 'Bangpound\\oEmbed\\Response\\Response';
     }
     return $this->serializer->deserialize($data, $type, $format, $context);
 }
All Usage Examples Of Symfony\Component\Serializer\Serializer::deserialize