Schematron / schematron-enhancement-proposals

This repository collects proposals to enhance Schematron beyond the ISO specification
9 stars 0 forks source link

05.05.14 subject attribute [ref. JP31 032] #55

Closed AndrewSales closed 8 months ago

AndrewSales commented 1 year ago

First, "may" is used in an inappropriate manner, since the validation result becomes unpredictable. Second, is the subject node used for evaluating assertions? Or, is it used for error message? Third, "If no subject attribute is specified, the current subject node may be used" appears to be incorrect. The current context node" should be used.

rjelliffe commented 1 year ago

The @subject is not used for validation, merely for calculating the location in the SVRL, e.g., so that the location better corresponds with the text of the assertion.

But it can be cleared up. The intent is

1) If a rule has no @subject, the @context is its subject (provided in its SVRL location) 2) If an assertion has no @subject, the subject of its parent rule is its subject (provided in its SVRL location)

The purpose is to decouple somewhat the implementation XPaths, the modeling pragmatics of which assertions are grouped into which rules, the text of the assertions, and the location information reported in the SVRL.

On Sat, Apr 22, 2023 at 11:20 PM Andrew Sales @.***> wrote:

First, "may" is used in an inappropriate manner, since the validation result becomes unpredictable. Second, is the subject node used for evaluating assertions? Or, is it used for error message? Third, "If no subject attribute is specified, the current subject node may be used" appears to be incorrect. The current context node" should be used.

— Reply to this email directly, view it on GitHub https://github.com/Schematron/schematron-enhancement-proposals/issues/55, or unsubscribe https://github.com/notifications/unsubscribe-auth/AF65KKLVGN4QEECV77IL7ZDXCPLKJANCNFSM6AAAAAAXH226OQ . You are receiving this because you are subscribed to this thread.Message ID: @.***>

AndrewSales commented 8 months ago

Clarified in latest draft.