|
|
|
@ -26,6 +26,13 @@ class AttributeSingleXmlStructure implements IXmlStructure {
|
|
|
|
* @inheritDoc
|
|
|
|
* @inheritDoc
|
|
|
|
*/
|
|
|
|
*/
|
|
|
|
public function parseXml (SimpleXMLElement $xmlNode): string {
|
|
|
|
public function parseXml (SimpleXMLElement $xmlNode): string {
|
|
|
|
return (string)$xmlNode[$this->attributeName];
|
|
|
|
if (($attributes = $xmlNode->attributes()) !== null) {
|
|
|
|
|
|
|
|
foreach ($attributes as $attributeName => $attributeValue) {
|
|
|
|
|
|
|
|
if (mb_strtolower($attributeName) === mb_strtolower($this->attributeName)) {
|
|
|
|
|
|
|
|
return (string)$attributeValue;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
return '';
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|