comparison flys-backend/contrib/shpimporter/shpimporter.py @ 2861:b0132e1b9719

Added further shape importers and added the option to reproject shapes during the import process. flys-backend/trunk@4342 c6561f87-3c4e-4783-a992-168aeb5c3f6f
author Ingo Weinzierl <ingo.weinzierl@intevation.de>
date Thu, 03 May 2012 14:19:52 +0000
parents bd9e76e0b55d
children 998f1a7dcfde
comparison
equal deleted inserted replaced
2860:2f874d14ac68 2861:b0132e1b9719
6 from km import KM 6 from km import KM
7 from lines import Line 7 from lines import Line
8 from fixpoints import Fixpoint 8 from fixpoints import Fixpoint
9 from buildings import Building 9 from buildings import Building
10 from crosssectiontracks import CrosssectionTrack 10 from crosssectiontracks import CrosssectionTrack
11 from floodplains import Floodplain
12 from boundaries import HydrBoundary, HydrBoundaryPoly
11 13
12 DBCONN='OCI:user/pass@host' 14 DBCONN='OCI:user/pass@host'
13 PATH='/path/to/Gewaesser/Elbe' 15 PATH='/path/to/Gewaesser/Elbe'
14 RIVER_ID=the_river_id 16 RIVER_ID=the_river_id
17 DEST_SRS=31467
15 18
16 19
17 def getImporters(): 20 def getImporters():
18 return [ 21 return [
19 Axis(DBCONN, RIVER_ID), 22 Axis(DBCONN, RIVER_ID, DEST_SRS),
20 KM(DBCONN, RIVER_ID), 23 KM(DBCONN, RIVER_ID, DEST_SRS),
21 CrosssectionTrack(DBCONN, RIVER_ID), 24 CrosssectionTrack(DBCONN, RIVER_ID, DEST_SRS),
22 Line(DBCONN, RIVER_ID), 25 Line(DBCONN, RIVER_ID, DEST_SRS),
23 Fixpoint(DBCONN, RIVER_ID), 26 Fixpoint(DBCONN, RIVER_ID, DEST_SRS),
24 Building(DBCONN, RIVER_ID), 27 Building(DBCONN, RIVER_ID, DEST_SRS),
25 UESG(DBCONN, RIVER_ID)] 28 Floodplain(DBCONN, RIVER_ID, DEST_SRS),
29 HydrBoundary(DBCONN, RIVER_ID, DEST_SRS),
30 HydrBoundaryPoly(DBCONN, RIVER_ID, DEST_SRS),
31 UESG(DBCONN, RIVER_ID, DEST_SRS)
32 ]
26 33
27 34
28 if __name__ == '__main__': 35 if __name__ == '__main__':
29 importers = getImporters() 36 importers = getImporters()
30 37

http://dive4elements.wald.intevation.org