1 | <?php |
||
9 | class JMSSerializer extends AbstractSerializer implements SerializerInterface |
||
10 | { |
||
11 | /** |
||
12 | * @var Serializer |
||
13 | */ |
||
14 | private $serializer; |
||
15 | |||
16 | /** |
||
17 | * @var SerializationContext |
||
18 | */ |
||
19 | private $context; |
||
20 | |||
21 | /** |
||
22 | * @param Serializer $serializer |
||
23 | * @param SerializationContext|null $context |
||
24 | */ |
||
25 | 4 | public function __construct(Serializer $serializer, SerializationContext $context = null) |
|
30 | |||
31 | /** |
||
32 | * @param $data |
||
33 | * @param $format |
||
34 | * @return mixed|string |
||
35 | */ |
||
36 | 2 | public function serialize($data, $format) |
|
40 | |||
41 | /** |
||
42 | * @return array |
||
43 | */ |
||
44 | 2 | public function getSupportedFormats() |
|
48 | |||
49 | /** |
||
50 | * @return string |
||
51 | */ |
||
52 | 1 | public function getDefaultFormat() |
|
56 | } |
||
57 |