asXMLNode {XML}R Documentation

Converts non-XML node objects to XMLTextNode objects

Description

This function is used to convert S objects that are not already XMLNode objects into objects of that class. Specifically, it treats the object as a string and creates an XMLTextNode object.

Usage

asXMLNode(x)

Arguments

x the object to be converted to an XMLNode object. This is typically alread an object that inherits from XMLNode or a string.

Value

Author(s)

Duncan Temple Lang

References

http://www.w3.org/XML, http://www.jclark.com/xml, http://www.omegahat.org

See Also

xmlNode xmlTextNode

Examples

   # creates an XMLTextNode.
 asXMLNode("a text node")

   # unaltered.
 asXMLNode(xmlNode("p"))

[Package XML version 0.97-0 Index]