|
1 | | -=== Logical Model |
| 1 | +=== GeoSciML Core Abstract Requirements Class (Normative) |
2 | 2 |
|
3 | | -Paragraph |
| 3 | +[width="100%",cols="10%,90%",options="header",] |
| 4 | +|=== |
| 5 | +|*Abstract Requirements Class* | |
| 6 | +|/req/gsml4-core | |
| 7 | +|*Target type* |Encoding |
| 8 | +|*Dependency* |ISO19103:2005 Conceptual Schema Language |
| 9 | +|*Dependency* |ISO19107:2003 Spatial Schema |
| 10 | +|*Dependency* |ISO19109:2015 Rules for application schemas |
| 11 | +|*Dependency* |RFC 3986 Uniform Resource Identifier (URI): Generic Syntax |
| 12 | +|*Dependency* |ISO19115-3 Metadata |
| 13 | +|*Requirement* a| |
| 14 | +*/req/gsml4-core/uml-entity-name* |
4 | 15 |
|
5 | | -==== Requirement Class A or Requirement A Example |
| 16 | +When the target implementation allows it, the exact name of the classifier SHALL be used. |
6 | 17 |
|
7 | | -TBA |
| 18 | +|*Requirement* a| |
| 19 | +*/req/gsml4-core/uml-cardinality* |
| 20 | + |
| 21 | +If the target implementation allows it, it SHALL implement the same cardinality of properties and associations as defined in the UML. |
| 22 | + |
| 23 | +|*Requirement* a| |
| 24 | +*/req/gsml4-core/uml-abstract* |
| 25 | + |
| 26 | +Abstract classes SHALL NOT be materialised. |
| 27 | + |
| 28 | +|*Requirement* a| |
| 29 | +*/req/gsml4-core/uml-polymorphism* |
| 30 | + |
| 31 | +A target implementation SHALL implement type substitutions inferred from the UML model. |
| 32 | + |
| 33 | +|*Requirement* a| |
| 34 | +*/req/gsml4-core/quantities-uom* |
| 35 | + |
| 36 | +Quantities and measurements SHALL have explicit units of measure from a governed ontology. |
| 37 | + |
| 38 | +|*Requirement* a| |
| 39 | +*/req/gsml4-core/quantities-single-range* |
| 40 | + |
| 41 | +QuantityRange properties that must report a single value SHALL assign both lower and upper value as equal to that single value. |
| 42 | + |
| 43 | +|*Requirement* a| |
| 44 | +/req/gsml4-core/codelist |
| 45 | + |
| 46 | +Empty classes with stereotype ++<<++CodeList++>>++ SHALL be implemented as externally governed vocabularies which terms are encoded as URI (RFC 3986). |
| 47 | + |
| 48 | +|=== |
| 49 | + |
| 50 | +This section presents requirements to which all target encodings must conform in to order to claim compliance to GeoSciML 4.1. |
| 51 | + |
| 52 | +==== Naming of entities |
| 53 | + |
| 54 | +[width="100%",cols="100%",options="header",] |
| 55 | +|=== |
| 56 | +|*Requirement /req/gsml4-core/uml-entity-name* |
| 57 | +|When the target implementation allows it, the exact name of the classifier SHALL be used. |
| 58 | +|=== |
| 59 | + |
| 60 | +If a target implementation is capable of encoding all the artefacts (classes and properties) using the same names used in UML, it shall do so. Some target implementations might prevent it; for example, dBase (DBF files) column names are restricted to 10 characters or some RDBMS limits the use of camel case names. But if the target allows it, the exact names shall be used. |
| 61 | + |
| 62 | +==== Cardinality |
| 63 | + |
| 64 | +[width="100%",cols="100%",options="header",] |
| 65 | +|=== |
| 66 | +|*Requirement /req/gsml4-core/uml-cardinality* |
| 67 | +|If the target implementation allows it, it SHALL implement the same cardinality of properties and associations as defined in the UML. |
| 68 | +|=== |
| 69 | + |
| 70 | +Cardinality shall be the same as defined in UML model. Since essentially all properties are optional, this clause addresses the upper bounds of cardinality: “1” or “many” in almost all cases. Therefore, if the UML model limits a property’s maximum cardinality to “1”, then the target implementation cardinality cannot be “many”. |
| 71 | + |
| 72 | +==== Abstract classes |
| 73 | + |
| 74 | +[width="100%",cols="100%",options="header",] |
| 75 | +|=== |
| 76 | +|*Requirement /req/gsml4-core/uml-abstract* |
| 77 | +|Abstract classes SHALL NOT be materialised. |
| 78 | +|=== |
| 79 | + |
| 80 | + |
| 81 | + |
| 82 | +Not all physical implementations support the concept of an abstract class, or even inheritance and polymorphism. XSD does support that concept and all its implications, but JSON does not – although JavaScript can somewhat. This requirement specifies that the encoding specification shall not allow materialisation of an instance of a class stereotyped as abstract. |
| 83 | + |
| 84 | +==== Polymorphism |
| 85 | + |
| 86 | +[width="100%",cols="100%",options="header",] |
| 87 | +|=== |
| 88 | +|*Requirement /req/gsml4-core/uml-polymorphism* |
| 89 | +|A target implementation SHALL implement type substitutions inferred from the UML model. |
| 90 | +|=== |
| 91 | + |
| 92 | +The type hierarchy of the UML model implies type substitutions for property values. For instance, a property value of type GeologicEvent can be substituted by a value of type DisplacementEvent because DisplacementEvent is a subtype of GeologicEvent. Many property types are abstract types and only a concrete subtype may be materialised (as per /req/gsml4-core/uml-abstract). A target implementation shall consider type substitutions using mechanisms available for this implementation. |
| 93 | + |
| 94 | +==== Quantities |
| 95 | + |
| 96 | +[width="100%",cols="100%",options="header",] |
| 97 | +|=== |
| 98 | +|*Requirement /req/gsml4-core/quantities-uom* |
| 99 | +|Quantities and measurements SHALL have explicit units of measure from a governed ontology. |
| 100 | +|=== |
| 101 | + |
| 102 | +The quantities and measurements units of measure shall be taken from a standard vocabulary governed by an appropriate community, for example the Unified Code for Units of Measure (UCUM). |
| 103 | + |
| 104 | +==== QuantityRange |
| 105 | + |
| 106 | +A QuantityRange is a quantity formed of a lower and upper value forming a range of values. If a single value needs to be represented as a QuantityRange, where the single value is assigned to both lower and upper properties. |
| 107 | + |
| 108 | +[width="100%",cols="100%",options="header",] |
| 109 | +|=== |
| 110 | +|*Requirement /req/gsml4-core/quantities-single-range* |
| 111 | +| |
| 112 | +|QuantityRange properties that must report a single value SHALL assign both lower and upper value as equal to that single value. |
| 113 | +|=== |
| 114 | + |
| 115 | +==== Code lists |
| 116 | + |
| 117 | +[width="100%",cols="100%",options="header",] |
| 118 | +|=== |
| 119 | +|*Requirement /req/gsml4-core/codelist* |
| 120 | +|Empty classes with stereotype ++<<++CodeList++>>++ SHALL be implemented as externally governed vocabularies which terms are encoded as URI (RFC 3986). |
| 121 | +|=== |
| 122 | + |
| 123 | +All properties that require formal vocabularies are modelled in the UML as classes having the stereotype ++<<++CodeList++>>++. The list of valid terms is either prescribed by this specification, with a list of possible entries (Figure 9) or open (i.e., without any terms). |
| 124 | + |
| 125 | +.Example CodeLists, with a) a prescribed list of terms (DescriptionPurpose) and b) 'open' with no prescribed terms (GeologicUnitHierarchyRoleTerm) |
| 126 | +image::images/image9.png[width=118,height=96] |
| 127 | + |
| 128 | +When the list is open, the vocabulary is managed externally over the web where each vocabulary term should be encoded as a resource. Vocabulary term identifiers are URIs representing concepts from a standard vocabulary governed by an appropriate community - for example, the IUGS CGI Geoscience Terminology Working Group (http://www.cgi-iugs.org/tech_collaboration/geoscience_terminology_working_group.html[[.underline]#http://www.cgi-iugs.org/tech++_++collaboration/geoscience++_++terminology++_++working++_++group.html#] and http://resource.geosciml.org/[[.underline]#http://resource.geosciml.org#]) or INSPIRE ++[++8++]++. |
| 129 | + |
| 130 | +This requirement does not require that URIs be actually dereferenceable, but just that a vocabulary term is associated with a syntactically correct URI. |
0 commit comments