Learn R Programming

xmlwriter (version 0.1.1)

add_child_fragment: Add a child fragment to an existing xml_fragment

Description

Add a child fragment to an existing xml_fragment. The child fragment can be a named frag element in which case the name is used as the tag name, an unnamed element in which case the element is added as a text node. This functionality is equivalent with the / operator.

Usage

add_child_fragment(x, ..., .frag = frag(...))

Value

the original xml_fragment() with the child added.

Arguments

x

an xml_fragment() object

...

nest named elements and characters to include in the fragment (see example)

.frag

an xml_fragment to add as a child, overrides the ... argument

See Also

Other xml_fragment: as.character.xml_fragment(), as_frag(), as_xml_nodeset(), data_frag(), frag(), xml_fragment()