Commit 96d46e05 authored by Rushikesh Padsala's avatar Rushikesh Padsala
Browse files

Updated to Energy ADE 3 beta 7 - version 0.2

parent 06a2b146
energy-ade-2-citydb
\ No newline at end of file
energy-ade-3-citydb
\ No newline at end of file
......@@ -7,10 +7,10 @@
<compositeConfiguration>
<compositeBuild compositeDefinitionSource="SCRIPT">
<builds>
<build path="$PROJECT_DIR$/../energy-ade-2-citygml4j" name="energy-ade-2-citygml4j">
<build path="$PROJECT_DIR$/../energy-ade-3-citygml4j" name="energy-ade-3-citygml4j">
<projects>
<project path="$PROJECT_DIR$/../energy-ade-2-citygml4j" />
<project path="$PROJECT_DIR$/../energy-ade-2-citygml4j/energy-ade-samples" />
<project path="$PROJECT_DIR$/../energy-ade-3-citygml4j" />
<project path="$PROJECT_DIR$/../energy-ade-3-citygml4j/energy-ade-samples" />
</projects>
</build>
</builds>
......@@ -21,8 +21,8 @@
<option name="modules">
<set>
<option value="$PROJECT_DIR$" />
<option value="$PROJECT_DIR$/../energy-ade-2-citygml4j" />
<option value="$PROJECT_DIR$/../energy-ade-2-citygml4j/energy-ade-samples" />
<option value="$PROJECT_DIR$/../energy-ade-3-citygml4j" />
<option value="$PROJECT_DIR$/../energy-ade-3-citygml4j/energy-ade-samples" />
</set>
</option>
</GradleProjectSettings>
......
......@@ -3,8 +3,9 @@
<component name="ExternalStorageConfigurationManager" enabled="true" />
<component name="FrameworkDetectionExcludesConfiguration">
<file type="web" url="file://$PROJECT_DIR$/../digitwins4peds" />
<file type="web" url="file://$PROJECT_DIR$" />
<file type="web" url="file://$PROJECT_DIR$/../energy-ade-2-citygml4j" />
<file type="web" url="file://$PROJECT_DIR$" />
<file type="web" url="file://$PROJECT_DIR$/../energy-ade-3-citygml4j" />
</component>
<component name="ProjectRootManager" version="2" languageLevel="JDK_17" default="true" project-jdk-name="liberica-17" project-jdk-type="JavaSDK">
<output url="file://$PROJECT_DIR$/out" />
......
......@@ -2,6 +2,6 @@
<project version="4">
<component name="VcsDirectoryMappings">
<mapping directory="" vcs="Git" />
<mapping directory="$PROJECT_DIR$/../energy-ade-2-citygml4j" vcs="Git" />
<mapping directory="$PROJECT_DIR$/../energy-ade-3-citygml4j" vcs="Git" />
</component>
</project>
\ No newline at end of file
......@@ -12,12 +12,12 @@ Currently, there are _no plans to migrate_ the Energy ADE 3 importer-exporter AP
The following modules are supported at the moment:
- Core (AbstractBuilding, Refurbishment Measures)
- Core (AbstractBuilding, RefurbishmentMeasures, WeatherData)
- Resource
- UrbanFunctionArea
- WeatherStation
- Timeseries
- DataTypes
- DataTypes (AbstractQualifiedAttribute)
The following modules are currently in development:
......@@ -27,6 +27,7 @@ The following modules are currently in development:
- LayeredConstruction
- Schedule
- Devices
- DataTypes (AbstractOpticalProperties)
# Release
......
......@@ -8,8 +8,8 @@ plugins {
}
group = 'de.stuttgart.hft'
version = 'beta7-0.1'
description 'Energy ADE 3 (beta 7) extension for the 3DCityDB - release 0.1'
version = 'beta7-0.2'
description 'Energy ADE 3 (beta 7) extension for the 3DCityDB - release 0.2'
repositories {
maven {
......@@ -28,9 +28,9 @@ configurations {
dependencies {
api 'org.citydb:impexp-client-gui:5.5.1'
api 'org.citygml4j.ade:energy-ade-3-citygml4j:3.0.1'
api 'org.citygml4j.ade:energy-ade-3-citygml4j:3.0.2'
citygml4j('org.citygml4j.ade:energy-ade-3-citygml4j:3.0.1') {
citygml4j('org.citygml4j.ade:energy-ade-3-citygml4j:3.0.2') {
transitive = false
}
......
-- ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
-- ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
--
-- CityGML Energy ADE 2.0 (beta 7)
-- CityGML Energy ADE 3.0 (beta 7)
--
-- Last update: 2025-06-25
-- Last update: 2025-10-14
--
-- This DDL script installs the 3DCityDB schema for the Energy ADE 2.0. It must be run
-- This DDL script installs the 3DCityDB schema for the Energy ADE. It must be run
-- from within the ADE Manager plugin of the 3DCityDB Importer/Exporter.
--
-- This script was first automatically generated using the 3DCityDB ADE Manager
......@@ -26,28 +26,28 @@
-- *********************************** Create Sequences ***********************************
-- ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
CREATE SEQUENCE ng2_ctyobj_relation_seq INCREMENT BY 1 MINVALUE 0 MAXVALUE 9223372036854775807 START WITH 1 CACHE 1 NO CYCLE OWNED BY NONE;
CREATE SEQUENCE ng2_optical_property_seq INCREMENT BY 1 MINVALUE 0 MAXVALUE 9223372036854775807 START WITH 1 CACHE 1 NO CYCLE OWNED BY NONE;
CREATE SEQUENCE ng2_qualified_attribute_seq INCREMENT BY 1 MINVALUE 0 MAXVALUE 9223372036854775807 START WITH 1 CACHE 1 NO CYCLE OWNED BY NONE;
CREATE SEQUENCE ng2_suitability_seq INCREMENT BY 1 MINVALUE 0 MAXVALUE 9223372036854775807 START WITH 1 CACHE 1 NO CYCLE OWNED BY NONE;
CREATE SEQUENCE ng3_ctyobj_relation_seq INCREMENT BY 1 MINVALUE 0 MAXVALUE 9223372036854775807 START WITH 1 CACHE 1 NO CYCLE OWNED BY NONE;
CREATE SEQUENCE ng3_optical_property_seq INCREMENT BY 1 MINVALUE 0 MAXVALUE 9223372036854775807 START WITH 1 CACHE 1 NO CYCLE OWNED BY NONE;
CREATE SEQUENCE ng3_qualified_attribute_seq INCREMENT BY 1 MINVALUE 0 MAXVALUE 9223372036854775807 START WITH 1 CACHE 1 NO CYCLE OWNED BY NONE;
CREATE SEQUENCE ng3_suitability_seq INCREMENT BY 1 MINVALUE 0 MAXVALUE 9223372036854775807 START WITH 1 CACHE 1 NO CYCLE OWNED BY NONE;
-- ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
-- *********************************** Create tables **************************************
-- ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
-- --------------------------------------------------------------------
-- ng2_address_to_building_unit
-- ng3_address_to_building_unit
-- --------------------------------------------------------------------
CREATE TABLE ng2_address_to_building_unit (
CREATE TABLE ng3_address_to_building_unit (
address_id BIGINT NOT NULL,
building_unit_id BIGINT NOT NULL,
PRIMARY KEY (address_id, building_unit_id)
);
-- --------------------------------------------------------------------
-- ng2_building - extends building table
-- ng3_building - extends building table
-- --------------------------------------------------------------------
CREATE TABLE ng2_building (
CREATE TABLE ng3_building (
id BIGINT PRIMARY KEY,
type VARCHAR,
type_codespace VARCHAR,
......@@ -59,9 +59,9 @@ CREATE TABLE ng2_building (
);
-- --------------------------------------------------------------------
-- ng2_building_partition
-- ng3_building_partition
-- --------------------------------------------------------------------
CREATE TABLE ng2_building_partition (
CREATE TABLE ng3_building_partition (
id BIGINT PRIMARY KEY,
objectclass_id INTEGER,
-- Thermal Zone attributes
......@@ -109,21 +109,21 @@ CREATE TABLE ng2_building_partition (
);
-- --------------------------------------------------------------------
-- ng2_cityobject - extends cityobject table
-- ng3_cityobject - extends cityobject table
-- --------------------------------------------------------------------
CREATE TABLE ng2_cityobject (
CREATE TABLE ng3_cityobject (
id BIGINT PRIMARY KEY,
layered_construction_id BIGINT,
ref_point geometry(POINTZ)
);
-- --------------------------------------------------------------------
-- ng2_ctyobj_relation
-- ng3_ctyobj_relation
-- --------------------------------------------------------------------
CREATE TABLE ng2_ctyobj_relation (
id BIGINT PRIMARY KEY DEFAULT nextval('ng2_ctyobj_relation_seq'::regclass),
-- this refers to ng2_cityobject (id), i.e. the source
ng2_cityobject_id BIGINT,
CREATE TABLE ng3_ctyobj_relation (
id BIGINT PRIMARY KEY DEFAULT nextval('ng3_ctyobj_relation_seq'::regclass),
-- this refers to ng3_cityobject (id), i.e. the source
ng3_cityobject_id BIGINT,
-- this refers to cityobject (id), i.e. the target
cityobject_id BIGINT,
relation_type VARCHAR,
......@@ -131,9 +131,9 @@ CREATE TABLE ng2_ctyobj_relation (
);
-- --------------------------------------------------------------------
-- ng2_device
-- ng3_device
-- --------------------------------------------------------------------
CREATE TABLE ng2_device (
CREATE TABLE ng3_device (
id BIGINT PRIMARY KEY,
objectclass_id INTEGER,
-- AbstractDevice attributes (also for LightingDevice, GenericDevice, GenericElectricalDevice)
......@@ -173,9 +173,9 @@ CREATE TABLE ng2_device (
);
-- --------------------------------------------------------------------
-- ng2_device_operation
-- ng3_device_operation
-- --------------------------------------------------------------------
CREATE TABLE ng2_device_operation (
CREATE TABLE ng3_device_operation (
id BIGINT PRIMARY KEY,
type VARCHAR,
type_codespace VARCHAR,
......@@ -186,9 +186,9 @@ CREATE TABLE ng2_device_operation (
);
-- --------------------------------------------------------------------
-- ng2_energy_perf_cert
-- ng3_energy_perf_cert
-- --------------------------------------------------------------------
CREATE TABLE ng2_energy_perf_cert (
CREATE TABLE ng3_energy_perf_cert (
id BIGINT PRIMARY KEY,
type VARCHAR,
type_codespace VARCHAR,
......@@ -205,9 +205,9 @@ CREATE TABLE ng2_energy_perf_cert (
);
-- --------------------------------------------------------------------
-- ng2_layer
-- ng3_layer
-- --------------------------------------------------------------------
CREATE TABLE ng2_layer (
CREATE TABLE ng3_layer (
id BIGINT PRIMARY KEY,
thickness NUMERIC,
thickness_uom VARCHAR,
......@@ -217,9 +217,9 @@ CREATE TABLE ng2_layer (
);
-- --------------------------------------------------------------------
-- ng2_layered_construction
-- ng3_layered_construction
-- --------------------------------------------------------------------
CREATE TABLE ng2_layered_construction (
CREATE TABLE ng3_layered_construction (
id BIGINT PRIMARY KEY,
objectclass_id INTEGER,
u_value NUMERIC,
......@@ -236,9 +236,9 @@ CREATE TABLE ng2_layered_construction (
);
-- --------------------------------------------------------------------
-- ng2_library
-- ng3_library
-- --------------------------------------------------------------------
CREATE TABLE ng2_library (
CREATE TABLE ng3_library (
id BIGINT PRIMARY KEY,
objectclass_id INTEGER,
type VARCHAR,
......@@ -248,9 +248,9 @@ CREATE TABLE ng2_library (
);
-- --------------------------------------------------------------------
-- ng2_material
-- ng3_material
-- --------------------------------------------------------------------
CREATE TABLE ng2_material (
CREATE TABLE ng3_material (
id BIGINT PRIMARY KEY,
objectclass_id INTEGER,
-- Abstract library attributes
......@@ -280,9 +280,9 @@ CREATE TABLE ng2_material (
);
-- --------------------------------------------------------------------
-- ng2_occupants
-- ng3_occupants
-- --------------------------------------------------------------------
CREATE TABLE ng2_occupants (
CREATE TABLE ng3_occupants (
id BIGINT PRIMARY KEY,
type VARCHAR,
type_codespace VARCHAR,
......@@ -307,9 +307,9 @@ CREATE TABLE ng2_occupants (
);
-- --------------------------------------------------------------------
-- ng2_opening - extends (building) opening table
-- ng3_opening - extends (building) opening table
-- --------------------------------------------------------------------
CREATE TABLE ng2_opening (
CREATE TABLE ng3_opening (
id BIGINT PRIMARY KEY,
area NUMERIC,
area_uom VARCHAR,
......@@ -324,10 +324,10 @@ CREATE TABLE ng2_opening (
);
-- --------------------------------------------------------------------
-- ng2_optical_property
-- ng3_optical_property
-- --------------------------------------------------------------------
CREATE TABLE ng2_optical_property (
id BIGINT PRIMARY KEY DEFAULT nextval('ng2_optical_property_seq'::regclass),
CREATE TABLE ng3_optical_property (
id BIGINT PRIMARY KEY DEFAULT nextval('ng3_optical_property_seq'::regclass),
objectclass_id INTEGER,
fraction NUMERIC,
fraction_uom VARCHAR,
......@@ -338,10 +338,10 @@ CREATE TABLE ng2_optical_property (
);
-- --------------------------------------------------------------------
-- ng2_qualified_attribute
-- ng3_qualified_attribute
-- --------------------------------------------------------------------
CREATE TABLE ng2_qualified_attribute (
id BIGINT PRIMARY KEY DEFAULT nextval('ng2_qualified_attribute_seq'::regclass),
CREATE TABLE ng3_qualified_attribute (
id BIGINT PRIMARY KEY DEFAULT nextval('ng3_qualified_attribute_seq'::regclass),
objectclass_id INTEGER,
type VARCHAR,
type_codespace VARCHAR,
......@@ -355,9 +355,9 @@ CREATE TABLE ng2_qualified_attribute (
);
-- --------------------------------------------------------------------
-- ng2_refurbishment_measure
-- ng3_refurbishment_measure
-- --------------------------------------------------------------------
CREATE TABLE ng2_refurbishment_measure (
CREATE TABLE ng3_refurbishment_measure (
id BIGINT PRIMARY KEY,
type VARCHAR,
type_codespace VARCHAR,
......@@ -371,9 +371,9 @@ CREATE TABLE ng2_refurbishment_measure (
);
-- --------------------------------------------------------------------
-- ng2_resource
-- ng3_resource
-- --------------------------------------------------------------------
CREATE TABLE ng2_resource (
CREATE TABLE ng3_resource (
id BIGINT PRIMARY KEY,
objectclass_id INTEGER,
type VARCHAR,
......@@ -414,9 +414,9 @@ CREATE TABLE ng2_resource (
);
-- --------------------------------------------------------------------
-- ng2_schedule
-- ng3_schedule
-- --------------------------------------------------------------------
CREATE TABLE ng2_schedule (
CREATE TABLE ng3_schedule (
id BIGINT PRIMARY KEY,
objectclass_id INTEGER,
library_code VARCHAR,
......@@ -447,9 +447,9 @@ CREATE TABLE ng2_schedule (
);
-- --------------------------------------------------------------------
-- ng2_schedule_component
-- ng3_schedule_component
-- --------------------------------------------------------------------
CREATE TABLE ng2_schedule_component (
CREATE TABLE ng3_schedule_component (
id BIGINT PRIMARY KEY,
type VARCHAR,
type_codespace VARCHAR,
......@@ -464,9 +464,9 @@ CREATE TABLE ng2_schedule_component (
);
-- --------------------------------------------------------------------
-- ng2_solar_collector
-- ng3_solar_collector
-- --------------------------------------------------------------------
CREATE TABLE ng2_solar_collector (
CREATE TABLE ng3_solar_collector (
id BIGINT PRIMARY KEY,
objectclass_id INTEGER,
type VARCHAR,
......@@ -491,9 +491,9 @@ CREATE TABLE ng2_solar_collector (
);
-- --------------------------------------------------------------------
-- ng2_storage_device
-- ng3_storage_device
-- --------------------------------------------------------------------
CREATE TABLE ng2_storage_device (
CREATE TABLE ng3_storage_device (
id BIGINT PRIMARY KEY,
objectclass_id INTEGER,
medium VARCHAR,
......@@ -511,10 +511,10 @@ CREATE TABLE ng2_storage_device (
);
-- --------------------------------------------------------------------
-- ng2_suitability
-- ng3_suitability
-- --------------------------------------------------------------------
CREATE TABLE ng2_suitability (
id BIGINT PRIMARY KEY DEFAULT nextval('ng2_suitability_seq'::regclass),
CREATE TABLE ng3_suitability (
id BIGINT PRIMARY KEY DEFAULT nextval('ng3_suitability_seq'::regclass),
reason VARCHAR,
reason_codespace VARCHAR,
value NUMERIC,
......@@ -526,18 +526,18 @@ CREATE TABLE ng2_suitability (
);
-- --------------------------------------------------------------------
-- ng2_them_surf_to_thermal_zone
-- ng3_them_surf_to_thermal_zone
-- --------------------------------------------------------------------
CREATE TABLE ng2_them_surf_to_thermal_zone (
CREATE TABLE ng3_them_surf_to_thermal_zone (
thematic_surface_id BIGINT NOT NULL,
thermal_zone_id BIGINT NOT NULL,
PRIMARY KEY (thematic_surface_id, thermal_zone_id)
);
-- --------------------------------------------------------------------
-- ng2_thematic_surface - extends (building) thematic_surface table
-- ng3_thematic_surface - extends (building) thematic_surface table
-- --------------------------------------------------------------------
CREATE TABLE ng2_thematic_surface (
CREATE TABLE ng3_thematic_surface (
id BIGINT PRIMARY KEY,
total_surf_area NUMERIC,
total_surf_area_uom VARCHAR,
......@@ -561,9 +561,9 @@ CREATE TABLE ng2_thematic_surface (
);
-- --------------------------------------------------------------------
-- ng2_time_series
-- ng3_time_series
-- --------------------------------------------------------------------
CREATE TABLE ng2_time_series (
CREATE TABLE ng3_time_series (
id BIGINT PRIMARY KEY,
objectclass_id INTEGER,
-- AbstractTieSeries attributes
......@@ -611,9 +611,9 @@ CREATE TABLE ng2_time_series (
);
-- --------------------------------------------------------------------
-- ng2_urban_function_area
-- ng3_urban_function_area
-- --------------------------------------------------------------------
CREATE TABLE ng2_urban_function_area (
CREATE TABLE ng3_urban_function_area (
id BIGINT PRIMARY KEY,
type VARCHAR,
type_codespace VARCHAR,
......@@ -622,9 +622,9 @@ CREATE TABLE ng2_urban_function_area (
);
-- --------------------------------------------------------------------
-- ng2_utl_ntw_connection
-- ng3_utl_ntw_connection
-- --------------------------------------------------------------------
CREATE TABLE ng2_utl_ntw_connection (
CREATE TABLE ng3_utl_ntw_connection (
id BIGINT PRIMARY KEY,
network_type VARCHAR,
network_type_codespace VARCHAR,
......@@ -640,9 +640,9 @@ CREATE TABLE ng2_utl_ntw_connection (
);
-- --------------------------------------------------------------------
-- ng2_weather_data
-- ng3_weather_data
-- --------------------------------------------------------------------
CREATE TABLE ng2_weather_data (
CREATE TABLE ng3_weather_data (
id BIGINT PRIMARY KEY,
type VARCHAR,
type_codespace VARCHAR,
......@@ -664,201 +664,201 @@ CREATE TABLE ng2_weather_data (
-- ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
-- --------------------------------------------------------------------
-- ng2_address_to_building_unit
-- ng3_address_to_building_unit
-- --------------------------------------------------------------------
ALTER TABLE ng2_address_to_building_unit ADD CONSTRAINT ng2_addr_to_bdgu_fk1 FOREIGN KEY (address_id) REFERENCES address (id) ON DELETE CASCADE;
ALTER TABLE ng2_address_to_building_unit ADD CONSTRAINT ng2_addr_to_bdgu_fk2 FOREIGN KEY (building_unit_id) REFERENCES ng2_building_partition (id) ON DELETE CASCADE;
ALTER TABLE ng3_address_to_building_unit ADD CONSTRAINT ng3_addr_to_bdgu_fk1 FOREIGN KEY (address_id) REFERENCES address (id) ON DELETE CASCADE;
ALTER TABLE ng3_address_to_building_unit ADD CONSTRAINT ng3_addr_to_bdgu_fk2 FOREIGN KEY (building_unit_id) REFERENCES ng3_building_partition (id) ON DELETE CASCADE;
-- --------------------------------------------------------------------
-- ng2_building
-- ng3_building
-- --------------------------------------------------------------------
ALTER TABLE ng2_building ADD CONSTRAINT ng2_bdg_fk FOREIGN KEY (id) REFERENCES building (id);
ALTER TABLE ng3_building ADD CONSTRAINT ng3_bdg_fk FOREIGN KEY (id) REFERENCES building (id);
-- --------------------------------------------------------------------
-- ng2_building_partition
-- ng3_building_partition
-- --------------------------------------------------------------------
ALTER TABLE ng2_building_partition ADD CONSTRAINT ng2_bdgp_fk FOREIGN KEY (id) REFERENCES cityobject (id);
ALTER TABLE ng2_building_partition ADD CONSTRAINT ng2_bdgp_oc_fk FOREIGN KEY (objectclass_id) REFERENCES objectclass (id);
ALTER TABLE ng2_building_partition ADD CONSTRAINT ng2_bdgp_lod1_fk FOREIGN KEY (lod1_solid_id) REFERENCES surface_geometry (id);
ALTER TABLE ng2_building_partition ADD CONSTRAINT ng2_bdgp_lod2_fk FOREIGN KEY (lod2_solid_id) REFERENCES surface_geometry (id);
ALTER TABLE ng2_building_partition ADD CONSTRAINT ng2_bdgp_lod3_fk FOREIGN KEY (lod3_solid_id) REFERENCES surface_geometry (id);
ALTER TABLE ng2_building_partition ADD CONSTRAINT ng2_bdgp_uz_fk FOREIGN KEY (usage_zone_id) REFERENCES ng2_building_partition (id) ON DELETE SET NULL;
ALTER TABLE ng2_building_partition ADD CONSTRAINT ng2_bdgp_tz_fk FOREIGN KEY (thermal_zone_id) REFERENCES ng2_building_partition (id) ON DELETE SET NULL;
ALTER TABLE ng2_building_partition ADD CONSTRAINT ng2_bdgp_bdg_fk FOREIGN KEY (building_id) REFERENCES ng2_building (id);
ALTER TABLE ng2_building_partition ADD CONSTRAINT ng2_bdgp_sched_fk1 FOREIGN KEY (cooling_schedule_id) REFERENCES ng2_schedule (id) ON DELETE SET NULL;
ALTER TABLE ng2_building_partition ADD CONSTRAINT ng2_bdgp_sched_fk2 FOREIGN KEY (heating_schedule_id) REFERENCES ng2_schedule (id) ON DELETE SET NULL;
ALTER TABLE ng2_building_partition ADD CONSTRAINT ng2_bdgp_sched_fk3 FOREIGN KEY (ventilation_schedule_id) REFERENCES ng2_schedule (id) ON DELETE SET NULL;
ALTER TABLE ng3_building_partition ADD CONSTRAINT ng3_bdgp_fk FOREIGN KEY (id) REFERENCES cityobject (id);
ALTER TABLE ng3_building_partition ADD CONSTRAINT ng3_bdgp_oc_fk FOREIGN KEY (objectclass_id) REFERENCES objectclass (id);
ALTER TABLE ng3_building_partition ADD CONSTRAINT ng3_bdgp_lod1_fk FOREIGN KEY (lod1_solid_id) REFERENCES surface_geometry (id);
ALTER TABLE ng3_building_partition ADD CONSTRAINT ng3_bdgp_lod2_fk FOREIGN KEY (lod2_solid_id) REFERENCES surface_geometry (id);
ALTER TABLE ng3_building_partition ADD CONSTRAINT ng3_bdgp_lod3_fk FOREIGN KEY (lod3_solid_id) REFERENCES surface_geometry (id);
ALTER TABLE ng3_building_partition ADD CONSTRAINT ng3_bdgp_uz_fk FOREIGN KEY (usage_zone_id) REFERENCES ng3_building_partition (id) ON DELETE SET NULL;
ALTER TABLE ng3_building_partition ADD CONSTRAINT ng3_bdgp_tz_fk FOREIGN KEY (thermal_zone_id) REFERENCES ng3_building_partition (id) ON DELETE SET NULL;
ALTER TABLE ng3_building_partition ADD CONSTRAINT ng3_bdgp_bdg_fk FOREIGN KEY (building_id) REFERENCES ng3_building (id);
ALTER TABLE ng3_building_partition ADD CONSTRAINT ng3_bdgp_sched_fk1 FOREIGN KEY (cooling_schedule_id) REFERENCES ng3_schedule (id) ON DELETE SET NULL;
ALTER TABLE ng3_building_partition ADD CONSTRAINT ng3_bdgp_sched_fk2 FOREIGN KEY (heating_schedule_id) REFERENCES ng3_schedule (id) ON DELETE SET NULL;
ALTER TABLE ng3_building_partition ADD CONSTRAINT ng3_bdgp_sched_fk3 FOREIGN KEY (ventilation_schedule_id) REFERENCES ng3_schedule (id) ON DELETE SET NULL;
-- --------------------------------------------------------------------
-- ng2_cityobject
-- ng3_cityobject
-- --------------------------------------------------------------------
ALTER TABLE ng2_cityobject ADD CONSTRAINT ng2_cto_fk FOREIGN KEY (id) REFERENCES cityobject (id);
ALTER TABLE ng2_cityobject ADD CONSTRAINT ng2_cto_lcns_fk FOREIGN KEY (layered_construction_id) REFERENCES ng2_layered_construction (id) ON DELETE SET NULL;
ALTER TABLE ng3_cityobject ADD CONSTRAINT ng3_cto_fk FOREIGN KEY (id) REFERENCES cityobject (id);
ALTER TABLE ng3_cityobject ADD CONSTRAINT ng3_cto_lcns_fk FOREIGN KEY (layered_construction_id) REFERENCES ng3_layered_construction (id) ON DELETE SET NULL;
-- --------------------------------------------------------------------
-- ng2_ctyobj_relation
-- ng3_ctyobj_relation
-- --------------------------------------------------------------------
ALTER TABLE ng2_ctyobj_relation ADD CONSTRAINT ng2_cto_rel_fk2 FOREIGN KEY (cityobject_id) REFERENCES cityobject (id) ON DELETE SET NULL;
ALTER TABLE ng2_ctyobj_relation ADD CONSTRAINT ng2_cto_rel_fk1 FOREIGN KEY (ng2_cityobject_id) REFERENCES ng2_cityobject (id);
ALTER TABLE ng3_ctyobj_relation ADD CONSTRAINT ng3_cto_rel_fk2 FOREIGN KEY (cityobject_id) REFERENCES cityobject (id) ON DELETE SET NULL;
ALTER TABLE ng3_ctyobj_relation ADD CONSTRAINT ng3_cto_rel_fk1 FOREIGN KEY (ng3_cityobject_id) REFERENCES ng3_cityobject (id);
-- --------------------------------------------------------------------
-- ng2_device
-- ng3_device
-- --------------------------------------------------------------------
ALTER TABLE ng2_device ADD CONSTRAINT ng2_dev_fk FOREIGN KEY (id) REFERENCES cityobject (id);
ALTER TABLE ng2_device ADD CONSTRAINT ng2_dev_oc_fk FOREIGN KEY (objectclass_id) REFERENCES objectclass (id);
ALTER TABLE ng2_device ADD CONSTRAINT ng2_dev_opt_fk FOREIGN KEY (transmittance_id) REFERENCES ng2_optical_property (id) ON DELETE SET NULL;
ALTER TABLE ng2_device ADD CONSTRAINT ng2_dev_ng2_cto_fk FOREIGN KEY (cityobject_id) REFERENCES ng2_cityobject (id) ON DELETE SET NULL;
ALTER TABLE ng3_device ADD CONSTRAINT ng3_dev_fk FOREIGN KEY (id) REFERENCES cityobject (id);
ALTER TABLE ng3_device ADD CONSTRAINT ng3_dev_oc_fk FOREIGN KEY (objectclass_id) REFERENCES objectclass (id);
ALTER TABLE ng3_device ADD CONSTRAINT ng3_dev_opt_fk FOREIGN KEY (transmittance_id) REFERENCES ng3_optical_property (id) ON DELETE SET NULL;
ALTER TABLE ng3_device ADD CONSTRAINT ng3_dev_ng3_cto_fk FOREIGN KEY (cityobject_id) REFERENCES ng3_cityobject (id) ON DELETE SET NULL;
-- --------------------------------------------------------------------
-- ng2_device_operation
-- ng3_device_operation
-- --------------------------------------------------------------------
ALTER TABLE ng2_device_operation ADD CONSTRAINT ng2_dev_opr_fk FOREIGN KEY (id) REFERENCES cityobject (id);
ALTER TABLE ng2_device_operation ADD CONSTRAINT ng2_dev_opr_sched_fk FOREIGN KEY (schedule_id) REFERENCES ng2_schedule (id) ON DELETE SET NULL;
ALTER TABLE ng2_device_operation ADD CONSTRAINT ng2_dev_opr_dev_fk FOREIGN KEY (device_id) REFERENCES ng2_device (id) ON DELETE SET NULL;
ALTER TABLE ng3_device_operation ADD CONSTRAINT ng3_dev_opr_fk FOREIGN KEY (id) REFERENCES cityobject (id);
ALTER TABLE ng3_device_operation ADD CONSTRAINT ng3_dev_opr_sched_fk FOREIGN KEY (schedule_id) REFERENCES ng3_schedule (id) ON DELETE SET NULL;
ALTER TABLE ng3_device_operation ADD CONSTRAINT ng3_dev_opr_dev_fk FOREIGN KEY (device_id) REFERENCES ng3_device (id) ON DELETE SET NULL;
-- --------------------------------------------------------------------
-- ng2_energy_perf_cert
-- ng3_energy_perf_cert
-- --------------------------------------------------------------------
ALTER TABLE ng2_energy_perf_cert ADD CONSTRAINT ng2_epc_fk FOREIGN KEY (id) REFERENCES cityobject (id);
ALTER TABLE ng2_energy_perf_cert ADD CONSTRAINT ng2_epc_bdg_fk FOREIGN KEY (building_id) REFERENCES ng2_building (id) ON DELETE SET NULL;
ALTER TABLE ng2_energy_perf_cert ADD CONSTRAINT ng2_epc_bdg_part_fk FOREIGN KEY (building_partition_id) REFERENCES ng2_building_partition (id) ON DELETE SET NULL;
ALTER TABLE ng3_energy_perf_cert ADD CONSTRAINT ng3_epc_fk FOREIGN KEY (id) REFERENCES cityobject (id);
ALTER TABLE ng3_energy_perf_cert ADD CONSTRAINT ng3_epc_bdg_fk FOREIGN KEY (building_id) REFERENCES ng3_building (id) ON DELETE SET NULL;
ALTER TABLE ng3_energy_perf_cert ADD CONSTRAINT ng3_epc_bdg_part_fk FOREIGN KEY (building_partition_id) REFERENCES ng3_building_partition (id) ON DELETE SET NULL;
-- --------------------------------------------------------------------
-- ng2_layer
-- ng3_layer
-- --------------------------------------------------------------------
ALTER TABLE ng2_layer ADD CONSTRAINT ng2_lyr_fk FOREIGN KEY (id) REFERENCES cityobject (id);
ALTER TABLE ng2_layer ADD CONSTRAINT ng2_lyr_mat_fk FOREIGN KEY (material_id) REFERENCES ng2_material (id) ON DELETE SET NULL;
ALTER TABLE ng2_layer ADD CONSTRAINT ng2_lyr_lcns_fk FOREIGN KEY (layered_construction_id) REFERENCES ng2_layered_construction (id) ON DELETE SET NULL;
ALTER TABLE ng3_layer ADD CONSTRAINT ng3_lyr_fk FOREIGN KEY (id) REFERENCES cityobject (id);
ALTER TABLE ng3_layer ADD CONSTRAINT ng3_lyr_mat_fk FOREIGN KEY (material_id) REFERENCES ng3_material (id) ON DELETE SET NULL;
ALTER TABLE ng3_layer ADD CONSTRAINT ng3_lyr_lcns_fk FOREIGN KEY (layered_construction_id) REFERENCES ng3_layered_construction (id) ON DELETE SET NULL;
-- --------------------------------------------------------------------
-- ng2_layered_construction
-- ng3_layered_construction
-- --------------------------------------------------------------------
ALTER TABLE ng2_layered_construction ADD CONSTRAINT ng2_lcns_fk FOREIGN KEY (id) REFERENCES cityobject (id);
ALTER TABLE ng2_layered_construction ADD CONSTRAINT ng2_lcns_oc_fk FOREIGN KEY (objectclass_id) REFERENCES objectclass (id);
ALTER TABLE ng2_layered_construction ADD CONSTRAINT ng2_lcns_lcns_fk FOREIGN KEY (layered_construction_id) REFERENCES ng2_layered_construction (id) ON DELETE SET NULL;
ALTER TABLE ng2_layered_construction ADD CONSTRAINT ng2_lcns_lib_fk FOREIGN KEY (library_id) REFERENCES ng2_library (id) ON DELETE SET NULL;
ALTER TABLE ng3_layered_construction ADD CONSTRAINT ng3_lcns_fk FOREIGN KEY (id) REFERENCES cityobject (id);
ALTER TABLE ng3_layered_construction ADD CONSTRAINT ng3_lcns_oc_fk FOREIGN KEY (objectclass_id) REFERENCES objectclass (id);
ALTER TABLE ng3_layered_construction ADD CONSTRAINT ng3_lcns_lcns_fk FOREIGN KEY (layered_construction_id) REFERENCES ng3_layered_construction (id) ON DELETE SET NULL;
ALTER TABLE ng3_layered_construction ADD CONSTRAINT ng3_lcns_lib_fk FOREIGN KEY (library_id) REFERENCES ng3_library (id) ON DELETE SET NULL;
-- --------------------------------------------------------------------
-- ng2_library
-- ng3_library
-- --------------------------------------------------------------------
ALTER TABLE ng2_library ADD CONSTRAINT ng2_lib_fk FOREIGN KEY (id) REFERENCES cityobject (id);
ALTER TABLE ng2_library ADD CONSTRAINT ng2_lib_oc_fk FOREIGN KEY (objectclass_id) REFERENCES objectclass (id);
ALTER TABLE ng3_library ADD CONSTRAINT ng3_lib_fk FOREIGN KEY (id) REFERENCES cityobject (id);
ALTER TABLE ng3_library ADD CONSTRAINT ng3_lib_oc_fk FOREIGN KEY (objectclass_id) REFERENCES objectclass (id);
-- --------------------------------------------------------------------
-- ng2_material
-- ng3_material
-- --------------------------------------------------------------------
ALTER TABLE ng2_material ADD CONSTRAINT ng2_mat_fk FOREIGN KEY (id) REFERENCES cityobject (id);
ALTER TABLE ng2_material ADD CONSTRAINT ng2_mat_lib_fk FOREIGN KEY (library_id) REFERENCES ng2_library (id) ON DELETE SET NULL;
ALTER TABLE ng3_material ADD CONSTRAINT ng3_mat_fk FOREIGN KEY (id) REFERENCES cityobject (id);
ALTER TABLE ng3_material ADD CONSTRAINT ng3_mat_lib_fk FOREIGN KEY (library_id) REFERENCES ng3_library (id) ON DELETE SET NULL;
-- --------------------------------------------------------------------
-- ng2_occupants
-- ng3_occupants
-- --------------------------------------------------------------------
ALTER TABLE ng2_occupants ADD CONSTRAINT ng2_occ_fk FOREIGN KEY (id) REFERENCES cityobject (id);
ALTER TABLE ng2_occupants ADD CONSTRAINT ng2_occ_sched_fk FOREIGN KEY (schedule_id) REFERENCES ng2_schedule (id) ON DELETE SET NULL;
ALTER TABLE ng2_occupants ADD CONSTRAINT ng2_occ_ng2_bdgp_fk FOREIGN KEY (building_partition_id) REFERENCES ng2_building_partition (id) ON DELETE SET NULL;
ALTER TABLE ng3_occupants ADD CONSTRAINT ng3_occ_fk FOREIGN KEY (id) REFERENCES cityobject (id);
ALTER TABLE ng3_occupants ADD CONSTRAINT ng3_occ_sched_fk FOREIGN KEY (schedule_id) REFERENCES ng3_schedule (id) ON DELETE SET NULL;
ALTER TABLE ng3_occupants ADD CONSTRAINT ng3_occ_ng3_bdgp_fk FOREIGN KEY (building_partition_id) REFERENCES ng3_building_partition (id) ON DELETE SET NULL;
-- --------------------------------------------------------------------
-- ng2_opening
-- ng3_opening
-- --------------------------------------------------------------------
ALTER TABLE ng2_opening ADD CONSTRAINT ng2_opn_fk FOREIGN KEY (id) REFERENCES opening (id);
ALTER TABLE ng3_opening ADD CONSTRAINT ng3_opn_fk FOREIGN KEY (id) REFERENCES opening (id);
-- --------------------------------------------------------------------
-- ng2_optical_property
-- ng3_optical_property
-- --------------------------------------------------------------------
ALTER TABLE ng2_optical_property ADD CONSTRAINT ng2_optpty_oc_fk FOREIGN KEY (objectclass_id) REFERENCES objectclass (id);
ALTER TABLE ng2_optical_property ADD CONSTRAINT ng2_optpty_lcns_fk FOREIGN KEY (layered_construction_id) REFERENCES ng2_layered_construction (id);
ALTER TABLE ng3_optical_property ADD CONSTRAINT ng3_optpty_oc_fk FOREIGN KEY (objectclass_id) REFERENCES objectclass (id);
ALTER TABLE ng3_optical_property ADD CONSTRAINT ng3_optpty_lcns_fk FOREIGN KEY (layered_construction_id) REFERENCES ng3_layered_construction (id);
-- --------------------------------------------------------------------
-- ng2_qualified_attribute
-- ng3_qualified_attribute
-- --------------------------------------------------------------------
ALTER TABLE ng2_qualified_attribute ADD CONSTRAINT ng2_qatt_oc_fk FOREIGN KEY (objectclass_id) REFERENCES objectclass (id);
ALTER TABLE ng2_qualified_attribute ADD CONSTRAINT ng2_qatt_bdg_fk FOREIGN KEY (building_id) REFERENCES ng2_building (id);
ALTER TABLE ng2_qualified_attribute ADD CONSTRAINT ng2_qatt_bdg_part_fk FOREIGN KEY (building_partition_id) REFERENCES ng2_building_partition (id);
ALTER TABLE ng3_qualified_attribute ADD CONSTRAINT ng3_qatt_oc_fk FOREIGN KEY (objectclass_id) REFERENCES objectclass (id);
ALTER TABLE ng3_qualified_attribute ADD CONSTRAINT ng3_qatt_bdg_fk FOREIGN KEY (building_id) REFERENCES ng3_building (id);
ALTER TABLE ng3_qualified_attribute ADD CONSTRAINT ng3_qatt_bdg_part_fk FOREIGN KEY (building_partition_id) REFERENCES ng3_building_partition (id);
-- --------------------------------------------------------------------
-- ng2_refurbishment_measure
-- ng3_refurbishment_measure
-- --------------------------------------------------------------------
ALTER TABLE ng2_refurbishment_measure ADD CONSTRAINT ng2_refurb_fk FOREIGN KEY (id) REFERENCES cityobject (id);
ALTER TABLE ng2_refurbishment_measure ADD CONSTRAINT ng2_refurb_bdg_fk FOREIGN KEY (building_id) REFERENCES ng2_building (id) ON DELETE SET NULL;
ALTER TABLE ng2_refurbishment_measure ADD CONSTRAINT ng2_refurb_bdg_part_fk FOREIGN KEY (building_partition_id) REFERENCES ng2_building_partition (id) ON DELETE SET NULL;
ALTER TABLE ng3_refurbishment_measure ADD CONSTRAINT ng3_refurb_fk FOREIGN KEY (id) REFERENCES cityobject (id);
ALTER TABLE ng3_refurbishment_measure ADD CONSTRAINT ng3_refurb_bdg_fk FOREIGN KEY (building_id) REFERENCES ng3_building (id) ON DELETE SET NULL;
ALTER TABLE ng3_refurbishment_measure ADD CONSTRAINT ng3_refurb_bdg_part_fk FOREIGN KEY (building_partition_id) REFERENCES ng3_building_partition (id) ON DELETE SET NULL;
-- --------------------------------------------------------------------
-- ng2_resource
-- ng3_resource
-- --------------------------------------------------------------------
ALTER TABLE ng2_resource ADD CONSTRAINT ng2_res_fk FOREIGN KEY (id) REFERENCES cityobject (id);
ALTER TABLE ng2_resource ADD CONSTRAINT ng2_res_oc_fk FOREIGN KEY (objectclass_id) REFERENCES objectclass (id);
ALTER TABLE ng2_resource ADD CONSTRAINT ng2_res_ts_fk FOREIGN KEY (time_series_id) REFERENCES ng2_time_series (id) ON DELETE SET NULL;
ALTER TABLE ng2_resource ADD CONSTRAINT ng2_res_cto_fk FOREIGN KEY (cityobject_id) REFERENCES ng2_cityobject (id) ON DELETE SET NULL;
ALTER TABLE ng3_resource ADD CONSTRAINT ng3_res_fk FOREIGN KEY (id) REFERENCES cityobject (id);
ALTER TABLE ng3_resource ADD CONSTRAINT ng3_res_oc_fk FOREIGN KEY (objectclass_id) REFERENCES objectclass (id);
ALTER TABLE ng3_resource ADD CONSTRAINT ng3_res_ts_fk FOREIGN KEY (time_series_id) REFERENCES ng3_time_series (id) ON DELETE SET NULL;
ALTER TABLE ng3_resource ADD CONSTRAINT ng3_res_cto_fk FOREIGN KEY (cityobject_id) REFERENCES ng3_cityobject (id) ON DELETE SET NULL;
-- --------------------------------------------------------------------
-- ng2_schedule
-- ng3_schedule
-- --------------------------------------------------------------------
ALTER TABLE ng2_schedule ADD CONSTRAINT ng2_sched_fk FOREIGN KEY (id) REFERENCES cityobject (id);
ALTER TABLE ng2_schedule ADD CONSTRAINT ng2_sched_oc_fk FOREIGN KEY (objectclass_id) REFERENCES objectclass (id);
ALTER TABLE ng2_schedule ADD CONSTRAINT ng2_sched_ts_fk FOREIGN KEY (time_series_id) REFERENCES ng2_time_series (id) ON DELETE SET NULL;
ALTER TABLE ng2_schedule ADD CONSTRAINT ng2_sched_lib_fk FOREIGN KEY (library_id) REFERENCES ng2_library (id) ON DELETE SET NULL;
ALTER TABLE ng3_schedule ADD CONSTRAINT ng3_sched_fk FOREIGN KEY (id) REFERENCES cityobject (id);
ALTER TABLE ng3_schedule ADD CONSTRAINT ng3_sched_oc_fk FOREIGN KEY (objectclass_id) REFERENCES objectclass (id);
ALTER TABLE ng3_schedule ADD CONSTRAINT ng3_sched_ts_fk FOREIGN KEY (time_series_id) REFERENCES ng3_time_series (id) ON DELETE SET NULL;
ALTER TABLE ng3_schedule ADD CONSTRAINT ng3_sched_lib_fk FOREIGN KEY (library_id) REFERENCES ng3_library (id) ON DELETE SET NULL;
-- --------------------------------------------------------------------
-- ng2_schedule_component
-- ng3_schedule_component
-- --------------------------------------------------------------------
ALTER TABLE ng2_schedule_component ADD CONSTRAINT ng2_sched_comp_fk FOREIGN KEY (id) REFERENCES cityobject (id);
ALTER TABLE ng2_schedule_component ADD CONSTRAINT ng2_sched_comp_sched_fk1 FOREIGN KEY (parent_schedule_id) REFERENCES ng2_schedule (id);
ALTER TABLE ng2_schedule_component ADD CONSTRAINT ng2_sched_comp_sched_fk2 FOREIGN KEY (schedule_id) REFERENCES ng2_schedule (id) ON DELETE SET NULL;
ALTER TABLE ng3_schedule_component ADD CONSTRAINT ng3_sched_comp_fk FOREIGN KEY (id) REFERENCES cityobject (id);
ALTER TABLE ng3_schedule_component ADD CONSTRAINT ng3_sched_comp_sched_fk1 FOREIGN KEY (parent_schedule_id) REFERENCES ng3_schedule (id);
ALTER TABLE ng3_schedule_component ADD CONSTRAINT ng3_sched_comp_sched_fk2 FOREIGN KEY (schedule_id) REFERENCES ng3_schedule (id) ON DELETE SET NULL;
-- --------------------------------------------------------------------
-- ng2_solar_collector
-- ng3_solar_collector
-- --------------------------------------------------------------------
ALTER TABLE ng2_solar_collector ADD CONSTRAINT ng2_sol_coll_fk FOREIGN KEY (id) REFERENCES ng2_device (id);
ALTER TABLE ng2_solar_collector ADD CONSTRAINT ng2_sol_coll_oc_fk FOREIGN KEY (objectclass_id) REFERENCES objectclass (id);
ALTER TABLE ng2_solar_collector ADD CONSTRAINT ng2_sol_coll_lod2_fk FOREIGN KEY (lod2_multi_surface_id) REFERENCES surface_geometry (id);
ALTER TABLE ng2_solar_collector ADD CONSTRAINT ng2_sol_coll_lod3_fk FOREIGN KEY (lod3_multi_surface_id) REFERENCES surface_geometry (id);
ALTER TABLE ng3_solar_collector ADD CONSTRAINT ng3_sol_coll_fk FOREIGN KEY (id) REFERENCES ng3_device (id);
ALTER TABLE ng3_solar_collector ADD CONSTRAINT ng3_sol_coll_oc_fk FOREIGN KEY (objectclass_id) REFERENCES objectclass (id);
ALTER TABLE ng3_solar_collector ADD CONSTRAINT ng3_sol_coll_lod2_fk FOREIGN KEY (lod2_multi_surface_id) REFERENCES surface_geometry (id);
ALTER TABLE ng3_solar_collector ADD CONSTRAINT ng3_sol_coll_lod3_fk FOREIGN KEY (lod3_multi_surface_id) REFERENCES surface_geometry (id);
-- --------------------------------------------------------------------
-- ng2_storage_device
-- ng3_storage_device
-- --------------------------------------------------------------------
ALTER TABLE ng2_storage_device ADD CONSTRAINT ng2_sto_dev_fk FOREIGN KEY (id) REFERENCES ng2_device (id);
ALTER TABLE ng2_storage_device ADD CONSTRAINT ng2_sto_dev_oc_fk FOREIGN KEY (objectclass_id) REFERENCES objectclass (id);
ALTER TABLE ng3_storage_device ADD CONSTRAINT ng3_sto_dev_fk FOREIGN KEY (id) REFERENCES ng3_device (id);
ALTER TABLE ng3_storage_device ADD CONSTRAINT ng3_sto_dev_oc_fk FOREIGN KEY (objectclass_id) REFERENCES objectclass (id);
-- --------------------------------------------------------------------
-- ng2_suitability
-- ng3_suitability
-- --------------------------------------------------------------------
ALTER TABLE ng2_suitability ADD CONSTRAINT ng2_suit_cto_fk FOREIGN KEY (cityobject_id) REFERENCES ng2_cityobject (id);
ALTER TABLE ng2_suitability ADD CONSTRAINT ng2_suit_sched_fk FOREIGN KEY (schedule_id) REFERENCES ng2_schedule (id) ON DELETE SET NULL;
ALTER TABLE ng3_suitability ADD CONSTRAINT ng3_suit_cto_fk FOREIGN KEY (cityobject_id) REFERENCES ng3_cityobject (id);
ALTER TABLE ng3_suitability ADD CONSTRAINT ng3_suit_sched_fk FOREIGN KEY (schedule_id) REFERENCES ng3_schedule (id) ON DELETE SET NULL;
-- --------------------------------------------------------------------
-- ng2_them_surf_to_thermal_zone
-- ng3_them_surf_to_thermal_zone
-- --------------------------------------------------------------------
ALTER TABLE ng2_them_surf_to_thermal_zone ADD CONSTRAINT ng2_thm_surf_to_tz_fk2 FOREIGN KEY (thermal_zone_id) REFERENCES ng2_building_partition (id);
ALTER TABLE ng2_them_surf_to_thermal_zone ADD CONSTRAINT ng2_thm_surf_to_tz_fk1 FOREIGN KEY (thematic_surface_id) REFERENCES thematic_surface (id) ON DELETE CASCADE;
ALTER TABLE ng3_them_surf_to_thermal_zone ADD CONSTRAINT ng3_thm_surf_to_tz_fk2 FOREIGN KEY (thermal_zone_id) REFERENCES ng3_building_partition (id);
ALTER TABLE ng3_them_surf_to_thermal_zone ADD CONSTRAINT ng3_thm_surf_to_tz_fk1 FOREIGN KEY (thematic_surface_id) REFERENCES thematic_surface (id) ON DELETE CASCADE;
-- --------------------------------------------------------------------
-- ng2_thematic_surface
-- ng3_thematic_surface
-- --------------------------------------------------------------------
ALTER TABLE ng2_thematic_surface ADD CONSTRAINT ng2_them_surf_fk FOREIGN KEY (id) REFERENCES thematic_surface (id);
ALTER TABLE ng3_thematic_surface ADD CONSTRAINT ng3_them_surf_fk FOREIGN KEY (id) REFERENCES thematic_surface (id);
-- --------------------------------------------------------------------
-- ng2_time_series
-- ng3_time_series
-- --------------------------------------------------------------------
ALTER TABLE ng2_time_series ADD CONSTRAINT ng2_ts_fk FOREIGN KEY (id) REFERENCES cityobject (id);
ALTER TABLE ng2_time_series ADD CONSTRAINT ng2_ts_oc_fk FOREIGN KEY (objectclass_id) REFERENCES objectclass (id);
ALTER TABLE ng3_time_series ADD CONSTRAINT ng3_ts_fk FOREIGN KEY (id) REFERENCES cityobject (id);
ALTER TABLE ng3_time_series ADD CONSTRAINT ng3_ts_oc_fk FOREIGN KEY (objectclass_id) REFERENCES objectclass (id);
-- --------------------------------------------------------------------
-- ng2_urban_function_area
-- ng3_urban_function_area
-- --------------------------------------------------------------------
ALTER TABLE ng2_urban_function_area ADD CONSTRAINT ng2_ufa_fk FOREIGN KEY (id) REFERENCES cityobjectgroup (id);
ALTER TABLE ng3_urban_function_area ADD CONSTRAINT ng3_ufa_fk FOREIGN KEY (id) REFERENCES cityobjectgroup (id);
-- --------------------------------------------------------------------
-- ng2_utl_ntw_connection
-- ng3_utl_ntw_connection
-- --------------------------------------------------------------------
ALTER TABLE ng2_utl_ntw_connection ADD CONSTRAINT ng2_utl_ntw_con_fk FOREIGN KEY (id) REFERENCES cityobject (id);
ALTER TABLE ng2_utl_ntw_connection ADD CONSTRAINT ng2_utl_ntw_con_cto_fk FOREIGN KEY (cityobject_id) REFERENCES ng2_cityobject (id) ON DELETE SET NULL;
ALTER TABLE ng3_utl_ntw_connection ADD CONSTRAINT ng3_utl_ntw_con_fk FOREIGN KEY (id) REFERENCES cityobject (id);
ALTER TABLE ng3_utl_ntw_connection ADD CONSTRAINT ng3_utl_ntw_con_cto_fk FOREIGN KEY (cityobject_id) REFERENCES ng3_cityobject (id) ON DELETE SET NULL;
-- --------------------------------------------------------------------
-- ng2_weather_data
-- ng3_weather_data
-- --------------------------------------------------------------------
ALTER TABLE ng2_weather_data ADD CONSTRAINT ng2_wth_data_fk FOREIGN KEY (id) REFERENCES cityobject (id);
ALTER TABLE ng2_weather_data ADD CONSTRAINT ng2_wth_data_ts_fk FOREIGN KEY (time_series_id) REFERENCES ng2_time_series (id) ON DELETE SET NULL;
ALTER TABLE ng2_weather_data ADD CONSTRAINT ng2_wth_data_ng2_cto_fk FOREIGN KEY (cityobject_id) REFERENCES ng2_cityobject (id) ON DELETE SET NULL;
ALTER TABLE ng3_weather_data ADD CONSTRAINT ng3_wth_data_fk FOREIGN KEY (id) REFERENCES cityobject (id);
ALTER TABLE ng3_weather_data ADD CONSTRAINT ng3_wth_data_ts_fk FOREIGN KEY (time_series_id) REFERENCES ng3_time_series (id) ON DELETE SET NULL;
ALTER TABLE ng3_weather_data ADD CONSTRAINT ng3_wth_data_ng3_cto_fk FOREIGN KEY (cityobject_id) REFERENCES ng3_cityobject (id) ON DELETE SET NULL;
-- ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
......@@ -866,183 +866,183 @@ ALTER TABLE ng2_weather_data ADD CONSTRAINT ng2_wth_data_ng2_cto_fk FOREIGN KEY
-- ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
-- --------------------------------------------------------------------
-- ng2_address_to_building_unit
-- ng3_address_to_building_unit
-- --------------------------------------------------------------------
CREATE INDEX ng2_address_to_bdgu_fk1x ON ng2_address_to_building_unit USING btree (address_id ASC NULLS LAST) WITH (FILLFACTOR = 90);
CREATE INDEX ng2_address_to_bdgu_fk2x ON ng2_address_to_building_unit USING btree (building_unit_id ASC NULLS LAST) WITH (FILLFACTOR = 90);
CREATE INDEX ng3_address_to_bdgu_fk1x ON ng3_address_to_building_unit USING btree (address_id ASC NULLS LAST) WITH (FILLFACTOR = 90);
CREATE INDEX ng3_address_to_bdgu_fk2x ON ng3_address_to_building_unit USING btree (building_unit_id ASC NULLS LAST) WITH (FILLFACTOR = 90);
-- --------------------------------------------------------------------
-- ng2_building
-- ng3_building
-- --------------------------------------------------------------------
-- no indices needed
-- --------------------------------------------------------------------
-- ng2_building_partition
-- ng3_building_partition
-- --------------------------------------------------------------------
CREATE INDEX ng2_bdgp_oc_fkx ON ng2_building_partition USING btree (objectclass_id ASC NULLS LAST) WITH (FILLFACTOR = 90);
CREATE INDEX ng2_bdgp_sched_fk1x ON ng2_building_partition USING btree (cooling_schedule_id ASC NULLS LAST) WITH (FILLFACTOR = 90);
CREATE INDEX ng2_bdgp_sched_fk2x ON ng2_building_partition USING btree (heating_schedule_id ASC NULLS LAST) WITH (FILLFACTOR = 90);
CREATE INDEX ng2_bdgp_sched_fk3x ON ng2_building_partition USING btree (ventilation_schedule_id ASC NULLS LAST) WITH (FILLFACTOR = 90);
CREATE INDEX ng2_bdgp_uz_fkx ON ng2_building_partition USING btree (usage_zone_id ASC NULLS LAST) WITH (FILLFACTOR = 90);
CREATE INDEX ng2_bdgp_tz_fkx ON ng2_building_partition USING btree (thermal_zone_id ASC NULLS LAST) WITH (FILLFACTOR = 90);
CREATE INDEX ng2_bdgp_bdg_fkx ON ng2_building_partition USING btree (building_id ASC NULLS LAST) WITH (FILLFACTOR = 90);
CREATE INDEX ng2_bdgp_solid1_fkx ON ng2_building_partition USING btree (lod1_solid_id ASC NULLS LAST) WITH (FILLFACTOR = 90);
CREATE INDEX ng2_bdgp_solid2_fkx ON ng2_building_partition USING btree (lod2_solid_id ASC NULLS LAST) WITH (FILLFACTOR = 90);
CREATE INDEX ng2_bdgp_solid3_fkx ON ng2_building_partition USING btree (lod3_solid_id ASC NULLS LAST) WITH (FILLFACTOR = 90);
CREATE INDEX ng3_bdgp_oc_fkx ON ng3_building_partition USING btree (objectclass_id ASC NULLS LAST) WITH (FILLFACTOR = 90);
CREATE INDEX ng3_bdgp_sched_fk1x ON ng3_building_partition USING btree (cooling_schedule_id ASC NULLS LAST) WITH (FILLFACTOR = 90);
CREATE INDEX ng3_bdgp_sched_fk2x ON ng3_building_partition USING btree (heating_schedule_id ASC NULLS LAST) WITH (FILLFACTOR = 90);
CREATE INDEX ng3_bdgp_sched_fk3x ON ng3_building_partition USING btree (ventilation_schedule_id ASC NULLS LAST) WITH (FILLFACTOR = 90);
CREATE INDEX ng3_bdgp_uz_fkx ON ng3_building_partition USING btree (usage_zone_id ASC NULLS LAST) WITH (FILLFACTOR = 90);
CREATE INDEX ng3_bdgp_tz_fkx ON ng3_building_partition USING btree (thermal_zone_id ASC NULLS LAST) WITH (FILLFACTOR = 90);
CREATE INDEX ng3_bdgp_bdg_fkx ON ng3_building_partition USING btree (building_id ASC NULLS LAST) WITH (FILLFACTOR = 90);
CREATE INDEX ng3_bdgp_solid1_fkx ON ng3_building_partition USING btree (lod1_solid_id ASC NULLS LAST) WITH (FILLFACTOR = 90);
CREATE INDEX ng3_bdgp_solid2_fkx ON ng3_building_partition USING btree (lod2_solid_id ASC NULLS LAST) WITH (FILLFACTOR = 90);
CREATE INDEX ng3_bdgp_solid3_fkx ON ng3_building_partition USING btree (lod3_solid_id ASC NULLS LAST) WITH (FILLFACTOR = 90);
-- --------------------------------------------------------------------
-- ng2_cityobject
-- ng3_cityobject
-- --------------------------------------------------------------------
CREATE INDEX ng2_cto_ref_point_spx ON ng2_cityobject USING gist (ref_point);
CREATE INDEX ng2_cto_lcns_fkx ON ng2_cityobject USING btree (layered_construction_id ASC NULLS LAST) WITH (FILLFACTOR = 90);
CREATE INDEX ng3_cto_ref_point_spx ON ng3_cityobject USING gist (ref_point);
CREATE INDEX ng3_cto_lcns_fkx ON ng3_cityobject USING btree (layered_construction_id ASC NULLS LAST) WITH (FILLFACTOR = 90);
-- --------------------------------------------------------------------
-- ng2_ctyobj_relation
-- ng3_ctyobj_relation
-- --------------------------------------------------------------------
CREATE INDEX ng2_cto_rel_fk1x ON ng2_ctyobj_relation USING btree (ng2_cityobject_id ASC NULLS LAST) WITH (FILLFACTOR = 90);
CREATE INDEX ng2_cto_rel_fk2x ON ng2_ctyobj_relation USING btree (cityobject_id ASC NULLS LAST) WITH (FILLFACTOR = 90);
CREATE INDEX ng3_cto_rel_fk1x ON ng3_ctyobj_relation USING btree (ng3_cityobject_id ASC NULLS LAST) WITH (FILLFACTOR = 90);
CREATE INDEX ng3_cto_rel_fk2x ON ng3_ctyobj_relation USING btree (cityobject_id ASC NULLS LAST) WITH (FILLFACTOR = 90);
-- --------------------------------------------------------------------
-- ng2_device
-- ng3_device
-- --------------------------------------------------------------------
CREATE INDEX ng2_dev_oc_fkx ON ng2_device USING btree (objectclass_id ASC NULLS LAST) WITH (FILLFACTOR = 90);
CREATE INDEX ng2_dev_opt_fkx ON ng2_device USING btree (transmittance_id ASC NULLS LAST) WITH (FILLFACTOR = 90);
CREATE INDEX ng2_dev_cto_fkx ON ng2_device USING btree (cityobject_id ASC NULLS LAST) WITH (FILLFACTOR = 90);
CREATE INDEX ng3_dev_oc_fkx ON ng3_device USING btree (objectclass_id ASC NULLS LAST) WITH (FILLFACTOR = 90);
CREATE INDEX ng3_dev_opt_fkx ON ng3_device USING btree (transmittance_id ASC NULLS LAST) WITH (FILLFACTOR = 90);
CREATE INDEX ng3_dev_cto_fkx ON ng3_device USING btree (cityobject_id ASC NULLS LAST) WITH (FILLFACTOR = 90);
-- --------------------------------------------------------------------
-- ng2_device_operation
-- ng3_device_operation
-- --------------------------------------------------------------------
CREATE INDEX ng2_dev_opr_sched_fkx ON ng2_device_operation USING btree (schedule_id ASC NULLS LAST) WITH (FILLFACTOR = 90);
CREATE INDEX ng2_dev_opr_dev_fkx ON ng2_device_operation USING btree (device_id ASC NULLS LAST) WITH (FILLFACTOR = 90);
CREATE INDEX ng3_dev_opr_sched_fkx ON ng3_device_operation USING btree (schedule_id ASC NULLS LAST) WITH (FILLFACTOR = 90);
CREATE INDEX ng3_dev_opr_dev_fkx ON ng3_device_operation USING btree (device_id ASC NULLS LAST) WITH (FILLFACTOR = 90);
-- --------------------------------------------------------------------
-- ng2_energy_perf_cert
-- ng3_energy_perf_cert
-- --------------------------------------------------------------------
CREATE INDEX ng2_epc_bdg_fkx ON ng2_energy_perf_cert USING btree (building_id ASC NULLS LAST) WITH (FILLFACTOR = 90);
CREATE INDEX ng2_epc_bdg_part_fkx ON ng2_energy_perf_cert USING btree (building_partition_id ASC NULLS LAST) WITH (FILLFACTOR = 90);
CREATE INDEX ng3_epc_bdg_fkx ON ng3_energy_perf_cert USING btree (building_id ASC NULLS LAST) WITH (FILLFACTOR = 90);
CREATE INDEX ng3_epc_bdg_part_fkx ON ng3_energy_perf_cert USING btree (building_partition_id ASC NULLS LAST) WITH (FILLFACTOR = 90);
-- --------------------------------------------------------------------
-- ng2_layer
-- ng3_layer
-- --------------------------------------------------------------------
CREATE INDEX ng2_lyr_mat_fkx ON ng2_layer USING btree (material_id ASC NULLS LAST) WITH (FILLFACTOR = 90);
CREATE INDEX ng2_lyr_lcns_fkx ON ng2_layer USING btree (layered_construction_id ASC NULLS LAST) WITH (FILLFACTOR = 90);
CREATE INDEX ng3_lyr_mat_fkx ON ng3_layer USING btree (material_id ASC NULLS LAST) WITH (FILLFACTOR = 90);
CREATE INDEX ng3_lyr_lcns_fkx ON ng3_layer USING btree (layered_construction_id ASC NULLS LAST) WITH (FILLFACTOR = 90);
-- --------------------------------------------------------------------
-- ng2_layered_constr
-- ng3_layered_constr
-- --------------------------------------------------------------------
CREATE INDEX ng2_lcns_oc_fkx ON ng2_layered_construction USING btree (objectclass_id ASC NULLS LAST) WITH (FILLFACTOR = 90);
CREATE INDEX ng2_lcns_lcns_fkx ON ng2_layered_construction USING btree (layered_construction_id ASC NULLS LAST) WITH (FILLFACTOR = 90);
CREATE INDEX ng2_lcns_lib_fkx ON ng2_layered_construction USING btree (library_id ASC NULLS LAST) WITH (FILLFACTOR = 90);
CREATE INDEX ng3_lcns_oc_fkx ON ng3_layered_construction USING btree (objectclass_id ASC NULLS LAST) WITH (FILLFACTOR = 90);
CREATE INDEX ng3_lcns_lcns_fkx ON ng3_layered_construction USING btree (layered_construction_id ASC NULLS LAST) WITH (FILLFACTOR = 90);
CREATE INDEX ng3_lcns_lib_fkx ON ng3_layered_construction USING btree (library_id ASC NULLS LAST) WITH (FILLFACTOR = 90);
-- --------------------------------------------------------------------
-- ng2_library
-- ng3_library
-- --------------------------------------------------------------------
CREATE INDEX ng2_lib_oc_fkx ON ng2_library USING btree (objectclass_id ASC NULLS LAST) WITH (FILLFACTOR = 90);
CREATE INDEX ng3_lib_oc_fkx ON ng3_library USING btree (objectclass_id ASC NULLS LAST) WITH (FILLFACTOR = 90);
-- --------------------------------------------------------------------
-- ng2_material
-- ng3_material
-- --------------------------------------------------------------------
CREATE INDEX ng2_mat_oc_fkx ON ng2_material USING btree (objectclass_id ASC NULLS LAST) WITH (FILLFACTOR = 90);
CREATE INDEX ng2_mat_lib_fkx ON ng2_material USING btree (library_id ASC NULLS LAST) WITH (FILLFACTOR = 90);
CREATE INDEX ng3_mat_oc_fkx ON ng3_material USING btree (objectclass_id ASC NULLS LAST) WITH (FILLFACTOR = 90);
CREATE INDEX ng3_mat_lib_fkx ON ng3_material USING btree (library_id ASC NULLS LAST) WITH (FILLFACTOR = 90);
-- --------------------------------------------------------------------
-- ng2_occupants
-- ng3_occupants
-- --------------------------------------------------------------------
CREATE INDEX ng2_occ_sched_fkx ON ng2_occupants USING btree (schedule_id ASC NULLS LAST) WITH (FILLFACTOR = 90);
CREATE INDEX ng2_occ_ng2_bdgp_fkx ON ng2_occupants USING btree (building_partition_id ASC NULLS LAST) WITH (FILLFACTOR = 90);
CREATE INDEX ng3_occ_sched_fkx ON ng3_occupants USING btree (schedule_id ASC NULLS LAST) WITH (FILLFACTOR = 90);
CREATE INDEX ng3_occ_ng3_bdgp_fkx ON ng3_occupants USING btree (building_partition_id ASC NULLS LAST) WITH (FILLFACTOR = 90);
-- --------------------------------------------------------------------
-- ng2_opening
-- ng3_opening
-- --------------------------------------------------------------------
-- no indices needed
-- --------------------------------------------------------------------
-- ng2_optical_property
-- ng3_optical_property
-- --------------------------------------------------------------------
CREATE INDEX ng2_optpty_oc_fkx ON ng2_optical_property USING btree (objectclass_id ASC NULLS LAST) WITH (FILLFACTOR = 90);
CREATE INDEX ng2_optpty_lcns_fkx ON ng2_optical_property USING btree (layered_construction_id ASC NULLS LAST) WITH (FILLFACTOR = 90);
CREATE INDEX ng3_optpty_oc_fkx ON ng3_optical_property USING btree (objectclass_id ASC NULLS LAST) WITH (FILLFACTOR = 90);
CREATE INDEX ng3_optpty_lcns_fkx ON ng3_optical_property USING btree (layered_construction_id ASC NULLS LAST) WITH (FILLFACTOR = 90);
-- --------------------------------------------------------------------
-- ng2_qualified_attribute
-- ng3_qualified_attribute
-- --------------------------------------------------------------------
CREATE INDEX ng2_qual_attr_oc_fkx ON ng2_qualified_attribute USING btree (objectclass_id ASC NULLS LAST) WITH (FILLFACTOR = 90);
CREATE INDEX ng2_qual_attr_bdg_fkx ON ng2_qualified_attribute USING btree (building_id ASC NULLS LAST) WITH (FILLFACTOR = 90);
CREATE INDEX ng2_qual_attr_bdg_part_fkx ON ng2_qualified_attribute USING btree (building_partition_id ASC NULLS LAST) WITH (FILLFACTOR = 90);
CREATE INDEX ng2_qual_attr_type_idx ON ng2_qualified_attribute USING btree (type ASC NULLS LAST) WITH (FILLFACTOR = 90);
CREATE INDEX ng3_qual_attr_oc_fkx ON ng3_qualified_attribute USING btree (objectclass_id ASC NULLS LAST) WITH (FILLFACTOR = 90);
CREATE INDEX ng3_qual_attr_bdg_fkx ON ng3_qualified_attribute USING btree (building_id ASC NULLS LAST) WITH (FILLFACTOR = 90);
CREATE INDEX ng3_qual_attr_bdg_part_fkx ON ng3_qualified_attribute USING btree (building_partition_id ASC NULLS LAST) WITH (FILLFACTOR = 90);
CREATE INDEX ng3_qual_attr_type_idx ON ng3_qualified_attribute USING btree (type ASC NULLS LAST) WITH (FILLFACTOR = 90);
-- --------------------------------------------------------------------
-- ng2_refurbishment_measure
-- ng3_refurbishment_measure
-- --------------------------------------------------------------------
CREATE INDEX ng2_ref_meas_bdg_fkx ON ng2_refurbishment_measure USING btree (building_id ASC NULLS LAST) WITH (FILLFACTOR = 90);
CREATE INDEX ng2_ref_meas_bdg_part_fkx ON ng2_refurbishment_measure USING btree (building_partition_id ASC NULLS LAST) WITH (FILLFACTOR = 90);
CREATE INDEX ng3_ref_meas_bdg_fkx ON ng3_refurbishment_measure USING btree (building_id ASC NULLS LAST) WITH (FILLFACTOR = 90);
CREATE INDEX ng3_ref_meas_bdg_part_fkx ON ng3_refurbishment_measure USING btree (building_partition_id ASC NULLS LAST) WITH (FILLFACTOR = 90);
-- --------------------------------------------------------------------
-- ng2_resource
-- ng3_resource
-- --------------------------------------------------------------------
CREATE INDEX ng2_res_oc_fkx ON ng2_resource USING btree (objectclass_id ASC NULLS LAST) WITH (FILLFACTOR = 90);
CREATE INDEX ng2_res_ts_fkx ON ng2_resource USING btree (time_series_id ASC NULLS LAST) WITH (FILLFACTOR = 90);
CREATE INDEX ng2_res_cto_fkx ON ng2_resource USING btree (cityobject_id ASC NULLS LAST) WITH (FILLFACTOR = 90);
CREATE INDEX ng3_res_oc_fkx ON ng3_resource USING btree (objectclass_id ASC NULLS LAST) WITH (FILLFACTOR = 90);
CREATE INDEX ng3_res_ts_fkx ON ng3_resource USING btree (time_series_id ASC NULLS LAST) WITH (FILLFACTOR = 90);
CREATE INDEX ng3_res_cto_fkx ON ng3_resource USING btree (cityobject_id ASC NULLS LAST) WITH (FILLFACTOR = 90);
-- --------------------------------------------------------------------
-- ng2_schedule
-- ng3_schedule
-- --------------------------------------------------------------------
CREATE INDEX ng2_sched_oc_fkx ON ng2_schedule USING btree (objectclass_id ASC NULLS LAST) WITH (FILLFACTOR = 90);
CREATE INDEX ng2_sched_ts_fkx ON ng2_schedule USING btree (time_series_id ASC NULLS LAST) WITH (FILLFACTOR = 90);
CREATE INDEX ng2_sched_lib_fkx ON ng2_schedule USING btree (library_id ASC NULLS LAST) WITH (FILLFACTOR = 90);
CREATE INDEX ng3_sched_oc_fkx ON ng3_schedule USING btree (objectclass_id ASC NULLS LAST) WITH (FILLFACTOR = 90);
CREATE INDEX ng3_sched_ts_fkx ON ng3_schedule USING btree (time_series_id ASC NULLS LAST) WITH (FILLFACTOR = 90);
CREATE INDEX ng3_sched_lib_fkx ON ng3_schedule USING btree (library_id ASC NULLS LAST) WITH (FILLFACTOR = 90);
-- --------------------------------------------------------------------
-- ng2_schedule_component
-- ng3_schedule_component
-- --------------------------------------------------------------------
CREATE INDEX ng2_sched_comp_sched_fk1x ON ng2_schedule_component USING btree (parent_schedule_id ASC NULLS LAST) WITH (FILLFACTOR = 90);
CREATE INDEX ng2_sched_comp_sched_fk2x ON ng2_schedule_component USING btree (schedule_id ASC NULLS LAST) WITH (FILLFACTOR = 90);
CREATE INDEX ng3_sched_comp_sched_fk1x ON ng3_schedule_component USING btree (parent_schedule_id ASC NULLS LAST) WITH (FILLFACTOR = 90);
CREATE INDEX ng3_sched_comp_sched_fk2x ON ng3_schedule_component USING btree (schedule_id ASC NULLS LAST) WITH (FILLFACTOR = 90);
-- --------------------------------------------------------------------
-- ng2_solar_collector
-- ng3_solar_collector
-- --------------------------------------------------------------------
CREATE INDEX ng2_sol_col_oc_fkx ON ng2_solar_collector USING btree (objectclass_id ASC NULLS LAST) WITH (FILLFACTOR = 90);
CREATE INDEX ng2_sol_col_lod2_fkx ON ng2_solar_collector USING btree (lod2_multi_surface_id ASC NULLS LAST) WITH (FILLFACTOR = 90);
CREATE INDEX ng2_sol_col_lod3_fkx ON ng2_solar_collector USING btree (lod2_multi_surface_id ASC NULLS LAST) WITH (FILLFACTOR = 90);
CREATE INDEX ng3_sol_col_oc_fkx ON ng3_solar_collector USING btree (objectclass_id ASC NULLS LAST) WITH (FILLFACTOR = 90);
CREATE INDEX ng3_sol_col_lod2_fkx ON ng3_solar_collector USING btree (lod2_multi_surface_id ASC NULLS LAST) WITH (FILLFACTOR = 90);
CREATE INDEX ng3_sol_col_lod3_fkx ON ng3_solar_collector USING btree (lod2_multi_surface_id ASC NULLS LAST) WITH (FILLFACTOR = 90);
-- --------------------------------------------------------------------
-- ng2_storage_device
-- ng3_storage_device
-- --------------------------------------------------------------------
CREATE INDEX ng2_sto_dev_oc_fkx ON ng2_storage_device USING btree (objectclass_id ASC NULLS LAST) WITH (FILLFACTOR = 90);
CREATE INDEX ng3_sto_dev_oc_fkx ON ng3_storage_device USING btree (objectclass_id ASC NULLS LAST) WITH (FILLFACTOR = 90);
-- --------------------------------------------------------------------
-- ng2_suitability
-- ng3_suitability
-- --------------------------------------------------------------------
CREATE INDEX ng2_suit_cto_fkx ON ng2_suitability USING btree (cityobject_id ASC NULLS LAST) WITH (FILLFACTOR = 90);
CREATE INDEX ng2_suit_sched_fkx ON ng2_suitability USING btree (schedule_id ASC NULLS LAST) WITH (FILLFACTOR = 90);
CREATE INDEX ng2_suit_reas_fkx ON ng2_suitability USING btree (reason ASC NULLS LAST) WITH (FILLFACTOR = 90);
CREATE INDEX ng3_suit_cto_fkx ON ng3_suitability USING btree (cityobject_id ASC NULLS LAST) WITH (FILLFACTOR = 90);
CREATE INDEX ng3_suit_sched_fkx ON ng3_suitability USING btree (schedule_id ASC NULLS LAST) WITH (FILLFACTOR = 90);
CREATE INDEX ng3_suit_reas_fkx ON ng3_suitability USING btree (reason ASC NULLS LAST) WITH (FILLFACTOR = 90);
-- --------------------------------------------------------------------
-- ng2_them_surf_to_thermal_zone
-- ng3_them_surf_to_thermal_zone
-- --------------------------------------------------------------------
CREATE INDEX ng2_thm_surf_to_tz_fk1x ON ng2_them_surf_to_thermal_zone USING btree (thematic_surface_id ASC NULLS LAST) WITH (FILLFACTOR = 90);
CREATE INDEX ng2_thm_surf_to_tz_fk2x ON ng2_them_surf_to_thermal_zone USING btree (thermal_zone_id ASC NULLS LAST) WITH (FILLFACTOR = 90);
CREATE INDEX ng3_thm_surf_to_tz_fk1x ON ng3_them_surf_to_thermal_zone USING btree (thematic_surface_id ASC NULLS LAST) WITH (FILLFACTOR = 90);
CREATE INDEX ng3_thm_surf_to_tz_fk2x ON ng3_them_surf_to_thermal_zone USING btree (thermal_zone_id ASC NULLS LAST) WITH (FILLFACTOR = 90);
-- --------------------------------------------------------------------
-- ng2_thematic_surface
-- ng3_thematic_surface
-- --------------------------------------------------------------------
-- no indices needed
-- --------------------------------------------------------------------
-- ng2_time_series
-- ng3_time_series
-- --------------------------------------------------------------------
CREATE INDEX ng2_ts_oc_fkx ON ng2_time_series USING btree (objectclass_id ASC NULLS LAST) WITH (FILLFACTOR = 90);
CREATE INDEX ng3_ts_oc_fkx ON ng3_time_series USING btree (objectclass_id ASC NULLS LAST) WITH (FILLFACTOR = 90);
-- --------------------------------------------------------------------
-- ng2_urban_function_area
-- ng3_urban_function_area
-- --------------------------------------------------------------------
-- no indices needed
-- --------------------------------------------------------------------
-- ng2_utl_ntw_connection
-- ng3_utl_ntw_connection
-- --------------------------------------------------------------------
CREATE INDEX ng2_utl_ntw_conn_cto_fkx ON ng2_utl_ntw_connection USING btree (cityobject_id ASC NULLS LAST) WITH (FILLFACTOR = 90);
CREATE INDEX ng3_utl_ntw_conn_cto_fkx ON ng3_utl_ntw_connection USING btree (cityobject_id ASC NULLS LAST) WITH (FILLFACTOR = 90);
-- --------------------------------------------------------------------
-- ng2_weather_data
-- ng3_weather_data
-- --------------------------------------------------------------------
CREATE INDEX ng2_wht_data_ts_fkx ON ng2_weather_data USING btree (time_series_id ASC NULLS LAST) WITH (FILLFACTOR = 90);
CREATE INDEX ng2_wht_data_cto_fkx ON ng2_weather_data USING btree (cityobject_id ASC NULLS LAST) WITH (FILLFACTOR = 90);
CREATE INDEX ng3_wht_data_ts_fkx ON ng3_weather_data USING btree (time_series_id ASC NULLS LAST) WITH (FILLFACTOR = 90);
CREATE INDEX ng3_wht_data_cto_fkx ON ng3_weather_data USING btree (cityobject_id ASC NULLS LAST) WITH (FILLFACTOR = 90);
-- ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
-- ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
--
-- CityGML Energy ADE 2.0 (beta 7)
-- CityGML Energy ADE 3.0 (beta 7)
--
-- Last update: 2025-05-09
-- Last update: 2025-10-14
--
-- This DDL script uninstalls the 3DCityDB schema for the Energy ADE 2.0. It must be run
-- This DDL script uninstalls the 3DCityDB schema for the Energy ADE. It must be run
-- from within the ADE Manager plugin of the 3DCityDB Importer/Exporter.
--
-- This script was first automatically generated using the 3DCityDB ADE Manager
......@@ -25,125 +25,125 @@
-- ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
-- *********************************** Drop foreign keys **********************************
-- ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
ALTER TABLE ng2_address_to_building_unit DROP CONSTRAINT ng2_addr_to_bdgu_fk1;
ALTER TABLE ng2_address_to_building_unit DROP CONSTRAINT ng2_addr_to_bdgu_fk2;
ALTER TABLE ng2_building DROP CONSTRAINT ng2_bdg_fk;
ALTER TABLE ng2_building_partition DROP CONSTRAINT ng2_bdgp_bdg_fk;
ALTER TABLE ng2_building_partition DROP CONSTRAINT ng2_bdgp_fk;
ALTER TABLE ng2_building_partition DROP CONSTRAINT ng2_bdgp_lod1_fk;
ALTER TABLE ng2_building_partition DROP CONSTRAINT ng2_bdgp_lod2_fk;
ALTER TABLE ng2_building_partition DROP CONSTRAINT ng2_bdgp_lod3_fk;
ALTER TABLE ng2_building_partition DROP CONSTRAINT ng2_bdgp_oc_fk;
ALTER TABLE ng2_building_partition DROP CONSTRAINT ng2_bdgp_sched_fk1;
ALTER TABLE ng2_building_partition DROP CONSTRAINT ng2_bdgp_sched_fk2;
ALTER TABLE ng2_building_partition DROP CONSTRAINT ng2_bdgp_sched_fk3;
ALTER TABLE ng2_building_partition DROP CONSTRAINT ng2_bdgp_tz_fk;
ALTER TABLE ng2_building_partition DROP CONSTRAINT ng2_bdgp_uz_fk;
ALTER TABLE ng2_cityobject DROP CONSTRAINT ng2_cto_fk;
ALTER TABLE ng2_cityobject DROP CONSTRAINT ng2_cto_lcns_fk;
ALTER TABLE ng2_ctyobj_relation DROP CONSTRAINT ng2_cto_rel_fk1;
ALTER TABLE ng2_ctyobj_relation DROP CONSTRAINT ng2_cto_rel_fk2;
ALTER TABLE ng2_device DROP CONSTRAINT ng2_dev_fk;
ALTER TABLE ng2_device DROP CONSTRAINT ng2_dev_ng2_cto_fk;
ALTER TABLE ng2_device DROP CONSTRAINT ng2_dev_oc_fk;
ALTER TABLE ng2_device DROP CONSTRAINT ng2_dev_opt_fk;
ALTER TABLE ng2_device_operation DROP CONSTRAINT ng2_dev_opr_fk;
ALTER TABLE ng2_device_operation DROP CONSTRAINT ng2_dev_opr_dev_fk;
ALTER TABLE ng2_device_operation DROP CONSTRAINT ng2_dev_opr_sched_fk;
ALTER TABLE ng2_energy_perf_cert DROP CONSTRAINT ng2_epc_fk;
ALTER TABLE ng2_energy_perf_cert DROP CONSTRAINT ng2_epc_bdg_fk;
ALTER TABLE ng2_energy_perf_cert DROP CONSTRAINT ng2_epc_bdg_part_fk;
ALTER TABLE ng2_layer DROP CONSTRAINT ng2_lyr_fk;
ALTER TABLE ng2_layer DROP CONSTRAINT ng2_lyr_lcns_fk;
ALTER TABLE ng2_layer DROP CONSTRAINT ng2_lyr_mat_fk;
ALTER TABLE ng2_layered_construction DROP CONSTRAINT ng2_lcns_fk;
ALTER TABLE ng2_layered_construction DROP CONSTRAINT ng2_lcns_lcns_fk;
ALTER TABLE ng2_layered_construction DROP CONSTRAINT ng2_lcns_oc_fk;
ALTER TABLE ng2_layered_construction DROP CONSTRAINT ng2_lcns_lib_fk;
ALTER TABLE ng2_library DROP CONSTRAINT ng2_lib_fk;
ALTER TABLE ng2_library DROP CONSTRAINT ng2_lib_oc_fk;
ALTER TABLE ng2_material DROP CONSTRAINT ng2_mat_fk;
ALTER TABLE ng2_material DROP CONSTRAINT ng2_mat_lib_fk;
ALTER TABLE ng2_occupants DROP CONSTRAINT ng2_occ_fk;
ALTER TABLE ng2_occupants DROP CONSTRAINT ng2_occ_ng2_bdgp_fk;
ALTER TABLE ng2_occupants DROP CONSTRAINT ng2_occ_sched_fk;
ALTER TABLE ng2_opening DROP CONSTRAINT ng2_opn_fk;
ALTER TABLE ng2_optical_property DROP CONSTRAINT ng2_optpty_lcns_fk;
ALTER TABLE ng2_optical_property DROP CONSTRAINT ng2_optpty_oc_fk;
ALTER TABLE ng2_qualified_attribute DROP CONSTRAINT ng2_qatt_oc_fk;
ALTER TABLE ng2_qualified_attribute DROP CONSTRAINT ng2_qatt_bdg_fk;
ALTER TABLE ng2_qualified_attribute DROP CONSTRAINT ng2_qatt_bdg_part_fk;
ALTER TABLE ng2_refurbishment_measure DROP CONSTRAINT ng2_refurb_fk;
ALTER TABLE ng2_refurbishment_measure DROP CONSTRAINT ng2_refurb_bdg_fk;
ALTER TABLE ng2_refurbishment_measure DROP CONSTRAINT ng2_refurb_bdg_part_fk;
ALTER TABLE ng2_resource DROP CONSTRAINT ng2_res_fk;
ALTER TABLE ng2_resource DROP CONSTRAINT ng2_res_oc_fk;
ALTER TABLE ng2_resource DROP CONSTRAINT ng2_res_ts_fk;
ALTER TABLE ng2_resource DROP CONSTRAINT ng2_res_cto_fk;
ALTER TABLE ng2_schedule DROP CONSTRAINT ng2_sched_fk;
ALTER TABLE ng2_schedule DROP CONSTRAINT ng2_sched_oc_fk;
ALTER TABLE ng2_schedule DROP CONSTRAINT ng2_sched_ts_fk;
ALTER TABLE ng2_schedule DROP CONSTRAINT ng2_sched_lib_fk;
ALTER TABLE ng2_schedule_component DROP CONSTRAINT ng2_sched_comp_fk;
ALTER TABLE ng2_schedule_component DROP CONSTRAINT ng2_sched_comp_sched_fk1;
ALTER TABLE ng2_schedule_component DROP CONSTRAINT ng2_sched_comp_sched_fk2;
ALTER TABLE ng2_solar_collector DROP CONSTRAINT ng2_sol_coll_fk;
ALTER TABLE ng2_solar_collector DROP CONSTRAINT ng2_sol_coll_oc_fk;
ALTER TABLE ng2_solar_collector DROP CONSTRAINT ng2_sol_coll_lod2_fk;
ALTER TABLE ng2_solar_collector DROP CONSTRAINT ng2_sol_coll_lod3_fk;
ALTER TABLE ng2_storage_device DROP CONSTRAINT ng2_sto_dev_fk;
ALTER TABLE ng2_storage_device DROP CONSTRAINT ng2_sto_dev_oc_fk;
ALTER TABLE ng2_suitability DROP CONSTRAINT ng2_suit_cto_fk;
ALTER TABLE ng2_suitability DROP CONSTRAINT ng2_suit_sched_fk;
ALTER TABLE ng2_them_surf_to_thermal_zone DROP CONSTRAINT ng2_thm_surf_to_tz_fk1;
ALTER TABLE ng2_them_surf_to_thermal_zone DROP CONSTRAINT ng2_thm_surf_to_tz_fk2;
ALTER TABLE ng2_thematic_surface DROP CONSTRAINT ng2_them_surf_fk;
ALTER TABLE ng2_time_series DROP CONSTRAINT ng2_ts_fk;
ALTER TABLE ng2_time_series DROP CONSTRAINT ng2_ts_oc_fk;
ALTER TABLE ng2_urban_function_area DROP CONSTRAINT ng2_ufa_fk;
ALTER TABLE ng2_utl_ntw_connection DROP CONSTRAINT ng2_utl_ntw_con_cto_fk;
ALTER TABLE ng2_utl_ntw_connection DROP CONSTRAINT ng2_utl_ntw_con_fk;
ALTER TABLE ng2_weather_data DROP CONSTRAINT ng2_wth_data_fk;
ALTER TABLE ng2_weather_data DROP CONSTRAINT ng2_wth_data_ng2_cto_fk;
ALTER TABLE ng2_weather_data DROP CONSTRAINT ng2_wth_data_ts_fk;
ALTER TABLE ng3_address_to_building_unit DROP CONSTRAINT ng3_addr_to_bdgu_fk1;
ALTER TABLE ng3_address_to_building_unit DROP CONSTRAINT ng3_addr_to_bdgu_fk2;
ALTER TABLE ng3_building DROP CONSTRAINT ng3_bdg_fk;
ALTER TABLE ng3_building_partition DROP CONSTRAINT ng3_bdgp_bdg_fk;
ALTER TABLE ng3_building_partition DROP CONSTRAINT ng3_bdgp_fk;
ALTER TABLE ng3_building_partition DROP CONSTRAINT ng3_bdgp_lod1_fk;
ALTER TABLE ng3_building_partition DROP CONSTRAINT ng3_bdgp_lod2_fk;
ALTER TABLE ng3_building_partition DROP CONSTRAINT ng3_bdgp_lod3_fk;
ALTER TABLE ng3_building_partition DROP CONSTRAINT ng3_bdgp_oc_fk;
ALTER TABLE ng3_building_partition DROP CONSTRAINT ng3_bdgp_sched_fk1;
ALTER TABLE ng3_building_partition DROP CONSTRAINT ng3_bdgp_sched_fk2;
ALTER TABLE ng3_building_partition DROP CONSTRAINT ng3_bdgp_sched_fk3;
ALTER TABLE ng3_building_partition DROP CONSTRAINT ng3_bdgp_tz_fk;
ALTER TABLE ng3_building_partition DROP CONSTRAINT ng3_bdgp_uz_fk;
ALTER TABLE ng3_cityobject DROP CONSTRAINT ng3_cto_fk;
ALTER TABLE ng3_cityobject DROP CONSTRAINT ng3_cto_lcns_fk;
ALTER TABLE ng3_ctyobj_relation DROP CONSTRAINT ng3_cto_rel_fk1;
ALTER TABLE ng3_ctyobj_relation DROP CONSTRAINT ng3_cto_rel_fk2;
ALTER TABLE ng3_device DROP CONSTRAINT ng3_dev_fk;
ALTER TABLE ng3_device DROP CONSTRAINT ng3_dev_ng3_cto_fk;
ALTER TABLE ng3_device DROP CONSTRAINT ng3_dev_oc_fk;
ALTER TABLE ng3_device DROP CONSTRAINT ng3_dev_opt_fk;
ALTER TABLE ng3_device_operation DROP CONSTRAINT ng3_dev_opr_fk;
ALTER TABLE ng3_device_operation DROP CONSTRAINT ng3_dev_opr_dev_fk;
ALTER TABLE ng3_device_operation DROP CONSTRAINT ng3_dev_opr_sched_fk;
ALTER TABLE ng3_energy_perf_cert DROP CONSTRAINT ng3_epc_fk;
ALTER TABLE ng3_energy_perf_cert DROP CONSTRAINT ng3_epc_bdg_fk;
ALTER TABLE ng3_energy_perf_cert DROP CONSTRAINT ng3_epc_bdg_part_fk;
ALTER TABLE ng3_layer DROP CONSTRAINT ng3_lyr_fk;
ALTER TABLE ng3_layer DROP CONSTRAINT ng3_lyr_lcns_fk;
ALTER TABLE ng3_layer DROP CONSTRAINT ng3_lyr_mat_fk;
ALTER TABLE ng3_layered_construction DROP CONSTRAINT ng3_lcns_fk;
ALTER TABLE ng3_layered_construction DROP CONSTRAINT ng3_lcns_lcns_fk;
ALTER TABLE ng3_layered_construction DROP CONSTRAINT ng3_lcns_oc_fk;
ALTER TABLE ng3_layered_construction DROP CONSTRAINT ng3_lcns_lib_fk;
ALTER TABLE ng3_library DROP CONSTRAINT ng3_lib_fk;
ALTER TABLE ng3_library DROP CONSTRAINT ng3_lib_oc_fk;
ALTER TABLE ng3_material DROP CONSTRAINT ng3_mat_fk;
ALTER TABLE ng3_material DROP CONSTRAINT ng3_mat_lib_fk;
ALTER TABLE ng3_occupants DROP CONSTRAINT ng3_occ_fk;
ALTER TABLE ng3_occupants DROP CONSTRAINT ng3_occ_ng3_bdgp_fk;
ALTER TABLE ng3_occupants DROP CONSTRAINT ng3_occ_sched_fk;
ALTER TABLE ng3_opening DROP CONSTRAINT ng3_opn_fk;
ALTER TABLE ng3_optical_property DROP CONSTRAINT ng3_optpty_lcns_fk;
ALTER TABLE ng3_optical_property DROP CONSTRAINT ng3_optpty_oc_fk;
ALTER TABLE ng3_qualified_attribute DROP CONSTRAINT ng3_qatt_oc_fk;
ALTER TABLE ng3_qualified_attribute DROP CONSTRAINT ng3_qatt_bdg_fk;
ALTER TABLE ng3_qualified_attribute DROP CONSTRAINT ng3_qatt_bdg_part_fk;
ALTER TABLE ng3_refurbishment_measure DROP CONSTRAINT ng3_refurb_fk;
ALTER TABLE ng3_refurbishment_measure DROP CONSTRAINT ng3_refurb_bdg_fk;
ALTER TABLE ng3_refurbishment_measure DROP CONSTRAINT ng3_refurb_bdg_part_fk;
ALTER TABLE ng3_resource DROP CONSTRAINT ng3_res_fk;
ALTER TABLE ng3_resource DROP CONSTRAINT ng3_res_oc_fk;
ALTER TABLE ng3_resource DROP CONSTRAINT ng3_res_ts_fk;
ALTER TABLE ng3_resource DROP CONSTRAINT ng3_res_cto_fk;
ALTER TABLE ng3_schedule DROP CONSTRAINT ng3_sched_fk;
ALTER TABLE ng3_schedule DROP CONSTRAINT ng3_sched_oc_fk;
ALTER TABLE ng3_schedule DROP CONSTRAINT ng3_sched_ts_fk;
ALTER TABLE ng3_schedule DROP CONSTRAINT ng3_sched_lib_fk;
ALTER TABLE ng3_schedule_component DROP CONSTRAINT ng3_sched_comp_fk;
ALTER TABLE ng3_schedule_component DROP CONSTRAINT ng3_sched_comp_sched_fk1;
ALTER TABLE ng3_schedule_component DROP CONSTRAINT ng3_sched_comp_sched_fk2;
ALTER TABLE ng3_solar_collector DROP CONSTRAINT ng3_sol_coll_fk;
ALTER TABLE ng3_solar_collector DROP CONSTRAINT ng3_sol_coll_oc_fk;
ALTER TABLE ng3_solar_collector DROP CONSTRAINT ng3_sol_coll_lod2_fk;
ALTER TABLE ng3_solar_collector DROP CONSTRAINT ng3_sol_coll_lod3_fk;
ALTER TABLE ng3_storage_device DROP CONSTRAINT ng3_sto_dev_fk;
ALTER TABLE ng3_storage_device DROP CONSTRAINT ng3_sto_dev_oc_fk;
ALTER TABLE ng3_suitability DROP CONSTRAINT ng3_suit_cto_fk;
ALTER TABLE ng3_suitability DROP CONSTRAINT ng3_suit_sched_fk;
ALTER TABLE ng3_them_surf_to_thermal_zone DROP CONSTRAINT ng3_thm_surf_to_tz_fk1;
ALTER TABLE ng3_them_surf_to_thermal_zone DROP CONSTRAINT ng3_thm_surf_to_tz_fk2;
ALTER TABLE ng3_thematic_surface DROP CONSTRAINT ng3_them_surf_fk;
ALTER TABLE ng3_time_series DROP CONSTRAINT ng3_ts_fk;
ALTER TABLE ng3_time_series DROP CONSTRAINT ng3_ts_oc_fk;
ALTER TABLE ng3_urban_function_area DROP CONSTRAINT ng3_ufa_fk;
ALTER TABLE ng3_utl_ntw_connection DROP CONSTRAINT ng3_utl_ntw_con_cto_fk;
ALTER TABLE ng3_utl_ntw_connection DROP CONSTRAINT ng3_utl_ntw_con_fk;
ALTER TABLE ng3_weather_data DROP CONSTRAINT ng3_wth_data_fk;
ALTER TABLE ng3_weather_data DROP CONSTRAINT ng3_wth_data_ng3_cto_fk;
ALTER TABLE ng3_weather_data DROP CONSTRAINT ng3_wth_data_ts_fk;
-- ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
-- *********************************** Drop tables ***************************************
-- ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
DROP TABLE ng2_address_to_building_unit CASCADE;
DROP TABLE ng2_building CASCADE;
DROP TABLE ng2_building_partition CASCADE;
DROP TABLE ng2_cityobject CASCADE;
DROP TABLE ng2_ctyobj_relation CASCADE;
DROP TABLE ng2_device CASCADE;
DROP TABLE ng2_device_operation CASCADE;
DROP TABLE ng2_energy_perf_cert CASCADE;
DROP TABLE ng2_layer CASCADE;
DROP TABLE ng2_layered_construction CASCADE;
DROP TABLE ng2_library CASCADE;
DROP TABLE ng2_material CASCADE;
DROP TABLE ng2_occupants CASCADE;
DROP TABLE ng2_opening CASCADE;
DROP TABLE ng2_optical_property CASCADE;
DROP TABLE ng2_qualified_attribute CASCADE;
DROP TABLE ng2_refurbishment_measure CASCADE;
DROP TABLE ng2_resource CASCADE;
DROP TABLE ng2_schedule CASCADE;
DROP TABLE ng2_schedule_component CASCADE;
DROP TABLE ng2_solar_collector CASCADE;
DROP TABLE ng2_storage_device CASCADE;
DROP TABLE ng2_suitability CASCADE;
DROP TABLE ng2_them_surf_to_thermal_zone CASCADE;
DROP TABLE ng2_thematic_surface CASCADE;
DROP TABLE ng2_time_series CASCADE;
DROP TABLE ng2_urban_function_area CASCADE;
DROP TABLE ng2_utl_ntw_connection CASCADE;
DROP TABLE ng2_weather_data CASCADE;
DROP TABLE ng3_address_to_building_unit CASCADE;
DROP TABLE ng3_building CASCADE;
DROP TABLE ng3_building_partition CASCADE;
DROP TABLE ng3_cityobject CASCADE;
DROP TABLE ng3_ctyobj_relation CASCADE;
DROP TABLE ng3_device CASCADE;
DROP TABLE ng3_device_operation CASCADE;
DROP TABLE ng3_energy_perf_cert CASCADE;
DROP TABLE ng3_layer CASCADE;
DROP TABLE ng3_layered_construction CASCADE;
DROP TABLE ng3_library CASCADE;
DROP TABLE ng3_material CASCADE;
DROP TABLE ng3_occupants CASCADE;
DROP TABLE ng3_opening CASCADE;
DROP TABLE ng3_optical_property CASCADE;
DROP TABLE ng3_qualified_attribute CASCADE;
DROP TABLE ng3_refurbishment_measure CASCADE;
DROP TABLE ng3_resource CASCADE;
DROP TABLE ng3_schedule CASCADE;
DROP TABLE ng3_schedule_component CASCADE;
DROP TABLE ng3_solar_collector CASCADE;
DROP TABLE ng3_storage_device CASCADE;
DROP TABLE ng3_suitability CASCADE;
DROP TABLE ng3_them_surf_to_thermal_zone CASCADE;
DROP TABLE ng3_thematic_surface CASCADE;
DROP TABLE ng3_time_series CASCADE;
DROP TABLE ng3_urban_function_area CASCADE;
DROP TABLE ng3_utl_ntw_connection CASCADE;
DROP TABLE ng3_weather_data CASCADE;
-- ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
-- *********************************** Drop Sequences *************************************
-- ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
DROP SEQUENCE ng2_ctyobj_relation_seq;
DROP SEQUENCE ng2_optical_property_seq;
DROP SEQUENCE ng2_qualified_attribute_seq;
DROP SEQUENCE ng2_suitability_seq;
\ No newline at end of file
DROP SEQUENCE ng3_ctyobj_relation_seq;
DROP SEQUENCE ng3_optical_property_seq;
DROP SEQUENCE ng3_qualified_attribute_seq;
DROP SEQUENCE ng3_suitability_seq;
\ No newline at end of file
......@@ -3,9 +3,9 @@
****************************************************************************************
****************************************************************************************
CityGML Energy ADE 2.0 (beta 7)
CityGML Energy ADE 3.0 (beta 7)
Last update: 2025-06-25
Last update: 2025-10-14
This schema mapping file was first automatically generated using the ADE Manager
of the 3DCityDB Importer/Exporter and successively manually edited and restructured.
......@@ -27,13 +27,13 @@ https://3d.bk.tudelft.nl/gagugiaro/
<schemaMapping xmlns="http://www.3dcitydb.org/database/schema/1.0">
<metadata>
<name>Energy ADE</name>
<version>2.0 beta 7 (2025-06-25)</version>
<version>3.0 beta 7 (2025-10-14)</version>
<description>Database schema for the 3DCityDB 4.x</description>
<dbPrefix>ng2</dbPrefix>
<dbPrefix>ng3</dbPrefix>
</metadata>
<applicationSchemas>
<schema id="ng2" isADERoot="true">
<namespace context="citygml-2.0">http://www.citygml.org/ade/energy/2.0</namespace>
<schema id="ng3" isADERoot="true">
<namespace context="citygml-2.0">http://www.citygml.org/ade/energy/3.0</namespace>
</schema>
</applicationSchemas>
......@@ -41,84 +41,84 @@ https://3d.bk.tudelft.nl/gagugiaro/
<complexTypes>
<!-- Abstract Optical Property -->
<complexType abstract="true" id="ng2_AbstractOpticalProperty_Type" table="ng2_optical_property" objectClassId="11001" path="AbstractOpticalProperty" schema="ng2">
<complexAttribute minOccurs="1" maxOccurs="1" path="fraction" schema="ng2">
<attribute column="fraction" type="double" path="." schema="ng2"/>
<complexType abstract="true" id="ng3_AbstractOpticalProperty_Type" table="ng3_optical_property" objectClassId="11001" path="AbstractOpticalProperty" schema="ng3">
<complexAttribute minOccurs="1" maxOccurs="1" path="fraction" schema="ng3">
<attribute column="fraction" type="double" path="." schema="ng3"/>
<attribute column="fraction_uom" type="string" path="@uom" schema="gml"/>
</complexAttribute>
</complexType>
<!-- Emissivity-->
<complexType id="ng2_EmissivityType" table="ng2_optical_property" objectClassId="11002" path="Emissivity" schema="ng2">
<extension base="ng2_AbstractOpticalProperty_Type"/>
<attribute minOccurs="1" maxOccurs="1" column="surface" type="string" path="surface" schema="ng2"/>
<complexType id="ng3_EmissivityType" table="ng3_optical_property" objectClassId="11002" path="Emissivity" schema="ng3">
<extension base="ng3_AbstractOpticalProperty_Type"/>
<attribute minOccurs="1" maxOccurs="1" column="surface" type="string" path="surface" schema="ng3"/>
</complexType>
<!-- Reflectance -->
<complexType id="ng2_ReflectanceType" table="ng2_optical_property" objectClassId="11003" path="Reflectance" schema="ng2">
<extension base="ng2_AbstractOpticalProperty_Type"/>
<attribute minOccurs="1" maxOccurs="1" column="surface" type="string" path="surface" schema="ng2"/>
<attribute minOccurs="1" maxOccurs="1" column="wavelength_range" type="string" path="wavelengthRange" schema="ng2"/>
<complexType id="ng3_ReflectanceType" table="ng3_optical_property" objectClassId="11003" path="Reflectance" schema="ng3">
<extension base="ng3_AbstractOpticalProperty_Type"/>
<attribute minOccurs="1" maxOccurs="1" column="surface" type="string" path="surface" schema="ng3"/>
<attribute minOccurs="1" maxOccurs="1" column="wavelength_range" type="string" path="wavelengthRange" schema="ng3"/>
</complexType>
<!-- Transmittance -->
<complexType id="ng2_TransmittanceType" table="ng2_optical_property" objectClassId="11004" path="Transmittance" schema="ng2">
<extension base="ng2_AbstractOpticalProperty_Type"/>
<attribute minOccurs="1" maxOccurs="1" column="wavelength_range" type="string" path="wavelengthRange" schema="ng2"/>
<complexType id="ng3_TransmittanceType" table="ng3_optical_property" objectClassId="11004" path="Transmittance" schema="ng3">
<extension base="ng3_AbstractOpticalProperty_Type"/>
<attribute minOccurs="1" maxOccurs="1" column="wavelength_range" type="string" path="wavelengthRange" schema="ng3"/>
</complexType>
<!-- Abstract Qualified Attribute (height, area, volume) -->
<complexType abstract="true" id="ng2_AbstractQualifiedAttributeType" table="ng2_qualified_attribute" objectClassId="11005" path="AbstractQualifiedAttribute" schema="ng2">
<attribute maxOccurs="1" column="description" type="string" path="description" schema="ng2"/>
<attribute maxOccurs="1" column="source" type="string" path="description" schema="ng2"/>
<complexType abstract="true" id="ng3_AbstractQualifiedAttributeType" table="ng3_qualified_attribute" objectClassId="11005" path="AbstractQualifiedAttribute" schema="ng3">
<attribute maxOccurs="1" column="description" type="string" path="description" schema="ng3"/>
<attribute maxOccurs="1" column="source" type="string" path="description" schema="ng3"/>
</complexType>
<!-- Qualified Area -->
<complexType id="ng2_QualifiedAreaType" table="ng2_qualified_attribute" objectClassId="11006" path="QualifiedArea" schema="ng2">
<extension base="ng2_AbstractQualifiedAttributeType"/>
<complexAttribute minOccurs="1" maxOccurs="1" path="type" schema="ng2">
<attribute column="type" type="string" path="." schema="ng2"/>
<complexType id="ng3_QualifiedAreaType" table="ng3_qualified_attribute" objectClassId="11006" path="QualifiedArea" schema="ng3">
<extension base="ng3_AbstractQualifiedAttributeType"/>
<complexAttribute minOccurs="1" maxOccurs="1" path="type" schema="ng3">
<attribute column="type" type="string" path="." schema="ng3"/>
<attribute column="type_codespace" type="string" path="@codespace" schema="gml"/>
</complexAttribute>
<complexAttribute minOccurs="1" maxOccurs="1" path="value" schema="ng2">
<attribute column="value" type="double" path="." schema="ng2"/>
<complexAttribute minOccurs="1" maxOccurs="1" path="value" schema="ng3">
<attribute column="value" type="double" path="." schema="ng3"/>
<attribute column="value_uom" type="string" path="@uom" schema="gml"/>
</complexAttribute>
</complexType>
<!-- Qualified Height -->
<complexType id="ng2_QualifiedHeightType" table="ng2_qualified_attribute" objectClassId="11007" path="QualifiedHeight" schema="ng2">
<extension base="ng2_AbstractQualifiedAttributeType"/>
<complexAttribute minOccurs="1" maxOccurs="1" path="type" schema="ng2">
<attribute column="type" type="string" path="." schema="ng2"/>
<complexType id="ng3_QualifiedHeightType" table="ng3_qualified_attribute" objectClassId="11007" path="QualifiedHeight" schema="ng3">
<extension base="ng3_AbstractQualifiedAttributeType"/>
<complexAttribute minOccurs="1" maxOccurs="1" path="type" schema="ng3">
<attribute column="type" type="string" path="." schema="ng3"/>
<attribute column="type_codespace" type="string" path="@codespace" schema="gml"/>
</complexAttribute>
<complexAttribute minOccurs="1" maxOccurs="1" path="value" schema="ng2">
<attribute column="value" type="double" path="." schema="ng2"/>
<complexAttribute minOccurs="1" maxOccurs="1" path="value" schema="ng3">
<attribute column="value" type="double" path="." schema="ng3"/>
<attribute column="value_uom" type="string" path="@uom" schema="gml"/>
</complexAttribute>
</complexType>
<!-- Qualified Volume -->
<complexType id="ng2_QualifiedVolumeType" table="ng2_qualified_attribute" objectClassId="11008" path="QualifiedVolume" schema="ng2">
<extension base="ng2_AbstractQualifiedAttributeType"/>
<complexAttribute minOccurs="1" maxOccurs="1" path="type" schema="ng2">
<attribute column="type" type="string" path="." schema="ng2"/>
<complexType id="ng3_QualifiedVolumeType" table="ng3_qualified_attribute" objectClassId="11008" path="QualifiedVolume" schema="ng3">
<extension base="ng3_AbstractQualifiedAttributeType"/>
<complexAttribute minOccurs="1" maxOccurs="1" path="type" schema="ng3">
<attribute column="type" type="string" path="." schema="ng3"/>
<attribute column="type_codespace" type="string" path="@codespace" schema="gml"/>
</complexAttribute>
<complexAttribute minOccurs="1" maxOccurs="1" path="value" schema="ng2">
<attribute column="value" type="double" path="." schema="ng2"/>
<complexAttribute minOccurs="1" maxOccurs="1" path="value" schema="ng3">
<attribute column="value" type="double" path="." schema="ng3"/>
<attribute column="value_uom" type="string" path="@uom" schema="gml"/>
</complexAttribute>
</complexType>
<!-- CityObjectRelation -->
<complexType id="ng2_CityObjectRelationType" table="ng2_ctyobj_relation" objectClassId="11009" path="CityObjectRelation" schema="ng2">
<complexAttribute minOccurs="1" maxOccurs="1" path="relationType" schema="ng2">
<attribute column="relation_type" type="string" path="." schema="ng2"/>
<complexType id="ng3_CityObjectRelationType" table="ng3_ctyobj_relation" objectClassId="11009" path="CityObjectRelation" schema="ng3">
<complexAttribute minOccurs="1" maxOccurs="1" path="relationType" schema="ng3">
<attribute column="relation_type" type="string" path="." schema="ng3"/>
<attribute column="relation_type_codespace" type="string" path="@codespace" schema="gml"/>
</complexAttribute>
<featureProperty minOccurs="1" maxOccurs="1" target="AbstractCityObjectType" path="relatedTo" schema="ng2" relationType="association">
<featureProperty minOccurs="1" maxOccurs="1" target="AbstractCityObjectType" path="relatedTo" schema="ng3" relationType="association">
<join table="cityobject" fromColumn="cityobject_id" toColumn="id" toRole="parent">
<condition column="objectclass_id" value="${target.objectclass_id}" type="integer"/>
</join>
......@@ -126,18 +126,18 @@ https://3d.bk.tudelft.nl/gagugiaro/
</complexType>
<!-- Suitability -->
<complexType id="ng2_SuitabilityType" table="ng2_suitability" objectClassId="11010" path="Suitability" schema="ng2">
<complexAttribute minOccurs="1" maxOccurs="1" path="reason" schema="ng2">
<complexType id="ng3_SuitabilityType" table="ng3_suitability" objectClassId="11010" path="Suitability" schema="ng3">
<complexAttribute minOccurs="1" maxOccurs="1" path="reason" schema="ng3">
<attribute column="reason_codespace" type="string" path="@codespace" schema="gml"/>
<attribute column="reason" type="string" path="." schema="ng2"/>
<attribute column="reason" type="string" path="." schema="ng3"/>
</complexAttribute>
<attribute maxOccurs="1" column="description" type="string" path="description" schema="ng2"/>
<complexAttribute minOccurs="1" maxOccurs="1" path="value" schema="ng2">
<attribute maxOccurs="1" column="description" type="string" path="description" schema="ng3"/>
<complexAttribute minOccurs="1" maxOccurs="1" path="value" schema="ng3">
<attribute column="value_uom" type="string" path="@uom" schema="gml"/>
<attribute column="value" type="double" path="." schema="ng2"/>
<attribute column="value" type="double" path="." schema="ng3"/>
</complexAttribute>
<featureProperty maxOccurs="1" target="ng2_AbstractScheduleType" path="schedule" schema="ng2" relationType="aggregation">
<join table="ng2_schedule" fromColumn="schedule_id" toColumn="id" toRole="parent">
<featureProperty maxOccurs="1" target="ng3_AbstractScheduleType" path="schedule" schema="ng3" relationType="aggregation">
<join table="ng3_schedule" fromColumn="schedule_id" toColumn="id" toRole="parent">
<condition column="objectclass_id" value="${target.objectclass_id}" type="integer"/>
</join>
</featureProperty>
......@@ -149,163 +149,163 @@ https://3d.bk.tudelft.nl/gagugiaro/
<featureTypes>
<!-- Abstract Time Series -->
<featureType abstract="true" id="ng2_AbstractTimeSeriesType" table="ng2_time_series" objectClassId="11020" path="AbstractTimeSeries" schema="ng2">
<featureType abstract="true" id="ng3_AbstractTimeSeriesType" table="ng3_time_series" objectClassId="11020" path="AbstractTimeSeries" schema="ng3">
<extension base="AbstractFeatureType">
<join table="cityobject" fromColumn="id" toColumn="id" toRole="parent"/>
</extension>
<complexAttribute maxOccurs="1" path="acquisitionMethod" schema="ng2">
<attribute column="acquisition_method" type="string" path="." schema="ng2"/>
<complexAttribute maxOccurs="1" path="acquisitionMethod" schema="ng3">
<attribute column="acquisition_method" type="string" path="." schema="ng3"/>
<attribute column="acquisition_method_codespace" type="string" path="@codespace" schema="gml"/>
</complexAttribute>
<attribute maxOccurs="1" column="interpolation_type" type="string" path="interpolationType" schema="ng2"/>
<attribute maxOccurs="1" column="source" type="string" path="source" schema="ng2"/>
<attribute maxOccurs="1" column="interpolation_type" type="string" path="interpolationType" schema="ng3"/>
<attribute maxOccurs="1" column="source" type="string" path="source" schema="ng3"/>
</featureType>
<!-- Regular Time Series -->
<featureType id="ng2_RegularTimeSeriesType" table="ng2_time_series" objectClassId="11021" path="RegularTimeSeries" schema="ng2">
<extension base="ng2_AbstractTimeSeriesType"/>
<complexAttribute minOccurs="1" maxOccurs="1" path="timeInterval" schema="ng2">
<attribute column="time_interval" type="double" path="." schema="ng2"/>
<featureType id="ng3_RegularTimeSeriesType" table="ng3_time_series" objectClassId="11021" path="RegularTimeSeries" schema="ng3">
<extension base="ng3_AbstractTimeSeriesType"/>
<complexAttribute minOccurs="1" maxOccurs="1" path="timeInterval" schema="ng3">
<attribute column="time_interval" type="double" path="." schema="ng3"/>
<attribute column="time_interval_unit" type="string" path="@unit" schema="gml"/>
<!-- <attribute column="time_interval_radix" type="integer" path="@radix" schema="gml"/> -->
<!-- <attribute column="time_interval_factor" type="integer" path="@factor" schema="gml"/> -->
</complexAttribute>
<complexProperty minOccurs="1" maxOccurs="1" path="temporalExtent" schema="ng2">
<type path="TimePeriod" schema="ng2">
<attribute minOccurs="1" maxOccurs="1" column="period_begin" type="timestamp" path="beginPosition" schema="ng2"/>
<attribute minOccurs="1" maxOccurs="1" column="period_end" type="timestamp" path="endPosition" schema="ng2"/>
<complexProperty minOccurs="1" maxOccurs="1" path="temporalExtent" schema="ng3">
<type path="TimePeriod" schema="ng3">
<attribute minOccurs="1" maxOccurs="1" column="period_begin" type="timestamp" path="beginPosition" schema="ng3"/>
<attribute minOccurs="1" maxOccurs="1" column="period_end" type="timestamp" path="endPosition" schema="ng3"/>
</type>
</complexProperty>
<complexAttribute minOccurs="1" maxOccurs="1" path="values" schema="ng2">
<attribute column="values_list" type="clob" path="." schema="ng2"/>
<attribute column="values_list_uom" type="string" path="@uom" schema="ng2"/>
<complexAttribute minOccurs="1" maxOccurs="1" path="values" schema="ng3">
<attribute column="values_list" type="clob" path="." schema="ng3"/>
<attribute column="values_list_uom" type="string" path="@uom" schema="ng3"/>
</complexAttribute>
</featureType>
<!-- Regular Time Series File -->
<featureType id="ng2_RegularTimeSeriesFileType" table="ng2_time_series" objectClassId="11022" path="RegularTimeSeriesFile" schema="ng2">
<extension base="ng2_AbstractTimeSeriesType"/>
<attribute minOccurs="1" maxOccurs="1" column="uom" type="string" path="uom" schema="ng2"/>
<attribute minOccurs="1" maxOccurs="1" column="file_uri" type="string" path="file" schema="ng2"/>
<complexAttribute minOccurs="1" maxOccurs="1" path="timeInterval" schema="ng2">
<attribute column="time_interval" type="double" path="." schema="ng2"/>
<featureType id="ng3_RegularTimeSeriesFileType" table="ng3_time_series" objectClassId="11022" path="RegularTimeSeriesFile" schema="ng3">
<extension base="ng3_AbstractTimeSeriesType"/>
<attribute minOccurs="1" maxOccurs="1" column="uom" type="string" path="uom" schema="ng3"/>
<attribute minOccurs="1" maxOccurs="1" column="file_uri" type="string" path="file" schema="ng3"/>
<complexAttribute minOccurs="1" maxOccurs="1" path="timeInterval" schema="ng3">
<attribute column="time_interval" type="double" path="." schema="ng3"/>
<attribute column="time_interval_unit" type="string" path="@unit" schema="gml"/>
<!-- <attribute column="time_interval_radix" type="integer" path="@radix" schema="gml"/> -->
<!-- <attribute column="time_interval_factor" type="integer" path="@factor" schema="gml"/> -->
</complexAttribute>
<attribute maxOccurs="1" column="num_of_header_lines" type="integer" path="numberOfHeaderLines" schema="ng2"/>
<attribute maxOccurs="1" column="field_separator" type="string" path="fieldSeparator" schema="ng2"/>
<attribute maxOccurs="1" column="record_separator" type="string" path="recordSeparator" schema="ng2"/>
<attribute maxOccurs="1" column="decimal_symbol" type="string" path="decimalSymbol" schema="ng2"/>
<attribute maxOccurs="1" column="value_column_number" type="integer" path="valueColumnNumber" schema="ng2"/>
<complexProperty minOccurs="1" maxOccurs="1" path="temporalExtent" schema="ng2">
<type path="TimePeriod" schema="ng2">
<attribute minOccurs="1" maxOccurs="1" column="period_begin" type="timestamp" path="beginPosition" schema="ng2"/>
<attribute minOccurs="1" maxOccurs="1" column="period_end" type="timestamp" path="endPosition" schema="ng2"/>
<attribute maxOccurs="1" column="num_of_header_lines" type="integer" path="numberOfHeaderLines" schema="ng3"/>
<attribute maxOccurs="1" column="field_separator" type="string" path="fieldSeparator" schema="ng3"/>
<attribute maxOccurs="1" column="record_separator" type="string" path="recordSeparator" schema="ng3"/>
<attribute maxOccurs="1" column="decimal_symbol" type="string" path="decimalSymbol" schema="ng3"/>
<attribute maxOccurs="1" column="value_column_number" type="integer" path="valueColumnNumber" schema="ng3"/>
<complexProperty minOccurs="1" maxOccurs="1" path="temporalExtent" schema="ng3">
<type path="TimePeriod" schema="ng3">
<attribute minOccurs="1" maxOccurs="1" column="period_begin" type="timestamp" path="beginPosition" schema="ng3"/>
<attribute minOccurs="1" maxOccurs="1" column="period_end" type="timestamp" path="endPosition" schema="ng3"/>
</type>
</complexProperty>
</featureType>
<!-- Typical Values Time Series -->
<featureType id="ng2_TypicalValuesTimeSeriesType" table="ng2_time_series" objectClassId="11023" path="TypicalValuesTimeSeries" schema="ng2">
<extension base="ng2_AbstractTimeSeriesType"/>
<attribute maxOccurs="1" column="start_time" type="timestamp" path="startTime" schema="ng2"/>
<attribute maxOccurs="1" column="start_day" type="integer" path="startDay" schema="ng2"/>
<attribute maxOccurs="1" column="start_month" type="integer" path="startMonth" schema="ng2"/>
<complexAttribute minOccurs="1" maxOccurs="1" path="temporalExtent" schema="ng2">
<attribute column="temporal_extent" type="double" path="." schema="ng2"/>
<featureType id="ng3_TypicalValuesTimeSeriesType" table="ng3_time_series" objectClassId="11023" path="TypicalValuesTimeSeries" schema="ng3">
<extension base="ng3_AbstractTimeSeriesType"/>
<attribute maxOccurs="1" column="start_time" type="timestamp" path="startTime" schema="ng3"/>
<attribute maxOccurs="1" column="start_day" type="integer" path="startDay" schema="ng3"/>
<attribute maxOccurs="1" column="start_month" type="integer" path="startMonth" schema="ng3"/>
<complexAttribute minOccurs="1" maxOccurs="1" path="temporalExtent" schema="ng3">
<attribute column="temporal_extent" type="double" path="." schema="ng3"/>
<attribute column="temporal_extent_unit" type="string" path="@unit" schema="gml"/>
<!-- <attribute column="temporal_extent_radix" type="integer" path="@radix" schema="gml"/> -->
<!-- <attribute column="temporal_extent_factor" type="integer" path="@factor" schema="gml"/> -->
</complexAttribute>
<complexAttribute minOccurs="1" maxOccurs="1" path="timeInterval" schema="ng2">
<attribute column="time_interval" type="double" path="." schema="ng2"/>
<complexAttribute minOccurs="1" maxOccurs="1" path="timeInterval" schema="ng3">
<attribute column="time_interval" type="double" path="." schema="ng3"/>
<attribute column="time_interval_unit" type="string" path="@unit" schema="gml"/>
<!-- <attribute column="time_interval_radix" type="integer" path="@radix" schema="gml"/> -->
<!-- <attribute column="time_interval_factor" type="integer" path="@factor" schema="gml"/> -->
</complexAttribute>
<complexAttribute minOccurs="1" maxOccurs="1" path="values" schema="ng2">
<attribute column="values_list" type="clob" path="." schema="ng2"/>
<attribute column="values_list_uom" type="string" path="@uom" schema="ng2"/>
<complexAttribute minOccurs="1" maxOccurs="1" path="values" schema="ng3">
<attribute column="values_list" type="clob" path="." schema="ng3"/>
<attribute column="values_list_uom" type="string" path="@uom" schema="ng3"/>
</complexAttribute>
</featureType>
<!-- Typical Values Time Series File -->
<featureType id="ng2_TypicalValuesTimeSeriesFileType" table="ng2_time_series" objectClassId="11024" path="TypicalValuesTimeSeriesFile" schema="ng2">
<extension base="ng2_AbstractTimeSeriesType"/>
<attribute maxOccurs="1" column="start_time" type="timestamp" path="startTime" schema="ng2"/>
<attribute maxOccurs="1" column="start_day" type="integer" path="startDay" schema="ng2"/>
<attribute maxOccurs="1" column="start_month" type="integer" path="startMonth" schema="ng2"/>
<attribute minOccurs="1" maxOccurs="1" column="uom" type="string" path="uom" schema="ng2"/>
<attribute minOccurs="1" maxOccurs="1" column="file_uri" type="string" path="file" schema="ng2"/>
<complexAttribute minOccurs="1" maxOccurs="1" path="temporalExtent" schema="ng2">
<attribute column="temporal_extent" type="double" path="." schema="ng2"/>
<featureType id="ng3_TypicalValuesTimeSeriesFileType" table="ng3_time_series" objectClassId="11024" path="TypicalValuesTimeSeriesFile" schema="ng3">
<extension base="ng3_AbstractTimeSeriesType"/>
<attribute maxOccurs="1" column="start_time" type="timestamp" path="startTime" schema="ng3"/>
<attribute maxOccurs="1" column="start_day" type="integer" path="startDay" schema="ng3"/>
<attribute maxOccurs="1" column="start_month" type="integer" path="startMonth" schema="ng3"/>
<attribute minOccurs="1" maxOccurs="1" column="uom" type="string" path="uom" schema="ng3"/>
<attribute minOccurs="1" maxOccurs="1" column="file_uri" type="string" path="file" schema="ng3"/>
<complexAttribute minOccurs="1" maxOccurs="1" path="temporalExtent" schema="ng3">
<attribute column="temporal_extent" type="double" path="." schema="ng3"/>
<attribute column="temporal_extent_unit" type="string" path="@unit" schema="gml"/>
<!-- <attribute column="temporal_extent_radix" type="integer" path="@radix" schema="gml"/> -->
<!-- <attribute column="temporal_extent_factor" type="integer" path="@factor" schema="gml"/> -->
</complexAttribute>
<complexAttribute minOccurs="1" maxOccurs="1" path="timeInterval" schema="ng2">
<attribute column="time_interval" type="double" path="." schema="ng2"/>
<complexAttribute minOccurs="1" maxOccurs="1" path="timeInterval" schema="ng3">
<attribute column="time_interval" type="double" path="." schema="ng3"/>
<attribute column="time_interval_unit" type="string" path="@unit" schema="gml"/>
<!-- <attribute column="time_interval_radix" type="integer" path="@radix" schema="gml"/> -->
<!-- <attribute column="time_interval_factor" type="integer" path="@factor" schema="gml"/> -->
</complexAttribute>
<attribute maxOccurs="1" column="num_of_header_lines" type="integer" path="numberOfHeaderLines" schema="ng2"/>
<attribute minOccurs="1" maxOccurs="1" column="field_separator" type="string" path="fieldSeparator" schema="ng2"/>
<attribute maxOccurs="1" column="record_separator" type="string" path="recordSeparator" schema="ng2"/>
<attribute maxOccurs="1" column="decimal_symbol" type="string" path="decimalSymbol" schema="ng2"/>
<attribute maxOccurs="1" column="value_column_number" type="integer" path="valueColumnNumber" schema="ng2"/>
<attribute maxOccurs="1" column="num_of_header_lines" type="integer" path="numberOfHeaderLines" schema="ng3"/>
<attribute minOccurs="1" maxOccurs="1" column="field_separator" type="string" path="fieldSeparator" schema="ng3"/>
<attribute maxOccurs="1" column="record_separator" type="string" path="recordSeparator" schema="ng3"/>
<attribute maxOccurs="1" column="decimal_symbol" type="string" path="decimalSymbol" schema="ng3"/>
<attribute maxOccurs="1" column="value_column_number" type="integer" path="valueColumnNumber" schema="ng3"/>
</featureType>
<!-- Sensor Connection -->
<featureType id="ng2_SensorConnectionType" table="ng2_time_series" objectClassId="11025" path="SensorConnection" schema="ng2">
<extension base="ng2_AbstractTimeSeriesType"/>
<complexAttribute minOccurs="1" maxOccurs="1" path="temporalExtent" schema="ng2">
<attribute column="temporal_extent" type="double" path="." schema="ng2"/>
<featureType id="ng3_SensorConnectionType" table="ng3_time_series" objectClassId="11025" path="SensorConnection" schema="ng3">
<extension base="ng3_AbstractTimeSeriesType"/>
<complexAttribute minOccurs="1" maxOccurs="1" path="temporalExtent" schema="ng3">
<attribute column="temporal_extent" type="double" path="." schema="ng3"/>
<attribute column="temporal_extent_unit" type="string" path="@unit" schema="gml"/>
<!-- <attribute column="temporal_extent_radix" type="integer" path="@radix" schema="gml"/> -->
<!-- <attribute column="temporal_extent_factor" type="integer" path="@factor" schema="gml"/> -->
</complexAttribute>
<complexAttribute minOccurs="1" maxOccurs="1" path="connectionType" schema="ng2">
<attribute column="connection_type" type="string" path="." schema="ng2"/>
<complexAttribute minOccurs="1" maxOccurs="1" path="connectionType" schema="ng3">
<attribute column="connection_type" type="string" path="." schema="ng3"/>
<attribute column="connection_type_codespace" type="string" path="@codespace" schema="gml"/>
</complexAttribute>
<attribute minOccurs="1" maxOccurs="1" column="observation_property" type="string" path="observationProperty" schema="ng2"/>
<attribute maxOccurs="1" column="uom" type="string" path="uom" schema="ng2"/>
<attribute maxOccurs="1" column="sensor_id" type="string" path="sensorID" schema="ng2"/>
<attribute maxOccurs="1" column="sensor_name" type="string" path="sensorName" schema="ng2"/>
<attribute maxOccurs="1" column="observation_id" type="string" path="observationID" schema="ng2"/>
<attribute maxOccurs="1" column="datastream_id" type="string" path="datastreamID" schema="ng2"/>
<attribute maxOccurs="1" column="base_url" type="string" path="baseURL" schema="ng2"/>
<complexAttribute maxOccurs="1" path="authType" schema="ng2">
<attribute column="auth_type" type="string" path="." schema="ng2"/>
<attribute minOccurs="1" maxOccurs="1" column="observation_property" type="string" path="observationProperty" schema="ng3"/>
<attribute maxOccurs="1" column="uom" type="string" path="uom" schema="ng3"/>
<attribute maxOccurs="1" column="sensor_id" type="string" path="sensorID" schema="ng3"/>
<attribute maxOccurs="1" column="sensor_name" type="string" path="sensorName" schema="ng3"/>
<attribute maxOccurs="1" column="observation_id" type="string" path="observationID" schema="ng3"/>
<attribute maxOccurs="1" column="datastream_id" type="string" path="datastreamID" schema="ng3"/>
<attribute maxOccurs="1" column="base_url" type="string" path="baseURL" schema="ng3"/>
<complexAttribute maxOccurs="1" path="authType" schema="ng3">
<attribute column="auth_type" type="string" path="." schema="ng3"/>
<attribute column="auth_type_codespace" type="string" path="@codespace" schema="gml"/>
</complexAttribute>
<attribute maxOccurs="1" column="mqtt_server" type="string" path="mqttServer" schema="ng2"/>
<attribute maxOccurs="1" column="mqtt_topic" type="string" path="mqttTopic" schema="ng2"/>
<attribute maxOccurs="1" column="link_to_observation" type="string" path="linkToObservation" schema="ng2"/>
<attribute maxOccurs="1" column="link_to_sensor_description" type="string" path="linkToSensorDescription" schema="ng2"/>
<attribute maxOccurs="1" column="mqtt_server" type="string" path="mqttServer" schema="ng3"/>
<attribute maxOccurs="1" column="mqtt_topic" type="string" path="mqttTopic" schema="ng3"/>
<attribute maxOccurs="1" column="link_to_observation" type="string" path="linkToObservation" schema="ng3"/>
<attribute maxOccurs="1" column="link_to_sensor_description" type="string" path="linkToSensorDescription" schema="ng3"/>
</featureType>
<!-- Abstract Schedule -->
<featureType abstract="true" id="ng2_AbstractScheduleType" table="ng2_schedule" objectClassId="11030" path="AbstractSchedule" schema="ng2">
<featureType abstract="true" id="ng3_AbstractScheduleType" table="ng3_schedule" objectClassId="11030" path="AbstractSchedule" schema="ng3">
<extension base="AbstractFeatureType">
<join table="cityobject" fromColumn="id" toColumn="id" toRole="parent"/>
</extension>
<complexAttribute maxOccurs="1" path="libraryCode" schema="ng2">
<attribute column="library_code" type="string" path="." schema="ng2"/>
<complexAttribute maxOccurs="1" path="libraryCode" schema="ng3">
<attribute column="library_code" type="string" path="." schema="ng3"/>
<attribute column="library_code_codespace" type="string" path="@codespace" schema="gml"/>
</complexAttribute>
<complexAttribute minOccurs="1" maxOccurs="1" path="type" schema="ng2">
<attribute column="type" type="string" path="." schema="ng2"/>
<complexAttribute minOccurs="1" maxOccurs="1" path="type" schema="ng3">
<attribute column="type" type="string" path="." schema="ng3"/>
<attribute column="type_codespace" type="string" path="@codespace" schema="gml"/>
</complexAttribute>
<attribute maxOccurs="1" column="start_time" type="timestamp" path="startTime" schema="ng2"/>
<attribute maxOccurs="1" column="start_day" type="integer" path="startDay" schema="ng2"/>
<attribute maxOccurs="1" column="start_month" type="integer" path="startMonth" schema="ng2"/>
<attribute maxOccurs="1" column="start_year" type="integer" path="startYear" schema="ng2"/>
<complexAttribute maxOccurs="1" path="temporalExtent" schema="ng2">
<attribute column="time_interval" type="double" path="." schema="ng2"/>
<attribute maxOccurs="1" column="start_time" type="timestamp" path="startTime" schema="ng3"/>
<attribute maxOccurs="1" column="start_day" type="integer" path="startDay" schema="ng3"/>
<attribute maxOccurs="1" column="start_month" type="integer" path="startMonth" schema="ng3"/>
<attribute maxOccurs="1" column="start_year" type="integer" path="startYear" schema="ng3"/>
<complexAttribute maxOccurs="1" path="temporalExtent" schema="ng3">
<attribute column="time_interval" type="double" path="." schema="ng3"/>
<attribute column="time_interval_unit" type="string" path="@unit" schema="gml"/>
<!-- <attribute column="time_interval_radix" type="integer" path="@radix" schema="gml"/> -->
<!-- <attribute column="time_interval_factor" type="integer" path="@factor" schema="gml"/> -->
......@@ -313,478 +313,478 @@ https://3d.bk.tudelft.nl/gagugiaro/
</featureType>
<!-- Atomic Schedule -->
<featureType id="ng2_AtomicScheduleType" table="ng2_schedule" objectClassId="11031" path="AtomicSchedule" schema="ng2">
<extension base="ng2_AbstractScheduleType"/>
<complexAttribute minOccurs="0" maxOccurs="1" path="constantValue" schema="ng2">
<attribute column="constant_value" type="double" path="." schema="ng2"/>
<featureType id="ng3_AtomicScheduleType" table="ng3_schedule" objectClassId="11031" path="AtomicSchedule" schema="ng3">
<extension base="ng3_AbstractScheduleType"/>
<complexAttribute minOccurs="0" maxOccurs="1" path="constantValue" schema="ng3">
<attribute column="constant_value" type="double" path="." schema="ng3"/>
<attribute column="constant_value_uom" type="string" path="@uom" schema="gml"/>
</complexAttribute>
<featureProperty minOccurs="0" maxOccurs="1" target="ng2_AbstractTimeSeriesType" path="timeSeries" schema="ng2" relationType="composition">
<join table="ng2_time_series" fromColumn="time_series_id" toColumn="id" toRole="parent">
<featureProperty minOccurs="0" maxOccurs="1" target="ng3_AbstractTimeSeriesType" path="timeSeries" schema="ng3" relationType="composition">
<join table="ng3_time_series" fromColumn="time_series_id" toColumn="id" toRole="parent">
<condition column="objectclass_id" value="${target.objectclass_id}" type="integer"/>
</join>
</featureProperty>
</featureType>
<!-- Dual Value Schedule -->
<featureType id="ng2_DualValueScheduleType" table="ng2_schedule" objectClassId="11032" path="DualValueSchedule" schema="ng2">
<extension base="ng2_AbstractScheduleType"/>
<complexAttribute minOccurs="1" maxOccurs="1" path="idleValue" schema="ng2">
<attribute column="idle_value" type="double" path="." schema="ng2"/>
<featureType id="ng3_DualValueScheduleType" table="ng3_schedule" objectClassId="11032" path="DualValueSchedule" schema="ng3">
<extension base="ng3_AbstractScheduleType"/>
<complexAttribute minOccurs="1" maxOccurs="1" path="idleValue" schema="ng3">
<attribute column="idle_value" type="double" path="." schema="ng3"/>
<attribute column="idle_value_uom" type="string" path="@uom" schema="gml"/>
</complexAttribute>
<complexAttribute minOccurs="1" maxOccurs="1" path="usageValue" schema="ng2">
<attribute column="usage_value" type="double" path="." schema="ng2"/>
<complexAttribute minOccurs="1" maxOccurs="1" path="usageValue" schema="ng3">
<attribute column="usage_value" type="double" path="." schema="ng3"/>
<attribute column="usage_value_uom" type="string" path="@uom" schema="gml"/>
</complexAttribute>
<attribute minOccurs="1" maxOccurs="1" column="start_usage_time" type="timestamp" path="startUsageTime" schema="ng2"/>
<attribute minOccurs="1" maxOccurs="1" column="end_usage_time" type="timestamp" path="endUsageTime" schema="ng2"/>
<attribute minOccurs="1" maxOccurs="1" column="start_usage_time" type="timestamp" path="startUsageTime" schema="ng3"/>
<attribute minOccurs="1" maxOccurs="1" column="end_usage_time" type="timestamp" path="endUsageTime" schema="ng3"/>
</featureType>
<!-- Composite Schedule -->
<featureType id="ng2_CompositeScheduleType" table="ng2_schedule" objectClassId="11033" path="CompositeSchedule" schema="ng2">
<extension base="ng2_AbstractScheduleType"/>
<featureProperty minOccurs="1" target="ng2_ScheduleComponentType" path="scheduleComponent" schema="ng2" relationType="composition">
<join table="ng2_schedule_component" fromColumn="id" toColumn="parent_schedule_id" toRole="child">
<featureType id="ng3_CompositeScheduleType" table="ng3_schedule" objectClassId="11033" path="CompositeSchedule" schema="ng3">
<extension base="ng3_AbstractScheduleType"/>
<featureProperty minOccurs="1" target="ng3_ScheduleComponentType" path="scheduleComponent" schema="ng3" relationType="composition">
<join table="ng3_schedule_component" fromColumn="id" toColumn="parent_schedule_id" toRole="child">
<condition column="objectclass_id" value="${target.objectclass_id}" type="integer"/>
</join>
</featureProperty>
</featureType>
<!-- Schedule Component -->
<featureType id="ng2_ScheduleComponentType" table="ng2_schedule_component" objectClassId="11034" path="ScheduleComponent" schema="ng2">
<featureType id="ng3_ScheduleComponentType" table="ng3_schedule_component" objectClassId="11034" path="ScheduleComponent" schema="ng3">
<extension base="AbstractFeatureType">
<join table="cityobject" fromColumn="id" toColumn="id" toRole="parent"/>
</extension>
<complexAttribute minOccurs="1" maxOccurs="1" path="type" schema="ng2">
<attribute column="type" type="string" path="." schema="ng2"/>
<complexAttribute minOccurs="1" maxOccurs="1" path="type" schema="ng3">
<attribute column="type" type="string" path="." schema="ng3"/>
<attribute column="type_codespace" type="string" path="@codespace" schema="gml"/>
</complexAttribute>
<attribute minOccurs="1" maxOccurs="1" column="repetitions" type="integer" path="repetitions" schema="ng2"/>
<complexAttribute maxOccurs="1" path="additionalGap" schema="ng2">
<attribute column="additional_gap" type="double" path="." schema="ng2"/>
<attribute minOccurs="1" maxOccurs="1" column="repetitions" type="integer" path="repetitions" schema="ng3"/>
<complexAttribute maxOccurs="1" path="additionalGap" schema="ng3">
<attribute column="additional_gap" type="double" path="." schema="ng3"/>
<attribute column="additional_gap_unit" type="string" path="@unit" schema="gml"/>
<!-- <attribute column="additional_gap_radix" type="integer" path="@radix" schema="gml"/> -->
<!-- <attribute column="additional_gap_factor" type="integer" path="@factor" schema="gml"/> -->
</complexAttribute>
<featureProperty minOccurs="1" maxOccurs="1" target="ng2_AbstractScheduleType" path="scheduleComponentMember" schema="ng2" relationType="aggregation">
<join table="ng2_schedule" fromColumn="schedule_id" toColumn="id" toRole="parent">
<featureProperty minOccurs="1" maxOccurs="1" target="ng3_AbstractScheduleType" path="scheduleComponentMember" schema="ng3" relationType="aggregation">
<join table="ng3_schedule" fromColumn="schedule_id" toColumn="id" toRole="parent">
<condition column="objectclass_id" value="${target.objectclass_id}" type="integer"/>
</join>
</featureProperty>
</featureType>
<!-- Energy Performance Certificate -->
<featureType id="ng2_EnergyPerformanceCertificateType" table="ng2_energy_perf_cert" objectClassId="11040" path="EnergyPerformanceCertificate" schema="ng2">
<featureType id="ng3_EnergyPerformanceCertificateType" table="ng3_energy_perf_cert" objectClassId="11040" path="EnergyPerformanceCertificate" schema="ng3">
<extension base="AbstractFeatureType">
<join table="cityobject" fromColumn="id" toColumn="id" toRole="parent"/>
</extension>
<complexAttribute minOccurs="1" maxOccurs="1" path="type" schema="ng2">
<attribute column="type" type="string" path="." schema="ng2"/>
<complexAttribute minOccurs="1" maxOccurs="1" path="type" schema="ng3">
<attribute column="type" type="string" path="." schema="ng3"/>
<attribute column="type_codespace" type="string" path="@codespace" schema="gml"/>
</complexAttribute>
<complexAttribute maxOccurs="1" path="value" schema="ng2">
<attribute column="value" type="double" path="." schema="ng2"/>
<complexAttribute maxOccurs="1" path="value" schema="ng3">
<attribute column="value" type="double" path="." schema="ng3"/>
<attribute column="value_uom" type="string" path="@uom" schema="gml"/>
</complexAttribute>
<attribute minOccurs="1" maxOccurs="1" column="label" type="string" path="label" schema="ng2"/>
<attribute maxOccurs="1" column="issue_date" type="date" path="issueDate" schema="ng2"/>
<attribute maxOccurs="1" column="expiration_date" type="date" path="expirationDate" schema="ng2"/>
<attribute maxOccurs="1" column="cert_method" type="string" path="certificationMethod" schema="ng2"/>
<attribute maxOccurs="1" column="cert_uri" type="string" path="certificationURI" schema="ng2"/>
<attribute minOccurs="1" maxOccurs="1" column="label" type="string" path="label" schema="ng3"/>
<attribute maxOccurs="1" column="issue_date" type="date" path="issueDate" schema="ng3"/>
<attribute maxOccurs="1" column="expiration_date" type="date" path="expirationDate" schema="ng3"/>
<attribute maxOccurs="1" column="cert_method" type="string" path="certificationMethod" schema="ng3"/>
<attribute maxOccurs="1" column="cert_uri" type="string" path="certificationURI" schema="ng3"/>
</featureType>
<!-- Refurbishment Measure -->
<featureType id="ng2_RefurbishmentMeasureType" table="ng2_refurbishment_measure" objectClassId="11041" path="RefurbishmentMeasure" schema="ng2">
<featureType id="ng3_RefurbishmentMeasureType" table="ng3_refurbishment_measure" objectClassId="11041" path="RefurbishmentMeasure" schema="ng3">
<extension base="AbstractFeatureType">
<join table="cityobject" fromColumn="id" toColumn="id" toRole="parent"/>
</extension>
<complexAttribute minOccurs="1" maxOccurs="1" path="type" schema="ng2">
<attribute column="type" type="string" path="." schema="ng2"/>
<complexAttribute minOccurs="1" maxOccurs="1" path="type" schema="ng3">
<attribute column="type" type="string" path="." schema="ng3"/>
<attribute column="type_codespace" type="string" path="@codespace" schema="gml"/>
</complexAttribute>
<attribute minOccurs="0" maxOccurs="1" column="start_date" type="date" path="startDate" schema="ng2"/>
<attribute minOccurs="1" maxOccurs="1" column="end_date" type="date" path="endDate" schema="ng2"/>
<complexAttribute maxOccurs="1" path="libraryCode" schema="ng2">
<attribute column="library_code" type="string" path="." schema="ng2"/>
<attribute minOccurs="0" maxOccurs="1" column="start_date" type="date" path="startDate" schema="ng3"/>
<attribute minOccurs="1" maxOccurs="1" column="end_date" type="date" path="endDate" schema="ng3"/>
<complexAttribute maxOccurs="1" path="libraryCode" schema="ng3">
<attribute column="library_code" type="string" path="." schema="ng3"/>
<attribute column="library_code_codespace" type="string" path="@codespace" schema="gml"/>
</complexAttribute>
</featureType>
<!-- Utility Network Connection -->
<featureType id="ng2_UtilityNetworkConnectionType" table="ng2_utl_ntw_connection" objectClassId="11042" path="UtilityNetworkConnection" schema="ng2">
<featureType id="ng3_UtilityNetworkConnectionType" table="ng3_utl_ntw_connection" objectClassId="11042" path="UtilityNetworkConnection" schema="ng3">
<extension base="AbstractFeatureType">
<join table="cityobject" fromColumn="id" toColumn="id" toRole="parent"/>
</extension>
<complexAttribute minOccurs="1" maxOccurs="1" path="networkType" schema="ng2">
<attribute column="network_type" type="string" path="." schema="ng2"/>
<complexAttribute minOccurs="1" maxOccurs="1" path="networkType" schema="ng3">
<attribute column="network_type" type="string" path="." schema="ng3"/>
<attribute column="network_type_codespace" type="string" path="@codespace" schema="gml"/>
</complexAttribute>
<attribute minOccurs="1" maxOccurs="1" column="connection_status" type="string" path="connectionStatus" schema="ng2"/>
<complexAttribute maxOccurs="1" path="functionInNetwork" schema="ng2">
<attribute column="function_in_network" type="string" path="." schema="ng2"/>
<attribute minOccurs="1" maxOccurs="1" column="connection_status" type="string" path="connectionStatus" schema="ng3"/>
<complexAttribute maxOccurs="1" path="functionInNetwork" schema="ng3">
<attribute column="function_in_network" type="string" path="." schema="ng3"/>
<attribute column="function_in_network_codespace" type="string" path="@codespace" schema="gml"/>
</complexAttribute>
<complexAttribute maxOccurs="1" path="usageInNetwork" schema="ng2">
<attribute column="usage_in_network" type="string" path="." schema="ng2"/>
<complexAttribute maxOccurs="1" path="usageInNetwork" schema="ng3">
<attribute column="usage_in_network" type="string" path="." schema="ng3"/>
<attribute column="usage_in_network_codespace" type="string" path="@codespace" schema="gml"/>
</complexAttribute>
<attribute maxOccurs="1" column="network_id" type="string" path="networkID" schema="ng2"/>
<attribute maxOccurs="1" column="network_node_id" type="string" path="networkNodeID" schema="ng2"/>
<attribute maxOccurs="1" column="network_id" type="string" path="networkID" schema="ng3"/>
<attribute maxOccurs="1" column="network_node_id" type="string" path="networkNodeID" schema="ng3"/>
</featureType>
<!-- Weather Data -->
<featureType id="ng2_WeatherDataType" table="ng2_weather_data" objectClassId="11043" path="WeatherData" schema="ng2">
<featureType id="ng3_WeatherDataType" table="ng3_weather_data" objectClassId="11043" path="WeatherData" schema="ng3">
<extension base="AbstractFeatureType">
<join table="cityobject" fromColumn="id" toColumn="id" toRole="parent"/>
</extension>
<complexAttribute maxOccurs="1" path="libraryCode" schema="ng2">
<attribute column="library_code" type="string" path="." schema="ng2"/>
<complexAttribute maxOccurs="1" path="libraryCode" schema="ng3">
<attribute column="library_code" type="string" path="." schema="ng3"/>
<attribute column="library_code_codespace" type="string" path="@codespace" schema="gml"/>
</complexAttribute>
<complexAttribute minOccurs="1" maxOccurs="1" path="type" schema="ng2">
<attribute column="type" type="string" path="." schema="ng2"/>
<complexAttribute minOccurs="1" maxOccurs="1" path="type" schema="ng3">
<attribute column="type" type="string" path="." schema="ng3"/>
<attribute column="type_codespace" type="string" path="@codespace" schema="gml"/>
</complexAttribute>
<complexAttribute minOccurs="1" maxOccurs="1" path="valueType" schema="ng2">
<attribute column="value_type" type="string" path="." schema="ng2"/>
<complexAttribute minOccurs="1" maxOccurs="1" path="valueType" schema="ng3">
<attribute column="value_type" type="string" path="." schema="ng3"/>
<attribute column="value_type_codespace" type="string" path="@codespace" schema="gml"/>
</complexAttribute>
<complexAttribute maxOccurs="1" path="yearlyValue" schema="ng2">
<attribute column="yearly_value" type="double" path="." schema="ng2"/>
<complexAttribute maxOccurs="1" path="yearlyValue" schema="ng3">
<attribute column="yearly_value" type="double" path="." schema="ng3"/>
<attribute column="yearly_value_uom" type="string" path="@uom" schema="gml"/>
</complexAttribute>
<featureProperty maxOccurs="1" target="ng2_AbstractTimeSeriesType" path="timeSeries" schema="ng2" relationType="composition">
<join table="ng2_time_series" fromColumn="time_series_id" toColumn="id" toRole="parent">
<featureProperty maxOccurs="1" target="ng3_AbstractTimeSeriesType" path="timeSeries" schema="ng3" relationType="composition">
<join table="ng3_time_series" fromColumn="time_series_id" toColumn="id" toRole="parent">
<condition column="objectclass_id" value="${target.objectclass_id}" type="integer"/>
</join>
</featureProperty>
<geometryProperty maxOccurs="1" inlineColumn="position" type="Point" path="position" schema="ng2"/>
<geometryProperty maxOccurs="1" inlineColumn="position" type="Point" path="position" schema="ng3"/>
</featureType>
<!-- Abstract Layered Construction -->
<featureType abstract="true" id="ng2_AbstractLayeredConstructionType" table="ng2_layered_construction" objectClassId="11050" path="AbstractLayeredConstruction" schema="ng2">
<featureType abstract="true" id="ng3_AbstractLayeredConstructionType" table="ng3_layered_construction" objectClassId="11050" path="AbstractLayeredConstruction" schema="ng3">
<extension base="AbstractFeatureType">
<join table="cityobject" fromColumn="id" toColumn="id" toRole="parent"/>
</extension>
</featureType>
<!-- Layered Construction -->
<featureType id="ng2_LayeredConstructionType" table="ng2_layered_construction" objectClassId="11051" path="LayeredConstruction" schema="ng2">
<extension base="ng2_AbstractLayeredConstructionType"/>
<complexAttribute maxOccurs="1" path="libraryCode" schema="ng2">
<attribute column="library_code" type="string" path="." schema="ng2"/>
<featureType id="ng3_LayeredConstructionType" table="ng3_layered_construction" objectClassId="11051" path="LayeredConstruction" schema="ng3">
<extension base="ng3_AbstractLayeredConstructionType"/>
<complexAttribute maxOccurs="1" path="libraryCode" schema="ng3">
<attribute column="library_code" type="string" path="." schema="ng3"/>
<attribute column="library_code_codespace" type="string" path="@codespace" schema="gml"/>
</complexAttribute>
<complexAttribute maxOccurs="1" path="uValue" schema="ng2">
<attribute column="u_value" type="double" path="." schema="ng2"/>
<complexAttribute maxOccurs="1" path="uValue" schema="ng3">
<attribute column="u_value" type="double" path="." schema="ng3"/>
<attribute column="u_value_uom" type="string" path="@uom" schema="gml"/>
</complexAttribute>
<complexAttribute maxOccurs="1" path="gValue" schema="ng2">
<attribute column="g_value" type="double" path="." schema="ng2"/>
<complexAttribute maxOccurs="1" path="gValue" schema="ng3">
<attribute column="g_value" type="double" path="." schema="ng3"/>
<attribute column="g_value_uom" type="string" path="@uom" schema="gml"/>
</complexAttribute>
<complexAttribute maxOccurs="1" path="glazingRatio" schema="ng2">
<attribute column="glazing_ratio" type="double" path="." schema="ng2"/>
<complexAttribute maxOccurs="1" path="glazingRatio" schema="ng3">
<attribute column="glazing_ratio" type="double" path="." schema="ng3"/>
<attribute column="glazing_ratio_uom" type="string" path="@uom" schema="gml"/>
</complexAttribute>
<complexProperty refType="ng2_EmissivityType" path="emissivity" schema="ng2">
<join table="ng2_optical_property" fromColumn="id" toColumn="layered_construction_id" toRole="child">
<complexProperty refType="ng3_EmissivityType" path="emissivity" schema="ng3">
<join table="ng3_optical_property" fromColumn="id" toColumn="layered_construction_id" toRole="child">
<condition column="objectclass_id" value="${target.objectclass_id}" type="integer"/>
</join>
</complexProperty>
<complexProperty refType="ng2_ReflectanceType" path="reflectance" schema="ng2">
<join table="ng2_optical_property" fromColumn="id" toColumn="layered_construction_id" toRole="child">
<complexProperty refType="ng3_ReflectanceType" path="reflectance" schema="ng3">
<join table="ng3_optical_property" fromColumn="id" toColumn="layered_construction_id" toRole="child">
<condition column="objectclass_id" value="${target.objectclass_id}" type="integer"/>
</join>
</complexProperty>
<complexProperty refType="ng2_TransmittanceType" path="transmittance" schema="ng2">
<join table="ng2_optical_property" fromColumn="id" toColumn="layered_construction_id" toRole="child">
<complexProperty refType="ng3_TransmittanceType" path="transmittance" schema="ng3">
<join table="ng3_optical_property" fromColumn="id" toColumn="layered_construction_id" toRole="child">
<condition column="objectclass_id" value="${target.objectclass_id}" type="integer"/>
</join>
</complexProperty>
<featureProperty target="ng2_LayerType" path="layer" schema="ng2" relationType="composition">
<join table="ng2_layer" fromColumn="id" toColumn="layered_construction_id" toRole="child"/>
<featureProperty target="ng3_LayerType" path="layer" schema="ng3" relationType="composition">
<join table="ng3_layer" fromColumn="id" toColumn="layered_construction_id" toRole="child"/>
</featureProperty>
</featureType>
<!-- Reverse Layered Construction -->
<featureType id="ng2_ReverseLayeredConstructionType" table="ng2_layered_construction" objectClassId="11052" path="ReverseLayeredConstruction" schema="ng2">
<extension base="ng2_AbstractLayeredConstructionType"/>
<featureProperty minOccurs="1" maxOccurs="1" target="ng2_LayeredConstructionType" path="baseLayeredConstruction" schema="ng2" relationType="association">
<join table="ng2_layered_construction" fromColumn="layered_construction_id" toColumn="id" toRole="parent">
<featureType id="ng3_ReverseLayeredConstructionType" table="ng3_layered_construction" objectClassId="11052" path="ReverseLayeredConstruction" schema="ng3">
<extension base="ng3_AbstractLayeredConstructionType"/>
<featureProperty minOccurs="1" maxOccurs="1" target="ng3_LayeredConstructionType" path="baseLayeredConstruction" schema="ng3" relationType="association">
<join table="ng3_layered_construction" fromColumn="layered_construction_id" toColumn="id" toRole="parent">
<condition column="objectclass_id" value="${target.objectclass_id}" type="integer"/>
</join>
</featureProperty>
</featureType>
<!-- Layer -->
<featureType id="ng2_LayerType" table="ng2_layer" objectClassId="11053" path="Layer" schema="ng2">
<featureType id="ng3_LayerType" table="ng3_layer" objectClassId="11053" path="Layer" schema="ng3">
<extension base="AbstractFeatureType">
<join table="cityobject" fromColumn="id" toColumn="id" toRole="parent"/>
</extension>
<complexAttribute minOccurs="1" maxOccurs="1" path="thickness" schema="ng2">
<attribute column="thickness" type="double" path="." schema="ng2"/>
<complexAttribute minOccurs="1" maxOccurs="1" path="thickness" schema="ng3">
<attribute column="thickness" type="double" path="." schema="ng3"/>
<attribute column="thickness_uom" type="string" path="@uom" schema="gml"/>
</complexAttribute>
<featureProperty minOccurs="1" maxOccurs="1" target="ng2_AbstractMaterialType" path="material" schema="ng2" relationType="aggregation">
<join table="ng2_material" fromColumn="material_id" toColumn="id" toRole="parent">
<featureProperty minOccurs="1" maxOccurs="1" target="ng3_AbstractMaterialType" path="material" schema="ng3" relationType="aggregation">
<join table="ng3_material" fromColumn="material_id" toColumn="id" toRole="parent">
<condition column="objectclass_id" value="${target.objectclass_id}" type="integer"/>
</join>
</featureProperty>
</featureType>
<!-- Abstract Material -->
<featureType abstract="true" id="ng2_AbstractMaterialType" table="ng2_material" objectClassId="11054" path="AbstractMaterial" schema="ng2">
<featureType abstract="true" id="ng3_AbstractMaterialType" table="ng3_material" objectClassId="11054" path="AbstractMaterial" schema="ng3">
<extension base="AbstractFeatureType">
<join table="cityobject" fromColumn="id" toColumn="id" toRole="parent"/>
</extension>
<complexAttribute maxOccurs="1" path="libraryCode" schema="ng2">
<attribute column="library_code" type="string" path="." schema="ng2"/>
<complexAttribute maxOccurs="1" path="libraryCode" schema="ng3">
<attribute column="library_code" type="string" path="." schema="ng3"/>
<attribute column="library_code_codespace" type="string" path="@codespace" schema="gml"/>
</complexAttribute>
</featureType>
<!-- Solid Material -->
<featureType id="ng2_SolidMaterialType" table="ng2_material" objectClassId="11055" path="SolidMaterial" schema="ng2">
<extension base="ng2_AbstractMaterialType"/>
<complexAttribute maxOccurs="1" path="thermalConductivity" schema="ng2">
<attribute column="thm_conductivity" type="double" path="." schema="ng2"/>
<featureType id="ng3_SolidMaterialType" table="ng3_material" objectClassId="11055" path="SolidMaterial" schema="ng3">
<extension base="ng3_AbstractMaterialType"/>
<complexAttribute maxOccurs="1" path="thermalConductivity" schema="ng3">
<attribute column="thm_conductivity" type="double" path="." schema="ng3"/>
<attribute column="thm_conductivity_uom" type="string" path="@uom" schema="gml"/>
</complexAttribute>
<complexAttribute maxOccurs="1" path="density" schema="ng2">
<attribute column="density" type="double" path="." schema="ng2"/>
<complexAttribute maxOccurs="1" path="density" schema="ng3">
<attribute column="density" type="double" path="." schema="ng3"/>
<attribute column="density_uom" type="string" path="@uom" schema="gml"/>
</complexAttribute>
<complexAttribute maxOccurs="1" path="specificHeatCapacity" schema="ng2">
<attribute column="spec_heat_capacity" type="double" path="." schema="ng2"/>
<complexAttribute maxOccurs="1" path="specificHeatCapacity" schema="ng3">
<attribute column="spec_heat_capacity" type="double" path="." schema="ng3"/>
<attribute column="spec_heat_capacity_uom" type="string" path="@uom" schema="gml"/>
</complexAttribute>
<complexAttribute maxOccurs="1" path="permeance" schema="ng2">
<attribute column="permeance" type="double" path="." schema="ng2"/>
<complexAttribute maxOccurs="1" path="permeance" schema="ng3">
<attribute column="permeance" type="double" path="." schema="ng3"/>
<attribute column="permeance_uom" type="string" path="@uom" schema="gml"/>
</complexAttribute>
<complexAttribute maxOccurs="1" path="porosity" schema="ng2">
<attribute column="porosity" type="double" path="." schema="ng2"/>
<complexAttribute maxOccurs="1" path="porosity" schema="ng3">
<attribute column="porosity" type="double" path="." schema="ng3"/>
<attribute column="porosity_uom" type="string" path="@uom" schema="gml"/>
</complexAttribute>
<complexAttribute maxOccurs="1" path="embodiedEnergy" schema="ng2">
<attribute column="embodied_energy" type="double" path="." schema="ng2"/>
<complexAttribute maxOccurs="1" path="embodiedEnergy" schema="ng3">
<attribute column="embodied_energy" type="double" path="." schema="ng3"/>
<attribute column="embodied_energy_uom" type="string" path="@uom" schema="gml"/>
</complexAttribute>
<complexAttribute maxOccurs="1" path="embodiedCarbon" schema="ng2">
<attribute column="embodied_carbon" type="double" path="." schema="ng2"/>
<complexAttribute maxOccurs="1" path="embodiedCarbon" schema="ng3">
<attribute column="embodied_carbon" type="double" path="." schema="ng3"/>
<attribute column="embodied_carbon_uom" type="string" path="@uom" schema="gml"/>
</complexAttribute>
</featureType>
<!-- Gas -->
<featureType id="ng2_GasType" table="ng2_material" objectClassId="11056" path="Gas" schema="ng2">
<extension base="ng2_AbstractMaterialType"/>
<attribute maxOccurs="1" column="is_ventilated" type="boolean" path="isVentilated" schema="ng2"/>
<complexAttribute maxOccurs="1" path="rValue" schema="ng2">
<attribute column="r_value" type="double" path="." schema="ng2"/>
<featureType id="ng3_GasType" table="ng3_material" objectClassId="11056" path="Gas" schema="ng3">
<extension base="ng3_AbstractMaterialType"/>
<attribute maxOccurs="1" column="is_ventilated" type="boolean" path="isVentilated" schema="ng3"/>
<complexAttribute maxOccurs="1" path="rValue" schema="ng3">
<attribute column="r_value" type="double" path="." schema="ng3"/>
<attribute column="r_value_uom" type="string" path="@uom" schema="gml"/>
</complexAttribute>
</featureType>
<!-- AbstractResource -->
<featureType abstract="true" id="ng2_AbstractResourceType" table="ng2_resource" objectClassId="11070" path="AbstractResource" schema="ng2">
<featureType abstract="true" id="ng3_AbstractResourceType" table="ng3_resource" objectClassId="11070" path="AbstractResource" schema="ng3">
<extension base="AbstractFeatureType">
<join table="cityobject" fromColumn="id" toColumn="id" toRole="parent"/>
</extension>
<attribute minOccurs="1" maxOccurs="1" column="status" type="string" path="status" schema="ng2"/>
<complexAttribute minOccurs="1" maxOccurs="1" path="operationType" schema="ng2">
<attribute column="operation_type" type="string" path="." schema="ng2"/>
<attribute minOccurs="1" maxOccurs="1" column="status" type="string" path="status" schema="ng3"/>
<complexAttribute minOccurs="1" maxOccurs="1" path="operationType" schema="ng3">
<attribute column="operation_type" type="string" path="." schema="ng3"/>
<attribute column="operation_type_codespace" type="string" path="@codespace" schema="gml"/>
</complexAttribute>
<complexAttribute minOccurs="1" maxOccurs="1" path="amountType" schema="ng2">
<attribute column="amount_type" type="string" path="." schema="ng2"/>
<complexAttribute minOccurs="1" maxOccurs="1" path="amountType" schema="ng3">
<attribute column="amount_type" type="string" path="." schema="ng3"/>
<attribute column="amount_type_codespace" type="string" path="@codespace" schema="gml"/>
</complexAttribute>
<complexAttribute maxOccurs="1" path="amount" schema="ng2">
<attribute column="amount" type="double" path="." schema="ng2"/>
<complexAttribute maxOccurs="1" path="amount" schema="ng3">
<attribute column="amount" type="double" path="." schema="ng3"/>
<attribute column="amount_uom" type="string" path="@uom" schema="gml"/>
</complexAttribute>
<featureProperty maxOccurs="1" target="ng2_AbstractTimeSeriesType" path="timeDependentAmount" schema="ng2" relationType="composition">
<join table="ng2_time_series" fromColumn="time_series_id" toColumn="id" toRole="parent">
<featureProperty maxOccurs="1" target="ng3_AbstractTimeSeriesType" path="timeDependentAmount" schema="ng3" relationType="composition">
<join table="ng3_time_series" fromColumn="time_series_id" toColumn="id" toRole="parent">
<condition column="objectclass_id" value="${target.objectclass_id}" type="integer"/>
</join>
</featureProperty>
<attribute minOccurs="1" maxOccurs="1" column="is_amount_normalized" type="boolean" path="isAmountNormalized" schema="ng2"/>
<complexAttribute maxOccurs="1" path="normalizationValue" schema="ng2">
<attribute column="normalization_value" type="double" path="." schema="ng2"/>
<attribute minOccurs="1" maxOccurs="1" column="is_amount_normalized" type="boolean" path="isAmountNormalized" schema="ng3"/>
<complexAttribute maxOccurs="1" path="normalizationValue" schema="ng3">
<attribute column="normalization_value" type="double" path="." schema="ng3"/>
<attribute column="normalization_value_uom" type="string" path="@uom" schema="gml"/>
</complexAttribute>
<attribute column="normalization_param" type="string" maxOccurs="1" path="normalizationParameter" schema="ng2"/>
<complexAttribute maxOccurs="1" path="co2Equivalent" schema="ng2">
<attribute column="co2_equivalent" type="double" path="." schema="ng2"/>
<attribute column="normalization_param" type="string" maxOccurs="1" path="normalizationParameter" schema="ng3"/>
<complexAttribute maxOccurs="1" path="co2Equivalent" schema="ng3">
<attribute column="co2_equivalent" type="double" path="." schema="ng3"/>
<attribute column="co2_equivalent_uom" type="string" path="@uom" schema="gml"/>
</complexAttribute>
<attribute maxOccurs="1" column="year" type="integer" path="year" schema="ng2"/>
<complexAttribute maxOccurs="1" path="costsMoney" schema="ng2">
<attribute column="costs_money" type="double" path="." schema="ng2"/>
<attribute maxOccurs="1" column="year" type="integer" path="year" schema="ng3"/>
<complexAttribute maxOccurs="1" path="costsMoney" schema="ng3">
<attribute column="costs_money" type="double" path="." schema="ng3"/>
<attribute column="co2_equivalent_uom" type="string" path="@uom" schema="gml"/>
</complexAttribute>
<complexAttribute maxOccurs="1" path="yieldsMoney" schema="ng2">
<attribute column="yields_money" type="double" path="." schema="ng2"/>
<complexAttribute maxOccurs="1" path="yieldsMoney" schema="ng3">
<attribute column="yields_money" type="double" path="." schema="ng3"/>
<attribute column="yields_money_uom" type="string" path="@uom" schema="gml"/>
</complexAttribute>
</featureType>
<!-- Resources: Construction Material -->
<featureType id="ng2_ConstructionMaterialType" table="ng2_resource" objectClassId="11071" path="ConstructionMaterial" schema="ng2">
<extension base="ng2_AbstractResourceType"/>
<complexAttribute minOccurs="1" maxOccurs="1" path="type" schema="ng2">
<attribute column="type" type="string" path="." schema="ng2"/>
<featureType id="ng3_ConstructionMaterialType" table="ng3_resource" objectClassId="11071" path="ConstructionMaterial" schema="ng3">
<extension base="ng3_AbstractResourceType"/>
<complexAttribute minOccurs="1" maxOccurs="1" path="type" schema="ng3">
<attribute column="type" type="string" path="." schema="ng3"/>
<attribute column="type_codespace" type="string" path="@codespace" schema="gml"/>
</complexAttribute>
<complexAttribute minOccurs="1" maxOccurs="1" path="endUse" schema="ng2">
<attribute column="enduse" type="string" path="." schema="ng2"/>
<complexAttribute minOccurs="1" maxOccurs="1" path="endUse" schema="ng3">
<attribute column="enduse" type="string" path="." schema="ng3"/>
<attribute column="enduse_codespace" type="string" path="@codespace" schema="gml"/>
</complexAttribute>
</featureType>
<!-- Resources: Energy -->
<featureType id="ng2_EnergyType" table="ng2_resource" objectClassId="11072" path="Energy" schema="ng2">
<extension base="ng2_AbstractResourceType"/>
<complexAttribute minOccurs="1" maxOccurs="1" path="type" schema="ng2">
<attribute column="type" type="string" path="." schema="ng2"/>
<featureType id="ng3_EnergyType" table="ng3_resource" objectClassId="11072" path="Energy" schema="ng3">
<extension base="ng3_AbstractResourceType"/>
<complexAttribute minOccurs="1" maxOccurs="1" path="type" schema="ng3">
<attribute column="type" type="string" path="." schema="ng3"/>
<attribute column="type_codespace" type="string" path="@codespace" schema="gml"/>
</complexAttribute>
<complexAttribute minOccurs="1" maxOccurs="1" path="endUse" schema="ng2">
<attribute column="enduse" type="string" path="." schema="ng2"/>
<complexAttribute minOccurs="1" maxOccurs="1" path="endUse" schema="ng3">
<attribute column="enduse" type="string" path="." schema="ng3"/>
<attribute column="enduse_codespace" type="string" path="@codespace" schema="gml"/>
</complexAttribute>
<complexAttribute maxOccurs="1" path="energyCarrier" schema="ng2">
<attribute column="energy_carrier" type="string" path="." schema="ng2"/>
<complexAttribute maxOccurs="1" path="energyCarrier" schema="ng3">
<attribute column="energy_carrier" type="string" path="." schema="ng3"/>
<attribute column="energy_carrier_codespace" type="string" path="@codespace" schema="gml"/>
</complexAttribute>
<complexAttribute maxOccurs="1" path="maximumLoad" schema="ng2">
<attribute column="maximum_load" type="double" path="." schema="ng2"/>
<complexAttribute maxOccurs="1" path="maximumLoad" schema="ng3">
<attribute column="maximum_load" type="double" path="." schema="ng3"/>
<attribute column="maximum_load_uom" type="string" path="@uom" schema="gml"/>
</complexAttribute>
<complexAttribute maxOccurs="1" path="source" schema="ng2">
<attribute column="source" type="string" path="." schema="ng2"/>
<complexAttribute maxOccurs="1" path="source" schema="ng3">
<attribute column="source" type="string" path="." schema="ng3"/>
<attribute column="source_codespace" type="string" path="@codespace" schema="gml"/>
</complexAttribute>
</featureType>
<!-- Resources: Food -->
<featureType id="ng2_FoodType" table="ng2_resource" objectClassId="11073" path="Food" schema="ng2">
<extension base="ng2_AbstractResourceType"/>
<complexAttribute minOccurs="1" maxOccurs="1" path="type" schema="ng2">
<attribute column="type" type="string" path="." schema="ng2"/>
<featureType id="ng3_FoodType" table="ng3_resource" objectClassId="11073" path="Food" schema="ng3">
<extension base="ng3_AbstractResourceType"/>
<complexAttribute minOccurs="1" maxOccurs="1" path="type" schema="ng3">
<attribute column="type" type="string" path="." schema="ng3"/>
<attribute column="type_codespace" type="string" path="@codespace" schema="gml"/>
</complexAttribute>
<complexAttribute minOccurs="1" maxOccurs="1" path="endUse" schema="ng2">
<attribute column="enduse" type="string" path="." schema="ng2"/>
<complexAttribute minOccurs="1" maxOccurs="1" path="endUse" schema="ng3">
<attribute column="enduse" type="string" path="." schema="ng3"/>
<attribute column="enduse_codespace" type="string" path="@codespace" schema="gml"/>
</complexAttribute>
</featureType>
<!-- Resources: Other Resource -->
<featureType id="ng2_OtherResourceType" table="ng2_resource" objectClassId="11074" path="OtherResource" schema="ng2">
<extension base="ng2_AbstractResourceType"/>
<complexAttribute minOccurs="1" maxOccurs="1" path="type" schema="ng2">
<attribute column="type" type="string" path="." schema="ng2"/>
<featureType id="ng3_OtherResourceType" table="ng3_resource" objectClassId="11074" path="OtherResource" schema="ng3">
<extension base="ng3_AbstractResourceType"/>
<complexAttribute minOccurs="1" maxOccurs="1" path="type" schema="ng3">
<attribute column="type" type="string" path="." schema="ng3"/>
<attribute column="type_codespace" type="string" path="@codespace" schema="gml"/>
</complexAttribute>
<complexAttribute minOccurs="1" maxOccurs="1" path="endUse" schema="ng2">
<attribute column="enduse" type="string" path="." schema="ng2"/>
<complexAttribute minOccurs="1" maxOccurs="1" path="endUse" schema="ng3">
<attribute column="enduse" type="string" path="." schema="ng3"/>
<attribute column="enduse_codespace" type="string" path="@codespace" schema="gml"/>
</complexAttribute>
</featureType>
<!-- Resources: Urban Space -->
<featureType id="ng2_UrbanSpaceType" table="ng2_resource" objectClassId="11075" path="UrbanSpace" schema="ng2">
<extension base="ng2_AbstractResourceType"/>
<complexAttribute minOccurs="1" maxOccurs="1" path="type" schema="ng2">
<attribute column="type" type="string" path="." schema="ng2"/>
<featureType id="ng3_UrbanSpaceType" table="ng3_resource" objectClassId="11075" path="UrbanSpace" schema="ng3">
<extension base="ng3_AbstractResourceType"/>
<complexAttribute minOccurs="1" maxOccurs="1" path="type" schema="ng3">
<attribute column="type" type="string" path="." schema="ng3"/>
<attribute column="type_codespace" type="string" path="@codespace" schema="gml"/>
</complexAttribute>
<complexAttribute minOccurs="1" maxOccurs="1" path="endUse" schema="ng2">
<attribute column="enduse" type="string" path="." schema="ng2"/>
<complexAttribute minOccurs="1" maxOccurs="1" path="endUse" schema="ng3">
<attribute column="enduse" type="string" path="." schema="ng3"/>
<attribute column="enduse_codespace" type="string" path="@codespace" schema="gml"/>
</complexAttribute>
</featureType>
<!-- Resources: Waste -->
<featureType id="ng2_WasteType" table="ng2_resource" objectClassId="11076" path="Waste" schema="ng2">
<extension base="ng2_AbstractResourceType"/>
<complexAttribute minOccurs="1" maxOccurs="1" path="type" schema="ng2">
<attribute column="type" type="string" path="." schema="ng2"/>
<featureType id="ng3_WasteType" table="ng3_resource" objectClassId="11076" path="Waste" schema="ng3">
<extension base="ng3_AbstractResourceType"/>
<complexAttribute minOccurs="1" maxOccurs="1" path="type" schema="ng3">
<attribute column="type" type="string" path="." schema="ng3"/>
<attribute column="type_codespace" type="string" path="@codespace" schema="gml"/>
</complexAttribute>
<complexAttribute minOccurs="1" maxOccurs="1" path="endUse" schema="ng2">
<attribute column="enduse" type="string" path="." schema="ng2"/>
<complexAttribute minOccurs="1" maxOccurs="1" path="endUse" schema="ng3">
<attribute column="enduse" type="string" path="." schema="ng3"/>
<attribute column="enduse_codespace" type="string" path="@codespace" schema="gml"/>
</complexAttribute>
<attribute maxOccurs="1" column="is_dangerous" type="boolean" path="isDangerous" schema="ng2"/>
<attribute maxOccurs="1" column="is_recyclable" type="boolean" path="isRecyclable" schema="ng2"/>
<attribute maxOccurs="1" column="is_dangerous" type="boolean" path="isDangerous" schema="ng3"/>
<attribute maxOccurs="1" column="is_recyclable" type="boolean" path="isRecyclable" schema="ng3"/>
</featureType>
<!-- Resources: Water -->
<featureType id="ng2_WaterType" table="ng2_resource" objectClassId="11077" path="Water" schema="ng2">
<extension base="ng2_AbstractResourceType"/>
<complexAttribute minOccurs="1" maxOccurs="1" path="type" schema="ng2">
<attribute column="type" type="string" path="." schema="ng2"/>
<featureType id="ng3_WaterType" table="ng3_resource" objectClassId="11077" path="Water" schema="ng3">
<extension base="ng3_AbstractResourceType"/>
<complexAttribute minOccurs="1" maxOccurs="1" path="type" schema="ng3">
<attribute column="type" type="string" path="." schema="ng3"/>
<attribute column="type_codespace" type="string" path="@codespace" schema="gml"/>
</complexAttribute>
<complexAttribute minOccurs="1" maxOccurs="1" path="endUse" schema="ng2">
<attribute column="enduse" type="string" path="." schema="ng2"/>
<complexAttribute minOccurs="1" maxOccurs="1" path="endUse" schema="ng3">
<attribute column="enduse" type="string" path="." schema="ng3"/>
<attribute column="enduse_codespace" type="string" path="@codespace" schema="gml"/>
</complexAttribute>
</featureType>
<!-- Abstract Building Partition -->
<featureType abstract="true" id="ng2_AbstractBuildingPartitionType" table="ng2_building_partition" objectClassId="11080" path="AbstractBuildingPartition" schema="ng2">
<featureType abstract="true" id="ng3_AbstractBuildingPartitionType" table="ng3_building_partition" objectClassId="11080" path="AbstractBuildingPartition" schema="ng3">
<extension base="AbstractCityObjectType">
<join table="cityobject" fromColumn="id" toColumn="id" toRole="parent"/>
</extension>
<complexProperty refType="ng2_QualifiedAreaType" path="area" schema="ng2">
<join table="ng2_qualified_attribute" fromColumn="id" toColumn="building_partition_id" toRole="child">
<complexProperty refType="ng3_QualifiedAreaType" path="area" schema="ng3">
<join table="ng3_qualified_attribute" fromColumn="id" toColumn="building_partition_id" toRole="child">
<condition column="objectclass_id" value="${target.objectclass_id}" type="integer"/>
</join>
</complexProperty>
<complexProperty refType="ng2_QualifiedVolumeType" path="volume" schema="ng2">
<join table="ng2_qualified_attribute" fromColumn="id" toColumn="building_partition_id" toRole="child">
<complexProperty refType="ng3_QualifiedVolumeType" path="volume" schema="ng3">
<join table="ng3_qualified_attribute" fromColumn="id" toColumn="building_partition_id" toRole="child">
<condition column="objectclass_id" value="${target.objectclass_id}" type="integer"/>
</join>
</complexProperty>
<geometryProperty maxOccurs="1" lod="1" refColumn="lod1_solid_id" type="AbstractSolid" path="lod1Solid" schema="ng2"/>
<geometryProperty maxOccurs="1" lod="2" refColumn="lod2_solid_id" type="AbstractSolid" path="lod2Solid" schema="ng2"/>
<geometryProperty maxOccurs="1" lod="3" refColumn="lod3_solid_id" type="AbstractSolid" path="lod3Solid" schema="ng2"/>
<geometryProperty maxOccurs="1" lod="1" refColumn="lod1_solid_id" type="AbstractSolid" path="lod1Solid" schema="ng3"/>
<geometryProperty maxOccurs="1" lod="2" refColumn="lod2_solid_id" type="AbstractSolid" path="lod2Solid" schema="ng3"/>
<geometryProperty maxOccurs="1" lod="3" refColumn="lod3_solid_id" type="AbstractSolid" path="lod3Solid" schema="ng3"/>
</featureType>
<!-- Abstract Thermal Zone -->
<featureType abstract="true" id="ng2_AbstractThermalZoneType" table="ng2_building_partition" objectClassId="11045" path="AbstractThermalZone" schema="ng2">
<extension base="ng2_AbstractBuildingPartitionType"/>
<featureProperty target="ng2_AbstractUsageZoneType" path="usageZone" schema="ng2" relationType="association">
<join table="ng2_building_partition" fromColumn="id" toColumn="thermal_zone_id" toRole="child">
<featureType abstract="true" id="ng3_AbstractThermalZoneType" table="ng3_building_partition" objectClassId="11045" path="AbstractThermalZone" schema="ng3">
<extension base="ng3_AbstractBuildingPartitionType"/>
<featureProperty target="ng3_AbstractUsageZoneType" path="usageZone" schema="ng3" relationType="association">
<join table="ng3_building_partition" fromColumn="id" toColumn="thermal_zone_id" toRole="child">
<condition column="objectclass_id" value="${target.objectclass_id}" type="integer"/>
</join>
</featureProperty>
</featureType>
<!-- Thermal Zone -->
<featureType id="ng2_ThermalZoneType" table="ng2_building_partition" objectClassId="11081" path="ThermalZone" schema="ng2">
<extension base="ng2_AbstractThermalZoneType"/>
<complexAttribute maxOccurs="1" path="heatCapacity" schema="ng2">
<attribute column="heat_capacity" type="double" path="." schema="ng2"/>
<featureType id="ng3_ThermalZoneType" table="ng3_building_partition" objectClassId="11081" path="ThermalZone" schema="ng3">
<extension base="ng3_AbstractThermalZoneType"/>
<complexAttribute maxOccurs="1" path="heatCapacity" schema="ng3">
<attribute column="heat_capacity" type="double" path="." schema="ng3"/>
<attribute column="heat_capacity_uom" type="string" path="@uom" schema="gml"/>
</complexAttribute>
<complexAttribute maxOccurs="1" path="infiltrationRate" schema="ng2">
<attribute column="infiltration_rate" type="double" path="." schema="ng2"/>
<complexAttribute maxOccurs="1" path="infiltrationRate" schema="ng3">
<attribute column="infiltration_rate" type="double" path="." schema="ng3"/>
<attribute column="infiltration_rate_uom" type="string" path="@uom" schema="gml"/>
</complexAttribute>
<attribute minOccurs="1" maxOccurs="1" column="is_cooled" type="boolean" path="isCooled" schema="ng2"/>
<attribute minOccurs="1" maxOccurs="1" column="is_heated" type="boolean" path="isHeated" schema="ng2"/>
<attribute minOccurs="1" maxOccurs="1" column="coincides_with_lod2_hull" type="boolean" path="coincidesWithLod2Hull" schema="ng2"/>
<attribute minOccurs="1" maxOccurs="1" column="coincides_with_lod3_hull" type="boolean" path="coincidesWithLod3Hull" schema="ng2"/>
<featureProperty target="AbstractBoundarySurfaceType" path="thermalBoundary" schema="ng2" relationType="composition">
<joinTable table="ng2_them_surf_to_thermal_zone">
<join table="ng2_building_partition" fromColumn="thermal_zone_id" toColumn="id" toRole="parent"/>
<attribute minOccurs="1" maxOccurs="1" column="is_cooled" type="boolean" path="isCooled" schema="ng3"/>
<attribute minOccurs="1" maxOccurs="1" column="is_heated" type="boolean" path="isHeated" schema="ng3"/>
<attribute minOccurs="1" maxOccurs="1" column="coincides_with_lod2_hull" type="boolean" path="coincidesWithLod2Hull" schema="ng3"/>
<attribute minOccurs="1" maxOccurs="1" column="coincides_with_lod3_hull" type="boolean" path="coincidesWithLod3Hull" schema="ng3"/>
<featureProperty target="AbstractBoundarySurfaceType" path="thermalBoundary" schema="ng3" relationType="composition">
<joinTable table="ng3_them_surf_to_thermal_zone">
<join table="ng3_building_partition" fromColumn="thermal_zone_id" toColumn="id" toRole="parent"/>
<inverseJoin table="thematic_surface" fromColumn="thematic_surface_id" toColumn="id" toRole="parent">
<condition column="objectclass_id" value="${target.objectclass_id}" type="integer"/>
</inverseJoin>
......@@ -792,9 +792,9 @@ https://3d.bk.tudelft.nl/gagugiaro/
</featureProperty>
<!-- To be tested: Improved version that does not require the association table -->
<!--
<featureProperty target="AbstractBoundarySurfaceType" path="thermalBoundary" schema="ng2">
<joinTable table="ng2_thematic_surface">
<join table="ng2_building_partition" fromColumn="id" toColumn="thermal_zone_id" toRole="parent"/>
<featureProperty target="AbstractBoundarySurfaceType" path="thermalBoundary" schema="ng3">
<joinTable table="ng3_thematic_surface">
<join table="ng3_building_partition" fromColumn="id" toColumn="thermal_zone_id" toRole="parent"/>
<inverseJoin table="thematic_surface" fromColumn="id" toColumn="id" toRole="parent">
<condition column="objectclass_id" value="${target.objectclass_id}" type="integer"/>
</inverseJoin>
......@@ -804,441 +804,441 @@ https://3d.bk.tudelft.nl/gagugiaro/
</featureType>
<!-- Attic Floor Surface -->
<featureType id="ng2_AtticFloorSurfaceType" table="thematic_surface" objectClassId="11082" path="AtticFloorSurface" schema="ng2">
<featureType id="ng3_AtticFloorSurfaceType" table="thematic_surface" objectClassId="11082" path="AtticFloorSurface" schema="ng3">
<extension base="AbstractBoundarySurfaceType"/>
</featureType>
<!-- Basement Ceiling Surface -->
<featureType id="ng2_BasementCeilingSurfaceType" table="thematic_surface" objectClassId="11083" path="BasementCeilingSurface" schema="ng2">
<featureType id="ng3_BasementCeilingSurfaceType" table="thematic_surface" objectClassId="11083" path="BasementCeilingSurface" schema="ng3">
<extension base="AbstractBoundarySurfaceType"/>
</featureType>
<!-- Intermediate Floor Surface -->
<featureType id="ng2_IntermediateFloorSurfaceType" table="thematic_surface" objectClassId="11084" path="IntermediateFloorSurface" schema="ng2">
<featureType id="ng3_IntermediateFloorSurfaceType" table="thematic_surface" objectClassId="11084" path="IntermediateFloorSurface" schema="ng3">
<extension base="AbstractBoundarySurfaceType"/>
</featureType>
<!-- Party Wall Surface -->
<featureType id="ng2_PartyWallSurfaceType" table="thematic_surface" objectClassId="11085" path="PartyWallSurface" schema="ng2">
<featureType id="ng3_PartyWallSurfaceType" table="thematic_surface" objectClassId="11085" path="PartyWallSurface" schema="ng3">
<extension base="AbstractBoundarySurfaceType"/>
</featureType>
<!-- Abstract Usage Zone -->
<featureType abstract="true" id="ng2_AbstractUsageZoneType" table="ng2_building_partition" objectClassId="11090" path="AbstractUsageZone" schema="ng2">
<extension base="ng2_AbstractBuildingPartitionType"/>
<featureProperty target="ng2_AbstractBuildingUnitType" path="buildingUnit" schema="ng2" relationType="association">
<join table="ng2_building_partition" fromColumn="id" toColumn="usage_zone_id" toRole="child">
<featureType abstract="true" id="ng3_AbstractUsageZoneType" table="ng3_building_partition" objectClassId="11090" path="AbstractUsageZone" schema="ng3">
<extension base="ng3_AbstractBuildingPartitionType"/>
<featureProperty target="ng3_AbstractBuildingUnitType" path="buildingUnit" schema="ng3" relationType="association">
<join table="ng3_building_partition" fromColumn="id" toColumn="usage_zone_id" toRole="child">
<condition column="objectclass_id" value="${target.objectclass_id}" type="integer"/>
</join>
</featureProperty>
</featureType>
<!-- Usage Zone -->
<featureType id="ng2_UsageZoneType" table="ng2_building_partition" objectClassId="11091" path="UsageZone" schema="ng2">
<extension base="ng2_AbstractUsageZoneType"/>
<complexAttribute minOccurs="1" maxOccurs="1" path="type" schema="ng2">
<attribute column="type" type="string" path="." schema="ng2"/>
<featureType id="ng3_UsageZoneType" table="ng3_building_partition" objectClassId="11091" path="UsageZone" schema="ng3">
<extension base="ng3_AbstractUsageZoneType"/>
<complexAttribute minOccurs="1" maxOccurs="1" path="type" schema="ng3">
<attribute column="type" type="string" path="." schema="ng3"/>
<attribute column="type_codespace" type="string" path="@codespace" schema="gml"/>
</complexAttribute>
<attribute column="is_primary" type="boolean" maxOccurs="1" path="isPrimary" schema="ng2"/>
<attribute column="num_of_building_units" type="integer" maxOccurs="1" path="numberOfBuildingUnits" schema="ng2"/>
<complexAttribute maxOccurs="1" path="internalHeatGains" schema="ng2">
<attribute column="int_heat_gains" type="double" path="." schema="ng2"/>
<attribute column="is_primary" type="boolean" maxOccurs="1" path="isPrimary" schema="ng3"/>
<attribute column="num_of_building_units" type="integer" maxOccurs="1" path="numberOfBuildingUnits" schema="ng3"/>
<complexAttribute maxOccurs="1" path="internalHeatGains" schema="ng3">
<attribute column="int_heat_gains" type="double" path="." schema="ng3"/>
<attribute column="int_heat_gains_uom" type="string" path="@uom" schema="gml"/>
</complexAttribute>
<complexAttribute maxOccurs="1" path="internalHeatGainsConvectiveFraction" schema="ng2">
<attribute column="int_heat_gains_conv" type="double" path="." schema="ng2"/>
<complexAttribute maxOccurs="1" path="internalHeatGainsConvectiveFraction" schema="ng3">
<attribute column="int_heat_gains_conv" type="double" path="." schema="ng3"/>
<attribute column="int_heat_gains_conv_uom" type="string" path="@uom" schema="gml"/>
</complexAttribute>
<complexAttribute maxOccurs="1" path="internalHeatGainsLatentFraction" schema="ng2">
<attribute column="int_heat_gains_lat" type="double" path="." schema="ng2"/>
<complexAttribute maxOccurs="1" path="internalHeatGainsLatentFraction" schema="ng3">
<attribute column="int_heat_gains_lat" type="double" path="." schema="ng3"/>
<attribute column="int_heat_gains_lat_uom" type="string" path="@uom" schema="gml"/>
</complexAttribute>
<complexAttribute maxOccurs="1" path="internalHeatGainsRadiantFraction" schema="ng2">
<attribute column="int_heat_gains_rad" type="double" path="." schema="ng2"/>
<complexAttribute maxOccurs="1" path="internalHeatGainsRadiantFraction" schema="ng3">
<attribute column="int_heat_gains_rad" type="double" path="." schema="ng3"/>
<attribute column="int_heat_gains_rad_uom" type="string" path="@uom" schema="gml"/>
</complexAttribute>
<featureProperty maxOccurs="1" target="ng2_AbstractScheduleType" path="coolingSchedule" schema="ng2" relationType="aggregation">
<join table="ng2_schedule" fromColumn="cooling_schedule_id" toColumn="id" toRole="parent">
<featureProperty maxOccurs="1" target="ng3_AbstractScheduleType" path="coolingSchedule" schema="ng3" relationType="aggregation">
<join table="ng3_schedule" fromColumn="cooling_schedule_id" toColumn="id" toRole="parent">
<condition column="objectclass_id" value="${target.objectclass_id}" type="integer"/>
</join>
</featureProperty>
<featureProperty maxOccurs="1" target="ng2_AbstractScheduleType" path="heatingSchedule" schema="ng2" relationType="aggregation">
<join table="ng2_schedule" fromColumn="heating_schedule_id" toColumn="id" toRole="parent">
<featureProperty maxOccurs="1" target="ng3_AbstractScheduleType" path="heatingSchedule" schema="ng3" relationType="aggregation">
<join table="ng3_schedule" fromColumn="heating_schedule_id" toColumn="id" toRole="parent">
<condition column="objectclass_id" value="${target.objectclass_id}" type="integer"/>
</join>
</featureProperty>
<featureProperty maxOccurs="1" target="ng2_AbstractScheduleType" path="ventilationSchedule" schema="ng2" relationType="aggregation">
<join table="ng2_schedule" fromColumn="ventilation_schedule_id" toColumn="id" toRole="parent">
<featureProperty maxOccurs="1" target="ng3_AbstractScheduleType" path="ventilationSchedule" schema="ng3" relationType="aggregation">
<join table="ng3_schedule" fromColumn="ventilation_schedule_id" toColumn="id" toRole="parent">
<condition column="objectclass_id" value="${target.objectclass_id}" type="integer"/>
</join>
</featureProperty>
<featureProperty target="ng2_OccupantsType" path="occupiedBy" schema="ng2" relationType="aggregation">
<join table="ng2_occupants" fromColumn="id" toColumn="building_partition_id" toRole="child"/>
<featureProperty target="ng3_OccupantsType" path="occupiedBy" schema="ng3" relationType="aggregation">
<join table="ng3_occupants" fromColumn="id" toColumn="building_partition_id" toRole="child"/>
</featureProperty>
</featureType>
<!-- Abstract Building Unit -->
<featureType abstract="true" id="ng2_AbstractBuildingUnitType" table="ng2_building_partition" objectClassId="11092" path="AbstractBuildingUnit" schema="ng2">
<extension base="ng2_AbstractBuildingPartitionType"/>
<featureType abstract="true" id="ng3_AbstractBuildingUnitType" table="ng3_building_partition" objectClassId="11092" path="AbstractBuildingUnit" schema="ng3">
<extension base="ng3_AbstractBuildingPartitionType"/>
</featureType>
<!-- Building Unit -->
<featureType id="ng2_BuildingUnitType" table="ng2_building_partition" objectClassId="11093" path="BuildingUnit" schema="ng2">
<extension base="ng2_AbstractBuildingUnitType"/>
<complexAttribute minOccurs="1" maxOccurs="1" path="type" schema="ng2">
<attribute column="type" type="string" path="." schema="ng2"/>
<featureType id="ng3_BuildingUnitType" table="ng3_building_partition" objectClassId="11093" path="BuildingUnit" schema="ng3">
<extension base="ng3_AbstractBuildingUnitType"/>
<complexAttribute minOccurs="1" maxOccurs="1" path="type" schema="ng3">
<attribute column="type" type="string" path="." schema="ng3"/>
<attribute column="type_codespace" type="string" path="@codespace" schema="gml"/>
</complexAttribute>
<attribute maxOccurs="1" column="num_of_rooms" type="integer" path="numberOfRooms" schema="ng2"/>
<attribute maxOccurs="1" column="owner_name" type="string" path="ownerName" schema="ng2"/>
<complexAttribute maxOccurs="1" path="ownershipType" schema="ng2">
<attribute column="ownership_type" type="string" path="." schema="ng2"/>
<attribute maxOccurs="1" column="num_of_rooms" type="integer" path="numberOfRooms" schema="ng3"/>
<attribute maxOccurs="1" column="owner_name" type="string" path="ownerName" schema="ng3"/>
<complexAttribute maxOccurs="1" path="ownershipType" schema="ng3">
<attribute column="ownership_type" type="string" path="." schema="ng3"/>
<attribute column="ownership_type_codespace" type="string" path="@codespace" schema="gml"/>
</complexAttribute>
<featureProperty target="AddressType" path="address" schema="ng2" relationType="association">
<joinTable table="ng2_address_to_building_unit">
<join table="ng2_building_partition" fromColumn="building_unit_id" toColumn="id" toRole="parent"/>
<featureProperty target="AddressType" path="address" schema="ng3" relationType="association">
<joinTable table="ng3_address_to_building_unit">
<join table="ng3_building_partition" fromColumn="building_unit_id" toColumn="id" toRole="parent"/>
<inverseJoin table="address" fromColumn="address_id" toColumn="id" toRole="parent"/>
</joinTable>
</featureProperty>
<featureProperty target="ng2_EnergyPerformanceCertificateType" path="energyPerformanceCertificate" schema="ng2" relationType="composition">
<join table="ng2_energy_perf_cert" fromColumn="id" toColumn="building_partition_id" toRole="child"/>
<featureProperty target="ng3_EnergyPerformanceCertificateType" path="energyPerformanceCertificate" schema="ng3" relationType="composition">
<join table="ng3_energy_perf_cert" fromColumn="id" toColumn="building_partition_id" toRole="child"/>
</featureProperty>
<featureProperty target="ng2_RefurbishmentMeasureType" path="refurbishmentMeasure" schema="ng2" relationType="composition">
<join table="ng2_refurbishment_measure" fromColumn="id" toColumn="building_partition_id" toRole="child"/>
<featureProperty target="ng3_RefurbishmentMeasureType" path="refurbishmentMeasure" schema="ng3" relationType="composition">
<join table="ng3_refurbishment_measure" fromColumn="id" toColumn="building_partition_id" toRole="child"/>
</featureProperty>
<featureProperty target="ng2_OccupantsType" path="occupiedBy" schema="ng2" relationType="aggregation">
<join table="ng2_occupants" fromColumn="id" toColumn="building_partition_id" toRole="child"/>
<featureProperty target="ng3_OccupantsType" path="occupiedBy" schema="ng3" relationType="aggregation">
<join table="ng3_occupants" fromColumn="id" toColumn="building_partition_id" toRole="child"/>
</featureProperty>
</featureType>
<!-- Occupants -->
<featureType id="ng2_OccupantsType" table="ng2_occupants" objectClassId="11094" path="Occupants" schema="ng2">
<featureType id="ng3_OccupantsType" table="ng3_occupants" objectClassId="11094" path="Occupants" schema="ng3">
<extension base="AbstractFeatureType">
<join table="cityobject" fromColumn="id" toColumn="id" toRole="parent"/>
</extension>
<complexAttribute minOccurs="1" maxOccurs="1" path="type" schema="ng2">
<complexAttribute minOccurs="1" maxOccurs="1" path="type" schema="ng3">
<attribute column="type_codespace" type="string" path="@codespace" schema="gml"/>
<attribute column="type" type="string" path="." schema="ng2"/>
<attribute column="type" type="string" path="." schema="ng3"/>
</complexAttribute>
<attribute maxOccurs="1" column="num_of_occupants" type="integer" path="numberOfOccupants" schema="ng2"/>
<complexAttribute maxOccurs="1" path="heatDissipation" schema="ng2">
<attribute column="heat_diss" type="double" path="." schema="ng2"/>
<attribute maxOccurs="1" column="num_of_occupants" type="integer" path="numberOfOccupants" schema="ng3"/>
<complexAttribute maxOccurs="1" path="heatDissipation" schema="ng3">
<attribute column="heat_diss" type="double" path="." schema="ng3"/>
<attribute column="heat_diss_uom" type="string" path="@uom" schema="gml"/>
</complexAttribute>
<complexAttribute maxOccurs="1" path="heatDissipationConvectiveFraction" schema="ng2">
<attribute column="heat_diss_conv" type="double" path="." schema="ng2"/>
<complexAttribute maxOccurs="1" path="heatDissipationConvectiveFraction" schema="ng3">
<attribute column="heat_diss_conv" type="double" path="." schema="ng3"/>
<attribute column="heat_diss_conv_uom" type="string" path="@uom" schema="gml"/>
</complexAttribute>
<complexAttribute maxOccurs="1" path="heatDissipationLatentFraction" schema="ng2">
<attribute column="heat_diss_lat" type="double" path="." schema="ng2"/>
<complexAttribute maxOccurs="1" path="heatDissipationLatentFraction" schema="ng3">
<attribute column="heat_diss_lat" type="double" path="." schema="ng3"/>
<attribute column="heat_diss_lat_uom" type="string" path="@uom" schema="gml"/>
</complexAttribute>
<complexAttribute maxOccurs="1" path="heatDissipationRadiantFraction" schema="ng2">
<attribute column="heat_diss_rad" type="double" path="." schema="ng2"/>
<complexAttribute maxOccurs="1" path="heatDissipationRadiantFraction" schema="ng3">
<attribute column="heat_diss_rad" type="double" path="." schema="ng3"/>
<attribute column="heat_diss_rad_uom" type="string" path="@uom" schema="gml"/>
</complexAttribute>
<complexAttribute maxOccurs="1" path="averageDietType" schema="ng2">
<attribute column="avg_diet_type" type="string" path="." schema="ng2"/>
<complexAttribute maxOccurs="1" path="averageDietType" schema="ng3">
<attribute column="avg_diet_type" type="string" path="." schema="ng3"/>
<attribute column="avg_diet_type_codespace" type="string" path="@codespace" schema="gml"/>
</complexAttribute>
<complexAttribute maxOccurs="1" path="averageIncomeLevel" schema="ng2">
<attribute column="avg_income_level" type="string" path="." schema="ng2"/>
<complexAttribute maxOccurs="1" path="averageIncomeLevel" schema="ng3">
<attribute column="avg_income_level" type="string" path="." schema="ng3"/>
<attribute column="avg_income_level_codespace" type="string" path="@codespace" schema="gml"/>
</complexAttribute>
<complexAttribute maxOccurs="1" path="averageInstructionLevel" schema="ng2">
<attribute column="avg_instr_level" type="string" path="." schema="ng2"/>
<complexAttribute maxOccurs="1" path="averageInstructionLevel" schema="ng3">
<attribute column="avg_instr_level" type="string" path="." schema="ng3"/>
<attribute column="avg_instr_level_codespace" type="string" path="@codespace" schema="gml"/>
</complexAttribute>
<featureProperty maxOccurs="1" target="ng2_AbstractScheduleType" path="occupancyRate" schema="ng2" relationType="aggregation">
<join table="ng2_schedule" fromColumn="schedule_id" toColumn="id" toRole="parent">
<featureProperty maxOccurs="1" target="ng3_AbstractScheduleType" path="occupancyRate" schema="ng3" relationType="aggregation">
<join table="ng3_schedule" fromColumn="schedule_id" toColumn="id" toRole="parent">
<condition column="objectclass_id" value="${target.objectclass_id}" type="integer"/>
</join>
</featureProperty>
</featureType>
<!-- Device Operation -->
<featureType id="ng2_DeviceOperationType" table="ng2_device_operation" objectClassId="11100" path="DeviceOperation" schema="ng2">
<featureType id="ng3_DeviceOperationType" table="ng3_device_operation" objectClassId="11100" path="DeviceOperation" schema="ng3">
<extension base="AbstractFeatureType">
<join table="cityobject" fromColumn="id" toColumn="id" toRole="parent"/>
</extension>
<complexAttribute minOccurs="1" maxOccurs="1" path="type" schema="ng2">
<attribute column="type" type="string" path="." schema="ng2"/>
<complexAttribute minOccurs="1" maxOccurs="1" path="type" schema="ng3">
<attribute column="type" type="string" path="." schema="ng3"/>
<attribute column="type_codespace" type="string" path="@codespace" schema="gml"/>
</complexAttribute>
<attribute maxOccurs="1" column="yearly_global_efficiency" type="double" path="yearlyGlobalEfficiency" schema="ng2"/>
<featureProperty maxOccurs="1" target="ng2_AbstractScheduleType" path="schedule" schema="ng2" relationType="aggregation">
<join table="ng2_schedule" fromColumn="schedule_id" toColumn="id" toRole="parent">
<attribute maxOccurs="1" column="yearly_global_efficiency" type="double" path="yearlyGlobalEfficiency" schema="ng3"/>
<featureProperty maxOccurs="1" target="ng3_AbstractScheduleType" path="schedule" schema="ng3" relationType="aggregation">
<join table="ng3_schedule" fromColumn="schedule_id" toColumn="id" toRole="parent">
<condition column="objectclass_id" value="${target.objectclass_id}" type="integer"/>
</join>
</featureProperty>
</featureType>
<!-- Abstract Device -->
<featureType abstract="true" id="ng2_AbstractDeviceType" table="ng2_device" objectClassId="11101" path="AbstractDevice" schema="ng2">
<featureType abstract="true" id="ng3_AbstractDeviceType" table="ng3_device" objectClassId="11101" path="AbstractDevice" schema="ng3">
<extension base="AbstractCityObjectType">
<join table="cityobject" fromColumn="id" toColumn="id" toRole="parent"/>
</extension>
<attribute maxOccurs="1" column="model" type="string" path="model" schema="ng2"/>
<attribute maxOccurs="1" column="year_of_manufacture" type="integer" path="yearOfManufacture" schema="ng2"/>
<attribute maxOccurs="1" column="num_of_devices" type="integer" path="numberOfDevices" schema="ng2"/>
<complexAttribute maxOccurs="1" path="installedPower" schema="ng2">
<attribute column="installed_power" type="double" path="." schema="ng2"/>
<attribute maxOccurs="1" column="model" type="string" path="model" schema="ng3"/>
<attribute maxOccurs="1" column="year_of_manufacture" type="integer" path="yearOfManufacture" schema="ng3"/>
<attribute maxOccurs="1" column="num_of_devices" type="integer" path="numberOfDevices" schema="ng3"/>
<complexAttribute maxOccurs="1" path="installedPower" schema="ng3">
<attribute column="installed_power" type="double" path="." schema="ng3"/>
<attribute column="installed_power_uom" type="string" path="@uom" schema="gml"/>
</complexAttribute>
<complexAttribute maxOccurs="1" path="nominalEfficiency" schema="ng2">
<attribute column="nominal_efficiency" type="double" path="." schema="ng2"/>
<complexAttribute maxOccurs="1" path="nominalEfficiency" schema="ng3">
<attribute column="nominal_efficiency" type="double" path="." schema="ng3"/>
<attribute column="nominal_efficiency_uom" type="string" path="@uom" schema="gml"/>
</complexAttribute>
<attribute maxOccurs="1" column="efficiency_indicator" type="string" path="efficiencyIndicator" schema="ng2"/>
<complexAttribute maxOccurs="1" path="heatDissipation" schema="ng2">
<attribute column="heat_diss" type="double" path="." schema="ng2"/>
<attribute maxOccurs="1" column="efficiency_indicator" type="string" path="efficiencyIndicator" schema="ng3"/>
<complexAttribute maxOccurs="1" path="heatDissipation" schema="ng3">
<attribute column="heat_diss" type="double" path="." schema="ng3"/>
<attribute column="heat_diss_uom" type="string" path="@uom" schema="gml"/>
</complexAttribute>
<complexAttribute maxOccurs="1" path="heatDissipationConvectiveFraction" schema="ng2">
<attribute column="heat_diss_conv" type="double" path="." schema="ng2"/>
<complexAttribute maxOccurs="1" path="heatDissipationConvectiveFraction" schema="ng3">
<attribute column="heat_diss_conv" type="double" path="." schema="ng3"/>
<attribute column="heat_diss_conv_uom" type="string" path="@uom" schema="gml"/>
</complexAttribute>
<complexAttribute maxOccurs="1" path="heatDissipationLatentFraction" schema="ng2">
<attribute column="heat_diss_lat" type="double" path="." schema="ng2"/>
<complexAttribute maxOccurs="1" path="heatDissipationLatentFraction" schema="ng3">
<attribute column="heat_diss_lat" type="double" path="." schema="ng3"/>
<attribute column="heat_diss_lat_uom" type="string" path="@uom" schema="gml"/>
</complexAttribute>
<complexAttribute maxOccurs="1" path="heatDissipationRadiantFraction" schema="ng2">
<attribute column="heat_diss_rad" type="double" path="." schema="ng2"/>
<complexAttribute maxOccurs="1" path="heatDissipationRadiantFraction" schema="ng3">
<attribute column="heat_diss_rad" type="double" path="." schema="ng3"/>
<attribute column="heat_diss_rad_uom" type="string" path="@uom" schema="gml"/>
</complexAttribute>
<featureProperty target="ng2_DeviceOperationType" path="deviceOperation" schema="ng2" relationType="aggregation">
<join table="ng2_device_operation" fromColumn="id" toColumn="device_id" toRole="child"/>
<featureProperty target="ng3_DeviceOperationType" path="deviceOperation" schema="ng3" relationType="aggregation">
<join table="ng3_device_operation" fromColumn="id" toColumn="device_id" toRole="child"/>
</featureProperty>
</featureType>
<!-- Boiler -->
<featureType id="ng2_BoilerType" table="ng2_device" objectClassId="11102" path="Boiler" schema="ng2">
<extension base="ng2_AbstractDeviceType"/>
<attribute column="has_condensation" type="boolean" minOccurs="1" maxOccurs="1" path="hasCondensation" schema="ng2"/>
<featureType id="ng3_BoilerType" table="ng3_device" objectClassId="11102" path="Boiler" schema="ng3">
<extension base="ng3_AbstractDeviceType"/>
<attribute column="has_condensation" type="boolean" minOccurs="1" maxOccurs="1" path="hasCondensation" schema="ng3"/>
</featureType>
<!-- Generic Device -->
<featureType id="ng2_GenericDeviceType" table="ng2_device" objectClassId="11103" path="GenericDevice" schema="ng2">
<extension base="ng2_AbstractDeviceType"/>
<featureType id="ng3_GenericDeviceType" table="ng3_device" objectClassId="11103" path="GenericDevice" schema="ng3">
<extension base="ng3_AbstractDeviceType"/>
</featureType>
<!-- Generic Electrical Device -->
<featureType id="ng2_GenericElectricalDeviceType" table="ng2_device" objectClassId="11104" path="GenericElectricalDevice" schema="ng2">
<extension base="ng2_AbstractDeviceType"/>
<featureType id="ng3_GenericElectricalDeviceType" table="ng3_device" objectClassId="11104" path="GenericElectricalDevice" schema="ng3">
<extension base="ng3_AbstractDeviceType"/>
</featureType>
<!-- Lighting Device -->
<featureType id="ng2_LightingDeviceType" table="ng2_device" objectClassId="11105" path="LightingDevice" schema="ng2">
<extension base="ng2_AbstractDeviceType"/>
<featureType id="ng3_LightingDeviceType" table="ng3_device" objectClassId="11105" path="LightingDevice" schema="ng3">
<extension base="ng3_AbstractDeviceType"/>
</featureType>
<!-- Heat Pump -->
<featureType id="ng2_HeatPumpType" table="ng2_device" objectClassId="11106" path="HeatPump" schema="ng2">
<extension base="ng2_AbstractDeviceType"/>
<complexAttribute minOccurs="1" maxOccurs="1" path="heatSource" schema="ng2">
<attribute column="heat_source" type="string" path="." schema="ng2"/>
<featureType id="ng3_HeatPumpType" table="ng3_device" objectClassId="11106" path="HeatPump" schema="ng3">
<extension base="ng3_AbstractDeviceType"/>
<complexAttribute minOccurs="1" maxOccurs="1" path="heatSource" schema="ng3">
<attribute column="heat_source" type="string" path="." schema="ng3"/>
<attribute column="heat_source_codespace" type="string" path="@codespace" schema="gml"/>
</complexAttribute>
<complexAttribute maxOccurs="1" path="copSourceTemperature" schema="ng2">
<attribute column="cop_source_temp" type="double" path="." schema="ng2"/>
<complexAttribute maxOccurs="1" path="copSourceTemperature" schema="ng3">
<attribute column="cop_source_temp" type="double" path="." schema="ng3"/>
<attribute column="cop_source_temp_uom" type="string" path="@uom" schema="gml"/>
</complexAttribute>
<complexAttribute maxOccurs="1" path="copOperationTemperature" schema="ng2">
<attribute column="cop_operation_temp" type="double" path="." schema="ng2"/>
<complexAttribute maxOccurs="1" path="copOperationTemperature" schema="ng3">
<attribute column="cop_operation_temp" type="double" path="." schema="ng3"/>
<attribute column="cop_operation_temp_uom" type="string" path="@uom" schema="gml"/>
</complexAttribute>
</featureType>
<!-- Movable Shading Device -->
<featureType id="ng2_MovableShadingDeviceType" table="ng2_device" objectClassId="11107" path="MovableShadingDevice" schema="ng2">
<extension base="ng2_AbstractDeviceType"/>
<complexAttribute minOccurs="1" maxOccurs="1" path="type" schema="ng2">
<attribute column="type" type="string" path="." schema="ng2"/>
<featureType id="ng3_MovableShadingDeviceType" table="ng3_device" objectClassId="11107" path="MovableShadingDevice" schema="ng3">
<extension base="ng3_AbstractDeviceType"/>
<complexAttribute minOccurs="1" maxOccurs="1" path="type" schema="ng3">
<attribute column="type" type="string" path="." schema="ng3"/>
<attribute column="type_codespace" type="string" path="@codespace" schema="gml"/>
</complexAttribute>
<attribute minOccurs="1" maxOccurs="1" column="installation_side" type="string" path="installationSide" schema="ng2"/>
<complexAttribute maxOccurs="1" path="maximumCoverRatio" schema="ng2">
<attribute column="max_cover_ratio" type="double" path="." schema="ng2"/>
<attribute minOccurs="1" maxOccurs="1" column="installation_side" type="string" path="installationSide" schema="ng3"/>
<complexAttribute maxOccurs="1" path="maximumCoverRatio" schema="ng3">
<attribute column="max_cover_ratio" type="double" path="." schema="ng3"/>
<attribute column="max_cover_ratio_uom" type="string" path="@uom" schema="gml"/>
</complexAttribute>
<complexProperty maxOccurs="1" refType="ng2_TransmittanceType" path="transmittance" schema="ng2">
<join table="ng2_optical_property" fromColumn="transmittance_id" toColumn="id" toRole="parent">
<complexProperty maxOccurs="1" refType="ng3_TransmittanceType" path="transmittance" schema="ng3">
<join table="ng3_optical_property" fromColumn="transmittance_id" toColumn="id" toRole="parent">
<condition column="objectclass_id" value="${target.objectclass_id}" type="integer"/>
</join>
</complexProperty>
</featureType>
<!-- Electrical Storage Device -->
<featureType id="ng2_ElectricalStorageDeviceType" table="ng2_storage_device" objectClassId="11108" path="ElectricalStorageDevice" schema="ng2">
<extension base="ng2_AbstractDeviceType">
<join table="ng2_device" fromColumn="id" toColumn="id" toRole="parent"/>
<featureType id="ng3_ElectricalStorageDeviceType" table="ng3_storage_device" objectClassId="11108" path="ElectricalStorageDevice" schema="ng3">
<extension base="ng3_AbstractDeviceType">
<join table="ng3_device" fromColumn="id" toColumn="id" toRole="parent"/>
</extension>
<complexAttribute maxOccurs="1" path="batteryTechnology" schema="ng2">
<attribute column="batt_techn" type="string" path="." schema="ng2"/>
<complexAttribute maxOccurs="1" path="batteryTechnology" schema="ng3">
<attribute column="batt_techn" type="string" path="." schema="ng3"/>
<attribute column="batt_techn_codespace" type="string" path="@codespace" schema="gml"/>
</complexAttribute>
<complexAttribute maxOccurs="1" path="powerCapacity" schema="ng2">
<attribute column="power_capacity" type="double" path="." schema="ng2"/>
<complexAttribute maxOccurs="1" path="powerCapacity" schema="ng3">
<attribute column="power_capacity" type="double" path="." schema="ng3"/>
<attribute column="power_capacity_uom" type="string" path="@uom" schema="gml"/>
</complexAttribute>
</featureType>
<!-- Thermal Storage Device -->
<featureType id="ng2_ThermalStorageDeviceType" table="ng2_storage_device" objectClassId="11109" path="ThermalStorageDevice" schema="ng2">
<extension base="ng2_AbstractDeviceType">
<join table="ng2_device" fromColumn="id" toColumn="id" toRole="parent"/>
<featureType id="ng3_ThermalStorageDeviceType" table="ng3_storage_device" objectClassId="11109" path="ThermalStorageDevice" schema="ng3">
<extension base="ng3_AbstractDeviceType">
<join table="ng3_device" fromColumn="id" toColumn="id" toRole="parent"/>
</extension>
<complexAttribute maxOccurs="1" path="preparationTemperature" schema="ng2">
<attribute column="preparation_temp" type="double" path="." schema="ng2"/>
<complexAttribute maxOccurs="1" path="preparationTemperature" schema="ng3">
<attribute column="preparation_temp" type="double" path="." schema="ng3"/>
<attribute column="preparation_temp_uom" type="string" path="@uom" schema="gml"/>
</complexAttribute>
<complexAttribute maxOccurs="1" path="medium" schema="ng2">
<attribute column="medium" type="string" path="." schema="ng2"/>
<complexAttribute maxOccurs="1" path="medium" schema="ng3">
<attribute column="medium" type="string" path="." schema="ng3"/>
<attribute column="medium_codespace" type="string" path="@codespace" schema="gml"/>
</complexAttribute>
<complexAttribute maxOccurs="1" path="thermalLossesFactor" schema="ng2">
<complexAttribute maxOccurs="1" path="thermalLossesFactor" schema="ng3">
<attribute column="thm_losses_factor_uom" type="string" path="@uom" schema="gml"/>
<attribute column="thm_losses_factor" type="double" path="." schema="ng2"/>
<attribute column="thm_losses_factor" type="double" path="." schema="ng3"/>
</complexAttribute>
<complexAttribute maxOccurs="1" path="volume" schema="ng2">
<attribute column="volume" type="double" path="." schema="ng2"/>
<complexAttribute maxOccurs="1" path="volume" schema="ng3">
<attribute column="volume" type="double" path="." schema="ng3"/>
<attribute column="volume_uom" type="string" path="@uom" schema="gml"/>
</complexAttribute>
</featureType>
<!-- Abstract Solar Collector -->
<featureType abstract="true" id="ng2_AbstractSolarCollectorType" table="ng2_solar_collector" objectClassId="11110" path="AbstractSolarCollector" schema="ng2">
<extension base="ng2_AbstractDeviceType">
<join table="ng2_device" fromColumn="id" toColumn="id" toRole="parent"/>
<featureType abstract="true" id="ng3_AbstractSolarCollectorType" table="ng3_solar_collector" objectClassId="11110" path="AbstractSolarCollector" schema="ng3">
<extension base="ng3_AbstractDeviceType">
<join table="ng3_device" fromColumn="id" toColumn="id" toRole="parent"/>
</extension>
<complexAttribute maxOccurs="1" path="moduleArea" schema="ng2">
<attribute column="module_area" type="double" path="." schema="ng2"/>
<complexAttribute maxOccurs="1" path="moduleArea" schema="ng3">
<attribute column="module_area" type="double" path="." schema="ng3"/>
<attribute column="module_area_uom" type="string" path="@uom" schema="gml"/>
</complexAttribute>
<complexAttribute maxOccurs="1" path="apertureArea" schema="ng2">
<attribute column="aperture_area" type="double" path="." schema="ng2"/>
<complexAttribute maxOccurs="1" path="apertureArea" schema="ng3">
<attribute column="aperture_area" type="double" path="." schema="ng3"/>
<attribute column="aperture_area_uom" type="string" path="@uom" schema="gml"/>
</complexAttribute>
<complexAttribute maxOccurs="1" path="azimuth" schema="ng2">
<attribute column="azimuth" type="double" path="." schema="ng2"/>
<complexAttribute maxOccurs="1" path="azimuth" schema="ng3">
<attribute column="azimuth" type="double" path="." schema="ng3"/>
<attribute column="azimuth_uom" type="string" path="@uom" schema="gml"/>
</complexAttribute>
<complexAttribute maxOccurs="1" path="inclination" schema="ng2">
<attribute column="inclination" type="double" path="." schema="ng2"/>
<complexAttribute maxOccurs="1" path="inclination" schema="ng3">
<attribute column="inclination" type="double" path="." schema="ng3"/>
<attribute column="inclination_uom" type="string" path="@uom" schema="gml"/>
</complexAttribute>
<geometryProperty maxOccurs="1" lod="2" refColumn="lod2_multi_surface_id" type="MultiSurface" path="lod2MultiSurface" schema="ng2"/>
<geometryProperty maxOccurs="1" lod="3" refColumn="lod3_multi_surface_id" type="MultiSurface" path="lod3MultiSurface" schema="ng2"/>
<geometryProperty maxOccurs="1" lod="2" refColumn="lod2_multi_surface_id" type="MultiSurface" path="lod2MultiSurface" schema="ng3"/>
<geometryProperty maxOccurs="1" lod="3" refColumn="lod3_multi_surface_id" type="MultiSurface" path="lod3MultiSurface" schema="ng3"/>
</featureType>
<!-- Generic Solar Collector -->
<featureType id="ng2_GenericSolarCollectorType" table="ng2_solar_collector" objectClassId="11111" path="GenericSolarCollector" schema="ng2">
<extension base="ng2_AbstractSolarCollectorType"/>
<featureType id="ng3_GenericSolarCollectorType" table="ng3_solar_collector" objectClassId="11111" path="GenericSolarCollector" schema="ng3">
<extension base="ng3_AbstractSolarCollectorType"/>
</featureType>
<!-- Photovoltaic Collector -->
<featureType id="ng2_PhotovoltaicCollectorType" table="ng2_solar_collector" objectClassId="11112" path="PhotovoltaicCollector" schema="ng2">
<extension base="ng2_AbstractSolarCollectorType"/>
<complexAttribute minOccurs="1" maxOccurs="1" path="cellType" schema="ng2">
<attribute column="cell_type" type="string" path="." schema="ng2"/>
<featureType id="ng3_PhotovoltaicCollectorType" table="ng3_solar_collector" objectClassId="11112" path="PhotovoltaicCollector" schema="ng3">
<extension base="ng3_AbstractSolarCollectorType"/>
<complexAttribute minOccurs="1" maxOccurs="1" path="cellType" schema="ng3">
<attribute column="cell_type" type="string" path="." schema="ng3"/>
<attribute column="cell_type_codespace" type="string" path="@codespace" schema="gml"/>
</complexAttribute>
</featureType>
<!-- Solar Thermal Collector -->
<featureType id="ng2_SolarThermalCollectorType" table="ng2_solar_collector" objectClassId="11113" path="SolarThermalCollector" schema="ng2">
<extension base="ng2_AbstractSolarCollectorType"/>
<complexAttribute minOccurs="1" maxOccurs="1" path="collectorType" schema="ng2">
<attribute column="type" type="string" path="." schema="ng2"/>
<featureType id="ng3_SolarThermalCollectorType" table="ng3_solar_collector" objectClassId="11113" path="SolarThermalCollector" schema="ng3">
<extension base="ng3_AbstractSolarCollectorType"/>
<complexAttribute minOccurs="1" maxOccurs="1" path="collectorType" schema="ng3">
<attribute column="type" type="string" path="." schema="ng3"/>
<attribute column="type_codespace" type="string" path="@codespace" schema="gml"/>
</complexAttribute>
<complexAttribute maxOccurs="1" path="opticalEfficiency" schema="ng2">
<attribute column="opt_efficiency" type="double" path="." schema="ng2"/>
<complexAttribute maxOccurs="1" path="opticalEfficiency" schema="ng3">
<attribute column="opt_efficiency" type="double" path="." schema="ng3"/>
<attribute column="opt_efficiency_uom" type="string" path="@uom" schema="gml"/>
</complexAttribute>
<attribute maxOccurs="1" column="lin_heat_loss_coeff" type="double" path="linearHeatLossCoefficient" schema="ng2"/>
<attribute maxOccurs="1" column="quad_heat_loss_coeff" type="double" path="quadraticHeatLossCoefficient" schema="ng2"/>
<attribute maxOccurs="1" column="lin_heat_loss_coeff" type="double" path="linearHeatLossCoefficient" schema="ng3"/>
<attribute maxOccurs="1" column="quad_heat_loss_coeff" type="double" path="quadraticHeatLossCoefficient" schema="ng3"/>
</featureType>
<!-- Photovoltaic Thermal Collector -->
<featureType id="ng2_PhotovoltaicThermalCollectorType" table="ng2_solar_collector" objectClassId="11114" path="PhotovoltaicThermalCollector" schema="ng2">
<extension base="ng2_AbstractSolarCollectorType"/>
<complexAttribute minOccurs="1" maxOccurs="1" path="collectorType" schema="ng2">
<attribute column="type" type="string" path="." schema="ng2"/>
<featureType id="ng3_PhotovoltaicThermalCollectorType" table="ng3_solar_collector" objectClassId="11114" path="PhotovoltaicThermalCollector" schema="ng3">
<extension base="ng3_AbstractSolarCollectorType"/>
<complexAttribute minOccurs="1" maxOccurs="1" path="collectorType" schema="ng3">
<attribute column="type" type="string" path="." schema="ng3"/>
<attribute column="type_codespace" type="string" path="@codespace" schema="gml"/>
</complexAttribute>
<complexAttribute minOccurs="1" maxOccurs="1" path="cellType" schema="ng2">
<attribute column="cell_type" type="string" path="." schema="ng2"/>
<complexAttribute minOccurs="1" maxOccurs="1" path="cellType" schema="ng3">
<attribute column="cell_type" type="string" path="." schema="ng3"/>
<attribute column="cell_type_codespace" type="string" path="@codespace" schema="gml"/>
</complexAttribute>
<complexAttribute maxOccurs="1" path="opticalEfficiency" schema="ng2">
<attribute column="opt_efficiency" type="double" path="." schema="ng2"/>
<complexAttribute maxOccurs="1" path="opticalEfficiency" schema="ng3">
<attribute column="opt_efficiency" type="double" path="." schema="ng3"/>
<attribute column="opt_efficiency_uom" type="string" path="@uom" schema="gml"/>
</complexAttribute>
<attribute maxOccurs="1" column="lin_heat_loss_coeff" type="double" path="linearHeatLossCoefficient" schema="ng2"/>
<attribute maxOccurs="1" column="quad_heat_loss_coeff" type="double" path="quadraticHeatLossCoefficient" schema="ng2"/>
<attribute maxOccurs="1" column="lin_heat_loss_coeff" type="double" path="linearHeatLossCoefficient" schema="ng3"/>
<attribute maxOccurs="1" column="quad_heat_loss_coeff" type="double" path="quadraticHeatLossCoefficient" schema="ng3"/>
</featureType>
<!-- Urban Function Area -->
<featureType id="ng2_UrbanFunctionAreaType" table="ng2_urban_function_area" objectClassId="11120" topLevel="true" path="UrbanFunctionArea" schema="ng2">
<featureType id="ng3_UrbanFunctionAreaType" table="ng3_urban_function_area" objectClassId="11120" topLevel="true" path="UrbanFunctionArea" schema="ng3">
<extension base="CityObjectGroupType">
<join table="cityobjectgroup" fromColumn="id" toColumn="id" toRole="parent"/>
</extension>
<complexAttribute minOccurs="1" maxOccurs="1" path="type" schema="ng2">
<attribute column="type" type="string" path="." schema="ng2"/>
<complexAttribute minOccurs="1" maxOccurs="1" path="type" schema="ng3">
<attribute column="type" type="string" path="." schema="ng3"/>
<attribute column="type_codespace" type="string" path="@codespace" schema="gml"/>
</complexAttribute>
<complexAttribute maxOccurs="1" path="code" schema="ng2">
<attribute column="code" type="string" path="." schema="ng2"/>
<complexAttribute maxOccurs="1" path="code" schema="ng3">
<attribute column="code" type="string" path="." schema="ng3"/>
<attribute column="code_codespace" type="string" path="@codespace" schema="gml"/>
</complexAttribute>
</featureType>
<!-- Weather Station -->
<featureType id="ng2_WeatherStationType" table="cityobject" objectClassId="11130" topLevel="true" path="WeatherStation" schema="ng2">
<featureType id="ng3_WeatherStationType" table="cityobject" objectClassId="11130" topLevel="true" path="WeatherStation" schema="ng3">
<extension base="AbstractCityObjectType"/>
</featureType>
<!-- Abstract Library -->
<featureType abstract="true" id="ng2_AbstractLibraryType" table="ng2_library" objectClassId="11140" path="AbstractLibrary" schema="ng2">
<featureType abstract="true" id="ng3_AbstractLibraryType" table="ng3_library" objectClassId="11140" path="AbstractLibrary" schema="ng3">
<extension base="AbstractCityObjectType">
<join table="cityobject" fromColumn="id" toColumn="id" toRole="parent"/>
</extension>
<complexAttribute maxOccurs="1" path="type" schema="ng2">
<complexAttribute maxOccurs="1" path="type" schema="ng3">
<attribute column="type_codespace" type="string" path="@codespace" schema="gml"/>
<attribute column="type" type="string" path="." schema="ng2"/>
<attribute column="type" type="string" path="." schema="ng3"/>
</complexAttribute>
<attribute maxOccurs="1" column="source" type="string" path="source" schema="ng2"/>
<attribute maxOccurs="1" column="author" type="string" path="author" schema="ng2"/>
<attribute maxOccurs="1" column="source" type="string" path="source" schema="ng3"/>
<attribute maxOccurs="1" column="author" type="string" path="author" schema="ng3"/>
</featureType>
<!-- Layered Construction Library -->
<featureType id="ng2_LayeredConstructionLibraryType" table="ng2_library" objectClassId="11141" topLevel="true" path="LayeredConstructionLibrary" schema="ng2">
<extension base="ng2_AbstractLibraryType"/>
<featureProperty target="ng2_AbstractLayeredConstructionType" path="libraryMember" schema="ng2" relationType="composition">
<join table="ng2_layered_construction" fromColumn="id" toColumn="library_id" toRole="child">
<featureType id="ng3_LayeredConstructionLibraryType" table="ng3_library" objectClassId="11141" topLevel="true" path="LayeredConstructionLibrary" schema="ng3">
<extension base="ng3_AbstractLibraryType"/>
<featureProperty target="ng3_AbstractLayeredConstructionType" path="libraryMember" schema="ng3" relationType="composition">
<join table="ng3_layered_construction" fromColumn="id" toColumn="library_id" toRole="child">
<condition column="objectclass_id" value="${target.objectclass_id}" type="integer"/>
</join>
</featureProperty>
</featureType>
<!-- Material Library -->
<featureType id="ng2_MaterialLibraryType" table="ng2_library" objectClassId="11142" topLevel="true" path="MaterialLibrary" schema="ng2">
<extension base="ng2_AbstractLibraryType"/>
<featureProperty target="ng2_AbstractMaterialType" path="libraryMember" schema="ng2" relationType="composition">
<join table="ng2_material" fromColumn="id" toColumn="library_id" toRole="child">
<featureType id="ng3_MaterialLibraryType" table="ng3_library" objectClassId="11142" topLevel="true" path="MaterialLibrary" schema="ng3">
<extension base="ng3_AbstractLibraryType"/>
<featureProperty target="ng3_AbstractMaterialType" path="libraryMember" schema="ng3" relationType="composition">
<join table="ng3_material" fromColumn="id" toColumn="library_id" toRole="child">
<condition column="objectclass_id" value="${target.objectclass_id}" type="integer"/>
</join>
</featureProperty>
</featureType>
<!-- Schedule Library -->
<featureType id="ng2_ScheduleLibraryType" table="ng2_library" objectClassId="11143" topLevel="true" path="ScheduleLibrary" schema="ng2">
<extension base="ng2_AbstractLibraryType"/>
<featureProperty target="ng2_AbstractScheduleType" path="libraryMember" schema="ng2" relationType="composition">
<join table="ng2_schedule" fromColumn="id" toColumn="library_id" toRole="child">
<featureType id="ng3_ScheduleLibraryType" table="ng3_library" objectClassId="11143" topLevel="true" path="ScheduleLibrary" schema="ng3">
<extension base="ng3_AbstractLibraryType"/>
<featureProperty target="ng3_AbstractScheduleType" path="libraryMember" schema="ng3" relationType="composition">
<join table="ng3_schedule" fromColumn="id" toColumn="library_id" toRole="child">
<condition column="objectclass_id" value="${target.objectclass_id}" type="integer"/>
</join>
</featureProperty>
......@@ -1250,153 +1250,153 @@ https://3d.bk.tudelft.nl/gagugiaro/
<propertyInjections>
<!-- ADE _CityObject -->
<propertyInjection table="ng2_cityobject" defaultBase="AbstractCityObjectType">
<join table="ng2_cityobject" fromColumn="id" toColumn="id" toRole="child"/>
<complexProperty refType="ng2_CityObjectRelationType" path="relatedTo" schema="ng2">
<join table="ng2_ctyobj_relation" fromColumn="id" toColumn="ng2_cityobject_id" toRole="child"/>
<propertyInjection table="ng3_cityobject" defaultBase="AbstractCityObjectType">
<join table="ng3_cityobject" fromColumn="id" toColumn="id" toRole="child"/>
<complexProperty refType="ng3_CityObjectRelationType" path="relatedTo" schema="ng3">
<join table="ng3_ctyobj_relation" fromColumn="id" toColumn="ng3_cityobject_id" toRole="child"/>
</complexProperty>
<featureProperty target="ng2_UtilityNetworkConnectionType" path="utilityNetworkConnection" schema="ng2" relationType="composition">
<join table="ng2_utl_ntw_connection" fromColumn="id" toColumn="cityobject_id" toRole="child"/>
<featureProperty target="ng3_UtilityNetworkConnectionType" path="utilityNetworkConnection" schema="ng3" relationType="composition">
<join table="ng3_utl_ntw_connection" fromColumn="id" toColumn="cityobject_id" toRole="child"/>
</featureProperty>
<featureProperty maxOccurs="1" target="ng2_AbstractLayeredConstructionType" path="layeredConstruction" schema="ng2" relationType="association"> <!-- could be "aggregation" -->
<join table="ng2_layered_construction" fromColumn="layered_construction_id" toColumn="id" toRole="parent">
<featureProperty maxOccurs="1" target="ng3_AbstractLayeredConstructionType" path="layeredConstruction" schema="ng3" relationType="association"> <!-- could be "aggregation" -->
<join table="ng3_layered_construction" fromColumn="layered_construction_id" toColumn="id" toRole="parent">
<condition column="objectclass_id" value="${target.objectclass_id}" type="integer"/>
</join>
</featureProperty>
<featureProperty target="ng2_AbstractDeviceType" path="device" schema="ng2" relationType="aggregation">
<join table="ng2_device" fromColumn="id" toColumn="cityobject_id" toRole="child">
<featureProperty target="ng3_AbstractDeviceType" path="device" schema="ng3" relationType="aggregation">
<join table="ng3_device" fromColumn="id" toColumn="cityobject_id" toRole="child">
<condition column="objectclass_id" value="${target.objectclass_id}" type="integer"/>
</join>
</featureProperty>
<featureProperty target="ng2_AbstractResourceType" path="resource" schema="ng2" relationType="composition">
<join table="ng2_resource" fromColumn="id" toColumn="cityobject_id" toRole="child">
<featureProperty target="ng3_AbstractResourceType" path="resource" schema="ng3" relationType="composition">
<join table="ng3_resource" fromColumn="id" toColumn="cityobject_id" toRole="child">
<condition column="objectclass_id" value="${target.objectclass_id}" type="integer"/>
</join>
</featureProperty>
<complexProperty refType="ng2_SuitabilityType" path="suitability" schema="ng2">
<join table="ng2_suitability" fromColumn="id" toColumn="cityobject_id" toRole="child"/>
<complexProperty refType="ng3_SuitabilityType" path="suitability" schema="ng3">
<join table="ng3_suitability" fromColumn="id" toColumn="cityobject_id" toRole="child"/>
</complexProperty>
<featureProperty target="ng2_WeatherDataType" path="weatherData" schema="ng2" relationType="composition">
<join table="ng2_weather_data" fromColumn="id" toColumn="cityobject_id" toRole="child"/>
<featureProperty target="ng3_WeatherDataType" path="weatherData" schema="ng3" relationType="composition">
<join table="ng3_weather_data" fromColumn="id" toColumn="cityobject_id" toRole="child"/>
</featureProperty>
<geometryProperty inlineColumn="ref_point" type="Point" path="referencePoint" schema="ng2"/>
<geometryProperty inlineColumn="ref_point" type="Point" path="referencePoint" schema="ng3"/>
</propertyInjection>
<!-- ADE Building -->
<propertyInjection table="ng2_building" defaultBase="AbstractBuildingType">
<join table="ng2_building" fromColumn="id" toColumn="id" toRole="child"/>
<complexAttribute maxOccurs="1" path="bdgType" schema="ng2">
<attribute column="type" type="string" path="." schema="ng2"/>
<propertyInjection table="ng3_building" defaultBase="AbstractBuildingType">
<join table="ng3_building" fromColumn="id" toColumn="id" toRole="child"/>
<complexAttribute maxOccurs="1" path="bdgType" schema="ng3">
<attribute column="type" type="string" path="." schema="ng3"/>
<attribute column="type_codespace" type="string" path="@codespace" schema="gml"/>
</complexAttribute>
<complexAttribute maxOccurs="1" path="bdgConstructionWeight" schema="ng2">
<attribute column="constr_weight" type="string" path="." schema="ng2"/>
<complexAttribute maxOccurs="1" path="bdgConstructionWeight" schema="ng3">
<attribute column="constr_weight" type="string" path="." schema="ng3"/>
<attribute column="constr_weight_codespace" type="string" path="@codespace" schema="gml"/>
</complexAttribute>
<attribute maxOccurs="1" column="is_protected" type="boolean" path="bdgIsProtected" schema="ng2"/>
<attribute maxOccurs="1" column="attic_thm_status" type="string" path="bdgAtticThermalStatus" schema="ng2"/>
<attribute maxOccurs="1" column="basement_thm_status" type="string" path="bdgBasementThermalStatus" schema="ng2"/>
<complexProperty refType="ng2_QualifiedHeightType" path="bdgHeight" schema="ng2">
<join table="ng2_qualified_attribute" fromColumn="id" toColumn="building_id" toRole="child">
<attribute maxOccurs="1" column="is_protected" type="boolean" path="bdgIsProtected" schema="ng3"/>
<attribute maxOccurs="1" column="attic_thm_status" type="string" path="bdgAtticThermalStatus" schema="ng3"/>
<attribute maxOccurs="1" column="basement_thm_status" type="string" path="bdgBasementThermalStatus" schema="ng3"/>
<complexProperty refType="ng3_QualifiedHeightType" path="bdgHeight" schema="ng3">
<join table="ng3_qualified_attribute" fromColumn="id" toColumn="building_id" toRole="child">
<condition column="objectclass_id" value="${target.objectclass_id}" type="integer"/>
</join>
</complexProperty>
<complexProperty refType="ng2_QualifiedAreaType" path="bdgArea" schema="ng2">
<join table="ng2_qualified_attribute" fromColumn="id" toColumn="building_id" toRole="child">
<complexProperty refType="ng3_QualifiedAreaType" path="bdgArea" schema="ng3">
<join table="ng3_qualified_attribute" fromColumn="id" toColumn="building_id" toRole="child">
<condition column="objectclass_id" value="${target.objectclass_id}" type="integer"/>
</join>
</complexProperty>
<complexProperty refType="ng2_QualifiedVolumeType" path="bdgVolume" schema="ng2">
<join table="ng2_qualified_attribute" fromColumn="id" toColumn="building_id" toRole="child">
<complexProperty refType="ng3_QualifiedVolumeType" path="bdgVolume" schema="ng3">
<join table="ng3_qualified_attribute" fromColumn="id" toColumn="building_id" toRole="child">
<condition column="objectclass_id" value="${target.objectclass_id}" type="integer"/>
</join>
</complexProperty>
<featureProperty target="ng2_RefurbishmentMeasureType" path="refurbishmentMeasure" schema="ng2" relationType="composition">
<join table="ng2_refurbishment_measure" fromColumn="id" toColumn="building_id" toRole="child"/>
<featureProperty target="ng3_RefurbishmentMeasureType" path="refurbishmentMeasure" schema="ng3" relationType="composition">
<join table="ng3_refurbishment_measure" fromColumn="id" toColumn="building_id" toRole="child"/>
</featureProperty>
<featureProperty target="ng2_EnergyPerformanceCertificateType" path="energyPerformanceCertificate" schema="ng2" relationType="composition">
<join table="ng2_energy_perf_cert" fromColumn="id" toColumn="building_id" toRole="child"/>
<featureProperty target="ng3_EnergyPerformanceCertificateType" path="energyPerformanceCertificate" schema="ng3" relationType="composition">
<join table="ng3_energy_perf_cert" fromColumn="id" toColumn="building_id" toRole="child"/>
</featureProperty>
<featureProperty target="ng2_AbstractBuildingUnitType" path="buildingUnit" schema="ng2" relationType="composition">
<join table="ng2_building_partition" fromColumn="id" toColumn="building_id" toRole="child">
<featureProperty target="ng3_AbstractBuildingUnitType" path="buildingUnit" schema="ng3" relationType="composition">
<join table="ng3_building_partition" fromColumn="id" toColumn="building_id" toRole="child">
<condition column="objectclass_id" value="${target.objectclass_id}" type="integer"/>
</join>
</featureProperty>
<featureProperty target="ng2_AbstractThermalZoneType" path="thermalZone" schema="ng2" relationType="composition">
<join table="ng2_building_partition" fromColumn="id" toColumn="building_id" toRole="child">
<featureProperty target="ng3_AbstractThermalZoneType" path="thermalZone" schema="ng3" relationType="composition">
<join table="ng3_building_partition" fromColumn="id" toColumn="building_id" toRole="child">
<condition column="objectclass_id" value="${target.objectclass_id}" type="integer"/>
</join>
</featureProperty>
<featureProperty target="ng2_AbstractUsageZoneType" path="usageZone" schema="ng2" relationType="composition">
<join table="ng2_building_partition" fromColumn="id" toColumn="building_id" toRole="child">
<featureProperty target="ng3_AbstractUsageZoneType" path="usageZone" schema="ng3" relationType="composition">
<join table="ng3_building_partition" fromColumn="id" toColumn="building_id" toRole="child">
<condition column="objectclass_id" value="${target.objectclass_id}" type="integer"/>
</join>
</featureProperty>
</propertyInjection>
<!-- (Building) ADE _BoundarySurface -->
<propertyInjection table="ng2_thematic_surface" defaultBase="AbstractBoundarySurfaceType">
<join table="ng2_thematic_surface" fromColumn="id" toColumn="id" toRole="child"/>
<complexAttribute maxOccurs="1" path="bdgBdrySurfAzimuth" schema="ng2">
<attribute column="azimuth" type="double" path="." schema="ng2"/>
<propertyInjection table="ng3_thematic_surface" defaultBase="AbstractBoundarySurfaceType">
<join table="ng3_thematic_surface" fromColumn="id" toColumn="id" toRole="child"/>
<complexAttribute maxOccurs="1" path="bdgBdrySurfAzimuth" schema="ng3">
<attribute column="azimuth" type="double" path="." schema="ng3"/>
<attribute column="azimuth_uom" type="string" path="@uom" schema="gml"/>
</complexAttribute>
<complexAttribute maxOccurs="1" path="bdgBdrySurfGroundViewFactor" schema="ng2">
<attribute column="ground_view_factor" type="double" path="." schema="ng2"/>
<complexAttribute maxOccurs="1" path="bdgBdrySurfGroundViewFactor" schema="ng3">
<attribute column="ground_view_factor" type="double" path="." schema="ng3"/>
<attribute column="ground_view_factor_uom" type="string" path="@uom" schema="gml"/>
</complexAttribute>
<complexAttribute maxOccurs="1" path="bdgBdrySurfHeatCapacity" schema="ng2">
<attribute column="heat_capacity" type="double" path="." schema="ng2"/>
<complexAttribute maxOccurs="1" path="bdgBdrySurfHeatCapacity" schema="ng3">
<attribute column="heat_capacity" type="double" path="." schema="ng3"/>
<attribute column="heat_capacity_uom" type="string" path="@uom" schema="gml"/>
</complexAttribute>
<complexAttribute maxOccurs="1" path="bdgBdrySurfInclination" schema="ng2">
<attribute column="inclination" type="double" path="." schema="ng2"/>
<complexAttribute maxOccurs="1" path="bdgBdrySurfInclination" schema="ng3">
<attribute column="inclination" type="double" path="." schema="ng3"/>
<attribute column="inclination_uom" type="string" path="@uom" schema="gml"/>
</complexAttribute>
<attribute maxOccurs="1" column="is_adiabatic" type="boolean" path="bdgBdrySurfIsAdiabatic" schema="ng2"/>
<complexAttribute maxOccurs="1" path="bdgBdrySurfOpaqueSurfaceArea" schema="ng2">
<attribute column="opaque_surf_area" type="double" path="." schema="ng2"/>
<attribute maxOccurs="1" column="is_adiabatic" type="boolean" path="bdgBdrySurfIsAdiabatic" schema="ng3"/>
<complexAttribute maxOccurs="1" path="bdgBdrySurfOpaqueSurfaceArea" schema="ng3">
<attribute column="opaque_surf_area" type="double" path="." schema="ng3"/>
<attribute column="opaque_surf_area_uom" type="string" path="@uom" schema="gml"/>
</complexAttribute>
<complexAttribute maxOccurs="1" path="bdgBdrySurfOpeningToSurfaceRatio" schema="ng2">
<attribute column="open_to_surf_ration" type="double" path="." schema="ng2"/>
<complexAttribute maxOccurs="1" path="bdgBdrySurfOpeningToSurfaceRatio" schema="ng3">
<attribute column="open_to_surf_ration" type="double" path="." schema="ng3"/>
<attribute column="open_to_surf_ration_uom" type="string" path="@uom" schema="gml"/>
</complexAttribute>
<complexAttribute maxOccurs="1" path="bdgBdrySurfSkyViewFactor" schema="ng2">
<attribute column="sky_view_factor" type="double" path="." schema="ng2"/>
<complexAttribute maxOccurs="1" path="bdgBdrySurfSkyViewFactor" schema="ng3">
<attribute column="sky_view_factor" type="double" path="." schema="ng3"/>
<attribute column="sky_view_factor_uom" type="string" path="@uom" schema="gml"/>
</complexAttribute>
<complexAttribute maxOccurs="1" path="bdgBdrySurfThickness" schema="ng2">
<attribute column="thickness" type="double" path="." schema="ng2"/>
<complexAttribute maxOccurs="1" path="bdgBdrySurfThickness" schema="ng3">
<attribute column="thickness" type="double" path="." schema="ng3"/>
<attribute column="thickness_uom" type="string" path="@uom" schema="gml"/>
</complexAttribute>
<complexAttribute maxOccurs="1" path="bdgBdrySurfTotalSurfaceArea" schema="ng2">
<attribute column="total_surf_area" type="double" path="." schema="ng2"/>
<complexAttribute maxOccurs="1" path="bdgBdrySurfTotalSurfaceArea" schema="ng3">
<attribute column="total_surf_area" type="double" path="." schema="ng3"/>
<attribute column="total_surf_area_uom" type="string" path="@uom" schema="gml"/>
</complexAttribute>
</propertyInjection>
<!-- (Building) ADE _Opening -->
<propertyInjection table="ng2_opening" defaultBase="AbstractOpeningType">
<join table="ng2_opening" fromColumn="id" toColumn="id" toRole="child"/>
<complexAttribute maxOccurs="1" path="bdgOpnArea" schema="ng2">
<attribute column="area" type="double" path="." schema="ng2"/>
<propertyInjection table="ng3_opening" defaultBase="AbstractOpeningType">
<join table="ng3_opening" fromColumn="id" toColumn="id" toRole="child"/>
<complexAttribute maxOccurs="1" path="bdgOpnArea" schema="ng3">
<attribute column="area" type="double" path="." schema="ng3"/>
<attribute column="area_uom" type="string" path="@uom" schema="gml"/>
</complexAttribute>
<complexAttribute maxOccurs="1" path="bdgOpnAzimuth" schema="ng2">
<attribute column="azimuth" type="double" path="." schema="ng2"/>
<complexAttribute maxOccurs="1" path="bdgOpnAzimuth" schema="ng3">
<attribute column="azimuth" type="double" path="." schema="ng3"/>
<attribute column="azimuth_uom" type="string" path="@uom" schema="gml"/>
</complexAttribute>
<complexAttribute maxOccurs="1" path="bdgOpnGroundViewFactor" schema="ng2">
<attribute column="ground_view_factor" type="double" path="." schema="ng2"/>
<complexAttribute maxOccurs="1" path="bdgOpnGroundViewFactor" schema="ng3">
<attribute column="ground_view_factor" type="double" path="." schema="ng3"/>
<attribute column="ground_view_factor_uom" type="string" path="@uom" schema="gml"/>
</complexAttribute>
<complexAttribute maxOccurs="1" path="bdgOpnInclination" schema="ng2">
<attribute column="inclination" type="double" path="." schema="ng2"/>
<complexAttribute maxOccurs="1" path="bdgOpnInclination" schema="ng3">
<attribute column="inclination" type="double" path="." schema="ng3"/>
<attribute column="inclination_uom" type="string" path="@uom" schema="gml"/>
</complexAttribute>
<complexAttribute maxOccurs="1" path="bdgOpnSkyViewFactor" schema="ng2">
<attribute column="sky_view_factor" type="double" path="." schema="ng2"/>
<complexAttribute maxOccurs="1" path="bdgOpnSkyViewFactor" schema="ng3">
<attribute column="sky_view_factor" type="double" path="." schema="ng3"/>
<attribute column="sky_view_factor_uom" type="string" path="@uom" schema="gml"/>
</complexAttribute>
</propertyInjection>
......
......@@ -40,15 +40,15 @@ public class AbstractQualifiedAttributeExporter implements ADEExporter {
this.manager = manager;
attributeClassMap = new HashMap<>();
SchemaMapping schemaMapping = ObjectRegistry.getInstance().getSchemaMapping();
ComplexType qualifiedHeightType = schemaMapping.getComplexType("QualifiedHeight", "http://www.citygml.org/ade/energy/2.0");
ComplexType qualifiedHeightType = schemaMapping.getComplexType("QualifiedHeight", "http://www.citygml.org/ade/energy/3.0");
int objectClassIdOfQualifiedHeight = qualifiedHeightType.getObjectClassId();
attributeClassMap.put(objectClassIdOfQualifiedHeight, QualifiedHeight.class);
ComplexType qualifiedAreaType = schemaMapping.getComplexType("QualifiedArea", "http://www.citygml.org/ade/energy/2.0");
ComplexType qualifiedAreaType = schemaMapping.getComplexType("QualifiedArea", "http://www.citygml.org/ade/energy/3.0");
int objectClassIdOfQualifiedArea = qualifiedAreaType.getObjectClassId();
attributeClassMap.put(objectClassIdOfQualifiedArea, QualifiedArea.class);
ComplexType qualifiedVolumeType = schemaMapping.getComplexType("QualifiedVolume", "http://www.citygml.org/ade/energy/2.0");
ComplexType qualifiedVolumeType = schemaMapping.getComplexType("QualifiedVolume", "http://www.citygml.org/ade/energy/3.0");
int objectClassIdOfQualifiedVolume = qualifiedVolumeType.getObjectClassId();
attributeClassMap.put(objectClassIdOfQualifiedVolume, QualifiedVolume.class);
......
......@@ -10,7 +10,7 @@ import org.citydb.core.query.filter.projection.ProjectionFilter;
import org.citygml4j.ade.energy3.model.core.*;
import org.citygml4j.ade.energy3.model.module.EnergyADEModule;
import org.citygml4j.model.citygml.building.AbstractBuilding;
import org.sig3d.citygml.energyADE2beta7.ThermalStatusValueType;
import org.sig3d.citygml.energyADE3beta7.ThermalStatusValueType;
import java.sql.Connection;
import java.sql.PreparedStatement;
......
......@@ -10,7 +10,7 @@ import org.citygml4j.ade.energy3.model.core.AbstractResource;
import org.citygml4j.ade.energy3.model.supportingClasses.*;
import org.citygml4j.model.gml.basicTypes.Code;
import org.citygml4j.model.gml.basicTypes.Measure;
import org.sig3d.citygml.energyADE2beta7.ResourceStatusValueType;
import org.sig3d.citygml.energyADE3beta7.ResourceStatusValueType;
import java.sql.*;
import java.util.ArrayList;
......
......@@ -10,10 +10,10 @@ import org.citydb.core.database.schema.mapping.SchemaMapping;
import org.citydb.core.operation.importer.CityGMLImportException;
import org.citydb.core.operation.importer.util.GeometryConverter;
import org.citydb.core.registry.ObjectRegistry;
import org.sig3d.citygml.energyADE2beta7.AbstractQualifiedAttributeType;
import org.sig3d.citygml.energyADE2beta7.QualifiedAreaType;
import org.sig3d.citygml.energyADE2beta7.QualifiedHeightType;
import org.sig3d.citygml.energyADE2beta7.QualifiedVolumeType;
import org.sig3d.citygml.energyADE3beta7.AbstractQualifiedAttributeType;
import org.sig3d.citygml.energyADE3beta7.QualifiedAreaType;
import org.sig3d.citygml.energyADE3beta7.QualifiedHeightType;
import org.sig3d.citygml.energyADE3beta7.QualifiedVolumeType;
import java.sql.Connection;
import java.sql.PreparedStatement;
......@@ -69,7 +69,7 @@ public class AbstractQualifiedAttributeImporter implements ADEImporter {
if (abstractQualifiedAttribute instanceof QualifiedHeightType qualifiedHeight) {
if (qualifiedHeight.isSetType()) {
SchemaMapping schemaMapping = ObjectRegistry.getInstance().getSchemaMapping();
ComplexType qualifiedHeightType = schemaMapping.getComplexType("QualifiedHeight", "http://www.citygml.org/ade/energy/2.0");
ComplexType qualifiedHeightType = schemaMapping.getComplexType("QualifiedHeight", "http://www.citygml.org/ade/energy/3.0");
int objectClassId = qualifiedHeightType.getObjectClassId();
ps.setInt(2, objectClassId);
ps.setString(3, qualifiedHeight.getType().getValue());
......@@ -78,7 +78,7 @@ public class AbstractQualifiedAttributeImporter implements ADEImporter {
} else if (abstractQualifiedAttribute instanceof QualifiedAreaType qualifiedArea) {
if (qualifiedArea.isSetType()) {
SchemaMapping schemaMapping = ObjectRegistry.getInstance().getSchemaMapping();
ComplexType qualifiedAreaType = schemaMapping.getComplexType("QualifiedArea", "http://www.citygml.org/ade/energy/2.0");
ComplexType qualifiedAreaType = schemaMapping.getComplexType("QualifiedArea", "http://www.citygml.org/ade/energy/3.0");
int objectClassId = qualifiedAreaType.getObjectClassId();
ps.setInt(2, objectClassId);
ps.setString(3, qualifiedArea.getType().getValue());
......@@ -87,7 +87,7 @@ public class AbstractQualifiedAttributeImporter implements ADEImporter {
} else if (abstractQualifiedAttribute instanceof QualifiedVolumeType qualifiedVolume) {
if (qualifiedVolume.isSetType()){
SchemaMapping schemaMapping = ObjectRegistry.getInstance().getSchemaMapping();
ComplexType qualifiedVolumeType = schemaMapping.getComplexType("QualifiedVolume", "http://www.citygml.org/ade/energy/2.0");
ComplexType qualifiedVolumeType = schemaMapping.getComplexType("QualifiedVolume", "http://www.citygml.org/ade/energy/3.0");
int objectClassId = qualifiedVolumeType.getObjectClassId();
ps.setInt(2, objectClassId);
ps.setString(3, qualifiedVolume.getType().getValue());
......
......@@ -11,9 +11,9 @@ import org.citydb.core.operation.importer.CityGMLImportException;
import org.citydb.core.operation.importer.util.GeometryConverter;
import org.citygml4j.ade.energy3.model.core.*;
import org.citygml4j.model.citygml.building.AbstractBuilding;
import org.sig3d.citygml.energyADE2beta7.QualifiedAreaType;
import org.sig3d.citygml.energyADE2beta7.QualifiedHeightType;
import org.sig3d.citygml.energyADE2beta7.QualifiedVolumeType;
import org.sig3d.citygml.energyADE3beta7.QualifiedAreaType;
import org.sig3d.citygml.energyADE3beta7.QualifiedHeightType;
import org.sig3d.citygml.energyADE3beta7.QualifiedVolumeType;
import java.sql.Connection;
import java.sql.PreparedStatement;
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment