| Total Complexity | 9 |
| Total Lines | 67 |
| Duplicated Lines | 0 % |
| Changes | 1 | ||
| Bugs | 0 | Features | 0 |
| 1 | <?php |
||
| 17 | class Category extends BaseObject |
||
| 18 | { |
||
| 19 | public $name; |
||
| 20 | public $id; |
||
| 21 | public $parentId; |
||
| 22 | public $customTags = []; |
||
| 23 | |||
| 24 | /** |
||
| 25 | * @param XMLWriter $writer |
||
| 26 | */ |
||
| 27 | public function write($writer): void |
||
| 44 | } |
||
| 45 | |||
| 46 | /** |
||
| 47 | * @param XMLWriter $writer |
||
| 48 | */ |
||
| 49 | public function writeCustomTags($writer): void |
||
| 50 | { |
||
| 51 | foreach ($this->customTags as $tag) { |
||
| 52 | $tag->write($writer); |
||
| 53 | } |
||
| 54 | } |
||
| 55 | |||
| 56 | /** |
||
| 57 | * @param mixed $name |
||
| 58 | * @return Category |
||
| 59 | */ |
||
| 60 | public function setName($name): Category |
||
| 61 | { |
||
| 62 | $this->name = $name; |
||
| 63 | return $this; |
||
| 64 | } |
||
| 65 | |||
| 66 | /** |
||
| 67 | * @param mixed $id |
||
| 68 | * @return Category |
||
| 69 | */ |
||
| 70 | public function setId($id): Category |
||
| 74 | } |
||
| 75 | |||
| 76 | /** |
||
| 77 | * @param mixed $parentId |
||
| 78 | * @return Category |
||
| 79 | */ |
||
| 80 | public function setParentId($parentId): Category |
||
| 84 | } |
||
| 85 | } |
||
| 86 |