Delta Chat Core C-API
dc_jobthread.h
1 #ifndef __DC_JOBTHREAD_H__
2 #define __DC_JOBTHREAD_H__
3 #ifdef __cplusplus
4 extern "C" {
5 #endif
6 
7 
8 typedef struct _dc_jobthread dc_jobthread_t;
9 
10 
11 struct _dc_jobthread
12 {
13  dc_context_t* context;
14  char* name;
15  char* folder_config_name;
16 
17  struct _dc_imap* imap;
18 
19  pthread_mutex_t mutex;
20 
21  pthread_cond_t idle_cond;
22  int idle_condflag;
23 
24  int jobs_needed;
25  int suspended;
26  int using_handle;
27 
28 };
29 
30 
31 void dc_jobthread_init (dc_jobthread_t*, dc_context_t* context, const char* name,
32  const char* folder_config_name);
33 void dc_jobthread_exit (dc_jobthread_t*);
34 void dc_jobthread_suspend (dc_jobthread_t*, int suspend);
35 
36 void dc_jobthread_fetch (dc_jobthread_t*, int use_network);
37 void dc_jobthread_idle (dc_jobthread_t*, int use_network);
38 void dc_jobthread_interrupt_idle (dc_jobthread_t*);
39 
40 
41 #ifdef __cplusplus
42 } /* /extern "C" */
43 #endif
44 #endif /* __DC_JOBTHREAD_H__ */
45 
An object representing a single account.