File: future.h

package info (click to toggle)
syslog-ng 3.8.1-10
  • links: PTS, VCS
  • area: main
  • in suites: stretch
  • size: 47,320 kB
  • ctags: 43,937
  • sloc: ansic: 159,432; yacc: 25,059; sh: 13,574; makefile: 4,669; python: 3,468; java: 3,218; xml: 2,309; perl: 318; lex: 316; awk: 184
file content (112 lines) | stat: -rw-r--r-- 2,484 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
#ifndef FUTURE_H
#define FUTURE_H

#include <bson.h>

#include "future-value.h"
#include "mongoc-thread-private.h"

/**************************************************
 *
 * Generated by build/generate-future-functions.py.
 *
 * DO NOT EDIT THIS FILE.
 *
 *************************************************/

typedef struct
{
   bool             resolved;
   bool             awaited;
   future_value_t   return_value;
   int              argc;
   future_value_t  *argv;
   mongoc_cond_t    cond;
   mongoc_mutex_t   mutex;
   mongoc_thread_t  thread;
} future_t;

future_t *future_new (future_value_type_t return_type, int argc);

future_value_t *future_get_param (future_t *future, int i);

void future_start (future_t *future,
                   void *(*start_routine)(void *));

void future_resolve (future_t *future, future_value_t return_value);

bool future_wait (future_t *future);

void future_get_void (future_t *future);


bool
future_get_bool (future_t *future);

char_ptr
future_get_char_ptr (future_t *future);

char_ptr_ptr
future_get_char_ptr_ptr (future_t *future);

int64_t
future_get_int64_t (future_t *future);

uint32_t
future_get_uint32_t (future_t *future);

const_char_ptr
future_get_const_char_ptr (future_t *future);

bson_error_ptr
future_get_bson_error_ptr (future_t *future);

bson_ptr
future_get_bson_ptr (future_t *future);

const_bson_ptr
future_get_const_bson_ptr (future_t *future);

const_bson_ptr_ptr
future_get_const_bson_ptr_ptr (future_t *future);

mongoc_bulk_operation_ptr
future_get_mongoc_bulk_operation_ptr (future_t *future);

mongoc_client_ptr
future_get_mongoc_client_ptr (future_t *future);

mongoc_collection_ptr
future_get_mongoc_collection_ptr (future_t *future);

mongoc_cursor_ptr
future_get_mongoc_cursor_ptr (future_t *future);

mongoc_database_ptr
future_get_mongoc_database_ptr (future_t *future);

mongoc_insert_flags_t
future_get_mongoc_insert_flags_t (future_t *future);

mongoc_query_flags_t
future_get_mongoc_query_flags_t (future_t *future);

mongoc_server_description_ptr
future_get_mongoc_server_description_ptr (future_t *future);

mongoc_ss_optype_t
future_get_mongoc_ss_optype_t (future_t *future);

mongoc_topology_ptr
future_get_mongoc_topology_ptr (future_t *future);

const_mongoc_read_prefs_ptr
future_get_const_mongoc_read_prefs_ptr (future_t *future);

const_mongoc_write_concern_ptr
future_get_const_mongoc_write_concern_ptr (future_t *future);


void future_destroy (future_t *future);

#endif /* FUTURE_H */