s3:winbind: Add async wb_group_members
[Samba/aatanasov.git] / source3 / librpc / gen_ndr / ndr_notify.c
blob844c278cd238743c653ed670b785b5198da09b18
1 /* parser auto-generated by pidl */
3 #include "includes.h"
4 #include "librpc/gen_ndr/ndr_notify.h"
6 _PUBLIC_ enum ndr_err_code ndr_push_notify_entry(struct ndr_push *ndr, int ndr_flags, const struct notify_entry *r)
8 if (ndr_flags & NDR_SCALARS) {
9 NDR_CHECK(ndr_push_align(ndr, 8));
10 NDR_CHECK(ndr_push_server_id(ndr, NDR_SCALARS, &r->server));
11 NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->filter));
12 NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->subdir_filter));
13 NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->dir_fd));
14 NDR_CHECK(ndr_push_file_id(ndr, NDR_SCALARS, &r->dir_id));
16 uint32_t _flags_save_string = ndr->flags;
17 ndr_set_flags(&ndr->flags, LIBNDR_FLAG_STR_UTF8|LIBNDR_FLAG_STR_NULLTERM);
18 NDR_CHECK(ndr_push_string(ndr, NDR_SCALARS, r->path));
19 ndr->flags = _flags_save_string;
21 NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->path_len));
22 NDR_CHECK(ndr_push_pointer(ndr, NDR_SCALARS, r->private_data));
24 if (ndr_flags & NDR_BUFFERS) {
25 NDR_CHECK(ndr_push_server_id(ndr, NDR_BUFFERS, &r->server));
26 NDR_CHECK(ndr_push_file_id(ndr, NDR_BUFFERS, &r->dir_id));
28 return NDR_ERR_SUCCESS;
31 _PUBLIC_ enum ndr_err_code ndr_pull_notify_entry(struct ndr_pull *ndr, int ndr_flags, struct notify_entry *r)
33 if (ndr_flags & NDR_SCALARS) {
34 NDR_CHECK(ndr_pull_align(ndr, 8));
35 NDR_CHECK(ndr_pull_server_id(ndr, NDR_SCALARS, &r->server));
36 NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->filter));
37 NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->subdir_filter));
38 NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->dir_fd));
39 NDR_CHECK(ndr_pull_file_id(ndr, NDR_SCALARS, &r->dir_id));
41 uint32_t _flags_save_string = ndr->flags;
42 ndr_set_flags(&ndr->flags, LIBNDR_FLAG_STR_UTF8|LIBNDR_FLAG_STR_NULLTERM);
43 NDR_CHECK(ndr_pull_string(ndr, NDR_SCALARS, &r->path));
44 ndr->flags = _flags_save_string;
46 NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->path_len));
47 NDR_CHECK(ndr_pull_pointer(ndr, NDR_SCALARS, &r->private_data));
49 if (ndr_flags & NDR_BUFFERS) {
50 NDR_CHECK(ndr_pull_server_id(ndr, NDR_BUFFERS, &r->server));
51 NDR_CHECK(ndr_pull_file_id(ndr, NDR_BUFFERS, &r->dir_id));
53 return NDR_ERR_SUCCESS;
56 _PUBLIC_ void ndr_print_notify_entry(struct ndr_print *ndr, const char *name, const struct notify_entry *r)
58 ndr_print_struct(ndr, name, "notify_entry");
59 ndr->depth++;
60 ndr_print_server_id(ndr, "server", &r->server);
61 ndr_print_uint32(ndr, "filter", r->filter);
62 ndr_print_uint32(ndr, "subdir_filter", r->subdir_filter);
63 ndr_print_uint32(ndr, "dir_fd", r->dir_fd);
64 ndr_print_file_id(ndr, "dir_id", &r->dir_id);
65 ndr_print_string(ndr, "path", r->path);
66 ndr_print_uint32(ndr, "path_len", r->path_len);
67 ndr_print_pointer(ndr, "private_data", r->private_data);
68 ndr->depth--;
71 _PUBLIC_ enum ndr_err_code ndr_push_notify_entry_array(struct ndr_push *ndr, int ndr_flags, const struct notify_entry_array *r)
73 uint32_t cntr_entries_0;
74 if (ndr_flags & NDR_SCALARS) {
75 NDR_CHECK(ndr_push_align(ndr, 8));
76 NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->num_entries));
77 for (cntr_entries_0 = 0; cntr_entries_0 < r->num_entries; cntr_entries_0++) {
78 NDR_CHECK(ndr_push_notify_entry(ndr, NDR_SCALARS, &r->entries[cntr_entries_0]));
81 if (ndr_flags & NDR_BUFFERS) {
82 for (cntr_entries_0 = 0; cntr_entries_0 < r->num_entries; cntr_entries_0++) {
83 NDR_CHECK(ndr_push_notify_entry(ndr, NDR_BUFFERS, &r->entries[cntr_entries_0]));
86 return NDR_ERR_SUCCESS;
89 _PUBLIC_ enum ndr_err_code ndr_pull_notify_entry_array(struct ndr_pull *ndr, int ndr_flags, struct notify_entry_array *r)
91 uint32_t cntr_entries_0;
92 TALLOC_CTX *_mem_save_entries_0;
93 if (ndr_flags & NDR_SCALARS) {
94 NDR_CHECK(ndr_pull_align(ndr, 8));
95 NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->num_entries));
96 NDR_PULL_ALLOC_N(ndr, r->entries, r->num_entries);
97 _mem_save_entries_0 = NDR_PULL_GET_MEM_CTX(ndr);
98 NDR_PULL_SET_MEM_CTX(ndr, r->entries, 0);
99 for (cntr_entries_0 = 0; cntr_entries_0 < r->num_entries; cntr_entries_0++) {
100 NDR_CHECK(ndr_pull_notify_entry(ndr, NDR_SCALARS, &r->entries[cntr_entries_0]));
102 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_entries_0, 0);
104 if (ndr_flags & NDR_BUFFERS) {
105 _mem_save_entries_0 = NDR_PULL_GET_MEM_CTX(ndr);
106 NDR_PULL_SET_MEM_CTX(ndr, r->entries, 0);
107 for (cntr_entries_0 = 0; cntr_entries_0 < r->num_entries; cntr_entries_0++) {
108 NDR_CHECK(ndr_pull_notify_entry(ndr, NDR_BUFFERS, &r->entries[cntr_entries_0]));
110 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_entries_0, 0);
112 return NDR_ERR_SUCCESS;
115 _PUBLIC_ void ndr_print_notify_entry_array(struct ndr_print *ndr, const char *name, const struct notify_entry_array *r)
117 uint32_t cntr_entries_0;
118 ndr_print_struct(ndr, name, "notify_entry_array");
119 ndr->depth++;
120 ndr_print_uint32(ndr, "num_entries", r->num_entries);
121 ndr->print(ndr, "%s: ARRAY(%d)", "entries", (int)r->num_entries);
122 ndr->depth++;
123 for (cntr_entries_0=0;cntr_entries_0<r->num_entries;cntr_entries_0++) {
124 char *idx_0=NULL;
125 if (asprintf(&idx_0, "[%d]", cntr_entries_0) != -1) {
126 ndr_print_notify_entry(ndr, "entries", &r->entries[cntr_entries_0]);
127 free(idx_0);
130 ndr->depth--;
131 ndr->depth--;
134 static enum ndr_err_code ndr_push_notify_depth(struct ndr_push *ndr, int ndr_flags, const struct notify_depth *r)
136 uint32_t cntr_entries_0;
137 if (ndr_flags & NDR_SCALARS) {
138 NDR_CHECK(ndr_push_align(ndr, 8));
139 NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->max_mask));
140 NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->max_mask_subdir));
141 NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->num_entries));
142 for (cntr_entries_0 = 0; cntr_entries_0 < r->num_entries; cntr_entries_0++) {
143 NDR_CHECK(ndr_push_notify_entry(ndr, NDR_SCALARS, &r->entries[cntr_entries_0]));
146 if (ndr_flags & NDR_BUFFERS) {
147 for (cntr_entries_0 = 0; cntr_entries_0 < r->num_entries; cntr_entries_0++) {
148 NDR_CHECK(ndr_push_notify_entry(ndr, NDR_BUFFERS, &r->entries[cntr_entries_0]));
151 return NDR_ERR_SUCCESS;
154 static enum ndr_err_code ndr_pull_notify_depth(struct ndr_pull *ndr, int ndr_flags, struct notify_depth *r)
156 uint32_t cntr_entries_0;
157 TALLOC_CTX *_mem_save_entries_0;
158 if (ndr_flags & NDR_SCALARS) {
159 NDR_CHECK(ndr_pull_align(ndr, 8));
160 NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->max_mask));
161 NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->max_mask_subdir));
162 NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->num_entries));
163 NDR_PULL_ALLOC_N(ndr, r->entries, r->num_entries);
164 _mem_save_entries_0 = NDR_PULL_GET_MEM_CTX(ndr);
165 NDR_PULL_SET_MEM_CTX(ndr, r->entries, 0);
166 for (cntr_entries_0 = 0; cntr_entries_0 < r->num_entries; cntr_entries_0++) {
167 NDR_CHECK(ndr_pull_notify_entry(ndr, NDR_SCALARS, &r->entries[cntr_entries_0]));
169 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_entries_0, 0);
171 if (ndr_flags & NDR_BUFFERS) {
172 _mem_save_entries_0 = NDR_PULL_GET_MEM_CTX(ndr);
173 NDR_PULL_SET_MEM_CTX(ndr, r->entries, 0);
174 for (cntr_entries_0 = 0; cntr_entries_0 < r->num_entries; cntr_entries_0++) {
175 NDR_CHECK(ndr_pull_notify_entry(ndr, NDR_BUFFERS, &r->entries[cntr_entries_0]));
177 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_entries_0, 0);
179 return NDR_ERR_SUCCESS;
182 _PUBLIC_ void ndr_print_notify_depth(struct ndr_print *ndr, const char *name, const struct notify_depth *r)
184 uint32_t cntr_entries_0;
185 ndr_print_struct(ndr, name, "notify_depth");
186 ndr->depth++;
187 ndr_print_uint32(ndr, "max_mask", r->max_mask);
188 ndr_print_uint32(ndr, "max_mask_subdir", r->max_mask_subdir);
189 ndr_print_uint32(ndr, "num_entries", r->num_entries);
190 ndr->print(ndr, "%s: ARRAY(%d)", "entries", (int)r->num_entries);
191 ndr->depth++;
192 for (cntr_entries_0=0;cntr_entries_0<r->num_entries;cntr_entries_0++) {
193 char *idx_0=NULL;
194 if (asprintf(&idx_0, "[%d]", cntr_entries_0) != -1) {
195 ndr_print_notify_entry(ndr, "entries", &r->entries[cntr_entries_0]);
196 free(idx_0);
199 ndr->depth--;
200 ndr->depth--;
203 _PUBLIC_ enum ndr_err_code ndr_push_notify_array(struct ndr_push *ndr, int ndr_flags, const struct notify_array *r)
205 uint32_t cntr_depth_0;
206 if (ndr_flags & NDR_SCALARS) {
207 NDR_CHECK(ndr_push_align(ndr, 8));
208 NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->num_depths));
209 for (cntr_depth_0 = 0; cntr_depth_0 < r->num_depths; cntr_depth_0++) {
210 NDR_CHECK(ndr_push_notify_depth(ndr, NDR_SCALARS, &r->depth[cntr_depth_0]));
213 if (ndr_flags & NDR_BUFFERS) {
214 for (cntr_depth_0 = 0; cntr_depth_0 < r->num_depths; cntr_depth_0++) {
215 NDR_CHECK(ndr_push_notify_depth(ndr, NDR_BUFFERS, &r->depth[cntr_depth_0]));
218 return NDR_ERR_SUCCESS;
221 _PUBLIC_ enum ndr_err_code ndr_pull_notify_array(struct ndr_pull *ndr, int ndr_flags, struct notify_array *r)
223 uint32_t cntr_depth_0;
224 TALLOC_CTX *_mem_save_depth_0;
225 if (ndr_flags & NDR_SCALARS) {
226 NDR_CHECK(ndr_pull_align(ndr, 8));
227 NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->num_depths));
228 NDR_PULL_ALLOC_N(ndr, r->depth, r->num_depths);
229 _mem_save_depth_0 = NDR_PULL_GET_MEM_CTX(ndr);
230 NDR_PULL_SET_MEM_CTX(ndr, r->depth, 0);
231 for (cntr_depth_0 = 0; cntr_depth_0 < r->num_depths; cntr_depth_0++) {
232 NDR_CHECK(ndr_pull_notify_depth(ndr, NDR_SCALARS, &r->depth[cntr_depth_0]));
234 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_depth_0, 0);
236 if (ndr_flags & NDR_BUFFERS) {
237 _mem_save_depth_0 = NDR_PULL_GET_MEM_CTX(ndr);
238 NDR_PULL_SET_MEM_CTX(ndr, r->depth, 0);
239 for (cntr_depth_0 = 0; cntr_depth_0 < r->num_depths; cntr_depth_0++) {
240 NDR_CHECK(ndr_pull_notify_depth(ndr, NDR_BUFFERS, &r->depth[cntr_depth_0]));
242 NDR_PULL_SET_MEM_CTX(ndr, _mem_save_depth_0, 0);
244 return NDR_ERR_SUCCESS;
247 _PUBLIC_ void ndr_print_notify_array(struct ndr_print *ndr, const char *name, const struct notify_array *r)
249 uint32_t cntr_depth_0;
250 ndr_print_struct(ndr, name, "notify_array");
251 ndr->depth++;
252 ndr_print_uint32(ndr, "num_depths", r->num_depths);
253 ndr->print(ndr, "%s: ARRAY(%d)", "depth", (int)r->num_depths);
254 ndr->depth++;
255 for (cntr_depth_0=0;cntr_depth_0<r->num_depths;cntr_depth_0++) {
256 char *idx_0=NULL;
257 if (asprintf(&idx_0, "[%d]", cntr_depth_0) != -1) {
258 ndr_print_notify_depth(ndr, "depth", &r->depth[cntr_depth_0]);
259 free(idx_0);
262 ndr->depth--;
263 ndr->depth--;
266 _PUBLIC_ enum ndr_err_code ndr_push_notify_event(struct ndr_push *ndr, int ndr_flags, const struct notify_event *r)
268 if (ndr_flags & NDR_SCALARS) {
269 NDR_CHECK(ndr_push_align(ndr, 8));
270 NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, r->action));
272 uint32_t _flags_save_string = ndr->flags;
273 ndr_set_flags(&ndr->flags, LIBNDR_FLAG_STR_UTF8|LIBNDR_FLAG_STR_NULLTERM);
274 NDR_CHECK(ndr_push_string(ndr, NDR_SCALARS, r->path));
275 ndr->flags = _flags_save_string;
277 NDR_CHECK(ndr_push_pointer(ndr, NDR_SCALARS, r->private_data));
279 if (ndr_flags & NDR_BUFFERS) {
281 return NDR_ERR_SUCCESS;
284 _PUBLIC_ enum ndr_err_code ndr_pull_notify_event(struct ndr_pull *ndr, int ndr_flags, struct notify_event *r)
286 if (ndr_flags & NDR_SCALARS) {
287 NDR_CHECK(ndr_pull_align(ndr, 8));
288 NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->action));
290 uint32_t _flags_save_string = ndr->flags;
291 ndr_set_flags(&ndr->flags, LIBNDR_FLAG_STR_UTF8|LIBNDR_FLAG_STR_NULLTERM);
292 NDR_CHECK(ndr_pull_string(ndr, NDR_SCALARS, &r->path));
293 ndr->flags = _flags_save_string;
295 NDR_CHECK(ndr_pull_pointer(ndr, NDR_SCALARS, &r->private_data));
297 if (ndr_flags & NDR_BUFFERS) {
299 return NDR_ERR_SUCCESS;
302 _PUBLIC_ void ndr_print_notify_event(struct ndr_print *ndr, const char *name, const struct notify_event *r)
304 ndr_print_struct(ndr, name, "notify_event");
305 ndr->depth++;
306 ndr_print_uint32(ndr, "action", r->action);
307 ndr_print_string(ndr, "path", r->path);
308 ndr_print_pointer(ndr, "private_data", r->private_data);
309 ndr->depth--;