disk_data_new
Creates a new disk data.
struct disk_data * disk_data_new ( void);
This function creates a new disk data. It's an allocation function.
Result: a pointer to the disk data structure. Returns NULL when an error occured. .
disk_data_set_info
Sets the disk data's informations.
gint disk_data_set_info ( struct disk_data *p, struct disk_info *info);
This function sets the disk's information. Disk informations is a struct disk_info.
Parameters
p | the disk data to set the informations |
info | the disk informations |
Result: an error code. Returns 0 when it's done. Returns -1 when an error occured. .
disk_data_set_child
Sets the disk data's children.
gint disk_data_set_child ( struct disk_data *p, GList *child);
This function sets the disk's children. The list of children is the list of file and subfolders in the disk.
Parameters
p | the disk data to set the children |
child | the list of children |
Result: an error code. Returns 0 when it's done. Returns -1 when an error occured. .
disk_data_append_child
Appends in the disk data's children a new child.
gint disk_data_append_child ( struct disk_data *p, struct file_info *child);
This function appends in the disk dat's children list a new child.
Parameters
p | the disk data to append a child |
child | the child |
Result: an error code. Returns 0 when it's done. Returns -1 when an error occured. .
disk_data_get_info
Gets disk data's informations.
struct disk_info * disk_data_get_info ( struct disk_data *p);
This function gets the disk data's informations.
Parameters
p | the disk data to get informations |
Result: the disk informations. Returns NULL when an error occured. .
disk_data_get_child
Gets disk data's list of children.
GList * disk_data_get_child ( struct disk_data *p);
This function gets the disk data's list of children. This list is the list of files and subfolders in the disk.
Parameters
p | the disk data to get list of children |
Result: the list of children. Returns NULL when an error occured. .
disk_data_free
Frees datas structure.
gint disk_data_free ( struct disk_data *p);
This function frees the disk data's datas.
Parameters
Result: an error code. Returns 0 when it's done. Returns -1 when an error occured. .
|