Learn R Programming

XML (version 1.2-0)

dtdElementValidEntry: Determines whether an XML element allows a particular type of sub-element.

Description

This tests whether name is a legitimate tag to use as a direct sub-element of the element tag according to the definition of the element element in the specified DTD. This is a generic function that dispatches on the element type, so that different version take effect for XMLSequenceContent, XMLOrContent, XMLElementContent.

Usage

dtdElementValidEntry(element, name, pos=NULL)

Arguments

Value

  • Logical value indicating whether the sub-element can appear in an element tag or not.

Details

This is not intended to be called directly, but indirectly by the dtdValidElement function.

References

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

See Also

parseDTD, dtdValidElement, dtdElement

Examples

Run this code
dtdFile <- system.file("exampleData", "foo.dtd",package="XML")
 dtd <- parseDTD(dtdFile) 
 
  dtdElementValidEntry(dtdElement("variables",dtd), "variable")

Run the code above in your browser using DataLab