1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47
|
# BGT Basisregistratie Grootschalige Topografie is based
# on CityGML. This ETL flattens this structure into Postgis tables
[etl]
# chains = input_big_gml_files|xml_assembler|transformer_xslt|output_std
chains = input_big_gml_files|xml_assembler|transformer_xslt|output_ogr2ogr_postgis
# The source input file(s) from dir and produce gml:featureMember elements
[input_big_gml_files]
class = stetl.inputs.fileinput.XmlElementStreamerFileInput
file_path = {gml_input}
element_tags = cityObjectMember
# Assembles etree docs gml:featureMember elements, each with "max_elements" elements
[xml_assembler]
class = stetl.filters.xmlassembler.XmlAssembler
max_elements = {max_in_memory_features}
container_doc = <?xml version="1.0" encoding="UTF-8"?>
<cit:CityModel xmlns:xlink="http://www.w3.org/1999/xlink"
xmlns:bri="http://www.opengis.net/citygml/bridge/2.0"
xmlns:bui="http://www.opengis.net/citygml/building/2.0"
xmlns:cif="http://www.opengis.net/citygml/cityfurniture/2.0"
xmlns:cit="http://www.opengis.net/citygml/2.0"
xmlns:gml="http://www.opengis.net/gml"
xmlns:imgeo="http://www.geostandaarden.nl/imgeo/2.1"
xmlns:lu="http://www.opengis.net/citygml/landuse/2.0"
xmlns:tra="http://www.opengis.net/citygml/transportation/2.0"
xmlns:tun="http://www.opengis.net/citygml/tunnel/2.0"
xmlns:veg="http://www.opengis.net/citygml/vegetation/2.0"
xmlns:wat="http://www.opengis.net/citygml/waterbody/2.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
gml:id="BgtExample"
xsi:schemaLocation="http://www.geostandaarden.nl/imgeo/2.1 schema/imgeo-2.1.1.xsd http://www.opengis.net/citygml/2.0 http://schemas.opengis.net/citygml/2.0/cityGMLBase.xsd">
</cit:CityModel>
element_container_tag = CityModel
[transformer_xslt]
class = stetl.filters.xsltfilter.XsltFilter
script = bgt-to-gmlfc-all.xsl
[output_std]
class = stetl.outputs.standardoutput.StandardXmlOutput
[output_ogr2ogr_postgis]
class = stetl.outputs.ogroutput.Ogr2OgrOutput
temp_file = output/temp.gml
ogr2ogr_cmd = ogr2ogr -f "Postgresql" PG:"host={host} port={port} user={user} dbname={database} password={password} active_schema={schema}" -a_srs epsg:28992 -dim 2 -overwrite -preserve_fid output/temp.gml
|