buildingSMART / IDS

Computer interpretable (XML) standard to define Information Delivery Specifications for BIM (mainly used for IFC)
Other
167 stars 52 forks source link

Double enumeration value in ids.xsd #278

Closed stefkeB closed 1 week ago

stefkeB commented 1 month ago

<xs:enumeration value="IFCRELVOIDSELEMENT IFCRELFILLSELEMENT"/>

In ids.xsd on line 270 this appears (which were two separate enumeration values before, according to the GitHub history). Is this an error? I don't think it's valid XML/XSD, but I'm not an XML expert.

aothms commented 1 month ago

The basis for this enum is xs:string, so I think there are no restrictions wrt e.g whitespace to the enum members, but I'm also not an XSD expert by any means. Automatic code generators could get into issues though because in probably all languages white space cannot be part of an enum literal, but maybe code generators have some automatic translation in place. I don't know.

I was also a bit surprised when I first saw this, but it is intentional, it means a combination of both relationships so that you can indicate in an IDS e.g a Window hosted in a Wall. Which is two hops in IFC because it is routed through the opening. (There is also other cases though. E.g for hosted elements that are not contained in an opening one is to use IfcRelConnects, so I'm also not sure this covers all behaviour from an end-user point of view).

My preference would probably have been to have the enum definitions as proper IFC entities, but allowing to use such enum references in a list so that one is able to precisely stipulate the path of relationship edges. But as far as I was told, this is mostly a stepping stone towards that because the space in XML is also the token separator for lists.

CBenghi commented 1 week ago

But as far as I was told, this is mostly a stepping stone towards that because the space in XML is also the token separator for lists.

Indeed that is the reason.

We hope this will make for an easier backwards compatibility with future versions.

@stefkeB is it ok to close?

stefkeB commented 1 week ago

ok for me