Service/RequestSerializer.php
public function deserializeRequest(Request $request)
    {
        $format = $this->checkAcceptHeader($request);

        try {
            return $this->serializer->deserialize($request->getContent(), 'array', $format);
        } catch (\Exception $e) {
            throw new \RuntimeException(
                'Could not deserialize content from the request.'
            );
        }
    }
public function deserializeRequest(Request $request)
    {
        $format = $this->checkAcceptHeader($request);

        try {
            return $this->serializer->deserialize($request->getContent(), 'array', $format);
        } catch (\Exception $e) {
            throw new \RuntimeException(
                'Could not deserialize content from the request.'
            );
        }
    }
public function deserializeRequest ( Request $ request ) { $ format = $ this -> checkAcceptHeader ( $ request ) ; try { return $ this -> serializer -> deserialize ( $ request -> getContent ( ) , 'array' , $ format ) ; } catch ( \ Exception $ e ) { throw new \ RuntimeException ( 'Could not deserialize content from the request.' ) ; } }
@param Request $request

@return array
@param Request $request