libgnomevfsmm 2.26.0
|
00001 // -*- c++ -*- 00002 // Generated by gtkmmproc -- DO NOT MODIFY! 00003 #ifndef _LIBGNOMEVFSMM_VOLUME_H 00004 #define _LIBGNOMEVFSMM_VOLUME_H 00005 00006 00007 #include <glibmm.h> 00008 00009 /* Copyright 2003 gnome-vfsmm Development Team 00010 * 00011 * This library is free software; you can redistribute it and/or 00012 * modify it under the terms of the GNU Lesser General Public 00013 * License as published by the Free Software Foundation; either 00014 * version 2.1 of the License, or (at your option) any later version. 00015 * 00016 * This library is distributed in the hope that it will be useful, 00017 * but WITHOUT ANY WARRANTY; without even the implied warranty of 00018 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 00019 * Lesser General Public License for more details. 00020 * 00021 * You should have received a copy of the GNU Lesser General Public 00022 * License along with this library; if not, write to the Free 00023 * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. 00024 */ 00025 00026 00027 #include <libgnomevfsmm/enums.h> 00028 00029 #ifndef DOXYGEN_SHOULD_SKIP_THIS 00030 typedef struct _GnomeVFSVolume GnomeVFSVolume; 00031 typedef struct _GnomeVFSVolumeClass GnomeVFSVolumeClass; 00032 #endif /* DOXYGEN_SHOULD_SKIP_THIS */ 00033 00034 00035 namespace Gnome 00036 { 00037 00038 namespace Vfs 00039 { class Volume_Class; } // namespace Vfs 00040 00041 } // namespace Gnome 00042 namespace Gnome 00043 { 00044 00045 namespace Vfs 00046 { 00047 00048 class Drive; 00049 00050 00051 class Volume : public Glib::Object 00052 { 00053 00054 #ifndef DOXYGEN_SHOULD_SKIP_THIS 00055 00056 public: 00057 typedef Volume CppObjectType; 00058 typedef Volume_Class CppClassType; 00059 typedef GnomeVFSVolume BaseObjectType; 00060 typedef GnomeVFSVolumeClass BaseClassType; 00061 00062 private: friend class Volume_Class; 00063 static CppClassType volume_class_; 00064 00065 private: 00066 // noncopyable 00067 Volume(const Volume&); 00068 Volume& operator=(const Volume&); 00069 00070 protected: 00071 explicit Volume(const Glib::ConstructParams& construct_params); 00072 explicit Volume(GnomeVFSVolume* castitem); 00073 00074 #endif /* DOXYGEN_SHOULD_SKIP_THIS */ 00075 00076 public: 00077 virtual ~Volume(); 00078 00079 #ifndef DOXYGEN_SHOULD_SKIP_THIS 00080 static GType get_type() G_GNUC_CONST; 00081 static GType get_base_type() G_GNUC_CONST; 00082 #endif 00083 00085 GnomeVFSVolume* gobj() { return reinterpret_cast<GnomeVFSVolume*>(gobject_); } 00086 00088 const GnomeVFSVolume* gobj() const { return reinterpret_cast<GnomeVFSVolume*>(gobject_); } 00089 00091 GnomeVFSVolume* gobj_copy(); 00092 00093 private: 00094 00095 00096 public: 00097 00101 typedef sigc::slot<void, bool, Glib::ustring, Glib::ustring> OpSlot; 00102 00103 00104 gulong get_id() const; 00105 00106 VolumeType get_volume_type() const; 00107 00108 DeviceType get_device_type() const; 00109 00110 Glib::RefPtr<Drive> get_drive() const; 00111 00112 Glib::ustring get_device_path() const; 00113 00114 Glib::ustring get_activation_uri() const; 00115 00116 Glib::ustring get_filesystem_type() const; 00117 00118 Glib::ustring get_display_name() const; 00119 00120 Glib::ustring get_icon() const; 00121 00122 Glib::ustring get_hal_udi() const; 00123 00124 bool is_user_visible() const; 00125 00126 bool is_read_only() const; 00127 00128 bool is_mounted() const; 00129 00130 bool handles_trash() const; 00131 00132 00133 static int compare(const Glib::RefPtr<const Volume>& a, const Glib::RefPtr<const Volume>& b); 00134 00135 00136 // These are not implemented in gnome-vfs on Win32 00137 #ifndef G_OS_WIN32 00138 void unmount(const OpSlot& slot); 00139 void eject(const OpSlot& slot); 00140 00141 // We can't use the ifdef functionality from WRAP_METHOD because we need 00142 // ifndef. 00143 00144 00145 static void connect_to_server(const Glib::ustring& uri, const Glib::ustring& display_name, const Glib::ustring& icon); 00146 00147 00148 #endif // G_OS_WIN32 00149 00150 00151 public: 00152 00153 public: 00154 //C++ methods used to invoke GTK+ virtual functions: 00155 #ifdef GLIBMM_VFUNCS_ENABLED 00156 #endif //GLIBMM_VFUNCS_ENABLED 00157 00158 protected: 00159 //GTK+ Virtual Functions (override these to change behaviour): 00160 #ifdef GLIBMM_VFUNCS_ENABLED 00161 #endif //GLIBMM_VFUNCS_ENABLED 00162 00163 //Default Signal Handlers:: 00164 #ifdef GLIBMM_DEFAULT_SIGNAL_HANDLERS_ENABLED 00165 #endif //GLIBMM_DEFAULT_SIGNAL_HANDLERS_ENABLED 00166 00167 00168 }; 00169 00170 00171 } // namespace Vfs 00172 } // namespace Gnome 00173 00174 00175 namespace Glib 00176 { 00185 Glib::RefPtr<Gnome::Vfs::Volume> wrap(GnomeVFSVolume* object, bool take_copy = false); 00186 } 00187 00188 00189 #endif /* _LIBGNOMEVFSMM_VOLUME_H */ 00190