Total Complexity | 6 |
Total Lines | 50 |
Duplicated Lines | 0 % |
Changes | 1 | ||
Bugs | 0 | Features | 0 |
1 | <?php |
||
15 | class OfferPicture extends BaseObject |
||
16 | { |
||
17 | public $url; |
||
18 | public $customTags = []; |
||
19 | |||
20 | /** |
||
21 | * @param XMLWriter $writer |
||
22 | */ |
||
23 | public function write($writer): void |
||
24 | { |
||
25 | $writer->startElement('picture'); |
||
26 | |||
27 | if (null !== $this->url) { |
||
28 | $writer->text($this->url); |
||
29 | } |
||
30 | |||
31 | $this->writeCustomTags($writer); |
||
32 | |||
33 | $writer->endElement(); |
||
34 | } |
||
35 | |||
36 | /** |
||
37 | * @param XMLWriter $writer |
||
38 | */ |
||
39 | public function writeCustomTags($writer): void |
||
43 | } |
||
44 | } |
||
45 | |||
46 | /** |
||
47 | * @return array |
||
48 | */ |
||
49 | public function rules(): array |
||
54 | ]; |
||
55 | } |
||
56 | |||
57 | /** |
||
58 | * @param $url |
||
59 | * @return BaseObject |
||
60 | */ |
||
61 | public function setUrl($url): BaseObject |
||
67 |