The element rule
encloses asserts and reports that should be evaluated provided that the conditions specified in the attributes (or children <where>
attributes) are true.
Formal Definition
~ed-stamp
?, (~inclusion
| ( ( {{{[TAN-mor (~action-condition-attributes
):]~action-condition-attributes
}}} OR {{{[TAN-class-2 (~action-condition-attributes
):]~action-condition-attributes
}}} OR {{{[TAN-core (~action-condition-attributes
):] {empty}}}} |<where>
+), (<assert>
|<report>
)+))
Defined at:
TAN-mor.rng
Used by: ~TAN-R-mor-body
Example 8.182. <rule>
<TAN-mor TAN-version="2018" id="tag:kalvesmaki.com,2014:tan-r-mor:eng:penn"> ......... <body> <for-lang>eng</for-lang> <rule m-matches=".+"> <assert m-has-how-many-features="1">Features may not be combined.</assert> </rule> <rule m-has-features="$"> <assert tok-matches="$">Only $ may be tagged as a dollar sign.</assert> </rule> <rule m-has-features="'' . ; :"> <report tok-matches="\w">Nothing marked as punctuation should have word characters.</report> </rule> </body> </TAN-mor>
Note | |
---|---|
Taken from eng.kalvesmaki.com,2014.2 |