Advertise here




Advertise here

Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

XML to NSDictionary

tangamampiliatangamampilia Posts: 7New Users
edited December 2010 in iOS SDK Development
Hi!

I hope you could help me. This is the scenario:

1.- My client have a RSS with XML.
2.- He wants to publish it into a iPhone.
3.- As you know, the native XML Object for Objective-C really sucks... so, here is my cuestion:

¿There is a library to convert XML to NSDictionary like SBJSON does?

Also for my client policies, I am unable to create a proxy file in my server which could convert the XML to JSON. I need to connect directly to their server.

Or maybe, ¿do you know an alternative XML Parser?

Thanks in advance. CYa!
Post edited by tangamampilia on
· ·

Replies

  • bugnotebugnote Posts: 183Registered Users
    edited April 2010
    touchxml is a very solid xml parser
    <b><a href="http://www.burnsoft.co.uk" target="_blank">Burnsoft Ltd.</a></b> Apps for your iOS device.
    · ·
  • funkyspiderfunkyspider Posts: 92Registered Users
    edited April 2010
    NSXMLParser is a little clumsy, but will do what you want and is quick enough for smaller XML packets.

    Have a look through this article to see if it suits what you are planning to do
    http://codesofa.com/blog/archive/2008/07/23/make-nsxmlparser-your-friend.html

    If your XML is coming from a SOAP webservice then this code generator takes all the hassle out of dealing with the SOAP service and also does handle parsing into a NSDictionary (depanding on the format of your XML).

    SudzC (alpha) | clean source code from your web services

    The author is a really nice guy who is very helpful if you need advice when using the generated code
    · ·
  • Benoit CaccinoloBenoit Caccinolo Posts: 5New Users
    edited December 2010
    To easily convert XML to NSDictionary, here is a little lib to do this conversion:

    XML to NSDictionary Converter bcaccinolo's blog

    The code is on Github.

    Cheers,
    · ·
Sign In or Register to comment.