1<?php
2
3namespace JMS\Serializer\Tests\Fixtures;
4
5use JMS\Serializer\Annotation\Type;
6use JMS\Serializer\Annotation\XmlKeyValuePairs;
7
8class ObjectWithXmlKeyValuePairsWithObjectType
9{
10    /**
11     * @var array
12     * @Type("array<string,JMS\Serializer\Tests\Fixtures\ObjectWithXmlKeyValuePairsWithType>")
13     * @XmlKeyValuePairs
14     */
15    private $list;
16
17    public function __construct(array $list)
18    {
19        $this->list = $list;
20    }
21
22    public static function create1()
23    {
24        return new self(
25            [
26                'key_first' => ObjectWithXmlKeyValuePairsWithType::create1(),
27                'key_second' => ObjectWithXmlKeyValuePairsWithType::create2(),
28            ]
29        );
30    }
31}
32