tag {tinytest2JUnit}R Documentation

XML tag

Description

Create a list object that roughly mimics the behaviour of a simplistic XML tag element. Supported are XML tag-name, tag-attributes and tag-content.

Usage

tag(name, attributes = list(), content = list())

Arguments

name

character(1) specifying the name of the tag.

attributes

named-list being the XML attributes. Names = attribute names, Values = attribute value.

content

unnamed-list being the content XML-tag. Either child XMLtag or only a single character vector being the xml text content. Currently no mixed-content is allowed. See details.

Details

If a character vector is in the content it is converted to a single-length character vector. See charVecToSingleLength()

Mixed content eg. a text string and a child xml tag next to each other is syntaxtically allows. In practices it does not occur for XML that is schema formatted with XSD (like JUnit). So for simplicity it is not supported here.

Value

a XMLtag-object.


[Package tinytest2JUnit version 1.1.2 Index]