addChildren: Add child nodes to the passed parent node

View source: R/add_children.R

addChildrenR Documentation

Add child nodes to the passed parent node

Description

Add child nodes to the passed parent node

Usage

addChildren(node, avps)

Arguments

node

An xml2 node

avps

A named list

Value

An xml2 node with the children appended

Examples

library("xml2")
parent    <- read_xml("<body/>")
add_nodes <- list(foo = "bar", fizz = "buzz")
parent    <- addressr::addChildren(parent, add_nodes)

McClellandLegge/addressr documentation built on June 8, 2022, 10:48 p.m.