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

Cardinality > 1, distinguish between Map / Array

Open alexgordtop opened this issue 10 months ago • 2 comments

The model should distinguish for attributes with cardinality > 1, it it is a kind of array/list or a kind of object/map.

This is relevant for Value-Only serialization only. For Normal it is always an array.

alexgordtop avatar Apr 16 '24 08:04 alexgordtop

In Part 2 for interfaces

image

Mandatory and Cardinality are distinguished. So there might be an optional element but the cardinality is 1. No Null object allowed in this case.

Similar we can add an additional column to the class definitions. For all cases with 0..1, 0..* etc. we need to define whether empty lists or NULL objects are allowed. To be backward compatible to the schema implementations we would have in the moment:

  • mandatory: false
  • Cardinality: 1 or 1..* etc.

BirgitBoss avatar Jun 03 '24 08:06 BirgitBoss

If I get this correctly, you want to specify in the model how a given attribute with cardinality > 1 should be implemented? (As a list or an array?)

That is nothing a technology-neutral model should specify in my opinion. What if there was an AAS implementation in a programming language that handles multivalued attributes differently and does not offer one or the other? If you want to specify this, it should be in the return value of the API call, imo.

Please correct me, if I didn't get the problem right.

s-heppner avatar Jun 03 '24 09:06 s-heppner