comparison flys-backend/contrib/shpimporter/floodplains.py @ 3654:59ca5dab2782

Shape importer: use python's OptionParse to read user specific configuration from command line. flys-backend/trunk@5231 c6561f87-3c4e-4783-a992-168aeb5c3f6f
author Ingo Weinzierl <ingo.weinzierl@intevation.de>
date Wed, 22 Aug 2012 11:55:55 +0000
parents b0132e1b9719
children f1c01fecf194
comparison
equal deleted inserted replaced
3653:20d249e1589f 3654:59ca5dab2782
2 2
3 from importer import Importer 3 from importer import Importer
4 4
5 TABLE_NAME="floodplain" 5 TABLE_NAME="floodplain"
6 PATH="Hydrologie/Hydr.Grenzen" 6 PATH="Hydrologie/Hydr.Grenzen"
7 NAME="Floodplains"
7 8
8 9
9 class Floodplain(Importer): 10 class Floodplain(Importer):
10 11
11 def getPath(self, base): 12 def getPath(self, base):
12 return "%s/%s" % (base, PATH) 13 return "%s/%s" % (base, PATH)
13 14
14 15
15 def getTablename(self): 16 def getTablename(self):
16 return TABLE_NAME 17 return TABLE_NAME
18
19
20 def getName(self):
21 return NAME
17 22
18 23
19 def isGeometryValid(self, geomType): 24 def isGeometryValid(self, geomType):
20 return geomType == 3 or geomType == 6 25 return geomType == 3 or geomType == 6
21 26

http://dive4elements.wald.intevation.org