Tizen Native API
5.0
|
This function helps when manipulating a file asynchronously.
These set of functions work on top of Eina_File and Ecore_Thread to do basic operations on a file, like opening, closing and mapping a file to memory.
Functions | |
Eio_File * | eio_file_open (const char *name, Eina_Bool shared, Eio_Open_Cb open_cb, Eio_Error_Cb error_cb, const void *data) |
Asynchronously open a file. | |
Eio_File * | eio_file_close (Eina_File *f, Eio_Done_Cb done_cb, Eio_Error_Cb error_cb, const void *data) |
Asynchronously close a file. | |
Eio_File * | eio_file_map_all (Eina_File *f, Eina_File_Populate rule, Eio_Filter_Map_Cb filter_cb, Eio_Map_Cb map_cb, Eio_Error_Cb error_cb, const void *data) |
Asynchronously map a file in memory. | |
Eio_File * | eio_file_map_new (Eina_File *f, Eina_File_Populate rule, unsigned long int offset, unsigned long int length, Eio_Filter_Map_Cb filter_cb, Eio_Map_Cb map_cb, Eio_Error_Cb error_cb, const void *data) |
Asynchronously map a part of a file in memory. |
Function Documentation
Eio_File* eio_file_close | ( | Eina_File * | f, |
Eio_Done_Cb | done_cb, | ||
Eio_Error_Cb | error_cb, | ||
const void * | data | ||
) |
Asynchronously close a file.
- Parameters:
-
f The file to close. done_cb Callback called in the main loop when the file has been successfully closed. error_cb Callback called in the main loop when the file couldn't be closed. data Unmodified user data passed to callbacks
- Returns:
- Pointer to the file if successful or NULL otherwise.
- Since :
- 3.0
Eio_File* eio_file_map_all | ( | Eina_File * | f, |
Eina_File_Populate | rule, | ||
Eio_Filter_Map_Cb | filter_cb, | ||
Eio_Map_Cb | map_cb, | ||
Eio_Error_Cb | error_cb, | ||
const void * | data | ||
) |
Asynchronously map a file in memory.
- Parameters:
-
f The file to map. rule The rule to apply to the map. filter_cb Callback called in the thread to validate the content of the map. map_cb Callback called in the main loop when the file has been successfully mapped. error_cb Callback called in the main loop when the file can't be mapped. data Unmodified user data passed to callbacks
- Returns:
- Pointer to the file if successful or NULL otherwise.
The container of the Eio_File is the Eina_File.
- Since :
- 3.0
Eio_File* eio_file_map_new | ( | Eina_File * | f, |
Eina_File_Populate | rule, | ||
unsigned long int | offset, | ||
unsigned long int | length, | ||
Eio_Filter_Map_Cb | filter_cb, | ||
Eio_Map_Cb | map_cb, | ||
Eio_Error_Cb | error_cb, | ||
const void * | data | ||
) |
Asynchronously map a part of a file in memory.
- Parameters:
-
f The file to map. rule The rule to apply to the map. offset The offset inside the file length The length of the memory to map filter_cb Callback called in the thread to validate the content of the map. map_cb Callback called in the main loop when the file has been successfully mapped. error_cb Callback called in the main loop when the file can't be mapped. data Unmodified user data passed to callbacks
- Returns:
- Pointer to the file if successful or NULL otherwise.
The container of the Eio_File is the Eina_File.
- Since :
- 3.0
Eio_File* eio_file_open | ( | const char * | name, |
Eina_Bool | shared, | ||
Eio_Open_Cb | open_cb, | ||
Eio_Error_Cb | error_cb, | ||
const void * | data | ||
) |
Asynchronously open a file.
- Parameters:
-
name The file to open. shared If it's a shared memory file. open_cb Callback called in the main loop when the file has been successfully opened. error_cb Callback called in the main loop when the file couldn't be opened. data Unmodified user data passed to callbacks
- Returns:
- Pointer to the file if successful or NULL otherwise.
- Since :
- 3.0