Learn R Programming

geometa (version 0.7)

convert_metadata: convert_metadata

Description

convert_metadata is a tentative generic metadata converter to convert from one source object, represented in a source metadata object model in R (eg eml) to a target metadata object, represented in another target metadata object model (eg geometa ISOMetadata). This function relies on a list of mapping rules defined to operate from the source metadata object to the target metadata object. This list of mapping rules is provided in a tabular format. A version is embedded in geometa and can be returned with getMappings.

Usage

convert_metadata(obj, from, to, mappings, verbose)

Value

an metadata object in the model specified as to argument

Arguments

obj

a metadata object given in one of the mapping formats known by geometa. The object should be a valid id as listed by getMappingFormats, supported as source format (from is TRUE).

from

a valid mapping format id (see getMappingFormats) that indicates the metadata model / format used for the argument obj

to

a valid mapping format id (see getMappingFormats) to convert to

mappings

a data.frame giving the reference mapping rules to convert metadata object. This data.frame is by default the output of getMappings.

verbose

print debugging messages. Default is FALSE

Author

Emmanuel Blondel <emmanuel.blondel1@gmail.com>