OSGeo FDO Provider for ODBC API Reference

OSGeo FDO Provider for ODBC API

API Reference OSGeo FDO Provider for ODBC

SqlServerOvPhysicalSchemaMapping.h

Go to the documentation of this file.
00001 #ifndef FDO_SqlServerOVPHYSICALSCHEMAMAPPING_H
00002 #define FDO_SqlServerOVPHYSICALSCHEMAMAPPING_H
00003 /*
00004  * Copyright (C) 2004-2008  Autodesk, Inc.
00005  * 
00006  * This library is free software; you can redistribute it and/or
00007  * modify it under the terms of version 2.1 of the GNU Lesser
00008  * General Public License as published by the Free Software Foundation.
00009  * 
00010  * This library is distributed in the hope that it will be useful,
00011  * but WITHOUT ANY WARRANTY; without even the implied warranty of
00012  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
00013  * Lesser General Public License for more details.
00014  * 
00015  * You should have received a copy of the GNU Lesser General Public
00016  * License along with this library; if not, write to the Free Software
00017  * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA  02110-1301  USA
00018  *
00019  */
00020 
00021 #include <Rdbms/Override/RdbmsOvPhysicalSchemaMapping.h>
00022 #include <Rdbms/Override/SQLServerSpatial/SqlServerOv.h>
00023 #include <Rdbms/Override/SQLServerSpatial/SqlServerOvClassCollection.h>
00024 #include <Rdbms/Override/SQLServerSpatial/SqlServerOvTextInRowOption.h>
00025 
00026 /// \brief
00027 /// Concrete class offering schema overrides for
00028 /// the SqlServer Provider.
00029 class FdoSqlServerOvPhysicalSchemaMapping : public FdoRdbmsOvPhysicalSchemaMapping
00030 {
00031 
00032 public:
00033 
00034     /// \brief
00035     /// Constructs a default of an FdoSqlServerOvPhysicalSchemaMapping
00036     /// 
00037     /// \return
00038     /// Returns FdoSqlServerOvPhysicalSchemaMapping
00039     /// 
00040     FDOSQLSERVER_OV_API static FdoSqlServerOvPhysicalSchemaMapping* Create();
00041 
00042     /// \brief
00043     /// Constructs an instance of an FdoSqlServerOvPhysicalSchemaMapping using the specified arguments
00044     /// 
00045     /// \param name 
00046     /// Input name
00047     /// 
00048     /// \return
00049     /// Returns FdoSqlServerOvPhysicalSchemaMapping
00050     /// 
00051     FDOSQLSERVER_OV_API static FdoSqlServerOvPhysicalSchemaMapping* Create(FdoString* name);
00052 
00053     /// \brief
00054     /// Gets the classes
00055     /// 
00056     /// \return
00057     /// Returns the classes
00058     /// 
00059     FDOSQLSERVER_OV_API FdoSqlServerOvClassCollection* GetClasses();
00060 
00061     /// \brief
00062     /// Gets the table Filegroup
00063     /// 
00064     /// \return
00065     /// Returns the table Filegroup
00066     /// 
00067     FDOSQLSERVER_OV_API FdoString *GetTableFilegroup();
00068 
00069     /// \brief
00070     /// Sets the table Filegroup
00071     /// 
00072     /// \return
00073     /// Returns nothing
00074     /// 
00075     FDOSQLSERVER_OV_API void SetTableFilegroup(FdoString *tableFilegroup);
00076 
00077     /// \brief
00078     /// Gets the text Filegroup
00079     /// 
00080     /// \return
00081     /// Returns the text Filegroup
00082     /// 
00083     FDOSQLSERVER_OV_API FdoString *GetTextFilegroup();
00084 
00085     /// \brief
00086     /// Sets the text Filegroup
00087     /// 
00088     /// \return
00089     /// Returns nothing
00090     /// 
00091     FDOSQLSERVER_OV_API void SetTextFilegroup(FdoString *textFilegroup);
00092 
00093     /// \brief
00094     /// Gets the index Filegroup
00095     /// 
00096     /// \return
00097     /// Returns the index Filegroup
00098     /// 
00099     FDOSQLSERVER_OV_API FdoString *GetIndexFilegroup();
00100 
00101     /// \brief
00102     /// Sets the index Filegroup
00103     /// 
00104     /// \return
00105     /// Returns nothing
00106     /// 
00107     FDOSQLSERVER_OV_API void SetIndexFilegroup(FdoString *indexFilegroup);
00108 
00109     /// \brief
00110     /// Gets the text-in-row option
00111     /// 
00112     /// \return
00113     /// Returns the text-in-row option
00114     /// 
00115     FDOSQLSERVER_OV_API SqlServerOvTextInRowOption GetTextInRow();
00116 
00117     /// \brief
00118     /// Sets the text-in-row option
00119     /// 
00120     /// \return
00121     /// Returns nothing
00122     /// 
00123     FDOSQLSERVER_OV_API void SetTextInRow(SqlServerOvTextInRowOption textInRow);
00124 
00125     /// \brief
00126     /// Gets the database
00127     /// 
00128     /// \return
00129     /// Returns the database
00130     /// 
00131     FDOSQLSERVER_OV_API FdoString *GetDatabase();
00132 
00133     /// \brief
00134     /// Sets the database
00135     /// 
00136     /// \return
00137     /// Returns nothing
00138     /// 
00139     FDOSQLSERVER_OV_API void SetDatabase(FdoString *database);
00140 
00141     /// \brief
00142     /// Gets the owner
00143     /// 
00144     /// \return
00145     /// Returns the owner
00146     /// 
00147     FDOSQLSERVER_OV_API FdoString *GetOwner();
00148 
00149     /// \brief
00150     /// Sets the owner
00151     /// 
00152     /// \return
00153     /// Returns nothing
00154     /// 
00155     FDOSQLSERVER_OV_API void SetOwner(FdoString *owner);
00156 
00157     /// \brief
00158     /// Gets the provider name
00159     /// 
00160     /// \return
00161     /// Returns the provider name
00162     /// 
00163     FDOSQLSERVER_OV_API virtual FdoString *GetProvider(void);
00164 
00165 /// \cond DOXYGEN-IGNORE
00166 
00167     /// XML Serialization functions, not part of API.
00168 
00169     /// Serialize this property to XML.
00170     virtual void _writeXmlAttributes(FdoXmlWriter* xmlWriter, const FdoXmlFlags* flags);
00171 
00172     /// Initialize this element from its XML attributes
00173     virtual void InitFromXml(FdoXmlSaxContext* pContext, FdoXmlAttributeCollection* attrs);
00174 
00175 /// \endcond
00176 
00177 protected:
00178     FdoSqlServerOvPhysicalSchemaMapping();
00179     FdoSqlServerOvPhysicalSchemaMapping(FdoString* name);
00180     virtual ~FdoSqlServerOvPhysicalSchemaMapping();
00181     virtual void Dispose();
00182 
00183     /// Create a class override from XML attributes
00184     virtual FdoRdbmsOvClassDefinition* CreateClass( 
00185         FdoXmlSaxContext* context,
00186         FdoXmlAttributeCollection* atts
00187     );
00188 
00189     /// Add the given class override to this schema override set
00190     virtual void AddClass( 
00191         FdoRdbmsOvClassDefinition* pClass
00192     );
00193 
00194     /// Common initializer for all constructors:
00195     void Init();
00196 
00197 private:
00198     FdoSqlServerOvClassesP      mClasses;
00199     FdoStringP                  mTableFilegroup;
00200     FdoStringP                  mTextFilegroup;
00201     FdoStringP                  mIndexFilegroup;
00202     SqlServerOvTextInRowOption  mTextInRow;
00203     FdoStringP                  mDatabase;
00204     FdoStringP                  mOwner;
00205 };
00206 
00207 /// \brief
00208 /// FdoSqlServerOvSchemaMappingP is a FdoPtr on FdoSqlServerOvPhysicalSchemaMapping, provided for convenience.
00209 typedef FdoPtr<FdoSqlServerOvPhysicalSchemaMapping> FdoSqlServerOvSchemaMappingP;
00210 
00211 #endif
00212 
00213 

Comments?