These are a collection of methods for providing easy access to the
top-level XMLNode object resulting from parsing an XML
document. They simplify accessing this node in the presence of
auxillary information such as DTDs, file name and version information
that is returned as part of the parsing.
Usage
xmlRoot(x, ...)
## S3 method for class 'XMLDocumentContent':
xmlRoot(x, ...)
## S3 method for class 'XMLInternalDocument':
xmlRoot(x, skip = TRUE, ...)
## S3 method for class 'HTMLDocument':
xmlRoot(x, ...)
Arguments
x
the object whose root/top-level XML node is to be returned.
skip
a logical value that controls whether DTD nodes and/or
XMLComment objects that appear
before the real top-level node of the document should be ignored (TRUE)
or not (FALSE) when returning the root node
...
arguments that are passed by the generic to the different specialized
methods of this generic.