/ gwvirtualfilesystemstats.h / Functions / Description

Functions



vfs_stats_new

Creates a new virtual file system stats.
struct vfs_stats * vfs_stats_new ( void);
This function creates a new virtual file system stats. It's an allocation function.

Result: a pointer to the virtual file system stats structure.
Returns NULL when an error occured.
.


vfs_stats_display

Dipslays all informations of the virtual file system stats.
void vfs_stats_display ( struct vfs_stats *p);
This function displays all informations of the virtual file system stats in the console.

Parameters
p the virtual file system to load


vfs_stats_set_name

Sets the virtual file system stats name.
gint vfs_stats_set_name ( struct vfs_stats *p, gchar *name);
This function sets the virtual file system stats name.


Parameters
p the virtual file system stats to set name
name the name

Result: an error code.
Returns 0 when it's done.
Returns -1 when an error occured.
.


vfs_stats_set_dir

Sets the virtual file system stats path.
gint vfs_stats_set_dir ( struct vfs_stats *p, gchar *dir);
This function sets the virtual file system stats path.


Parameters
p the virtual file system stats to set path
dir the fiel system path

Result: an error code.
Returns 0 when it's done.
Returns -1 when an error occured.
.


vfs_stats_set_label

Sets the virtual file system stats label.
gint vfs_stats_set_label ( struct vfs_stats *p, gchar *label);
This function sets the virtual file system stats label.


Parameters
p the virtual file system stats to set label
label the file system label

Result: an error code.
Returns 0 when it's done.
Returns -1 when an error occured.
.


vfs_stats_set_type

Sets the virtual file system stats type.
gint vfs_stats_set_type ( struct vfs_stats *p, gchar *type);
This function sets the virtual file system stats type.
Type can be vfat, ext2, iso9660,...

Parameters
p the virtual file system stats to set type
type the file system type

Result: an error code.
Returns 0 when it's done.
Returns -1 when an error occured.
.


vfs_stats_set_options

Sets the virtual file system stats options.
gint vfs_stats_set_options ( struct vfs_stats *p, gchar **options);
This function sets the virtual file system stats options.


Parameters
p the virtual file system stats to set options
options the file system options

Result: an error code.
Returns 0 when it's done.
Returns -1 when an error occured.
.


vfs_stats_set_ismounted

Sets if the virtual file system stats is mounted.
gint vfs_stats_set_ismounted ( struct vfs_stats *p, gboolean mounted);
This function sets if the virtual file system stats is mounted.


Parameters
p the virtual file system stats to set mount status
mounted the mount status

Result: an error code.
Returns 0 when it's done.
Returns -1 when an error occured.
.


vfs_stats_set_nb_files

Sets the total number of files of the virtual file system stats.
gint vfs_stats_set_nb_files ( struct vfs_stats *p, gulong nb_files);
This function sets the total number of files of the virtual file system stats.


Parameters
p the virtual file system stats to set number of files
nb_file the number of files

Result: an error code.
Returns 0 when it's done.
Returns -1 when an error occured.
.


vfs_stats_set_blocks_size

Sets blocks size of the virtual file system stats.
gint vfs_stats_set_blocks_size ( struct vfs_stats *p, glong blocks_size);
This function sets blocks size of the virtual file system stats.


Parameters
p the virtual file system stats to set blocks size
blocks_size the blocks size

Result: an error code.
Returns 0 when it's done.
Returns -1 when an error occured.
.


vfs_stats_set_blocks

Sets total number blocks of the virtual file system stats.
gint vfs_stats_set_blocks ( struct vfs_stats *p, gulong blocks);
This function sets total number blocks of the virtual file system stats.


Parameters
p the virtual file system stats to set total number blocks
blocks the total number blocks

Result: an error code.
Returns 0 when it's done.
Returns -1 when an error occured.
.


vfs_stats_set_blocks_free

Sets free blocks number of the virtual file system stats.
gint vfs_stats_set_blocks_free ( struct vfs_stats *p, gulong blocks_free);
This function sets free blocks number size of the virtual file system stats.


Parameters
p the virtual file system stats to set free blocks number
blocks_free the free blocks number

Result: an error code.
Returns 0 when it's done.
Returns -1 when an error occured.
.


vfs_stats_set_serial_number

Sets the virtual file system stats serial number.
gint vfs_stats_set_serial_number ( struct vfs_stats *p, gchar *serial_number);
This function sets the virtual file system stats serial number.


Parameters
p the virtual file system stats to set serial number
serial_number the file system serial number

Result: an error code.
Returns 0 when it's done.
Returns -1 when an error occured.
.


