Skip to content

Commit

Permalink
#187 add AbstractSimpleComponent + test geometa coverage with SWE
Browse files Browse the repository at this point in the history
  • Loading branch information
eblondel committed May 9, 2022
1 parent f58512f commit 614c1c4
Show file tree
Hide file tree
Showing 6 changed files with 73 additions and 5 deletions.
1 change: 1 addition & 0 deletions NAMESPACE
Original file line number Diff line number Diff line change
Expand Up @@ -321,6 +321,7 @@ export(ISOVectorSpatialRepresentation)
export(ISOVerticalExtent)
export(SWEAbstractDataComponent)
export(SWEAbstractObject)
export(SWEAbstractSimpleComponent)
export(cacheISOClasses)
export(convert_metadata)
export(geometaLogger)
Expand Down
34 changes: 34 additions & 0 deletions R/SWEAbstractSimpleComponent.R
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
#' SWEAbstractSimpleComponent
#'
#' @docType class
#' @importFrom R6 R6Class
#' @export
#' @keywords ISO SWE
#' @return Object of \code{\link{R6Class}} for modelling an SWS Abstract simple component
#' @format \code{\link{R6Class}} object.
#'
#' @references
#' OGC Geography Markup Language. https://www.ogc.org/standards/swecommon
#'
#' @author Emmanuel Blondel <emmanuel.blondel1@@gmail.com>
#'
SWEAbstractSimpleComponent <- R6Class("SWEAbstractSimpleComponent",
inherit = SWEAbstractDataComponent,
private = list(
xmlElement = "AbstractSimpleComponent",
xmlNamespacePrefix = "SWE"
),
public = list(

#'@description Initializes an object of class \link{SWEAbstractSimpleComponent}
#'@param xml object of class \link{XMLInternalNode-class} from \pkg{XML}
#'@param element element
#'@param attrs attrs
#'@param defaults defaults
#'@param wrap wrap
initialize = function(xml = NULL, element = NULL, attrs = list(), defaults = list(), wrap = TRUE){
if(is.null(element)) element <- private$xmlElement
super$initialize(xml, element = element, attrs = attrs, defaults = defaults, wrap = wrap)
}
)
)
3 changes: 1 addition & 2 deletions inst/extdata/coverage/geometa_coverage_inventory.csv
Original file line number Diff line number Diff line change
Expand Up @@ -275,7 +275,6 @@
"ISO/TC211 19139:2007","Geographic Metadata XML Schema","GMX","UomAlternativeExpression","<missing>",FALSE
"ISO/TC211 19139:2007","Geographic Metadata XML Schema - Geographic Temporal Schema (GTS)","GTS","TM_PeriodDuration","<missing>",FALSE
"ISO/TS 19103:2005","Geographic Common extensible markup language","GCO","AbstractObject","ISOAbstractObject",TRUE
"ISO/TS 19103:2005","Geographic Common extensible markup language","GCO","AbstractObject","ISOAbstractObject",TRUE
"ISO/TS 19103:2005","Geographic Common extensible markup language","GCO","Angle","ISOAngle",TRUE
"ISO/TS 19103:2005","Geographic Common extensible markup language","GCO","Binary","ISOBinary",TRUE
"ISO/TS 19103:2005","Geographic Common extensible markup language","GCO","Boolean","ISOBaseBoolean",TRUE
Expand Down Expand Up @@ -476,7 +475,7 @@
"SWE 2.0","Sensor Web Enablement (SWE) Common Data Model","SWE","AbstractDataComponent","SWEAbstractDataComponent",TRUE
"SWE 2.0","Sensor Web Enablement (SWE) Common Data Model","SWE","AbstractEncoding","<missing>",FALSE
"SWE 2.0","Sensor Web Enablement (SWE) Common Data Model","SWE","AbstractObject","SWEAbstractObject",TRUE
"SWE 2.0","Sensor Web Enablement (SWE) Common Data Model","SWE","AbstractSimpleComponent","<missing>",FALSE
"SWE 2.0","Sensor Web Enablement (SWE) Common Data Model","SWE","AbstractSimpleComponent","SWEAbstractSimpleComponent",TRUE
"SWE 2.0","Sensor Web Enablement (SWE) Common Data Model","SWE","AbstractSWE","<missing>",FALSE
"SWE 2.0","Sensor Web Enablement (SWE) Common Data Model","SWE","AbstractSWEIdentifiable","<missing>",FALSE
"SWE 2.0","Sensor Web Enablement (SWE) Common Data Model","SWE","AllowedTimes","<missing>",FALSE
Expand Down
4 changes: 2 additions & 2 deletions inst/extdata/coverage/geometa_coverage_summary.csv
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,8 @@
"ISO/TC211 19115-2:2009","Geographic Information - Metadata - Part 2: Extensions for imagery and gridded data","GMI",40,0,100
"ISO/TC211 19119:2005","Geographic Information - Service Metadata","SRV",7,12,36.84
"ISO/TC211 19139:2007","Geographic Metadata XML Schema","GMX",5,62,7.46
"ISO/TS 19103:2005","Geographic Common extensible markup language","GCO",24,0,100
"ISO/TS 19103:2005","Geographic Common extensible markup language","GCO",23,0,100
"GML 3.2.1 (ISO 19136)","Geographic Markup Language","GML",63,106,37.28
"GML 3.2.1 Coverage (OGC GMLCOV)","OGC GML Coverage Implementation Schema","GMLCOV",1,0,100
"GML 3.3 Referenceable Grid (OGC GML)","OGC GML Referenceable Grid","GMLRGRID",5,0,100
"SWE 2.0","Sensor Web Enablement (SWE) Common Data Model","SWE",2,28,6.67
"SWE 2.0","Sensor Web Enablement (SWE) Common Data Model","SWE",3,27,10
2 changes: 1 addition & 1 deletion inst/extdata/coverage/geometa_coverage_summary.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,4 +9,4 @@
|GML 3.2.1 (ISO 19136) |Geographic Markup Language |GML |[![GML 3.2.1 (ISO 19136)](https://img.shields.io/badge/-37%25-ff0c0c.svg)](https://github.com/eblondel/geometa) | 63| 106|
|GML 3.2.1 Coverage (OGC GMLCOV) |OGC GML Coverage Implementation Schema |GMLCOV |[![GML 3.2.1 Coverage (OGC GMLCOV)](https://img.shields.io/badge/-100%25-4a4ea8.svg)](https://github.com/eblondel/geometa) | 1| 0|
|GML 3.3 Referenceable Grid (OGC GML) |OGC GML Referenceable Grid |GMLRGRID |[![GML 3.3 Referenceable Grid (OGC GML)](https://img.shields.io/badge/-100%25-4a4ea8.svg)](https://github.com/eblondel/geometa) | 5| 0|
|SWE 2.0 |Sensor Web Enablement (SWE) Common Data Model |SWE |[![SWE 2.0](https://img.shields.io/badge/-7%25-ad0f0f.svg)](https://github.com/eblondel/geometa) | 2| 28|
|SWE 2.0 |Sensor Web Enablement (SWE) Common Data Model |SWE |[![SWE 2.0](https://img.shields.io/badge/-10%25-ad0f0f.svg)](https://github.com/eblondel/geometa) | 3| 27|
34 changes: 34 additions & 0 deletions man/SWEAbstractSimpleComponent.Rd

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit 614c1c4

Please sign in to comment.