Shadowrun: Awakened 29 September 2011 - Build 871
resultset_metadata.h
Go to the documentation of this file.
00001 /*
00002    Copyright 2007 - 2008 MySQL AB, 2008 - 2009 Sun Microsystems, Inc.  All rights reserved.
00003 
00004    The MySQL Connector/C++ is licensed under the terms of the GPL
00005    <http://www.gnu.org/licenses/old-licenses/gpl-2.0.html>, like most
00006    MySQL Connectors. There are special exceptions to the terms and
00007    conditions of the GPL as it is applied to this software, see the
00008    FLOSS License Exception
00009    <http://www.mysql.com/about/legal/licensing/foss-exception.html>.
00010 */
00011 
00012 #ifndef _SQL_RESULTSET_METADATA_H_
00013 #define _SQL_RESULTSET_METADATA_H_
00014 
00015 #include <string>
00016 #include "datatype.h"
00017 
00018 namespace sql
00019 {
00020 
00021 class ResultSetMetaData
00022 {
00023 public:
00024     enum
00025     {
00026         columnNoNulls,
00027         columnNullable,
00028         columnNullableUnknown
00029     };
00030 
00031     virtual std::string getCatalogName(unsigned int column) = 0;
00032 
00033     virtual unsigned int getColumnCount() = 0;
00034 
00035     virtual unsigned int getColumnDisplaySize(unsigned int column) = 0;
00036 
00037     virtual std::string getColumnLabel(unsigned int column) = 0;
00038 
00039     virtual std::string getColumnName(unsigned int column) = 0;
00040 
00041     virtual int getColumnType(unsigned int column) = 0;
00042 
00043     virtual std::string getColumnTypeName(unsigned int column) = 0;
00044 
00045     virtual unsigned int getPrecision(unsigned int column) = 0;
00046 
00047     virtual unsigned int getScale(unsigned int column) = 0;
00048 
00049     virtual std::string getSchemaName(unsigned int column) = 0;
00050 
00051     virtual std::string getTableName(unsigned int column) = 0;
00052 
00053     virtual bool isAutoIncrement(unsigned int column) = 0;
00054 
00055     virtual bool isCaseSensitive(unsigned int column) = 0;
00056 
00057     virtual bool isCurrency(unsigned int column) = 0;
00058 
00059     virtual bool isDefinitelyWritable(unsigned int column) = 0;
00060 
00061     virtual int isNullable(unsigned int column) = 0;
00062 
00063     virtual bool isReadOnly(unsigned int column) = 0;
00064 
00065     virtual bool isSearchable(unsigned int column) = 0;
00066 
00067     virtual bool isSigned(unsigned int column) = 0;
00068 
00069     virtual bool isWritable(unsigned int column) = 0;
00070 
00071     virtual bool isZerofill(unsigned int column) = 0;
00072 
00073 protected:
00074     virtual ~ResultSetMetaData() {}
00075 };
00076 
00077 
00078 } /* namespace sql */
00079 
00080 #endif /* _SQL_RESULTSET_METADATA_H_ */

Copyright © 2007-2010 by The Shadowrun: Awakened Team. This work is licensed under the GNU Lesser General Public License 3.

GNU Lesser General Public License 3 Sourceforge.net