\hypertarget{group__Ecore__Job__Group}{}\doxysection{Ecore Job functions}
\label{group__Ecore__Job__Group}\index{Ecore Job functions@{Ecore Job functions}}


You can queue jobs that are to be done by the main loop when the current event is dealt with.  


\doxysubsection*{Typedefs}
\begin{DoxyCompactItemize}
\item 
typedef struct \+\_\+\+Ecore\+\_\+\+Job \mbox{\hyperlink{group__Ecore__Job__Group_ga51a4bfa938b1205aead7d0dd2dae83db}{Ecore\+\_\+\+Job}}
\begin{DoxyCompactList}\small\item\em A job handle. \end{DoxyCompactList}\end{DoxyCompactItemize}
\doxysubsection*{Functions}
\begin{DoxyCompactItemize}
\item 
\mbox{\hyperlink{group__Ecore__Job__Group_ga51a4bfa938b1205aead7d0dd2dae83db}{Ecore\+\_\+\+Job}} $\ast$ \mbox{\hyperlink{group__Ecore__Job__Group_ga859b3807977b215b7589f5b61dbf9ac2}{ecore\+\_\+job\+\_\+add}} (\mbox{\hyperlink{group__Ecore__Main__Loop__Group_ga00aa98b68b33de046b49a0158956874f}{Ecore\+\_\+\+Cb}} func, const void $\ast$data)
\begin{DoxyCompactList}\small\item\em Adds a job to the event queue. \end{DoxyCompactList}\item 
void $\ast$ \mbox{\hyperlink{group__Ecore__Job__Group_ga6baa274d218948aaaeaaa19cd8b094f4}{ecore\+\_\+job\+\_\+del}} (\mbox{\hyperlink{group__Ecore__Job__Group_ga51a4bfa938b1205aead7d0dd2dae83db}{Ecore\+\_\+\+Job}} $\ast$obj)
\begin{DoxyCompactList}\small\item\em Deletes a queued job that has not yet been executed. \end{DoxyCompactList}\end{DoxyCompactItemize}


\doxysubsection{Detailed Description}
You can queue jobs that are to be done by the main loop when the current event is dealt with. 

Jobs are processed by the main loop similarly to events. They also will be executed in the order in which they were added.

A good use for them is when you don\textquotesingle{}t want to execute an action immediately, but want to give the control back to the main loop so that it will call your job callback when jobs start being processed (and if there are other jobs added before yours, they will be processed first). This also gives the chance to other actions in your program to cancel the job before it is started.

Examples of using \mbox{\hyperlink{group__Ecore__Job__Group_ga51a4bfa938b1205aead7d0dd2dae83db}{Ecore\+\_\+\+Job}} \+: \begin{DoxyItemize}
\item \mbox{\hyperlink{ecore_job_example_c}{ecore\+\_\+job -\/ Queuing tasks}} \end{DoxyItemize}


\doxysubsection{Typedef Documentation}
\mbox{\Hypertarget{group__Ecore__Job__Group_ga51a4bfa938b1205aead7d0dd2dae83db}\label{group__Ecore__Job__Group_ga51a4bfa938b1205aead7d0dd2dae83db}} 
\index{Ecore Job functions@{Ecore Job functions}!Ecore\_Job@{Ecore\_Job}}
\index{Ecore\_Job@{Ecore\_Job}!Ecore Job functions@{Ecore Job functions}}
\doxysubsubsection{\texorpdfstring{Ecore\_Job}{Ecore\_Job}}
{\footnotesize\ttfamily typedef struct \+\_\+\+Ecore\+\_\+\+Job \mbox{\hyperlink{group__Ecore__Job__Group_ga51a4bfa938b1205aead7d0dd2dae83db}{Ecore\+\_\+\+Job}}}



A job handle. 

\begin{DoxySince}{Since}
1.\+8 
\end{DoxySince}


\doxysubsection{Function Documentation}
\mbox{\Hypertarget{group__Ecore__Job__Group_ga859b3807977b215b7589f5b61dbf9ac2}\label{group__Ecore__Job__Group_ga859b3807977b215b7589f5b61dbf9ac2}} 
\index{Ecore Job functions@{Ecore Job functions}!ecore\_job\_add@{ecore\_job\_add}}
\index{ecore\_job\_add@{ecore\_job\_add}!Ecore Job functions@{Ecore Job functions}}
\doxysubsubsection{\texorpdfstring{ecore\_job\_add()}{ecore\_job\_add()}}
{\footnotesize\ttfamily \mbox{\hyperlink{group__Ecore__Job__Group_ga51a4bfa938b1205aead7d0dd2dae83db}{Ecore\+\_\+\+Job}} $\ast$ ecore\+\_\+job\+\_\+add (\begin{DoxyParamCaption}\item[{\mbox{\hyperlink{group__Ecore__Main__Loop__Group_ga00aa98b68b33de046b49a0158956874f}{Ecore\+\_\+\+Cb}}}]{func,  }\item[{const void $\ast$}]{data }\end{DoxyParamCaption})}



Adds a job to the event queue. 


\begin{DoxyParams}{Parameters}
{\em func} & The function to call when the job gets handled. \\
\hline
{\em data} & Data pointer to be passed to the job function when the job is handled. \\
\hline
\end{DoxyParams}
\begin{DoxyReturn}{Returns}
The handle of the job. {\ttfamily NULL} is returned if the job could not be added to the queue. 
\end{DoxyReturn}
\begin{DoxyNote}{Note}
Once the job has been executed, the job handle is invalid. 
\end{DoxyNote}


References \mbox{\hyperlink{group__Ecore__Event__Group_ga81a4c863503927fb70fa5f35625c4352}{ecore\+\_\+event\+\_\+add()}}, and \mbox{\hyperlink{group__Eina__Lock__Group_ga2974eb3f18404edcc375910cc7e4859c}{EINA\+\_\+\+MAIN\+\_\+\+LOOP\+\_\+\+CHECK\+\_\+\+RETURN\+\_\+\+VAL}}.



Referenced by \mbox{\hyperlink{group__Efreet__Icon_gaa8d4241562f9da12d8260e420a49d986}{efreet\+\_\+icon\+\_\+extra\+\_\+list\+\_\+get()}}.

\mbox{\Hypertarget{group__Ecore__Job__Group_ga6baa274d218948aaaeaaa19cd8b094f4}\label{group__Ecore__Job__Group_ga6baa274d218948aaaeaaa19cd8b094f4}} 
\index{Ecore Job functions@{Ecore Job functions}!ecore\_job\_del@{ecore\_job\_del}}
\index{ecore\_job\_del@{ecore\_job\_del}!Ecore Job functions@{Ecore Job functions}}
\doxysubsubsection{\texorpdfstring{ecore\_job\_del()}{ecore\_job\_del()}}
{\footnotesize\ttfamily void $\ast$ ecore\+\_\+job\+\_\+del (\begin{DoxyParamCaption}\item[{\mbox{\hyperlink{group__Ecore__Job__Group_ga51a4bfa938b1205aead7d0dd2dae83db}{Ecore\+\_\+\+Job}} $\ast$}]{obj }\end{DoxyParamCaption})}



Deletes a queued job that has not yet been executed. 


\begin{DoxyParams}{Parameters}
{\em obj} & Handle of the job to delete. \\
\hline
\end{DoxyParams}
\begin{DoxyReturn}{Returns}
The data pointer that was to be passed to the job. 
\end{DoxyReturn}


References \mbox{\hyperlink{group__Ecore__Event__Group_gac05faeba0b9dcf8906d744e23ea7aa3b}{ecore\+\_\+event\+\_\+del()}}, and \mbox{\hyperlink{group__Eina__Lock__Group_ga2974eb3f18404edcc375910cc7e4859c}{EINA\+\_\+\+MAIN\+\_\+\+LOOP\+\_\+\+CHECK\+\_\+\+RETURN\+\_\+\+VAL}}.



Referenced by \mbox{\hyperlink{group__Elm__Cursors_ga1c97e902d92b738ddb6dda541ede562f}{elm\+\_\+object\+\_\+cursor\+\_\+unset()}}, and \mbox{\hyperlink{group__Store_ga04e5d401569956202edd4657a4503c58}{elm\+\_\+store\+\_\+free()}}.

