/[thuban]/branches/WIP-pyshapelib-bramz/Thuban/Model/postgisdb.py
ViewVC logotype

Diff of /branches/WIP-pyshapelib-bramz/Thuban/Model/postgisdb.py

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1662 by bh, Wed Aug 27 13:51:01 2003 UTC revision 1693 by bh, Mon Sep 1 11:23:26 2003 UTC
# Line 129  class PostGISColumn: Line 129  class PostGISColumn:
129    
130  class PostGISTable:  class PostGISTable:
131    
132      """A Table in a PostGIS database"""      """A Table in a PostGIS database
133    
134        A PostgreSQL table may contain columns with types not (yet)
135        supported by Thuban. Instances of this class ignore those columns
136        and pretend they don't exist, i.e. they won't show up in the column
137        descriptions returned by Columns() and other methods.
138        """
139    
140      def __init__(self, db, tablename):      def __init__(self, db, tablename):
141          """Initialize the PostGISTable.          """Initialize the PostGISTable.
# Line 152  class PostGISTable: Line 158  class PostGISTable:
158          for i in range(len(description)):          for i in range(len(description)):
159              for pgtyp, tabletyp in type_map:              for pgtyp, tabletyp in type_map:
160                  if pgtyp == description[i][1]:                  if pgtyp == description[i][1]:
161                      col = PostGISColumn(description[i][0], tabletyp, i)                      col = PostGISColumn(description[i][0], tabletyp,
162                                            len(self.columns))
163                      break                      break
164              else:              else:
165                  if description[i][1] == self.db.geometry_type:                  if description[i][1] == self.db.geometry_type:

Legend:
Removed from v.1662  
changed lines
  Added in v.1693

[email protected]
ViewVC Help
Powered by ViewVC 1.1.26