-
Notifications
You must be signed in to change notification settings - Fork 41
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
COBieLite Namespace #56
Comments
Simon, From what I can tell CobieLite defines its schema across 2 separate XSDs: core.xsd and cobielite.xsd, with the later referencing items in the former. In your examples above, I think the only difference is that xbim is being explicit with the namespace; whereas the example COBieLite at https://portal.nibs.org/files/wl/?id=EAyFiAEke4wwmojNiVSo2GMwPZJYJdWy is setting e.g. This is the start of the sample file <?xml version="1.0" encoding="UTF-8"?>
<cobielite:Facility xmlns:cobielite="http://docs.buildingsmartalliance.org/nbims03/cobie/cobielite"
xmlns="http://docs.buildingsmartalliance.org/nbims03/cobie/core"
xmlns:core="http://docs.buildingsmartalliance.org/nbims03/cobie/core"
core:externalEntityName="IfcBuilding" core:externalID="3eM8WbY_59RR5TDWry5aRU" core:externalSystemName="Autodesk Revit Architecture 2011" xsi:schemaLocation="http://docs.buildingsmartalliance.org/nbims03/cobie/cobielite cobielite.xsd" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
<FacilityName>PN 0001</FacilityName>
<FacilityCategory>11-13 24 14: Clinic</FacilityCategory> ... where FacilityName etc are implicitly in the core namespace. Regarding the issue: Looks to me that What's the origin of the last CobieLite file in your issue? it looks wrong... Change the |
Hi thanks for your answer! the last file in my issue is generated with xbim. If I change the namespace from core:Attribute to cobielite:Attribute it works fine as you suggest. In my first example (xml also generated with xbim) the core:Floor should also be cobielite:Floor as the FloorElevationValue only exists for cobielite (see xsd) and not in core. `
` I looked into your cobielite example file (Example File). There the attributes are also wrong marked with Also interiesting: XmlSerializationCode.cs |
Might need to loop in @CBenghi here as he touched this last (6 years ago!) - I'm not sure how that XmlSerialisationCode was generated - it doesn't look like standard xsd.exe generated code. @simiii Can you describe what the actual issue is, for you and which part of your process is failing. Just to help test any fix. If you feel like digging in and putting a PR together as well that would be great. Apart from updating/PRs, I've not really been that involved in this codebase. I believe it came out of the NBS BIM Toolkit project |
Hi all,
I can't recall having touched anything to do with the namespaces.
@andy Ward <[email protected]>, if you have had a look at the repository,
can you point me in the commit in question?
…On Wed, 16 Dec 2020 at 10:39, Andy Ward ***@***.***> wrote:
Might need to loop in @CBenghi <https://github.com/CBenghi> here as he
touched this last (6 years ago!) - I'm not sure how that
XmlSerialisationCode was generated - it doesn't look like standard xsd.exe
generated code.
@simiii <https://github.com/simiii> Can you describe what the actual
issue is, for you and which part of your process is failing. Just to help
test any fix. If you feel like digging in and putting a PR together as well
that would be great. Apart from updating/PRs, I've not really been that
involved in this codebase. I believe it came out of the NBS BIM Toolkit
project
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#56 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/ABJY7MJWV657JGQUO7VRFITSVB54RANCNFSM4UWZS7PA>
.
|
Hi Claudio It was a long while ago so appreciate it may be distant memory but it was this commit 548301f having looked at the full history it looks like you implemented the serialisation with No worries if you can't remember! |
I am trying to clarify my issue. I try to read an XML generated by XBIM with Java. I generated the Java-Classes with JAXB and the cobielite and core xsd files resulting in the classes below (simplified): org.buildingsmartalliance.docs.nbims03.cobie.core.FloorType:
org.buildingsmartalliance.docs.nbims03.cobie.cobielite:FloorType
Non processable XML generated by XBIM:
As you can see in the structure of the classes the attributes are only in org.buildingsmartalliance.docs.nbims03.cobie.cobielite.FloorType. If I read the XML generated by XBIM in JAVA, I only get the org.buildingsmartalliance.docs.nbims03.cobie.core.FloorType and not the subclass which results in the fact that I am unable to process the attributes in the floor. If I manually change the namespace of the Floor to cobielite in the xml generated with xbim I can read the XML and get the subclass and therefore can read the attributes of the floor. Processable XML generated by XBIM, manually edited:
|
Thanks @simiii, |
I should create a Pull Request, which you can do from Visual Studio. But to be fair we can reproduce from your |
In the zip file you find the Facility2.xml file. |
I am converting an IFC-File into COBieLite like this:
the generated XML-File looks like the following using the core-namespace for everything except the facility.
From the example clinik-file from https://www.nibs.org/page/bimc_cobielite I recognized that they use the cobielite-namespace instead of the core-namespace. Can I change the behaviour of the CoBieLiteHelper to use the cobielite-namespace? Is it a bug not using the cobielite-namespace as it provides more attributes for the elements in the xml?
Example: Can deserialize Attribute Value
Example: Cannot deserialize Attribute Value:
Thanks for your help,
Simon
The text was updated successfully, but these errors were encountered: