XPath (SimpleXML) selection of child based on value of child's sibling

后端 未结 3 1965
旧时难觅i
旧时难觅i 2021-01-22 05:28

I\'m using SimpleXML (Java) and I\'m trying to get a List of objects based on the value of one of the siblings of the list.

So, here\'s my XML:



        
3条回答
  •  别那么骄傲
    2021-01-22 06:23

    I never got SimpleXml to implement this style of XPath; from reading through their docs more thoroughly, it looks like they haven't implemented this XPath feature yet.

    So I settled on a different XML-parsing strategy here: https://stackoverflow.com/a/13236117/483257

提交回复
热议问题