- Main Page
- Classes
- Files
- Directories
- Related Pages

- File List
- File Members

# sfcschemarowsets.h

    00001 /******************************************************************************
    00002  * $Id: sfcschemarowsets.h,v 1.4 2006/03/31 17:57:32 fwarmerdam Exp $
    00003  *
    00004  * Project:  OpenGIS Simple Features Reference Implementation
    00005  * Purpose:  Definitions for OGIS specific, and generic OLE DB schema rowsets.
    00006  *           Generally application code shouldn't need to include this file
    00007  *           directly or indirectly.  It exists mostly to support the other
    00008  *           SFC class implementations.
    00009  * Author:   Frank Warmerdam, warmerdam@pobox.com
    00010  *
    00011  ******************************************************************************
    00012  * Copyright (c) 1999, Les Technologies SoftMap Inc.
    00013  *
    00014  * Permission is hereby granted, free of charge, to any person obtaining a
    00015  * copy of this software and associated documentation files (the "Software"),
    00016  * to deal in the Software without restriction, including without limitation
    00017  * the rights to use, copy, modify, merge, publish, distribute, sublicense,
    00018  * and/or sell copies of the Software, and to permit persons to whom the
    00019  * Software is furnished to do so, subject to the following conditions:
    00020  *
    00021  * The above copyright notice and this permission notice shall be included
    00022  * in all copies or substantial portions of the Software.
    00023  *
    00024  * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
    00025  * OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
    00026  * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
    00027  * THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
    00028  * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
    00029  * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
    00030  * DEALINGS IN THE SOFTWARE.
    00031  ******************************************************************************
    00032  *
    00033  * $Log: sfcschemarowsets.h,v $
    00034  * Revision 1.4  2006/03/31 17:57:32  fwarmerdam
    00035  * header updates
    00036  *
    00037  * Revision 1.3  2001/11/01 17:06:31  warmerda
    00038  * convert use of CRestrictions to deriving from CSchemaRowset
    00039  *
    00040  * Revision 1.2  1999/11/18 19:02:20  warmerda
    00041  * expanded tabs
    00042  *
    00043  * Revision 1.1  1999/06/10 19:34:33  warmerda
    00044  * New
    00045  *
    00046  */
    00047
    00048 #ifndef SFCSCHEMAROWSETS_H_INCLUDED
    00049 #define SFCSCHEMAROWSETS_H_INCLUDED
    00050
    00051 #include <atldbsch.h>
    00052
    00053 #include "oledbgis.h"
    00054
    00055 /************************************************************************/
    00056 /*                        COGISFeatureTableInfo                         */
    00057 /*                                                                      */
    00058 /*      Hardbound record for the OGIS Feature Tables schema rowset.     */
    00059 /*      Modelled on CTableInfo.                                         */
    00060 /************************************************************************/
    00061 class COGISFeatureTableInfo
    00062 {
    00063 public:
    00064 // Constructors
    00065         COGISFeatureTableInfo()
    00066         {
    00067                 memset(this, 0, sizeof(*this));
    00068         }
    00069
    00070 // Attributes
    00071
    00072         TCHAR   m_szFeatureTableAlias[129];
    00073         TCHAR   m_szCatalog[129];
    00074         TCHAR   m_szSchema[129];
    00075         TCHAR   m_szName[129];
    00076         TCHAR   m_szIdColumnName[129];
    00077         TCHAR   m_szDGColumnName[129];
    00078
    00079
    00080 // Binding Map
    00081 BEGIN_COLUMN_MAP(COGISFeatureTableInfo)
    00082         COLUMN_ENTRY(1, m_szFeatureTableAlias)
    00083         COLUMN_ENTRY(2, m_szCatalog)
    00084         COLUMN_ENTRY(3, m_szSchema)
    00085         COLUMN_ENTRY(4, m_szName)
    00086         COLUMN_ENTRY(5, m_szIdColumnName)
    00087         COLUMN_ENTRY(6, m_szDGColumnName)
    00088 END_COLUMN_MAP()
    00089 };
    00090
    00091 class COGISFeatureTables:
    00092       public CSchemaRowset<CAccessor<COGISFeatureTableInfo>,0>
    00093
    00094 {
    00095   public:
    00096     HRESULT Open(const CSession& session, bool bBind = true )
    00097     {
    00098         USES_CONVERSION;
    00099         return CSchemaRowset<CAccessor<COGISFeatureTableInfo>,0>::
    00100             Open(session, DBSCHEMA_OGIS_FEATURE_TABLES /*, bBind */);
    00101     }
    00102 };
    00103
    00104 /************************************************************************/
    00105 /*                       COGISGeometryColumnInfo                        */
    00106 /*                                                                      */
    00107 /*      Hardbound record for the OGIS column info schema rowset.        */
    00108 /*      Modelled on CTableInfo.                                         */
    00109 /************************************************************************/
    00110
    00111 class COGISGeometryColumnInfo
    00112 {
    00113 public:
    00114 // Constructors
    00115         COGISGeometryColumnInfo()
    00116         {
    00117                 memset(this, 0, sizeof(*this));
    00118         }
    00119
    00120 // Attributes
    00121
    00122         TCHAR   m_szCatalog[129];
    00123         TCHAR   m_szSchema[129];
    00124         TCHAR   m_szName[129];
    00125         TCHAR   m_szColumnName[129];
    00126         ULONG   m_nGeomType;
    00127         ULONG   m_nSRS_ID;
    00128
    00129 // Binding Map
    00130 BEGIN_COLUMN_MAP(COGISGeometryColumnInfo)
    00131         COLUMN_ENTRY(1, m_szCatalog)
    00132         COLUMN_ENTRY(2, m_szSchema)
    00133         COLUMN_ENTRY(3, m_szName)
    00134         COLUMN_ENTRY(4, m_szColumnName)
    00135         COLUMN_ENTRY(5, m_nGeomType)
    00136         COLUMN_ENTRY(6, m_nSRS_ID)
    00137 END_COLUMN_MAP()
    00138 };
    00139
    00140 class COGISGeometryColumnTable:
    00141       public CSchemaRowset<CAccessor<COGISGeometryColumnInfo>,0>
    00142
    00143 {
    00144   public:
    00145     HRESULT Open(const CSession& session, bool bBind = true )
    00146     {
    00147         USES_CONVERSION;
    00148         return CSchemaRowset<CAccessor<COGISGeometryColumnInfo>,0>::
    00149             Open(session, DBSCHEMA_OGIS_GEOMETRY_COLUMNS/*, bBind*/);
    00150     }
    00151 };
    00152
    00153 /************************************************************************/
    00154 /*                      COGISSpatialRefSystemsInfo                      */
    00155 /*                                                                      */
    00156 /*      Hardbound record for the OGIS SRS schema rowset record.         */
    00157 /*      Modelled on CTableInfo.                                         */
    00158 /************************************************************************/
    00159
    00160 class COGISSpatialRefSystemsInfo
    00161 {
    00162 public:
    00163 // Constructors
    00164         COGISSpatialRefSystemsInfo()
    00165         {
    00166                 memset(this, 0, sizeof(*this));
    00167         }
    00168
    00169 // Attributes
    00170
    00171         ULONG   m_nSRS_ID;
    00172         TCHAR   m_szAuthorityName[129];
    00173         ULONG   m_nAuthorityID;
    00174         TCHAR   m_szSpatialRefSystemWKT[2048];
    00175
    00176 // Binding Map
    00177 BEGIN_COLUMN_MAP(COGISSpatialRefSystemsInfo)
    00178         COLUMN_ENTRY(1, m_nSRS_ID)
    00179         COLUMN_ENTRY(2, m_szAuthorityName)
    00180         COLUMN_ENTRY(3, m_nAuthorityID)
    00181         COLUMN_ENTRY(4, m_szSpatialRefSystemWKT)
    00182 END_COLUMN_MAP()
    00183 };
    00184
    00185 class COGISSpatialRefSystemsTable:
    00186       public CSchemaRowset<CAccessor<COGISSpatialRefSystemsInfo>,0>
    00187
    00188 {
    00189   public:
    00190     HRESULT Open(const CSession& session, bool bBind = true )
    00191     {
    00192         USES_CONVERSION;
    00193         return CSchemaRowset<CAccessor<COGISSpatialRefSystemsInfo>,0>::
    00194             Open(session, DBSCHEMA_OGIS_SPATIAL_REF_SYSTEMS /*, bBind */);
    00195     }
    00196 };
    00197
    00198 #endif /* ndef SFCSCHEMAROWSETS_H_INCLUDED */

Generated for GDAL by 1.4.5.