Re: [Simple-support] how can I get only data for nested element in xml
Brought to you by:
niallg
|
From: Niall G. <gal...@ya...> - 2012-05-15 21:15:15
|
see the @Path annotation, that should do the job for u --- On Tue, 15/5/12, Simon (Zhe) Xu <si...@ho...> wrote: From: Simon (Zhe) Xu <si...@ho...> Subject: [Simple-support] how can I get only data for nested element in xml To: sim...@li... Received: Tuesday, 15 May, 2012, 1:04 PM Hi, I am hoping someone could help, and would really appreciate. I am trying to create elements from an xml and I am not interested in the root, but only some nested elements. I wonder if there is a way for simple xml to get those elements without me creating all the classes starting from root(Response class in this case). I am only interested in getting the Stations class from the xml below. Thank you. <Response xmlns="http://www.sss.com/ws/"> <GroupInfo> <Id>lirr</Id> <Name>Long Island Rail Road</Name><VehicleTypes>R</VehicleTypes> <Category>NYC to LI Regional Rail</Category><IconLarge> <Width>50</Width><Height>50</Height></IconLarge> <Icon><Width>25</Width> <Height>25</Height></Icon> <Stations><Station> <Id>albertson</Id> <Name>Albertson</Name> <X>-73.64169</X> <Y>40.77205</Y> <Radius>100</Radius> </Station><Station> <Id>yaphank</Id> <Name>Yaphank</Name> <X>-72.91588</X> <Y>40.8256</Y> <Radius>100</Radius> </Station></Stations> </GroupInfo><ResponseStatus> <ResultCode>200</ResultCode> <ResultString>Success.</ResultString> </ResponseStatus> </Response> Best wishes, Simon -----Inline Attachment Follows----- ------------------------------------------------------------------------------ Live Security Virtual Conference Exclusive live event will cover all the ways today's security and threat landscape has changed and how IT managers can respond. Discussions will include endpoint security, mobile security and the latest in malware threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/ -----Inline Attachment Follows----- _______________________________________________ Simple-support mailing list Sim...@li... https://lists.sourceforge.net/lists/listinfo/simple-support |