row.h

Go to the documentation of this file.
00001 // -*- c++ -*-
00002 // Generated by gtkmmproc -- DO NOT MODIFY!
00003 #ifndef _LIBGDAMM_ROW_H
00004 #define _LIBGDAMM_ROW_H
00005 
00006 
00007 #include <glibmm.h>
00008 
00009 /* $Id: row.hg,v 1.10 2006/11/06 04:38:05 murrayc Exp $ */
00010 // -*- C++ -*- // this is for the .hg, I realize gensig puts one in
00011 
00012 /* row.h
00013  *
00014  * Copyright 2003 libgdamm Development Team
00015  *
00016  * This library is free software; you can redistribute it and/or
00017  * modify it under the terms of the GNU Library General Public
00018  * License as published by the Free Software Foundation; either
00019  * version 2 of the License, or (at your option) any later version.
00020  *
00021  * This library is distributed in the hope that it will be useful,
00022  * but WITHOUT ANY WARRANTY; without even the implied warranty of
00023  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
00024  * Library General Public License for more details.
00025  *
00026  * You should have received a copy of the GNU Library General Public
00027  * License along with this library; if not, write to the Free
00028  * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
00029  */
00030 
00031 
00032 #include <libgdamm/value.h>
00033 #include <glibmm/object.h>
00034 
00035 
00036 #ifndef DOXYGEN_SHOULD_SKIP_THIS
00037 typedef struct _GdaRow GdaRow;
00038 typedef struct _GdaRowClass GdaRowClass;
00039 #endif /* DOXYGEN_SHOULD_SKIP_THIS */
00040 
00041 
00042 namespace Gnome
00043 {
00044 
00045 namespace Gda
00046 { class Row_Class; } // namespace Gda
00047 
00048 } // namespace Gnome
00049 namespace Gnome
00050 {
00051 
00052 namespace Gda
00053 {
00054 
00055 class DataModel;
00056 class Value;
00057 
00058 //TODO:
00059 
00060 class Row : public Glib::Object
00061 {
00062 protected:
00063   
00064 #ifndef DOXYGEN_SHOULD_SKIP_THIS
00065 
00066 public:
00067   typedef Row CppObjectType;
00068   typedef Row_Class CppClassType;
00069   typedef GdaRow BaseObjectType;
00070   typedef GdaRowClass BaseClassType;
00071 
00072 private:  friend class Row_Class;
00073   static CppClassType row_class_;
00074 
00075 private:
00076   // noncopyable
00077   Row(const Row&);
00078   Row& operator=(const Row&);
00079 
00080 protected:
00081   explicit Row(const Glib::ConstructParams& construct_params);
00082   explicit Row(GdaRow* castitem);
00083 
00084 #endif /* DOXYGEN_SHOULD_SKIP_THIS */
00085 
00086 public:
00087   virtual ~Row();
00088 
00089 #ifndef DOXYGEN_SHOULD_SKIP_THIS
00090   static GType get_type()      G_GNUC_CONST;
00091   static GType get_base_type() G_GNUC_CONST;
00092 #endif
00093 
00095   GdaRow*       gobj()       { return reinterpret_cast<GdaRow*>(gobject_); }
00096 
00098   const GdaRow* gobj() const { return reinterpret_cast<GdaRow*>(gobject_); }
00099 
00101   GdaRow* gobj_copy();
00102 
00103 private:
00104 
00105 
00106   explicit Row(const Glib::RefPtr<DataModel>& model, int count);
00107 
00108 //TODO: Use C++ type:
00109   explicit Row(const Glib::RefPtr<DataModel>& model, const GList *values);
00110 
00111 public:
00112   
00116   Glib::RefPtr<Row> copy() const;
00117   
00118   
00119   static Glib::RefPtr<Row> create(const Glib::RefPtr<DataModel>& model, int count);
00120 
00121   
00122   static Glib::RefPtr<Row> create(const Glib::RefPtr<DataModel>& model, const GList * values);
00123 
00124 
00129   int get_number() const;
00130   
00134   void set_number(int number);
00135   
00139   Glib::ustring get_id() const;
00140   
00145   void set_id(const Glib::ustring& id);
00146 
00147   Value get_value(int num) const;
00148   
00149 
00156   bool set_value(int num, const Value& value);;
00157 
00158   
00162   Glib::RefPtr<DataModel> get_model();  
00163   
00167   Glib::RefPtr<const DataModel> get_model() const; 
00168 
00169   
00175   void set_model(const Glib::RefPtr<DataModel>& model);
00176 
00177   
00181   int get_length() const;
00182 
00183   
00184   void set_is_default(int num, bool is_default = true);
00185   
00189   bool get_is_default(int num) const;
00190 
00191   //TODO: Properties.
00192 
00193 
00194 public:
00195 
00196 public:
00197   //C++ methods used to invoke GTK+ virtual functions:
00198 #ifdef GLIBMM_VFUNCS_ENABLED
00199 #endif //GLIBMM_VFUNCS_ENABLED
00200 
00201 protected:
00202   //GTK+ Virtual Functions (override these to change behaviour):
00203 #ifdef GLIBMM_VFUNCS_ENABLED
00204 #endif //GLIBMM_VFUNCS_ENABLED
00205 
00206   //Default Signal Handlers::
00207 #ifdef GLIBMM_DEFAULT_SIGNAL_HANDLERS_ENABLED
00208 #endif //GLIBMM_DEFAULT_SIGNAL_HANDLERS_ENABLED
00209 
00210 
00211 };
00212 
00213 } // namespace Gda
00214 } // namespace Gnome
00215 
00216 
00217 namespace Glib
00218 {
00224   Glib::RefPtr<Gnome::Gda::Row> wrap(GdaRow* object, bool take_copy = false);
00225 }
00226 
00227 
00228 #endif /* _LIBGDAMM_ROW_H */
00229 

Generated on Sat Feb 10 20:06:26 2007 for libgdamm by  doxygen 1.4.7