moduleinfo.h

Go to the documentation of this file.
00001 // -*- c++ -*-
00002 // Generated by gtkmmproc -- DO NOT MODIFY!
00003 #ifndef _LIBGNOMEMM_MODULEINFO_H
00004 #define _LIBGNOMEMM_MODULEINFO_H
00005 
00006 
00007 #include <glibmm.h>
00008 
00009 /* $Id: moduleinfo.hg,v 1.5 2002/04/01 16:54:24 murrayc Exp $ */
00010 
00011 /* moduleinfo.h
00012  *
00013  * Copyright 2001      Free Software Foundation
00014  *
00015  * This library is free software; you can redistribute it and/or
00016  * modify it under the terms of the GNU Library General Public
00017  * License as published by the Free Software Foundation; either
00018  * version 2 of the License, or (at your option) any later version.
00019  *
00020  * This library is distributed in the hope that it will be useful,
00021  * but WITHOUT ANY WARRANTY; without even the implied warranty of
00022  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
00023  * Library General Public License for more details.
00024  *
00025  * You should have received a copy of the GNU Library General Public
00026  * License along with this library; if not, write to the Free
00027  * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
00028  */
00029 
00030 #include <glibmm/containers.h>
00031 #include <libgnome/gnome-program.h>
00032 
00033 
00034 #ifndef DOXYGEN_SHOULD_SKIP_THIS
00035 extern "C" { typedef struct _GnomeModuleInfo GnomeModuleInfo; }
00036 #endif
00037 
00038 namespace Gnome
00039 {
00040 
00041 #ifndef DOXYGEN_SHOULD_SKIP_THIS
00042 //The C copy and free functions are hidden, but they are registered:
00043 GnomeModuleInfo* gnomemm_module_info_copy(const GnomeModuleInfo* src);
00044 void gnomemm_module_info_free(GnomeModuleInfo* src);
00045 #endif //DOXYGEN_SHOULD_SKIP_THIS
00046 
00047 class ModuleInfo
00048 {
00049   public:
00050 #ifndef DOXYGEN_SHOULD_SKIP_THIS
00051   typedef ModuleInfo CppObjectType;
00052   typedef GnomeModuleInfo BaseObjectType;
00053 
00054   static GType get_type() G_GNUC_CONST;
00055 #endif /* DOXYGEN_SHOULD_SKIP_THIS */
00056 
00057 
00058   explicit ModuleInfo(GnomeModuleInfo* gobject, bool make_a_copy = true);
00059 
00060   ModuleInfo(const ModuleInfo& other);
00061   ModuleInfo& operator=(const ModuleInfo& other);
00062 
00063   ~ModuleInfo();
00064 
00065   void swap(ModuleInfo& other);
00066 
00068   GnomeModuleInfo*       gobj()       { return gobject_; }
00069 
00071   const GnomeModuleInfo* gobj() const { return gobject_; }
00072 
00074   GnomeModuleInfo* gobj_copy() const;
00075 
00076 protected:
00077   GnomeModuleInfo* gobject_;
00078 
00079 private:
00080 
00081 public:
00082 
00083   
00084   ModuleInfo();
00085 
00087   ModuleInfo(const gchar* name, const gchar* version, const gchar* description);
00088 
00089 
00090    Glib::ustring get_name() const;
00091     Glib::ustring get_version() const;
00092     Glib::ustring get_description() const;
00093  
00094   //requirements array must be statically allocated.
00095   //last element has NULL version
00096   void set_requirements(GnomeModuleRequirement* requirements);
00097 
00098   void set_post_args_parse(GnomeModuleHook function);
00099 
00100 //
00101 //   GnomeModuleHook instance_init;
00102 //   GnomeModuleHook pre_args_parse, post_args_parse;
00103 //
00104 //   struct poptOption *options;
00105 //
00106 //   GnomeModuleInitHook init_pass;
00107 //
00108 //   GnomeModuleClassInitHook class_init;
00109 
00110 
00111 };
00112 
00113 } //namespace Gnome
00114 
00115 
00116 namespace Gnome
00117 {
00118 
00123 inline void swap(ModuleInfo& lhs, ModuleInfo& rhs)
00124   { lhs.swap(rhs); }
00125 
00126 } // namespace Gnome
00127 
00128 namespace Glib
00129 {
00130 
00136 Gnome::ModuleInfo wrap(GnomeModuleInfo* object, bool take_copy = false);
00137 
00138 #ifndef DOXYGEN_SHOULD_SKIP_THIS
00139 template <>
00140 class Value<Gnome::ModuleInfo> : public Glib::Value_Boxed<Gnome::ModuleInfo>
00141 {};
00142 #endif /* DOXYGEN_SHOULD_SKIP_THIS */
00143 
00144 } // namespace Glib
00145 
00146 
00147 #endif /* _LIBGNOMEMM_MODULEINFO_H */
00148 

Generated on Mon Aug 7 10:31:50 2006 for libgnomemm by  doxygen 1.4.7