vfs_stats_get_name

Gets the virtual file system stats name.
gchar * vfs_stats_get_name ( struct vfs_stats *p);
This function gets the virtual file system stats name.


Parameters
p the virtual file system stats to get name

Result: The name.
Returns NULL when an error occured.
.


vfs_stats_get_dir

Gets the virtual file system stats path.
gchar * vfs_stats_get_dir ( struct vfs_stats *p);
This function gets the virtual file system stats path.


Parameters
p the virtual file system stats to get path

Result: The path.
Returns NULL when an error occured.
.


vfs_stats_get_label

Gets the virtual file system stats label.
gchar * vfs_stats_get_label ( struct vfs_stats *p);
This function gets the virtual file system stats label.


Parameters
p the virtual file system stats to get label

Result: The label.
Returns NULL when an error occured.
.


vfs_stats_get_type

Gets the virtual file system stats type.
gchar * vfs_stats_get_type ( struct vfs_stats *p);
This function gets the virtual file system stats type.


Parameters
p the virtual file system stats to get type

Result: The file system type.
Returns NULL when file system type is unknown or when an error occured.
.


vfs_stats_get_serial_number

Gets the virtual file system stats serial number.
gchar * vfs_stats_get_serial_number ( struct vfs_stats *p);
This function gets the virtual file system stats serial number.


Parameters
p the virtual file system stats to get serial number

Result: The device serial number.
Returns NULL when an error occured.
.


vfs_stats_get_options

Gets the virtual file system stats options.
gchar ** vfs_stats_get_options ( struct vfs_stats *p);
This function gets the virtual file system stats options.


Parameters
p the virtual file system stats to get options

Result: The mount options Returns NULL when an error occured.
.


vfs_stats_get_ismounted

Gets if is mounted.
gboolean vfs_stats_get_ismounted ( struct vfs_stats *p);
This function gets if the virtual file system stats is mounted.


Parameters
p the virtual file system stats to get if is mounted

Result: TRUE if is mounted or FALSE if is not mounted.
Returns FALSE when an error occured.
.


vfs_stats_get_nb_files

Gets the total number of files of the virtual file system stats.
gulong vfs_stats_get_nb_files ( struct vfs_stats *p);
This function gets the total number of files of the virtual file system stats.


Parameters
p the virtual file system stats to get number of files

Result: The number of files Returns 0 when an error occured.
.


vfs_stats_get_blocks_size

Gets blocks size of the virtual file system stats.
glong vfs_stats_get_blocks_size ( struct vfs_stats *p);
This function gets blocks size of the virtual file system stats.


Parameters
p the virtual file system stats to get blocks size

Result: The blocks size Returns 0 when an error occured.
.


vfs_stats_get_blocks

Gets total number blocks of the virtual file system stats.
gulong vfs_stats_get_blocks ( struct vfs_stats *p);
This function gets total number blocks of the virtual file system stats.


Parameters
p the virtual file system stats to get total number blocks

Result: Total number blocks Returns 0 when an error occured.
.


vfs_stats_get_blocks_free

Gets free blocks number of the virtual file system stats.
gulong vfs_stats_get_blocks_free ( struct vfs_stats *p);
This function gets free blocks number of the virtual file system stats.


Parameters
p the virtual file system stats to get free blocks number

Result: Free number blocks Returns 0 when an error occured.
.


vfs_stats_get_total_capacity

Gets total capacity of the virtual file system stats.
guint64 vfs_stats_get_total_capacity ( struct vfs_stats *p);
This function gets the total capacity of the virtual file system stats.


Parameters
p the virtual file system stats to get total capacity

Result: Total capacity Returns -1 when an error occured.
.


vfs_stats_get_total_free_space

Gets free space of the virtual file system stats.
guint64 vfs_stats_get_total_free_space ( struct vfs_stats *p);
This function gets the free space of the virtual file system stats.


Parameters
p the virtual file system stats to get free space

Result: Free space Returns -1 when an error occured.
.


vfs_stats_get_total_used_space

Gets total used space of the virtual file system stats.
guint64 vfs_stats_get_total_used_space ( struct vfs_stats *p);
This function gets the total used space of the virtual file system stats.


Parameters
p the virtual file system stats to get total used space

Result: Total used space Returns -1 when an error occured.
.


vfs_stats_free

Frees datas structure.
gboolean vfs_stats_free ( struct vfs_stats *p);
This function frees the virtual file system stats datas structure.


Parameters
p the virtual file system stats to free

Result: an error code.
Returns 0 when it's done.
Returns -1 when an error occured.
.