Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [mdht-dev] Property Cardinality Update


Joerg -
Ok - I was hoping to have a discussion on how this breaks the schematron because the other way breaks the OCL
This constraint logic has always been a confusing point but if i have a base property that has a cardinality of 0..* and you define a constraint of 
“SHOULD HAVE ONE”  struc docs wants the cardinality in guide to be 0..1 - if you implement this literally - it will never be “invalid” so we imply a lower property of 1 for that reason in the OCL

The lower bound of 1 is ok - using the method enableVariation_UseOriginalLowerbound() the mdht code would normally switch between 0 or 1 - 0 for cases for schematron generation and 1 for the default case.
However this method for switching this constant is not used in the new code.

But the upper bound is also printed as "-1" directly in the OCL , this actually breaks the syntactic correctnes of the generated schematron code.
The syntactical errors as displayed by Oxygen's XML editor - if you use the initial schematron contribution, it should also be generated if  you want to reproduce it.

Cheers



Back to the top