... | ... | @@ -22,7 +22,7 @@ Description of that service at [Building Physics Library Web Service](../Buildin |
|
|
2. Using External References in CityGML 2.0 and CityGML 2.0 EnergyADE
|
|
|
|
|
|
In general, CityGML 2.0 offers a mechanism to access internal and external data like attributes in a dataset via ```xlink```'s. These references are normally used to reference to another section in the same CityGML file or dataset but an ```xlink``` can also reference to an external data source.
|
|
|
Usually ```xlink```s are known to compose a surface from a set of (referenced) subsurfaces as in the following sample excerpt from a CityGML Building file:
|
|
|
Usually ```xlink```'s are known to compose a surface from a set of (referenced) subsurfaces as in the following sample excerpt from a CityGML Building file:
|
|
|
```xml
|
|
|
...
|
|
|
<bldg:lod2Solid>
|
... | ... | @@ -44,12 +44,12 @@ Description of that service at [Building Physics Library Web Service](../Buildin |
|
|
|
|
|
The same mechanism can be used with the EnergyADE as shown in the following example where the material properties of a construction reference to a material definition in some other part of the same CityGML file:
|
|
|
|
|
|
```xml
|
|
|
```xml
|
|
|
...
|
|
|
<gml:featureMember>
|
|
|
<energy:Construction gml:id="GML_1d95ee10-2b3e-424c-afce-6bc4ad6017d2">
|
|
|
<gml:description>Bau 05 Structure Facade (U-Value 1.105)</gml:description>
|
|
|
<gml:name>Bau05-Facade-SingleLayer</gml:name>
|
|
|
<gml:description>Structure Facade (U-Value 1.105)</gml:description>
|
|
|
<gml:name>Facade-SingleLayer</gml:name>
|
|
|
<energy:uValue uom="W/K*m2">1.105</energy:uValue>
|
|
|
<energy:layer>
|
|
|
<energy:Layer gml:id="GML_373c66c6-0b0d-4d76-9481-d61e65653e02">
|
... | ... | @@ -64,6 +64,7 @@ Description of that service at [Building Physics Library Web Service](../Buildin |
|
|
</energy:layer>
|
|
|
</energy:Construction>
|
|
|
</gml:featureMember>
|
|
|
|
|
|
...
|
|
|
<gml:featureMember>
|
|
|
<energy:SolidMaterial gml:id="GML_94749b5f-ee27-491b-a906-eea7da12e9a0">
|
... | ... | @@ -75,12 +76,56 @@ Description of that service at [Building Physics Library Web Service](../Buildin |
|
|
</energy:SolidMaterial>
|
|
|
</gml:featureMember>
|
|
|
...
|
|
|
```
|
|
|
|
|
|
```
|
|
|
For each non-leaf ```featureType``` an ```xlink``` referencing to is possible, replacing the reference to an internal attribute with an external URI, as shown in the folling example. The external URI must me valid and can be e.g. a reference to a file or a call to a web service returning a valid ```gml``` code fragment.
|
|
|
|
|
|
The internal ```xlink``` to the material with the gml:id ```GML_94749b5f-ee27-491b-a906-eea7da12e9a0```
|
|
|
```xml
|
|
|
...
|
|
|
<energy:Layer gml:id="GML_373c66c6-0b0d-4d76-9481-d61e65653e02">
|
|
|
<energy:layerComponent>
|
|
|
<energy:LayerComponent gml:id="GML_e5e4790b-1b4c-47de-88ae-fdac359a7906">
|
|
|
<energy:areaFraction uom="scale">1</energy:areaFraction>
|
|
|
<energy:thickness uom="m">0.40</energy:thickness>
|
|
|
<energy:material xlink:href="#GML_94749b5f-ee27-491b-a906-eea7da12e9a0"/>
|
|
|
</energy:LayerComponent>
|
|
|
</energy:layerComponent>
|
|
|
</energy:Layer>
|
|
|
...
|
|
|
```
|
|
|
can be replaced with an external ```xlink``` e.g. to an XML file containing valid material properties conforming to the EnergyADE, as shown in the following example
|
|
|
```xml
|
|
|
...
|
|
|
<energy:Layer gml:id="GML_373c66c6-0b0d-4d76-9481-d61e65653e02">
|
|
|
<energy:layerComponent>
|
|
|
<energy:LayerComponent gml:id="GML_e5e4790b-1b4c-47de-88ae-fdac359a7906">
|
|
|
<energy:areaFraction uom="scale">1</energy:areaFraction>
|
|
|
<energy:thickness uom="m">0.40</energy:thickness>
|
|
|
<energy:material xlink:href="file:///some-local-directory/concrete-facade.xml"/>
|
|
|
</energy:LayerComponent>
|
|
|
</energy:layerComponent>
|
|
|
</energy:Layer>
|
|
|
...
|
|
|
```
|
|
|
or with an external ```xlink``` e.g. to a web service returning valid material properties conforming to the EnergyADE, as shown in the following example
|
|
|
```xml
|
|
|
...
|
|
|
<energy:Layer gml:id="GML_373c66c6-0b0d-4d76-9481-d61e65653e02">
|
|
|
<energy:layerComponent>
|
|
|
<energy:LayerComponent gml:id="GML_e5e4790b-1b4c-47de-88ae-fdac359a7906">
|
|
|
<energy:areaFraction uom="scale">1</energy:areaFraction>
|
|
|
<energy:thickness uom="m">0.40</energy:thickness>
|
|
|
<energy:material xlink:href="http://some.web.server/building_library/germany?material=concrete-facade"/>
|
|
|
</energy:LayerComponent>
|
|
|
</energy:layerComponent>
|
|
|
</energy:Layer>
|
|
|
...
|
|
|
```
|
|
|
Note: the use of external ```xlink```'s must be supported by the CityGML parser of the used application, e.g. the use of external ```xlink```'s is currently not supported in the 3DCityDB
|
|
|
|
|
|
3. Using Generic Attributes as References in Native CityGML 2.0
|
|
|
|
|
|
Alternatively you can use ```genericAttribute```'s in a generic CityGML file to define correlations between
|
|
|
Generic Attribute - UML Diagram
|
|
|
|
|
|
```mermaid
|
... | ... | |