thoughtbot/Argo

Supporting XML Parsing

hossamghareeb opened this issue · 3 comments

Is there any possibility to support XML parsing in the future? If I wanted to do it myself, is there any advices to tips to know about?

There's actually nothing JSON specific to Argo other than some naming. As a part of our test suite we're actually already parsing Plists and native Swift dictionaries.

So if you already have an XML parser that goes from XML -> NSDictionary, and the basic types line up with what Argo expects (strings, numbers, bools, null as raw values, arrays and string-to-value dictionaries as collections), then you shouldn't have any problems using Argo to perform the Dictionary -> Model transformation.

Yes true, actually the naming confused me so I thought it only works with JSON. I found some parser to convert XML to dictionary so I think it would work.

Thanks a lot.

@hossamghareeb Glad I could help! I'm going to go ahead and close this issue but feel free to re-open or add more comments if you have any questions in the future.