src/aria/utils/Xml.js
function (str) {
            var xmlDoc;
            var DOMParser = Aria.$global.DOMParser;
            if (DOMParser) {
                var parser = new DOMParser();
                xmlDoc = parser.parseFromString(str, "text/xml");
            } else { // Internet Explorer
                var ActiveXObject = Aria.$global.ActiveXObject;
                xmlDoc = new ActiveXObject("Microsoft.XMLDOM");
                xmlDoc.async = "false";
                xmlDoc.loadXML(str);
            }

            if (xmlDoc.hasChildNodes()) {
                return this.__parseXmlNode(xmlDoc);
            } else {
                return null;
            }
        }
function (str) {
            var xmlDoc;
            var DOMParser = Aria.$global.DOMParser;
            if (DOMParser) {
                var parser = new DOMParser();
                xmlDoc = parser.parseFromString(str, "text/xml");
            } else { // Internet Explorer
                var ActiveXObject = Aria.$global.ActiveXObject;
                xmlDoc = new ActiveXObject("Microsoft.XMLDOM");
                xmlDoc.async = "false";
                xmlDoc.loadXML(str);
            }

            if (xmlDoc.hasChildNodes()) {
                return this.__parseXmlNode(xmlDoc);
            } else {
                return null;
            }
        }
function ( str ) { var xmlDoc ; var DOMParser = Aria . $global . DOMParser ; if ( DOMParser ) { var parser = new DOMParser ( ) ; xmlDoc = parser . parseFromString ( str , "text/xml" ) ; } else { // Internet Explorer var ActiveXObject = Aria . $global . ActiveXObject ; xmlDoc = new ActiveXObject ( "Microsoft.XMLDOM" ) ; xmlDoc . async = "false" ; xmlDoc . loadXML ( str ) ; } if ( xmlDoc . hasChildNodes ( ) ) { return this . __parseXmlNode ( xmlDoc ) ; } else { return null ; } }
Performs a lossy conversion of a Xml string to a Json object Node atrributes are omitted in the parsing
process
@param {String} str The content of the Xml document
@return {Object} Json represantation of the Xml content
Performs a lossy conversion of a Xml string to a Json object Node atrributes are omitted in the parsing process