| Top |
| #define | GNOME_VFS_FILE_INFO_SYMLINK() |
| #define | GNOME_VFS_FILE_INFO_SET_SYMLINK() |
| #define | GNOME_VFS_FILE_INFO_LOCAL() |
| #define | GNOME_VFS_FILE_INFO_SET_LOCAL() |
| #define | GNOME_VFS_FILE_INFO_SUID() |
| #define | GNOME_VFS_FILE_INFO_SGID() |
| #define | GNOME_VFS_FILE_INFO_STICKY() |
| #define | GNOME_VFS_FILE_INFO_SET_SUID() |
| #define | GNOME_VFS_FILE_INFO_SET_SGID() |
| #define | GNOME_VFS_FILE_INFO_SET_STICKY() |
| GnomeVFSFileInfo * | gnome_vfs_file_info_new () |
| void | gnome_vfs_file_info_unref () |
| void | gnome_vfs_file_info_ref () |
| void | gnome_vfs_file_info_clear () |
| const char * | gnome_vfs_file_info_get_mime_type () |
| void | gnome_vfs_file_info_copy () |
| GnomeVFSFileInfo * | gnome_vfs_file_info_dup () |
| gboolean | gnome_vfs_file_info_matches () |
| GList * | gnome_vfs_file_info_list_ref () |
| GList * | gnome_vfs_file_info_list_unref () |
| GList * | gnome_vfs_file_info_list_copy () |
| void | gnome_vfs_file_info_list_free () |
| GnomeVFSGetFileInfoResult * | gnome_vfs_get_file_info_result_dup () |
| void | gnome_vfs_get_file_info_result_free () |
| enum | GnomeVFSFileFlags |
| enum | GnomeVFSFileType |
| enum | GnomeVFSFileInfoFields |
| enum | GnomeVFSFilePermissions |
| enum | GnomeVFSFileInfoOptions |
| enum | GnomeVFSSetFileInfoMask |
| GnomeVFSGetFileInfoResult | |
| typedef | GnomeVFSInodeNumber |
| GnomeVFSFileInfo |
#define GNOME_VFS_FILE_INFO_SYMLINK(info)
Determines whether a file is a symbolic link given info
.
#define GNOME_VFS_FILE_INFO_SET_SYMLINK(info, value)
Set the symbolic link field in info
to value
.
info |
GnomeVFSFileInfo struct |
|
value |
if |
#define GNOME_VFS_FILE_INFO_LOCAL(info)
Determines whether a file is local given info
.
#define GNOME_VFS_FILE_INFO_SET_LOCAL(info, value)
Set the "local file" field in info
to value
.
#define GNOME_VFS_FILE_INFO_SUID(info)
Determines whether a file belongs to the super user.
#define GNOME_VFS_FILE_INFO_SGID(info)
Determines whether a file belongs to the super user's group.
#define GNOME_VFS_FILE_INFO_STICKY(info)
Determines whether a file has the sticky bit set, given info
#define GNOME_VFS_FILE_INFO_SET_SUID(info, value)
Set the SUID field in info
to value
.
info |
GnomeVFSFileInfo struct |
|
value |
if |
#define GNOME_VFS_FILE_INFO_SET_SGID(info, value)
Set the SGID field in info
to value
.
info |
GnomeVFSFileInfo struct |
|
value |
if |
#define GNOME_VFS_FILE_INFO_SET_STICKY(info, value)
Set the sticky bit in info
to value
.
info |
GnomeVFSFileInfo struct |
|
value |
if |
GnomeVFSFileInfo *
gnome_vfs_file_info_new (void);
Allocate and initialize a new GnomeVFSFileInfo struct.
void
gnome_vfs_file_info_unref (GnomeVFSFileInfo *info);
Decreases the refcount of info
by 1. Frees the struct info
if refcount becomes 0.
void
gnome_vfs_file_info_ref (GnomeVFSFileInfo *info);
Increment refcount of info
by 1.
void
gnome_vfs_file_info_clear (GnomeVFSFileInfo *info);
Clear info
so that it's ready to accept new data. This is
supposed to be used when info
already contains meaningful information which
we want to replace.
const char *
gnome_vfs_file_info_get_mime_type (GnomeVFSFileInfo *info);
Retrieve MIME type from info
. There is no need to free the return
value.
void gnome_vfs_file_info_copy (GnomeVFSFileInfo *dest,const GnomeVFSFileInfo *src);
Copy information from src
into dest
.
GnomeVFSFileInfo *
gnome_vfs_file_info_dup (const GnomeVFSFileInfo *orig);
Duplicates orig
and returns it.
gboolean gnome_vfs_file_info_matches (const GnomeVFSFileInfo *a,const GnomeVFSFileInfo *b);
Compare the two file info structs, return TRUE if they match exactly
the same file data.
GList *
gnome_vfs_file_info_list_ref (GList *list);
Increments the refcount of the items in list
by one.
GList *
gnome_vfs_file_info_list_unref (GList *list);
Decrements the refcount of the items in list
by one.
Note that the list is *not freed* even if each member of the list
is freed.
GList *
gnome_vfs_file_info_list_copy (GList *list);
Creates a duplicate of list
, and references each member of
that list.
void
gnome_vfs_file_info_list_free (GList *list);
Decrements the refcount of each member of list
by one,
and frees the list itself.
GnomeVFSGetFileInfoResult *
gnome_vfs_get_file_info_result_dup (GnomeVFSGetFileInfoResult *result);
Duplicate result
.
Note: The internal uri and fileinfo objects are not duplicated but their refcount is incremented by 1.
Since: 2.12
void
gnome_vfs_get_file_info_result_free (GnomeVFSGetFileInfoResult *result);
Unrefs the internal uri and fileinfo objects and frees the
memory allocated for result
.
Since: 2.12
Packed boolean bitfield representing special flags a GnomeVFSFileInfo struct can have.
Maps to a stat mode, and identifies the kind of file represented by a
GnomeVFSFileInfo struct, stored in the type field.
|
The file type is unknown (none of the types below matches). |
||
|
The file is a regular file (stat: |
||
|
The file is a directory (stat: |
||
|
The file is a FIFO (stat: |
||
|
The file is a socket (stat: |
||
|
The file is a character device (stat: |
||
|
The file is a block device (stat: |
||
|
The file is a symbolic link (stat: |
Flags indicating what fields in a GnomeVFSFileInfo struct are valid. Name is always assumed valid (how else would you have gotten a FileInfo struct otherwise?)
|
No fields are valid |
||
|
Type field is valid |
||
|
Permissions field is valid |
||
|
Flags field is valid |
||
|
Device field is valid |
||
|
Inode field is valid |
||
|
Link count field is valid |
||
|
Size field is valid |
||
|
Block count field is valid |
||
|
I/O Block Size field is valid |
||
|
Access time field is valid |
||
|
Modification time field is valid |
||
|
Creating time field is valid |
||
|
Symlink name field is valid |
||
|
Mime type field is valid |
||
|
Access bits of the permissions bitfield are valid |
||
|
UID and GID information are valid |
||
|
ACL field is valid |
||
|
SELinux Security context is valid |
File permissions. Some of these fields correspond to traditional UNIX semantics, others provide more abstract concepts.
GNOME_VFS_PERM_ACCESS_* fields.
|
UID bit |
||
|
GID bit |
||
|
Sticky bit. |
||
|
Owner has read permission. |
||
|
Owner has write permission. |
||
|
Owner has execution permission. |
||
|
Owner has all permissions. |
||
|
Group has read permission. |
||
|
Group has write permission. |
||
|
Group has execution permission. |
||
|
Group has all permissions. |
||
|
Others have read permission. |
||
|
Others have write permission. |
||
|
Others have execution permission. |
||
|
Others have all permissions. |
||
|
This file is readable for the current client. |
||
|
This file is writable for the current client. |
||
|
This file is executable for the current client. |
Packed boolean bitfield representing options that can
be passed into a gnome_vfs_get_file_info() call (or other
related calls that return file info) and affect the operation
of get_file_info.
|
default flags |
||
|
detect the MIME type |
||
|
only use fast MIME type detection (extensions) |
||
|
force slow MIME type detection where available (sniffing, algorithmic detection, etc) |
||
|
automatically follow symbolic links and retrieve the properties of their target (recommended) |
||
|
tries to get data similar to what would return access(2) on a local file system (ie is the file readable, writable and/or executable). Can be really slow on remote file systems |
||
|
When reading a directory, only get the filename (if doing so is faster). Useful to e.g. count the number of files. |
||
|
get ACLs for the file |
||
Packed boolean bitfield representing the aspects of the file
to be changed in a gnome_vfs_set_file_info() call.
typedef struct {
GnomeVFSURI *uri;
GnomeVFSResult result;
GnomeVFSFileInfo *file_info;
} GnomeVFSGetFileInfoResult;
This data structure encapsulates the details of an individual file
info request that was part of a mass file info request launched
through gnome_vfs_async_get_file_info(), and is passed to a
GnomeVFSAsyncGetFileInfoCallback.