aas-specs icon indicating copy to clipboard operation
aas-specs copied to clipboard

add constraint: for Submodel with kind=Instance Property/value and MultiLanguageProperty shall be defined.

Open BirgitBoss opened this issue 10 months ago • 1 comments

Is your feature request related to a problem? Please describe. Up to now Property/value and Property/valueId (and similar for MultiLangaugeProperty) are both optional. The reasons: a) for Submodel TEmplate they do not exist b) it is possible to either have a value or a valueId: in both cases a value would be defined

For the Value-Only-Serialization this leads to problems because it cannot be expected that properties do have a value.

There is one constraints for value and valueId:

Constraint AASd-007: If both the Property/value and the Property/valueId are present, the value of Property/value needs to be identical to the value of the referenced coded value in Property/valueId.

and

Constraint AASd-012: if both the MultiLanguageProperty/value and the MultiLanguageProperty/valueId are present, the meaning must be the same for each string in a specific language, as specified in MultiLanguageProperty/valueId.

Proposal:

  • Add Constraints:

For of Property within a Submodel with kind=Instance Property/value shall be defined.

For of MultiLanguageProperty within a Submodel with kind=Instance MultiLanguageProperty/value shall be defined.

Since the introduction of these constraints would not be backwards-comptible, we can first just request "should"

For of Property within a Submodel with kind=Instance Property/value should be defined. and add a note: In future releases this constraints be mandatory to be fulfilled.

For of MultiLanguageProperty within a Submodel with kind=Instance MultiLanguageProperty/value should be defined. and add a note: In future releases this constraints be mandatory to be fulfilled.

BirgitBoss avatar Apr 10 '24 16:04 BirgitBoss

What exactly does shall be defined mean here? Is null an acceptable value or e.g. in case of an integer property, must the value be a valid integer?

mjacoby avatar Apr 11 '24 06:04 mjacoby