Learn R Programming

geometa (version 0.7)

pivot_format: pivot_format

Description

pivot_format

Arguments

Value

Object of R6Class for modelling a mapping format

Format

R6Class object.

Fields

id

(character) format identifier

pkg

(character) package(s) required for the format

reader

(function) handler used for reading a property

checker

(function) handler used for checking a property value

constructor

(function) handler used for object construction

Methods

new(id, pkg, reader, checker, constructor)

This method is used to instantiate a pivot_format, given a unique id, the name of package used (for information only). A format is then defined by string expressions (using sprintf formatting) to read metadata properties (reader), one for checking existence of properties (checker), and an expression to create metadata objects (constructor). In case the constructor is NULL, then no conversion to this metadata format will be possible.

Author

Emmanuel Blondel <emmanuel.blondel1@gmail.com>

Examples

Run this code
  #example on how geometa format is defined as pivot format
  pivot_format$new(
    id = "geometa", pkg = "geometa",
    reader = "%s[[%s]]", checker = "!is.null(%s[[%s]])",
    constructor = "ISOMetadata$new"
  )

Run the code above in your browser using DataLab