dtdIsAttribute

0th

Percentile

Query if a name is a valid attribute of a DTD element.

Examines the definition of the DTD element definition identified by element to see if it supports an attribute named name.

Keywords
file
Usage
dtdIsAttribute(name, element, dtd)
Arguments
name

The name of the attribute being queried

element

The name of the element whose definition is to be used to obtain the list of valid attributes.

dtd

The DTD containing the definition of the elements, specifically element.

Value

A logical value indicating if the list of attributes suppported by the specified element has an entry named name. This does indicate what type of value that attribute has, whether it is required, implied, fixed, etc.

References

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

See Also

parseDTD, dtdElement, xmlAttrs

Aliases
  • dtdIsAttribute
Examples
# NOT RUN {
 dtdFile <- system.file("exampleData", "foo.dtd", package="XML")
 foo.dtd <- parseDTD(dtdFile)

    # true
  dtdIsAttribute("numRecords", "dataset", foo.dtd)

    # false
  dtdIsAttribute("date", "dataset", foo.dtd)
# }
Documentation reproduced from package XML, version 3.98-1.19, License: BSD_2_clause + file LICENSE

Community examples

Looks like there are no examples yet.