1 | <?php |
||
8 | class ElggXMLElement { |
||
9 | /** |
||
10 | * @var SimpleXMLElement |
||
11 | */ |
||
12 | private $_element; |
||
13 | |||
14 | /** |
||
15 | * Creates an \ElggXMLParser from a string or existing SimpleXMLElement |
||
16 | * |
||
17 | * @param string|SimpleXMLElement $xml The XML to parse |
||
18 | */ |
||
19 | public function __construct($xml) { |
||
31 | |||
32 | /** |
||
33 | * @return string The name of the element |
||
34 | */ |
||
35 | public function getName() { |
||
38 | |||
39 | /** |
||
40 | * @return string[] The attributes |
||
41 | */ |
||
42 | public function getAttributes() { |
||
63 | |||
64 | /** |
||
65 | * @return string CData |
||
66 | */ |
||
67 | public function getContent() { |
||
70 | |||
71 | /** |
||
72 | * @return \ElggXMLElement[] Child elements |
||
73 | */ |
||
74 | public function getChildren() { |
||
83 | |||
84 | /** |
||
85 | * Override -> |
||
86 | * |
||
87 | * @param string $name Property name |
||
88 | * @return mixed |
||
89 | */ |
||
90 | public function __get($name) { |
||
107 | |||
108 | /** |
||
109 | * Override isset |
||
110 | * |
||
111 | * @param string $name Property name |
||
112 | * @return boolean |
||
113 | */ |
||
114 | public function __isset($name) { |
||
131 | } |
||
132 |
The break statement is not necessary if it is preceded for example by a return statement:
If you would like to keep this construct to be consistent with other case statements, you can safely mark this issue as a false-positive.