00001 #ifndef __EH_FILE_UTILS_H__
00002 #define __EH_FILE_UTILS_H__
00003
00004 FILE* eh_fopen ( const gchar* file , const gchar *type );
00005 gchar* eh_render_file_error_str ( gint err_no );
00006 FILE* eh_fopen_error ( const gchar* file , const char* type , GError** error );
00007 void eh_set_file_error_from_errno( GError** error , const gchar* file , gint err_no );
00008 FILE* eh_open_file ( const gchar *file , const gchar *type );
00009 FILE* eh_open_temp_file ( const gchar *template , gchar **name_used );
00010 gboolean eh_is_readable_file ( const gchar* file );
00011 gboolean eh_is_writable_file ( const gchar* file );
00012 gboolean eh_try_open ( const gchar* file );
00013 gboolean eh_open_dir ( const gchar* dir , GError** error );
00014 gboolean try_open ( const gchar* file , int flags);
00015 gboolean eh_touch_file ( const gchar* file , int flags , GError** error );
00016 gboolean try_dir ( const gchar* file , GError **error );
00017
00018 typedef struct
00019 {
00020 char *prefix;
00021 char *suffix;
00022 char *format;
00023 int count;
00024 }
00025 Eh_file_list;
00026
00027 Eh_file_list* eh_create_file_list ( char *base_name );
00028 gchar* eh_get_next_file ( Eh_file_list *list );
00029 void eh_destroy_file_list( Eh_file_list *list );
00030
00031
00032
00033 #endif