/[thuban]
ViewVC logotype

Revision 2106


Jump to revision: Previous Next
Author: bh
Date: Fri Mar 12 12:59:33 2004 UTC (20 years, 11 months ago)
Changed paths: 3
Log Message:
Support views in addition to normal tables in the postgis shapestore

* Thuban/Model/postgisdb.py
(PostGISShapeStore._fetch_table_information): Add a fallback for
the case where the table name is not in the geometry_columns
table.  This is usually the case for views.  Also, set
self.shapestore here.
(PostGISShapeStore.ShapeType): No need to query the database all
the time.  The shape type is now determined in
_fetch_table_information

* test/postgissupport.py (PostgreSQLServer.new_postgis_db)
(PostgreSQLServer.get_static_data_db, PostGISDatabase.__init__):
New parameter to specify views.
(PostGISDatabase.has_data): Also compare the views.  New views
parameter
(PostGISDatabase.initdb): Create the views.
(PostgreSQLServer.get_default_static_data_db): Add the v_landmarks
view

* test/test_postgis_db.py
(TestPostGISShapestorePointFromViews): New.  Test a
PostGISShapeStore with a view
(TestPostGISShapestorePointOIDAsGIDColumn.setUp): Pass the name of
the geometry_column explicitly to test whether that works


Changed paths

Path Details
Directorytrunk/thuban/Thuban/Model/postgisdb.py modified , text changed
Directorytrunk/thuban/test/postgissupport.py modified , text changed
Directorytrunk/thuban/test/test_postgis_db.py modified , text changed

[email protected]
ViewVC Help
Powered by ViewVC 1.1.26