Rsamples/testNew.R

library(XML)
gctorture()
doc = xmlParse("<mydoc><a><b><c>Some text</c></b><d>More text</d></a></mydoc>", asText = TRUE)
node = newXMLNode("bob", newXMLNode("jane", "my new text"))
addChildren(xmlRoot(doc)[["a"]], node)
rm(node)
gc()
rm(doc)
gc()
cosmicexplorer/xmlr documentation built on May 30, 2019, 8:28 a.m.