Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

How requirements on enumerated properties should be interpreted #125

Closed
pasi-paasiala opened this issue Jan 31, 2023 · 3 comments · Fixed by #289
Closed

How requirements on enumerated properties should be interpreted #125

pasi-paasiala opened this issue Jan 31, 2023 · 3 comments · Fixed by #289
Assignees
Labels
documentation Improvements or additions to documentation tests
Milestone

Comments

@pasi-paasiala
Copy link
Contributor

This is related to the following files:
IDS
IFC

The IDS requires that the enumerated value has simple value "EXISTING". The actual value of the property contains two values "EXISTING" and "DEMOLISH". Implicitly then it is sufficient that this list contains the "EXISTING" value, but is there a way to require that the value only contains that and nothing else?

@andyward
Copy link
Contributor

Isn't it asking new a value of "NEW" in the Enumerated Value property?

             <requirements>
                <property measure="IfcLabel" minOccurs="1" maxOccurs="1">
                    <propertySet>
                        <simpleValue>Pset_WallCommon</simpleValue>
                    </propertySet>
                    <name>
                        <simpleValue>Status</simpleValue>
                    </name>
                    <value>
                        <simpleValue>NEW</simpleValue>
                    </value>
                </property>
            </requirements>

But the entity actually contains "EXISTING" and "DEMOLISH", so you'd expect it to fail?

#11=IFCPROPERTYENUMERATEDVALUE('Status',$,(IFCLABEL('EXISTING'),IFCLABEL('DEMOLISH')),#10);

@aothms
Copy link

aothms commented Jan 31, 2023

The ids file referenced by @pasi-paasiala is indeed intended to fail as indicated by the name *fail*-any_matching_value_in_an_enumerated_property_will_pass_3_3.ids. Maybe the intended ids file to referenced was this one: pass-any_matching_value_in_an_enumerated_property_will_pass_1_3.ids

I think the current behaviour in the test cases is consistently that for any multi-valued construct (layered material, bounded prop, list prop, enum prop, ...) that at least one of these elements then must match the constraint.

It's been a while, but I also remember it has been discussed that for applicability the behaviour could be to have any of the values match: "A concrete wall is a wall with at least one layer of concrete", but for the requirement part all should match: e.g as you said: "existing or demolish, but nothing else". I think this was scrapped for being too magical and/or confusing.

So I don't think there is currently a way to specify that.

@CBenghi CBenghi added this to the 1.0 milestone May 31, 2023
@CBenghi CBenghi added documentation Improvements or additions to documentation tests labels May 31, 2023
@CBenghi CBenghi self-assigned this Apr 19, 2024
@CBenghi
Copy link
Contributor

CBenghi commented Apr 19, 2024

Make sure the test suite covers passes and failures appropriately. This specific file seems to be ok.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
documentation Improvements or additions to documentation tests
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants