eio: make it possible to know if an Eio_File was cancelled.

SVN revision: 60689
This commit is contained in:
Cedric BAIL 2011-06-25 22:49:01 +00:00
parent 3bde9147fb
commit 2217f284f7
1 changed files with 14 additions and 0 deletions

View File

@ -886,6 +886,20 @@ eio_file_cancel(Eio_File *ls)
return ecore_thread_cancel(ls->thread);
}
/**
* @brief Check if an Eio_File operation has been cancelled.
* @param ls The asynchronous IO operation to check.
* @return EINA_TRUE if it was canceled, EINA_FALSE other wise.
*
* In case of an error it also return EINA_TRUE.
*/
EAPI Eina_Bool
eio_file_check(Eio_File *ls)
{
EINA_SAFETY_ON_NULL_RETURN_VAL(ls, EINA_TRUE);
return ecore_thread_check(ls->thread);
}
/**
* @brief Return the container during EIO operation
* @param ls The asynchronous IO operation to retrieve container from.