changeset.h

Go to the documentation of this file.
00001 // -*- c++ -*-
00002 // Generated by gtkmmproc -- DO NOT MODIFY!
00003 #ifndef _GCONFMM_CHANGESET_H
00004 #define _GCONFMM_CHANGESET_H
00005 
00006 
00007 #include <glibmm.h>
00008 
00009 // -*- Mode: C++; c-basic-offset: 4  -*-
00010 /* $Id: changeset.hg,v 1.3 2004/02/13 17:26:18 murrayc Exp $ */
00011 
00012 /* changeset.hg 
00013  * 
00014  * Copyright (C) 2002 GConfmm 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 #include <glibmm/ustring.h>
00032 #include <gconfmm/value.h>
00033 #include <gconfmm/setinterface.h>
00034 #include <sigc++/slot.h>
00035 
00036 
00037 extern "C" {
00038     typedef struct _GConfChangeSet GConfChangeSet;
00039 }
00040 
00041 namespace Gnome
00042 {
00043 namespace Conf
00044 {
00045 
00046 
00057 class ChangeSet : public SetInterface
00058 {
00059     public:
00060 #ifndef DOXYGEN_SHOULD_SKIP_THIS
00061   typedef ChangeSet CppObjectType;
00062   typedef GConfChangeSet BaseObjectType;
00063 #endif /* DOXYGEN_SHOULD_SKIP_THIS */
00064 
00065 private:
00066 
00067     
00068 public:
00069     ChangeSet();
00070     explicit ChangeSet(GConfChangeSet* castitem, bool make_a_copy = false);
00071 
00072     ChangeSet(const ChangeSet& src);
00073     ChangeSet& operator=(const ChangeSet& src);
00074     virtual ~ChangeSet();
00075 
00076     GConfChangeSet*       gobj()       { return gobject_; }
00077     const GConfChangeSet* gobj() const { return gobject_; }
00078     GConfChangeSet* gobj_copy() const;
00079 
00080 protected:
00081     GConfChangeSet* gobject_;
00082 
00083 public:
00087   void clear();
00088 
00091   unsigned int size() const;
00092 
00096   void remove(const Glib::ustring& key);
00097 
00101     Value* exists(const Glib::ustring& key) const;
00102     
00103 
00107   void unset(const Glib::ustring& key);
00108 
00109     
00110   void set(const Glib::ustring& key, bool what);
00111     
00112   void set(const Glib::ustring& key, int what);
00113     
00114   void set(const Glib::ustring& key, double what);
00115     
00116   void set(const Glib::ustring& key, const Glib::ustring& what);
00117     
00118   void set(const Glib::ustring& key, const Schema& val);
00119 
00120     
00121   void set(const Glib::ustring& key, const Value& what);
00122     
00123     
00124     typedef sigc::slot<void, const Glib::ustring&, const Value&> ForeachSlot;
00129     void for_each(const ForeachSlot& slot);
00130     
00131 private:
00132     static GConfChangeSet* do_ref(GConfChangeSet*);
00133 
00134 
00135 };
00136 
00137 
00138 } // namespace Conf
00139 } // namespace Gnome
00140 
00141 
00142 #endif /* _GCONFMM_CHANGESET_H */
00143 

Generated on Fri Mar 17 08:30:21 2006 for gconfmm by  doxygen 1.4.6