00001
00002
00003 #ifndef _LIBGNOMEVFSMM_FILE_INFO_H
00004 #define _LIBGNOMEVFSMM_FILE_INFO_H
00005
00006 #include <glibmm.h>
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024
00025
00026
00027
00028
00029 #include <libgnomevfsmm/enums.h>
00030 #include <libgnomevfsmm/types.h>
00031
00032
00033 namespace Gnome
00034 {
00035
00036 namespace Vfs
00037 {
00038
00039 class FileInfo
00040 {
00041 public:
00042 #ifndef DOXYGEN_SHOULD_SKIP_THIS
00043 typedef FileInfo CppObjectType;
00044 typedef GnomeVFSFileInfo BaseObjectType;
00045 #endif
00046
00047 static Glib::RefPtr<FileInfo> create();
00048
00049
00050 void reference() const;
00051 void unreference() const;
00052
00054 GnomeVFSFileInfo* gobj();
00055
00057 const GnomeVFSFileInfo* gobj() const;
00058
00060 GnomeVFSFileInfo* gobj_copy() const;
00061
00062 protected:
00063
00064 FileInfo();
00065 void operator delete(void*, size_t);
00066
00067 private:
00068
00069 FileInfo(const FileInfo&);
00070 FileInfo& operator=(const FileInfo&);
00071
00072
00073 public:
00074
00075
00078 void clear();
00079
00083 Glib::ustring get_mime_type() const;
00084
00088 Glib::RefPtr<FileInfo> duplicate();
00089
00090
00094 std::string get_name() const;
00095
00096
00097
00098
00102 FileType get_type() const;
00103
00107 FilePermissions get_permissions() const;
00108
00112 FileFlags get_flags() const;
00113
00114
00115
00116
00117
00118
00122 guint get_link_count() const;
00123
00127 guint get_uid() const;
00128
00132 guint get_gid() const;
00133
00138 FileSize get_size() const;
00139
00144 FileSize get_block_count() const;
00145
00150 guint get_io_block_size() const;
00151
00155 time_t get_access_time() const;
00156
00160 time_t get_modification_time() const;
00161
00165 time_t get_creation_time() const;
00166
00170 std::string get_symlink_name() const;
00171
00176 bool is_symlink() const;
00177
00178
00179 };
00180
00181 }
00182 }
00183
00184
00185 namespace Gnome
00186 {
00187
00188 namespace Vfs
00189 {
00190
00196 bool operator==(const FileInfo& lhs, const FileInfo& rhs);
00197
00203 bool operator!=(const FileInfo& lhs, const FileInfo& rhs);
00204
00205
00206 }
00207
00208 }
00209
00210
00211 namespace Glib
00212 {
00213
00219 Glib::RefPtr<Gnome::Vfs::FileInfo> wrap(GnomeVFSFileInfo* object, bool take_copy = false);
00220
00221 }
00222
00223 #endif
00224