-
-
Save hivaga/917156 to your computer and use it in GitHub Desktop.
Converting XML to Object
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// converting XML to Object | |
private function xmlToObject( xml:XML ):Object { | |
var xmlStr:String = xml.toString(); | |
var xmlDoc:XMLDocument = new XMLDocument( xmlStr ); | |
var decoder:SimpleXMLDecoder = new SimpleXMLDecoder( true ); | |
var obj:Object = decoder.decodeXML( xmlDoc ); | |
return obj; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Converting XML ot Object using XMLDocument and SimpleXMLDecoder