Learn R Programming

geometa (version 0.7)

INSPIREMetadataValidator: INSPIREMetadataValidator

Description

INSPIREMetadataValidator

Arguments

Value

Object of R6Class for setting an INSPIREMetadataValidator

Format

R6Class object.

Methods

new(url, apiKey)

This method is used to instantiate an INSPIRE Metadata validator. To check metadata with the INSPIRE metadata validator, a user API key is now required, and should be specified with the apiKey. By default, the url will be the INSPIRE production service https://inspire.ec.europa.eu/validator/swagger-ui.html

The keyring_backend can be set to use a different backend for storing the INSPIRE metadata validator API key with keyring (Default value is 'env').

uploadFile(path)

Upload a XML metadata file to INSPIRE web-service. Method called internally through getValidationReport.

getAPIKey()

Get the API user key

getValidationReport(obj, file, raw)

Get validation report for a metadata specified either as R object of class ISOMetadata (from geometa package) or XMLInternalNode (from XML package), or as XML file, providing the path of the XML file to be sent to the INSPIRE metadata validator web-service. By default, a summary report is returned. To append the raw response of INSPIRE validation web-service to the summary report, set raw = TRUE.

Author

Emmanuel Blondel <emmanuel.blondel1@gmail.com>

References

INSPIRE Reference Validator Web Service (https://inspire.ec.europa.eu/validator/swagger-ui.html)

Examples

Run this code
 # \donttest{
  apiKey <- ""
  if(nzchar(apiKey)){
    inspireValidator <- INSPIREMetadataValidator$new(apiKey = apiKey)
    inspireReport <- inspireValidator$getValidationReport(obj = ISOMetadata$new())
  }
 # }

Run the code above in your browser using DataLab