Commit f95176d1 authored by Riegel's avatar Riegel
Browse files

Fix: Backwards compatibility with CityGML 2.0

parent 82596784
Pipeline #10962 passed with stage
in 1 minute and 26 seconds
......@@ -76,12 +76,18 @@ public class CityFurniture extends CityObject {
case LOD0:
cgmlCityFurniture.setLod0MultiSurface(new MultiSurfaceProperty(ms));
break;
case LOD1:
cgmlCityFurniture.getDeprecatedProperties().setLod1Geometry(new MultiSurfaceProperty(ms));
break;
case LOD2:
cgmlCityFurniture.setLod2MultiSurface(new MultiSurfaceProperty(ms));
break;
case LOD3:
cgmlCityFurniture.setLod3MultiSurface(new MultiSurfaceProperty(ms));
break;
case LOD4:
cgmlCityFurniture.getDeprecatedProperties().setLod4Geometry(new MultiSurfaceProperty(ms));
break;
default:
throw new IllegalStateException("Cannot add " + geom.getLod() + " multi surface to buildings");
}
......@@ -98,6 +104,8 @@ public class CityFurniture extends CityObject {
case LOD3:
cgmlCityFurniture.setLod3Solid(new SolidProperty(solid));
break;
case LOD4:
cgmlCityFurniture.getDeprecatedProperties().setLod4Geometry(new SolidProperty(solid));
default:
throw new IllegalStateException("Cannot add " + geom.getLod() + " solid to buildings");
}
......
......@@ -84,14 +84,20 @@ public class GenericCityObject extends CityObject {
case LOD0:
cgmlGos.setLod0MultiSurface(new MultiSurfaceProperty(ms));
break;
case LOD1:
cgmlGos.getDeprecatedProperties().setLod1Geometry(new MultiSurfaceProperty(ms));
break;
case LOD2:
cgmlGos.setLod2MultiSurface(new MultiSurfaceProperty(ms));
break;
case LOD3:
cgmlGos.setLod3MultiSurface(new MultiSurfaceProperty(ms));
break;
case LOD4:
cgmlGos.getDeprecatedProperties().setLod4Geometry(new MultiSurfaceProperty(ms));
break;
default:
throw new IllegalStateException("Cannot add " + geom.getLod() + " multi surface to buildings");
throw new IllegalStateException("Cannot add " + geom.getLod() + " multi surface to generic city object");
}
}
......@@ -106,6 +112,9 @@ public class GenericCityObject extends CityObject {
case LOD3:
cgmlGos.setLod3Solid(new SolidProperty(solid));
break;
case LOD4:
cgmlGos.getDeprecatedProperties().setLod4Geometry(new SolidProperty(solid));
break;
default:
throw new IllegalStateException("Cannot add " + geom.getLod() + " solid to buildings");
}
......
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