Skip to content

Commit

Permalink
definition list for requirement metadata: metanorma/ogcapi-processes#2
Browse files Browse the repository at this point in the history
  • Loading branch information
opoudjis committed Aug 13, 2021
1 parent 7bec011 commit 8427564
Show file tree
Hide file tree
Showing 2 changed files with 70 additions and 3 deletions.
36 changes: 34 additions & 2 deletions author/ogc/topics/requirements.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -60,10 +60,12 @@ followed by the attribute value
** The `subject` attribute of the requirement, if given: _Subject_, followed by the attribute.
(In other classes of requirement, the `subject` attribute of the requirement
is rendered differently; see below.) The subject attribute can be marked up as a cross-reference
to another requirent given in the same document.
to another requirent given in the same document. If there are multiple values of the subject,
they are semicolon delimited [added in https://github.com/metanorma/metanorma-standoc/releases/tag/v1.10.4].

** The `inherit` attribute of the requirement, if given: _Dependency_ followed
by the attribute value
by the attribute value. If there are multiple values of the subject,
they are semicolon delimited.

** The `component` components of the
requirement [added in https://github.com/metanorma/metanorma-ogc/releases/tag/v1.4.0],
Expand Down Expand Up @@ -166,6 +168,36 @@ Consult local coven for more information.
See Clause 4.5, Recommendation 1, in particular Clause 4.5, Recommendation 1 B.
____

As in the rest of Metanorma, attributes can also be expressed as a `[%metadata]` definition list
within the requirement:

[source,asciidoc]
.An exhaustive attribute example
-----
[requirement]
====
[%metadata]
model:: ogc
type:: class
label:: http://www.opengis.net/spec/waterml/2.0/req/xsd-xml-rules[*req/core*]
subject:: Encoding of logical models
inherit:: urn:iso:dis:iso:19156:clause:7.2.2
inherit:: urn:iso:dis:iso:19156:clause:8
inherit:: http://www.opengis.net/doc/IS/GML/3.2/clause/2.4
inherit:: O&M Abstract model, OGC 10-004r3, clause D.3.4
inherit:: http://www.opengis.net/spec/SWE/2.0/req/core/core-concepts-used
inherit:: <<ref2>>
inherit:: <<ref3>>
classification:: priority:P0
classification:: domain:Hydrology,Groundwater
classification:: control-class:Technical
obligation:: recommendation,requirement
I recommend this
====
-----


== OGC Classes of Requirement

To simplify the Modular Specification (Annex C),
Expand Down
37 changes: 36 additions & 1 deletion author/topics/document-format/requirements.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,8 @@ In addition to block type described above,
following attributes are supported (see usage example below):

`subject`:: Indicates the subject of the requirement.
Does not get rendered in final output.
Does not get rendered in final output (although this may be overridden in flavours).
Multiple instances of `subject` can be given, semicolon-delimited [added in https://github.com/metanorma/metanorma-standoc/releases/tag/v1.10.4]

`label`:: Indicates conventional label assigned to the requirement.
If present, it will be rendered in final output.
Expand Down Expand Up @@ -64,6 +65,40 @@ I recommend this
====
-----

As can be seen, the foregoing syntax can get quite awkward. For that reason, Metanorma also supports
using a definition list, marked with role attribute `[.metadata]`, within the requirement,
to enter the attributes [added in https://github.com/metanorma/metanorma-standoc/releases/tag/v1.10.4].
All attributes have the same syntax as above. That also allows `subjects` as well as `inherit` to
be marked up as cross-references, and it allows multiple instances of an attribute to be marked up
separately. So the foregoing example can also be marked up as:

[source,asciidoc]
.An exhaustive attribute example
-----
[requirement]
====
[%metadata]
model:: ogc
type:: class
label:: http://www.opengis.net/spec/waterml/2.0/req/xsd-xml-rules[*req/core*]
subject:: Encoding of logical models
inherit:: urn:iso:dis:iso:19156:clause:7.2.2
inherit:: urn:iso:dis:iso:19156:clause:8
inherit:: http://www.opengis.net/doc/IS/GML/3.2/clause/2.4
inherit:: O&M Abstract model, OGC 10-004r3, clause D.3.4
inherit:: http://www.opengis.net/spec/SWE/2.0/req/core/core-concepts-used
inherit:: <<ref2>>
inherit:: <<ref3>>
classification:: priority:P0
classification:: domain:Hydrology,Groundwater
classification:: control-class:Technical
obligation:: recommendation,requirement
I recommend this
====
-----


== Nested blocks

Requirements can be nested (as is the case with any delimited block AsciiDoc),
Expand Down

0 comments on commit 8427564

Please sign in to comment.