On 10/21/12 12:50 PM, Thomas Wetmore wrote:
I am using NSXMLDocument to parse XML files. Some of the files are not legal
XML because they contain a sequence of top level elements (legal XML must
have a unique root element).

Currently I handle this issue by programmatically adding a root element to
surround the entire file before parsing. This seems ugly and heavy-handed.

Is there a way to easily parse an XML file consisting of a sequence of top
level elements? I don't actually need the NSXMLDocument object for anything.
If there were an easy way to parse the files to an array of NSXMLElements it
would be fine.

If you find one, I'd be interested to hear about it. I had the same problem and solved it the same way.

Regards
Markus
--
__________________________________________
Markus Spoettl
_______________________________________________

Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
https://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com

Reply via email to