, ', &, and " for RFC4627-compliant JSON, which may also be // embedded into HTML. // @see \Symfony\Component\HttpFoundation\JsonResponse $json_encoding_options = JSON_HEX_TAG | JSON_HEX_APOS | JSON_HEX_AMP | JSON_HEX_QUOT; $this->encodingImpl = $encodingImpl ?: new JsonEncode($json_encoding_options); $this->decodingImpl = $decodingImpl ?: new JsonDecode(TRUE); } /** * {@inheritdoc} */ public function supportsEncoding($format) { return in_array($format, static::$format); } /** * {@inheritdoc} */ public function supportsDecoding($format) { return in_array($format, static::$format); } }