Learn R Programming

RTest (version 1.2.6)

xmlReadData_image: Read XML Data From Type 'xmlReadData_image' as R Variable

Description

Read XML Data From Type 'xmlReadData_image' as R Variable

Usage

xmlReadData_image(xmlItem)

Arguments

xmlItem

(XMLNode) Object of class XMLNode that defines the a simple variable and fullfills XSD definition 'xmlReadData_variable'.

Value

(vector)

See Also

XMLNode-class

Examples

Run this code
# NOT RUN {
location <- find.package("RTest")
data <- paste0(
     '<variable name="myvar" value="',location,
          '/images/Roche_Logo.png" type="character" image="TRUE"/>'
     )
item <- XML::xmlRoot(XML::xmlParse(data,asText=TRUE))
value <- RTest::xmlReadData_image(item)
stopifnot(grepl("png",value$address))

# }

Run the code above in your browser using DataLab