serializeSystemMetadata: Serialize a SystemMetadata object to an XML representation

Description Usage Arguments Details Value See Also Examples

Description

The SystemMetadata object is converted to XML and written to a file.

Usage

1
2
3
4
serializeSystemMetadata(x, ...)

## S4 method for signature 'SystemMetadata'
serializeSystemMetadata(x, version = "v1", ...)

Arguments

x

The SystemMetadata instance to be serialized.

...

(Not currently used)

version

A character string representing the DataONE API version that this system will be used with (eg. "v1", "v2").

Details

If the 'version' parameter is specified as *v2* then the SystemMetadata object is serialized according to the DataONE version 2.0 system metdata format.

Value

A character value of the filename that the XML representation of the SystemMetadata object was written to.

the character string representing a SystemMetadata object

See Also

SystemMetadata-class

Examples

1
2
3
4
5
library(XML)
doc <- xmlParseDoc(system.file("testfiles/sysmeta.xml", package="datapack"), asText=FALSE)
sysmeta <- new("SystemMetadata")
sysmeta <- parseSystemMetadata(sysmeta, xmlRoot(doc))
sysmetaXML <- serializeSystemMetadata(sysmeta, version="v2")


Search within the datapack package
Search all R packages, documentation and source code

Questions? Problems? Suggestions? or email at ian@mutexlabs.com.

Please suggest features or report bugs with the GitHub issue tracker.

All documentation is copyright its authors; we didn't write any of that.