Hi all,
although I'm sure this question came up already I wasn't able to find a solution for my issue.
I have this example XML structure:
<outer>
<req4711response>
<return>{D4564-4564-456-4564456}</return>
</req4711response>
</outer>
I want to unmarshal the ID value contained in the <return> XML tags. However this XML structure is dynamic, the embedding XML tag (in this case <req4711response>) changes with every request.
How can I unmarshal the return value universally?
Also I've read this paragraph in the package documentation:
* If the XML element contains a sub-element whose name matches
a struct field's XMLName tag and the struct field has no
explicit name tag as per the previous rule, unmarshal maps
the sub-element to that struct field.
I dont' know what is meant with "XMLName tag" in this context, but I think it might think it might point to a solution?
Thanks for any suggestions and hints,
Steffen