一、使用最原始的javax.xml.parsers,标准的jdk api
// 字符串转XML
- StringxmlStr=\"......\";@H_502_29@
- @H_502_29@ @H_404_34@ StringReadersr=newStringReader(xmlStr);@H_502_29@
- InputSourceis=newInputSource(sr);@H_502_29@
- DocumentBuilderFactoryfactory=DocumentBuilderFactory.newInstance();@H_502_29@
- DocumentBuilderbuilder=factory.newDocumentBuilder();@H_502_29@
- Documentdoc=builder.parse(is);@H_502_29@