Tizen 2.1 base
[platform/upstream/glib2.0.git] / gio / tests / gdbus-test-codegen-generated.c
1 /*
2  * Generated by gdbus-codegen 2.32.3. DO NOT EDIT.
3  *
4  * The license of this code is the same as for the source it was derived from.
5  */
6
7 #ifdef HAVE_CONFIG_H
8 #  include "config.h"
9 #endif
10
11 #include "gdbus-test-codegen-generated.h"
12
13 #ifdef G_OS_UNIX
14 #  include <gio/gunixfdlist.h>
15 #endif
16
17 typedef struct
18 {
19   GDBusArgInfo parent_struct;
20   gboolean use_gvariant;
21 } _ExtendedGDBusArgInfo;
22
23 typedef struct
24 {
25   GDBusMethodInfo parent_struct;
26   const gchar *signal_name;
27   gboolean pass_fdlist;
28 } _ExtendedGDBusMethodInfo;
29
30 typedef struct
31 {
32   GDBusSignalInfo parent_struct;
33   const gchar *signal_name;
34 } _ExtendedGDBusSignalInfo;
35
36 typedef struct
37 {
38   GDBusPropertyInfo parent_struct;
39   const gchar *hyphen_name;
40   gboolean use_gvariant;
41 } _ExtendedGDBusPropertyInfo;
42
43 typedef struct
44 {
45   GDBusInterfaceInfo parent_struct;
46   const gchar *hyphen_name;
47 } _ExtendedGDBusInterfaceInfo;
48
49 typedef struct
50 {
51   const _ExtendedGDBusPropertyInfo *info;
52   guint prop_id;
53   GValue orig_value; /* the value before the change */
54 } ChangedProperty;
55
56 static void
57 _changed_property_free (ChangedProperty *data)
58 {
59   g_value_unset (&data->orig_value);
60   g_free (data);
61 }
62
63 static gboolean
64 _g_strv_equal0 (gchar **a, gchar **b)
65 {
66   gboolean ret = FALSE;
67   guint n;
68   if (a == NULL && b == NULL)
69     {
70       ret = TRUE;
71       goto out;
72     }
73   if (a == NULL || b == NULL)
74     goto out;
75   if (g_strv_length (a) != g_strv_length (b))
76     goto out;
77   for (n = 0; a[n] != NULL; n++)
78     if (g_strcmp0 (a[n], b[n]) != 0)
79       goto out;
80   ret = TRUE;
81 out:
82   return ret;
83 }
84
85 static gboolean
86 _g_variant_equal0 (GVariant *a, GVariant *b)
87 {
88   gboolean ret = FALSE;
89   if (a == NULL && b == NULL)
90     {
91       ret = TRUE;
92       goto out;
93     }
94   if (a == NULL || b == NULL)
95     goto out;
96   ret = g_variant_equal (a, b);
97 out:
98   return ret;
99 }
100
101 G_GNUC_UNUSED static gboolean
102 _g_value_equal (const GValue *a, const GValue *b)
103 {
104   gboolean ret = FALSE;
105   g_assert (G_VALUE_TYPE (a) == G_VALUE_TYPE (b));
106   switch (G_VALUE_TYPE (a))
107     {
108       case G_TYPE_BOOLEAN:
109         ret = (g_value_get_boolean (a) == g_value_get_boolean (b));
110         break;
111       case G_TYPE_UCHAR:
112         ret = (g_value_get_uchar (a) == g_value_get_uchar (b));
113         break;
114       case G_TYPE_INT:
115         ret = (g_value_get_int (a) == g_value_get_int (b));
116         break;
117       case G_TYPE_UINT:
118         ret = (g_value_get_uint (a) == g_value_get_uint (b));
119         break;
120       case G_TYPE_INT64:
121         ret = (g_value_get_int64 (a) == g_value_get_int64 (b));
122         break;
123       case G_TYPE_UINT64:
124         ret = (g_value_get_uint64 (a) == g_value_get_uint64 (b));
125         break;
126       case G_TYPE_DOUBLE:
127         ret = (g_value_get_double (a) == g_value_get_double (b));
128         break;
129       case G_TYPE_STRING:
130         ret = (g_strcmp0 (g_value_get_string (a), g_value_get_string (b)) == 0);
131         break;
132       case G_TYPE_VARIANT:
133         ret = _g_variant_equal0 (g_value_get_variant (a), g_value_get_variant (b));
134         break;
135       default:
136         if (G_VALUE_TYPE (a) == G_TYPE_STRV)
137           ret = _g_strv_equal0 (g_value_get_boxed (a), g_value_get_boxed (b));
138         else
139           g_critical ("_g_value_equal() does not handle type %s", g_type_name (G_VALUE_TYPE (a)));
140         break;
141     }
142   return ret;
143 }
144
145 /* ------------------------------------------------------------------------
146  * Code for interface org.project.Bar
147  * ------------------------------------------------------------------------
148  */
149
150 /**
151  * SECTION:FooiGenBar
152  * @title: FooiGenBar
153  * @short_description: Generated C code for the org.project.Bar D-Bus interface
154  *
155  * This section contains code for working with the <link linkend="gdbus-interface-org-project-Bar.top_of_page">org.project.Bar</link> D-Bus interface in C.
156  */
157
158 /* ---- Introspection data for org.project.Bar ---- */
159
160 static const _ExtendedGDBusArgInfo _foo_igen_bar_method_info_hello_world_IN_ARG_greeting =
161 {
162   {
163     -1,
164     "greeting",
165     "s",
166     NULL
167   },
168   FALSE
169 };
170
171 static const _ExtendedGDBusArgInfo * const _foo_igen_bar_method_info_hello_world_IN_ARG_pointers[] =
172 {
173   &_foo_igen_bar_method_info_hello_world_IN_ARG_greeting,
174   NULL
175 };
176
177 static const _ExtendedGDBusArgInfo _foo_igen_bar_method_info_hello_world_OUT_ARG_response =
178 {
179   {
180     -1,
181     "response",
182     "s",
183     NULL
184   },
185   FALSE
186 };
187
188 static const _ExtendedGDBusArgInfo * const _foo_igen_bar_method_info_hello_world_OUT_ARG_pointers[] =
189 {
190   &_foo_igen_bar_method_info_hello_world_OUT_ARG_response,
191   NULL
192 };
193
194 static const GDBusAnnotationInfo _foo_igen_bar_method_hello_world_annotation_info_0 =
195 {
196   -1,
197   "Key3",
198   "Value3",
199   NULL
200 };
201
202 static const GDBusAnnotationInfo _foo_igen_bar_method_hello_world_annotation_info_1 =
203 {
204   -1,
205   "ExistingAnnotation",
206   "blah",
207   NULL
208 };
209
210 static const GDBusAnnotationInfo * const _foo_igen_bar_method_hello_world_annotation_info_pointers[] =
211 {
212   &_foo_igen_bar_method_hello_world_annotation_info_0,
213   &_foo_igen_bar_method_hello_world_annotation_info_1,
214   NULL
215 };
216
217 static const _ExtendedGDBusMethodInfo _foo_igen_bar_method_info_hello_world =
218 {
219   {
220     -1,
221     "HelloWorld",
222     (GDBusArgInfo **) &_foo_igen_bar_method_info_hello_world_IN_ARG_pointers,
223     (GDBusArgInfo **) &_foo_igen_bar_method_info_hello_world_OUT_ARG_pointers,
224     (GDBusAnnotationInfo **) &_foo_igen_bar_method_hello_world_annotation_info_pointers
225   },
226   "handle-hello-world",
227   FALSE
228 };
229
230 static const _ExtendedGDBusArgInfo _foo_igen_bar_method_info_test_primitive_types_IN_ARG_val_byte =
231 {
232   {
233     -1,
234     "val_byte",
235     "y",
236     NULL
237   },
238   FALSE
239 };
240
241 static const _ExtendedGDBusArgInfo _foo_igen_bar_method_info_test_primitive_types_IN_ARG_val_boolean =
242 {
243   {
244     -1,
245     "val_boolean",
246     "b",
247     NULL
248   },
249   FALSE
250 };
251
252 static const _ExtendedGDBusArgInfo _foo_igen_bar_method_info_test_primitive_types_IN_ARG_val_int16 =
253 {
254   {
255     -1,
256     "val_int16",
257     "n",
258     NULL
259   },
260   FALSE
261 };
262
263 static const _ExtendedGDBusArgInfo _foo_igen_bar_method_info_test_primitive_types_IN_ARG_val_uint16 =
264 {
265   {
266     -1,
267     "val_uint16",
268     "q",
269     NULL
270   },
271   FALSE
272 };
273
274 static const GDBusAnnotationInfo _foo_igen_bar_method_info_test_primitive_types_IN_ARG_arg_val_int32_annotation_info_0 =
275 {
276   -1,
277   "Key6",
278   "Value6",
279   NULL
280 };
281
282 static const GDBusAnnotationInfo * const _foo_igen_bar_method_info_test_primitive_types_IN_ARG_arg_val_int32_annotation_info_pointers[] =
283 {
284   &_foo_igen_bar_method_info_test_primitive_types_IN_ARG_arg_val_int32_annotation_info_0,
285   NULL
286 };
287
288 static const _ExtendedGDBusArgInfo _foo_igen_bar_method_info_test_primitive_types_IN_ARG_val_int32 =
289 {
290   {
291     -1,
292     "val_int32",
293     "i",
294     (GDBusAnnotationInfo **) &_foo_igen_bar_method_info_test_primitive_types_IN_ARG_arg_val_int32_annotation_info_pointers
295   },
296   FALSE
297 };
298
299 static const _ExtendedGDBusArgInfo _foo_igen_bar_method_info_test_primitive_types_IN_ARG_val_uint32 =
300 {
301   {
302     -1,
303     "val_uint32",
304     "u",
305     NULL
306   },
307   FALSE
308 };
309
310 static const _ExtendedGDBusArgInfo _foo_igen_bar_method_info_test_primitive_types_IN_ARG_val_int64 =
311 {
312   {
313     -1,
314     "val_int64",
315     "x",
316     NULL
317   },
318   FALSE
319 };
320
321 static const _ExtendedGDBusArgInfo _foo_igen_bar_method_info_test_primitive_types_IN_ARG_val_uint64 =
322 {
323   {
324     -1,
325     "val_uint64",
326     "t",
327     NULL
328   },
329   FALSE
330 };
331
332 static const _ExtendedGDBusArgInfo _foo_igen_bar_method_info_test_primitive_types_IN_ARG_val_double =
333 {
334   {
335     -1,
336     "val_double",
337     "d",
338     NULL
339   },
340   FALSE
341 };
342
343 static const _ExtendedGDBusArgInfo _foo_igen_bar_method_info_test_primitive_types_IN_ARG_val_string =
344 {
345   {
346     -1,
347     "val_string",
348     "s",
349     NULL
350   },
351   FALSE
352 };
353
354 static const _ExtendedGDBusArgInfo _foo_igen_bar_method_info_test_primitive_types_IN_ARG_val_objpath =
355 {
356   {
357     -1,
358     "val_objpath",
359     "o",
360     NULL
361   },
362   FALSE
363 };
364
365 static const _ExtendedGDBusArgInfo _foo_igen_bar_method_info_test_primitive_types_IN_ARG_val_signature =
366 {
367   {
368     -1,
369     "val_signature",
370     "g",
371     NULL
372   },
373   FALSE
374 };
375
376 static const _ExtendedGDBusArgInfo _foo_igen_bar_method_info_test_primitive_types_IN_ARG_val_bytestring =
377 {
378   {
379     -1,
380     "val_bytestring",
381     "ay",
382     NULL
383   },
384   FALSE
385 };
386
387 static const _ExtendedGDBusArgInfo * const _foo_igen_bar_method_info_test_primitive_types_IN_ARG_pointers[] =
388 {
389   &_foo_igen_bar_method_info_test_primitive_types_IN_ARG_val_byte,
390   &_foo_igen_bar_method_info_test_primitive_types_IN_ARG_val_boolean,
391   &_foo_igen_bar_method_info_test_primitive_types_IN_ARG_val_int16,
392   &_foo_igen_bar_method_info_test_primitive_types_IN_ARG_val_uint16,
393   &_foo_igen_bar_method_info_test_primitive_types_IN_ARG_val_int32,
394   &_foo_igen_bar_method_info_test_primitive_types_IN_ARG_val_uint32,
395   &_foo_igen_bar_method_info_test_primitive_types_IN_ARG_val_int64,
396   &_foo_igen_bar_method_info_test_primitive_types_IN_ARG_val_uint64,
397   &_foo_igen_bar_method_info_test_primitive_types_IN_ARG_val_double,
398   &_foo_igen_bar_method_info_test_primitive_types_IN_ARG_val_string,
399   &_foo_igen_bar_method_info_test_primitive_types_IN_ARG_val_objpath,
400   &_foo_igen_bar_method_info_test_primitive_types_IN_ARG_val_signature,
401   &_foo_igen_bar_method_info_test_primitive_types_IN_ARG_val_bytestring,
402   NULL
403 };
404
405 static const _ExtendedGDBusArgInfo _foo_igen_bar_method_info_test_primitive_types_OUT_ARG_ret_byte =
406 {
407   {
408     -1,
409     "ret_byte",
410     "y",
411     NULL
412   },
413   FALSE
414 };
415
416 static const _ExtendedGDBusArgInfo _foo_igen_bar_method_info_test_primitive_types_OUT_ARG_ret_boolean =
417 {
418   {
419     -1,
420     "ret_boolean",
421     "b",
422     NULL
423   },
424   FALSE
425 };
426
427 static const _ExtendedGDBusArgInfo _foo_igen_bar_method_info_test_primitive_types_OUT_ARG_ret_int16 =
428 {
429   {
430     -1,
431     "ret_int16",
432     "n",
433     NULL
434   },
435   FALSE
436 };
437
438 static const _ExtendedGDBusArgInfo _foo_igen_bar_method_info_test_primitive_types_OUT_ARG_ret_uint16 =
439 {
440   {
441     -1,
442     "ret_uint16",
443     "q",
444     NULL
445   },
446   FALSE
447 };
448
449 static const _ExtendedGDBusArgInfo _foo_igen_bar_method_info_test_primitive_types_OUT_ARG_ret_int32 =
450 {
451   {
452     -1,
453     "ret_int32",
454     "i",
455     NULL
456   },
457   FALSE
458 };
459
460 static const GDBusAnnotationInfo _foo_igen_bar_method_info_test_primitive_types_OUT_ARG_arg_ret_uint32_annotation_info_0 =
461 {
462   -1,
463   "Key7",
464   "Value7",
465   NULL
466 };
467
468 static const GDBusAnnotationInfo * const _foo_igen_bar_method_info_test_primitive_types_OUT_ARG_arg_ret_uint32_annotation_info_pointers[] =
469 {
470   &_foo_igen_bar_method_info_test_primitive_types_OUT_ARG_arg_ret_uint32_annotation_info_0,
471   NULL
472 };
473
474 static const _ExtendedGDBusArgInfo _foo_igen_bar_method_info_test_primitive_types_OUT_ARG_ret_uint32 =
475 {
476   {
477     -1,
478     "ret_uint32",
479     "u",
480     (GDBusAnnotationInfo **) &_foo_igen_bar_method_info_test_primitive_types_OUT_ARG_arg_ret_uint32_annotation_info_pointers
481   },
482   FALSE
483 };
484
485 static const _ExtendedGDBusArgInfo _foo_igen_bar_method_info_test_primitive_types_OUT_ARG_ret_int64 =
486 {
487   {
488     -1,
489     "ret_int64",
490     "x",
491     NULL
492   },
493   FALSE
494 };
495
496 static const _ExtendedGDBusArgInfo _foo_igen_bar_method_info_test_primitive_types_OUT_ARG_ret_uint64 =
497 {
498   {
499     -1,
500     "ret_uint64",
501     "t",
502     NULL
503   },
504   FALSE
505 };
506
507 static const _ExtendedGDBusArgInfo _foo_igen_bar_method_info_test_primitive_types_OUT_ARG_ret_double =
508 {
509   {
510     -1,
511     "ret_double",
512     "d",
513     NULL
514   },
515   FALSE
516 };
517
518 static const _ExtendedGDBusArgInfo _foo_igen_bar_method_info_test_primitive_types_OUT_ARG_ret_string =
519 {
520   {
521     -1,
522     "ret_string",
523     "s",
524     NULL
525   },
526   FALSE
527 };
528
529 static const _ExtendedGDBusArgInfo _foo_igen_bar_method_info_test_primitive_types_OUT_ARG_ret_objpath =
530 {
531   {
532     -1,
533     "ret_objpath",
534     "o",
535     NULL
536   },
537   FALSE
538 };
539
540 static const _ExtendedGDBusArgInfo _foo_igen_bar_method_info_test_primitive_types_OUT_ARG_ret_signature =
541 {
542   {
543     -1,
544     "ret_signature",
545     "g",
546     NULL
547   },
548   FALSE
549 };
550
551 static const _ExtendedGDBusArgInfo _foo_igen_bar_method_info_test_primitive_types_OUT_ARG_ret_bytestring =
552 {
553   {
554     -1,
555     "ret_bytestring",
556     "ay",
557     NULL
558   },
559   FALSE
560 };
561
562 static const _ExtendedGDBusArgInfo * const _foo_igen_bar_method_info_test_primitive_types_OUT_ARG_pointers[] =
563 {
564   &_foo_igen_bar_method_info_test_primitive_types_OUT_ARG_ret_byte,
565   &_foo_igen_bar_method_info_test_primitive_types_OUT_ARG_ret_boolean,
566   &_foo_igen_bar_method_info_test_primitive_types_OUT_ARG_ret_int16,
567   &_foo_igen_bar_method_info_test_primitive_types_OUT_ARG_ret_uint16,
568   &_foo_igen_bar_method_info_test_primitive_types_OUT_ARG_ret_int32,
569   &_foo_igen_bar_method_info_test_primitive_types_OUT_ARG_ret_uint32,
570   &_foo_igen_bar_method_info_test_primitive_types_OUT_ARG_ret_int64,
571   &_foo_igen_bar_method_info_test_primitive_types_OUT_ARG_ret_uint64,
572   &_foo_igen_bar_method_info_test_primitive_types_OUT_ARG_ret_double,
573   &_foo_igen_bar_method_info_test_primitive_types_OUT_ARG_ret_string,
574   &_foo_igen_bar_method_info_test_primitive_types_OUT_ARG_ret_objpath,
575   &_foo_igen_bar_method_info_test_primitive_types_OUT_ARG_ret_signature,
576   &_foo_igen_bar_method_info_test_primitive_types_OUT_ARG_ret_bytestring,
577   NULL
578 };
579
580 static const _ExtendedGDBusMethodInfo _foo_igen_bar_method_info_test_primitive_types =
581 {
582   {
583     -1,
584     "TestPrimitiveTypes",
585     (GDBusArgInfo **) &_foo_igen_bar_method_info_test_primitive_types_IN_ARG_pointers,
586     (GDBusArgInfo **) &_foo_igen_bar_method_info_test_primitive_types_OUT_ARG_pointers,
587     NULL
588   },
589   "handle-test-primitive-types",
590   FALSE
591 };
592
593 static const _ExtendedGDBusArgInfo _foo_igen_bar_method_info_test_non_primitive_types_IN_ARG_dict_s_to_s =
594 {
595   {
596     -1,
597     "dict_s_to_s",
598     "a{ss}",
599     NULL
600   },
601   FALSE
602 };
603
604 static const _ExtendedGDBusArgInfo _foo_igen_bar_method_info_test_non_primitive_types_IN_ARG_dict_s_to_pairs =
605 {
606   {
607     -1,
608     "dict_s_to_pairs",
609     "a{s(ii)}",
610     NULL
611   },
612   FALSE
613 };
614
615 static const _ExtendedGDBusArgInfo _foo_igen_bar_method_info_test_non_primitive_types_IN_ARG_a_struct =
616 {
617   {
618     -1,
619     "a_struct",
620     "(iss)",
621     NULL
622   },
623   FALSE
624 };
625
626 static const _ExtendedGDBusArgInfo _foo_igen_bar_method_info_test_non_primitive_types_IN_ARG_array_of_strings =
627 {
628   {
629     -1,
630     "array_of_strings",
631     "as",
632     NULL
633   },
634   FALSE
635 };
636
637 static const _ExtendedGDBusArgInfo _foo_igen_bar_method_info_test_non_primitive_types_IN_ARG_array_of_objpaths =
638 {
639   {
640     -1,
641     "array_of_objpaths",
642     "ao",
643     NULL
644   },
645   FALSE
646 };
647
648 static const _ExtendedGDBusArgInfo _foo_igen_bar_method_info_test_non_primitive_types_IN_ARG_array_of_signatures =
649 {
650   {
651     -1,
652     "array_of_signatures",
653     "ag",
654     NULL
655   },
656   FALSE
657 };
658
659 static const _ExtendedGDBusArgInfo _foo_igen_bar_method_info_test_non_primitive_types_IN_ARG_array_of_bytestrings =
660 {
661   {
662     -1,
663     "array_of_bytestrings",
664     "aay",
665     NULL
666   },
667   FALSE
668 };
669
670 static const _ExtendedGDBusArgInfo * const _foo_igen_bar_method_info_test_non_primitive_types_IN_ARG_pointers[] =
671 {
672   &_foo_igen_bar_method_info_test_non_primitive_types_IN_ARG_dict_s_to_s,
673   &_foo_igen_bar_method_info_test_non_primitive_types_IN_ARG_dict_s_to_pairs,
674   &_foo_igen_bar_method_info_test_non_primitive_types_IN_ARG_a_struct,
675   &_foo_igen_bar_method_info_test_non_primitive_types_IN_ARG_array_of_strings,
676   &_foo_igen_bar_method_info_test_non_primitive_types_IN_ARG_array_of_objpaths,
677   &_foo_igen_bar_method_info_test_non_primitive_types_IN_ARG_array_of_signatures,
678   &_foo_igen_bar_method_info_test_non_primitive_types_IN_ARG_array_of_bytestrings,
679   NULL
680 };
681
682 static const _ExtendedGDBusArgInfo _foo_igen_bar_method_info_test_non_primitive_types_OUT_ARG_result =
683 {
684   {
685     -1,
686     "result",
687     "ay",
688     NULL
689   },
690   FALSE
691 };
692
693 static const _ExtendedGDBusArgInfo * const _foo_igen_bar_method_info_test_non_primitive_types_OUT_ARG_pointers[] =
694 {
695   &_foo_igen_bar_method_info_test_non_primitive_types_OUT_ARG_result,
696   NULL
697 };
698
699 static const _ExtendedGDBusMethodInfo _foo_igen_bar_method_info_test_non_primitive_types =
700 {
701   {
702     -1,
703     "TestNonPrimitiveTypes",
704     (GDBusArgInfo **) &_foo_igen_bar_method_info_test_non_primitive_types_IN_ARG_pointers,
705     (GDBusArgInfo **) &_foo_igen_bar_method_info_test_non_primitive_types_OUT_ARG_pointers,
706     NULL
707   },
708   "handle-test-non-primitive-types",
709   FALSE
710 };
711
712 static const _ExtendedGDBusArgInfo _foo_igen_bar_method_info_request_signal_emission_IN_ARG_which_one =
713 {
714   {
715     -1,
716     "which_one",
717     "i",
718     NULL
719   },
720   FALSE
721 };
722
723 static const _ExtendedGDBusArgInfo * const _foo_igen_bar_method_info_request_signal_emission_IN_ARG_pointers[] =
724 {
725   &_foo_igen_bar_method_info_request_signal_emission_IN_ARG_which_one,
726   NULL
727 };
728
729 static const _ExtendedGDBusMethodInfo _foo_igen_bar_method_info_request_signal_emission =
730 {
731   {
732     -1,
733     "RequestSignalEmission",
734     (GDBusArgInfo **) &_foo_igen_bar_method_info_request_signal_emission_IN_ARG_pointers,
735     NULL,
736     NULL
737   },
738   "handle-request-signal-emission",
739   FALSE
740 };
741
742 static const _ExtendedGDBusMethodInfo _foo_igen_bar_method_info_request_multi_property_mods =
743 {
744   {
745     -1,
746     "RequestMultiPropertyMods",
747     NULL,
748     NULL,
749     NULL
750   },
751   "handle-request-multi-property-mods",
752   FALSE
753 };
754
755 static const _ExtendedGDBusMethodInfo _foo_igen_bar_method_info_unimplemented_method =
756 {
757   {
758     -1,
759     "UnimplementedMethod",
760     NULL,
761     NULL,
762     NULL
763   },
764   "handle-unimplemented-method",
765   FALSE
766 };
767
768 static const _ExtendedGDBusMethodInfo _foo_igen_bar_method_info_property_cancellation =
769 {
770   {
771     -1,
772     "PropertyCancellation",
773     NULL,
774     NULL,
775     NULL
776   },
777   "handle-property-cancellation",
778   FALSE
779 };
780
781 static const _ExtendedGDBusMethodInfo * const _foo_igen_bar_method_info_pointers[] =
782 {
783   &_foo_igen_bar_method_info_hello_world,
784   &_foo_igen_bar_method_info_test_primitive_types,
785   &_foo_igen_bar_method_info_test_non_primitive_types,
786   &_foo_igen_bar_method_info_request_signal_emission,
787   &_foo_igen_bar_method_info_request_multi_property_mods,
788   &_foo_igen_bar_method_info_unimplemented_method,
789   &_foo_igen_bar_method_info_property_cancellation,
790   NULL
791 };
792
793 static const _ExtendedGDBusArgInfo _foo_igen_bar_signal_info_test_signal_ARG_val_int32 =
794 {
795   {
796     -1,
797     "val_int32",
798     "i",
799     NULL
800   },
801   FALSE
802 };
803
804 static const GDBusAnnotationInfo _foo_igen_bar_signal_info_test_signal_ARG_arg_array_of_strings_annotation_info_0 =
805 {
806   -1,
807   "Key8",
808   "Value8",
809   NULL
810 };
811
812 static const GDBusAnnotationInfo * const _foo_igen_bar_signal_info_test_signal_ARG_arg_array_of_strings_annotation_info_pointers[] =
813 {
814   &_foo_igen_bar_signal_info_test_signal_ARG_arg_array_of_strings_annotation_info_0,
815   NULL
816 };
817
818 static const _ExtendedGDBusArgInfo _foo_igen_bar_signal_info_test_signal_ARG_array_of_strings =
819 {
820   {
821     -1,
822     "array_of_strings",
823     "as",
824     (GDBusAnnotationInfo **) &_foo_igen_bar_signal_info_test_signal_ARG_arg_array_of_strings_annotation_info_pointers
825   },
826   FALSE
827 };
828
829 static const _ExtendedGDBusArgInfo _foo_igen_bar_signal_info_test_signal_ARG_array_of_bytestrings =
830 {
831   {
832     -1,
833     "array_of_bytestrings",
834     "aay",
835     NULL
836   },
837   FALSE
838 };
839
840 static const _ExtendedGDBusArgInfo _foo_igen_bar_signal_info_test_signal_ARG_dict_s_to_pairs =
841 {
842   {
843     -1,
844     "dict_s_to_pairs",
845     "a{s(ii)}",
846     NULL
847   },
848   FALSE
849 };
850
851 static const _ExtendedGDBusArgInfo * const _foo_igen_bar_signal_info_test_signal_ARG_pointers[] =
852 {
853   &_foo_igen_bar_signal_info_test_signal_ARG_val_int32,
854   &_foo_igen_bar_signal_info_test_signal_ARG_array_of_strings,
855   &_foo_igen_bar_signal_info_test_signal_ARG_array_of_bytestrings,
856   &_foo_igen_bar_signal_info_test_signal_ARG_dict_s_to_pairs,
857   NULL
858 };
859
860 static const GDBusAnnotationInfo _foo_igen_bar_signal_test_signal_annotation_info_0 =
861 {
862   -1,
863   "Key4",
864   "Value4",
865   NULL
866 };
867
868 static const GDBusAnnotationInfo * const _foo_igen_bar_signal_test_signal_annotation_info_pointers[] =
869 {
870   &_foo_igen_bar_signal_test_signal_annotation_info_0,
871   NULL
872 };
873
874 static const _ExtendedGDBusSignalInfo _foo_igen_bar_signal_info_test_signal =
875 {
876   {
877     -1,
878     "TestSignal",
879     (GDBusArgInfo **) &_foo_igen_bar_signal_info_test_signal_ARG_pointers,
880     (GDBusAnnotationInfo **) &_foo_igen_bar_signal_test_signal_annotation_info_pointers
881   },
882   "test-signal"
883 };
884
885 static const _ExtendedGDBusArgInfo _foo_igen_bar_signal_info_another_signal_ARG_word =
886 {
887   {
888     -1,
889     "word",
890     "s",
891     NULL
892   },
893   FALSE
894 };
895
896 static const _ExtendedGDBusArgInfo * const _foo_igen_bar_signal_info_another_signal_ARG_pointers[] =
897 {
898   &_foo_igen_bar_signal_info_another_signal_ARG_word,
899   NULL
900 };
901
902 static const _ExtendedGDBusSignalInfo _foo_igen_bar_signal_info_another_signal =
903 {
904   {
905     -1,
906     "AnotherSignal",
907     (GDBusArgInfo **) &_foo_igen_bar_signal_info_another_signal_ARG_pointers,
908     NULL
909   },
910   "another-signal"
911 };
912
913 static const _ExtendedGDBusSignalInfo * const _foo_igen_bar_signal_info_pointers[] =
914 {
915   &_foo_igen_bar_signal_info_test_signal,
916   &_foo_igen_bar_signal_info_another_signal,
917   NULL
918 };
919
920 static const _ExtendedGDBusPropertyInfo _foo_igen_bar_property_info_y =
921 {
922   {
923     -1,
924     "y",
925     "y",
926     G_DBUS_PROPERTY_INFO_FLAGS_READABLE | G_DBUS_PROPERTY_INFO_FLAGS_WRITABLE,
927     NULL
928   },
929   "y",
930   FALSE
931 };
932
933 static const _ExtendedGDBusPropertyInfo _foo_igen_bar_property_info_b =
934 {
935   {
936     -1,
937     "b",
938     "b",
939     G_DBUS_PROPERTY_INFO_FLAGS_READABLE | G_DBUS_PROPERTY_INFO_FLAGS_WRITABLE,
940     NULL
941   },
942   "b",
943   FALSE
944 };
945
946 static const _ExtendedGDBusPropertyInfo _foo_igen_bar_property_info_n =
947 {
948   {
949     -1,
950     "n",
951     "n",
952     G_DBUS_PROPERTY_INFO_FLAGS_READABLE | G_DBUS_PROPERTY_INFO_FLAGS_WRITABLE,
953     NULL
954   },
955   "n",
956   FALSE
957 };
958
959 static const _ExtendedGDBusPropertyInfo _foo_igen_bar_property_info_q =
960 {
961   {
962     -1,
963     "q",
964     "q",
965     G_DBUS_PROPERTY_INFO_FLAGS_READABLE | G_DBUS_PROPERTY_INFO_FLAGS_WRITABLE,
966     NULL
967   },
968   "q",
969   FALSE
970 };
971
972 static const _ExtendedGDBusPropertyInfo _foo_igen_bar_property_info_i =
973 {
974   {
975     -1,
976     "i",
977     "i",
978     G_DBUS_PROPERTY_INFO_FLAGS_READABLE | G_DBUS_PROPERTY_INFO_FLAGS_WRITABLE,
979     NULL
980   },
981   "i",
982   FALSE
983 };
984
985 static const _ExtendedGDBusPropertyInfo _foo_igen_bar_property_info_u =
986 {
987   {
988     -1,
989     "u",
990     "u",
991     G_DBUS_PROPERTY_INFO_FLAGS_READABLE | G_DBUS_PROPERTY_INFO_FLAGS_WRITABLE,
992     NULL
993   },
994   "u",
995   FALSE
996 };
997
998 static const _ExtendedGDBusPropertyInfo _foo_igen_bar_property_info_x =
999 {
1000   {
1001     -1,
1002     "x",
1003     "x",
1004     G_DBUS_PROPERTY_INFO_FLAGS_READABLE | G_DBUS_PROPERTY_INFO_FLAGS_WRITABLE,
1005     NULL
1006   },
1007   "x",
1008   FALSE
1009 };
1010
1011 static const _ExtendedGDBusPropertyInfo _foo_igen_bar_property_info_t =
1012 {
1013   {
1014     -1,
1015     "t",
1016     "t",
1017     G_DBUS_PROPERTY_INFO_FLAGS_READABLE | G_DBUS_PROPERTY_INFO_FLAGS_WRITABLE,
1018     NULL
1019   },
1020   "t",
1021   FALSE
1022 };
1023
1024 static const _ExtendedGDBusPropertyInfo _foo_igen_bar_property_info_d =
1025 {
1026   {
1027     -1,
1028     "d",
1029     "d",
1030     G_DBUS_PROPERTY_INFO_FLAGS_READABLE | G_DBUS_PROPERTY_INFO_FLAGS_WRITABLE,
1031     NULL
1032   },
1033   "d",
1034   FALSE
1035 };
1036
1037 static const _ExtendedGDBusPropertyInfo _foo_igen_bar_property_info_s =
1038 {
1039   {
1040     -1,
1041     "s",
1042     "s",
1043     G_DBUS_PROPERTY_INFO_FLAGS_READABLE | G_DBUS_PROPERTY_INFO_FLAGS_WRITABLE,
1044     NULL
1045   },
1046   "s",
1047   FALSE
1048 };
1049
1050 static const _ExtendedGDBusPropertyInfo _foo_igen_bar_property_info_o =
1051 {
1052   {
1053     -1,
1054     "o",
1055     "o",
1056     G_DBUS_PROPERTY_INFO_FLAGS_READABLE | G_DBUS_PROPERTY_INFO_FLAGS_WRITABLE,
1057     NULL
1058   },
1059   "o",
1060   FALSE
1061 };
1062
1063 static const _ExtendedGDBusPropertyInfo _foo_igen_bar_property_info_g =
1064 {
1065   {
1066     -1,
1067     "g",
1068     "g",
1069     G_DBUS_PROPERTY_INFO_FLAGS_READABLE | G_DBUS_PROPERTY_INFO_FLAGS_WRITABLE,
1070     NULL
1071   },
1072   "g",
1073   FALSE
1074 };
1075
1076 static const GDBusAnnotationInfo _foo_igen_bar_property_ay_annotation_info_0 =
1077 {
1078   -1,
1079   "Key5",
1080   "Value5",
1081   NULL
1082 };
1083
1084 static const GDBusAnnotationInfo * const _foo_igen_bar_property_ay_annotation_info_pointers[] =
1085 {
1086   &_foo_igen_bar_property_ay_annotation_info_0,
1087   NULL
1088 };
1089
1090 static const _ExtendedGDBusPropertyInfo _foo_igen_bar_property_info_ay =
1091 {
1092   {
1093     -1,
1094     "ay",
1095     "ay",
1096     G_DBUS_PROPERTY_INFO_FLAGS_READABLE | G_DBUS_PROPERTY_INFO_FLAGS_WRITABLE,
1097     (GDBusAnnotationInfo **) &_foo_igen_bar_property_ay_annotation_info_pointers
1098   },
1099   "ay",
1100   FALSE
1101 };
1102
1103 static const _ExtendedGDBusPropertyInfo _foo_igen_bar_property_info_as =
1104 {
1105   {
1106     -1,
1107     "as",
1108     "as",
1109     G_DBUS_PROPERTY_INFO_FLAGS_READABLE | G_DBUS_PROPERTY_INFO_FLAGS_WRITABLE,
1110     NULL
1111   },
1112   "as",
1113   FALSE
1114 };
1115
1116 static const _ExtendedGDBusPropertyInfo _foo_igen_bar_property_info_aay =
1117 {
1118   {
1119     -1,
1120     "aay",
1121     "aay",
1122     G_DBUS_PROPERTY_INFO_FLAGS_READABLE | G_DBUS_PROPERTY_INFO_FLAGS_WRITABLE,
1123     NULL
1124   },
1125   "aay",
1126   FALSE
1127 };
1128
1129 static const _ExtendedGDBusPropertyInfo _foo_igen_bar_property_info_ao =
1130 {
1131   {
1132     -1,
1133     "ao",
1134     "ao",
1135     G_DBUS_PROPERTY_INFO_FLAGS_READABLE | G_DBUS_PROPERTY_INFO_FLAGS_WRITABLE,
1136     NULL
1137   },
1138   "ao",
1139   FALSE
1140 };
1141
1142 static const _ExtendedGDBusPropertyInfo _foo_igen_bar_property_info_ag =
1143 {
1144   {
1145     -1,
1146     "ag",
1147     "ag",
1148     G_DBUS_PROPERTY_INFO_FLAGS_READABLE | G_DBUS_PROPERTY_INFO_FLAGS_WRITABLE,
1149     NULL
1150   },
1151   "ag",
1152   FALSE
1153 };
1154
1155 static const _ExtendedGDBusPropertyInfo _foo_igen_bar_property_info_finally_normal_name =
1156 {
1157   {
1158     -1,
1159     "FinallyNormalName",
1160     "s",
1161     G_DBUS_PROPERTY_INFO_FLAGS_READABLE | G_DBUS_PROPERTY_INFO_FLAGS_WRITABLE,
1162     NULL
1163   },
1164   "finally-normal-name",
1165   FALSE
1166 };
1167
1168 static const _ExtendedGDBusPropertyInfo _foo_igen_bar_property_info_readonly_property =
1169 {
1170   {
1171     -1,
1172     "ReadonlyProperty",
1173     "s",
1174     G_DBUS_PROPERTY_INFO_FLAGS_READABLE,
1175     NULL
1176   },
1177   "readonly-property",
1178   FALSE
1179 };
1180
1181 static const _ExtendedGDBusPropertyInfo _foo_igen_bar_property_info_writeonly_property =
1182 {
1183   {
1184     -1,
1185     "WriteonlyProperty",
1186     "s",
1187     G_DBUS_PROPERTY_INFO_FLAGS_WRITABLE,
1188     NULL
1189   },
1190   "writeonly-property",
1191   FALSE
1192 };
1193
1194 static const _ExtendedGDBusPropertyInfo _foo_igen_bar_property_info_unset_i =
1195 {
1196   {
1197     -1,
1198     "unset_i",
1199     "i",
1200     G_DBUS_PROPERTY_INFO_FLAGS_READABLE | G_DBUS_PROPERTY_INFO_FLAGS_WRITABLE,
1201     NULL
1202   },
1203   "unset-i",
1204   FALSE
1205 };
1206
1207 static const _ExtendedGDBusPropertyInfo _foo_igen_bar_property_info_unset_d =
1208 {
1209   {
1210     -1,
1211     "unset_d",
1212     "d",
1213     G_DBUS_PROPERTY_INFO_FLAGS_READABLE | G_DBUS_PROPERTY_INFO_FLAGS_WRITABLE,
1214     NULL
1215   },
1216   "unset-d",
1217   FALSE
1218 };
1219
1220 static const _ExtendedGDBusPropertyInfo _foo_igen_bar_property_info_unset_s =
1221 {
1222   {
1223     -1,
1224     "unset_s",
1225     "s",
1226     G_DBUS_PROPERTY_INFO_FLAGS_READABLE | G_DBUS_PROPERTY_INFO_FLAGS_WRITABLE,
1227     NULL
1228   },
1229   "unset-s",
1230   FALSE
1231 };
1232
1233 static const _ExtendedGDBusPropertyInfo _foo_igen_bar_property_info_unset_o =
1234 {
1235   {
1236     -1,
1237     "unset_o",
1238     "o",
1239     G_DBUS_PROPERTY_INFO_FLAGS_READABLE | G_DBUS_PROPERTY_INFO_FLAGS_WRITABLE,
1240     NULL
1241   },
1242   "unset-o",
1243   FALSE
1244 };
1245
1246 static const _ExtendedGDBusPropertyInfo _foo_igen_bar_property_info_unset_g =
1247 {
1248   {
1249     -1,
1250     "unset_g",
1251     "g",
1252     G_DBUS_PROPERTY_INFO_FLAGS_READABLE | G_DBUS_PROPERTY_INFO_FLAGS_WRITABLE,
1253     NULL
1254   },
1255   "unset-g",
1256   FALSE
1257 };
1258
1259 static const _ExtendedGDBusPropertyInfo _foo_igen_bar_property_info_unset_ay =
1260 {
1261   {
1262     -1,
1263     "unset_ay",
1264     "ay",
1265     G_DBUS_PROPERTY_INFO_FLAGS_READABLE | G_DBUS_PROPERTY_INFO_FLAGS_WRITABLE,
1266     NULL
1267   },
1268   "unset-ay",
1269   FALSE
1270 };
1271
1272 static const _ExtendedGDBusPropertyInfo _foo_igen_bar_property_info_unset_as =
1273 {
1274   {
1275     -1,
1276     "unset_as",
1277     "as",
1278     G_DBUS_PROPERTY_INFO_FLAGS_READABLE | G_DBUS_PROPERTY_INFO_FLAGS_WRITABLE,
1279     NULL
1280   },
1281   "unset-as",
1282   FALSE
1283 };
1284
1285 static const _ExtendedGDBusPropertyInfo _foo_igen_bar_property_info_unset_ao =
1286 {
1287   {
1288     -1,
1289     "unset_ao",
1290     "ao",
1291     G_DBUS_PROPERTY_INFO_FLAGS_READABLE | G_DBUS_PROPERTY_INFO_FLAGS_WRITABLE,
1292     NULL
1293   },
1294   "unset-ao",
1295   FALSE
1296 };
1297
1298 static const _ExtendedGDBusPropertyInfo _foo_igen_bar_property_info_unset_ag =
1299 {
1300   {
1301     -1,
1302     "unset_ag",
1303     "ag",
1304     G_DBUS_PROPERTY_INFO_FLAGS_READABLE | G_DBUS_PROPERTY_INFO_FLAGS_WRITABLE,
1305     NULL
1306   },
1307   "unset-ag",
1308   FALSE
1309 };
1310
1311 static const _ExtendedGDBusPropertyInfo _foo_igen_bar_property_info_unset_struct =
1312 {
1313   {
1314     -1,
1315     "unset_struct",
1316     "(idsogayasaoag)",
1317     G_DBUS_PROPERTY_INFO_FLAGS_READABLE | G_DBUS_PROPERTY_INFO_FLAGS_WRITABLE,
1318     NULL
1319   },
1320   "unset-struct",
1321   FALSE
1322 };
1323
1324 static const _ExtendedGDBusPropertyInfo * const _foo_igen_bar_property_info_pointers[] =
1325 {
1326   &_foo_igen_bar_property_info_y,
1327   &_foo_igen_bar_property_info_b,
1328   &_foo_igen_bar_property_info_n,
1329   &_foo_igen_bar_property_info_q,
1330   &_foo_igen_bar_property_info_i,
1331   &_foo_igen_bar_property_info_u,
1332   &_foo_igen_bar_property_info_x,
1333   &_foo_igen_bar_property_info_t,
1334   &_foo_igen_bar_property_info_d,
1335   &_foo_igen_bar_property_info_s,
1336   &_foo_igen_bar_property_info_o,
1337   &_foo_igen_bar_property_info_g,
1338   &_foo_igen_bar_property_info_ay,
1339   &_foo_igen_bar_property_info_as,
1340   &_foo_igen_bar_property_info_aay,
1341   &_foo_igen_bar_property_info_ao,
1342   &_foo_igen_bar_property_info_ag,
1343   &_foo_igen_bar_property_info_finally_normal_name,
1344   &_foo_igen_bar_property_info_readonly_property,
1345   &_foo_igen_bar_property_info_writeonly_property,
1346   &_foo_igen_bar_property_info_unset_i,
1347   &_foo_igen_bar_property_info_unset_d,
1348   &_foo_igen_bar_property_info_unset_s,
1349   &_foo_igen_bar_property_info_unset_o,
1350   &_foo_igen_bar_property_info_unset_g,
1351   &_foo_igen_bar_property_info_unset_ay,
1352   &_foo_igen_bar_property_info_unset_as,
1353   &_foo_igen_bar_property_info_unset_ao,
1354   &_foo_igen_bar_property_info_unset_ag,
1355   &_foo_igen_bar_property_info_unset_struct,
1356   NULL
1357 };
1358
1359 static const GDBusAnnotationInfo _foo_igen_bar_annotation_info_0 =
1360 {
1361   -1,
1362   "Key1",
1363   "Value1",
1364   NULL
1365 };
1366
1367 static const GDBusAnnotationInfo * const _foo_igen_bar_annotation_info_pointers[] =
1368 {
1369   &_foo_igen_bar_annotation_info_0,
1370   NULL
1371 };
1372
1373 static const _ExtendedGDBusInterfaceInfo _foo_igen_bar_interface_info =
1374 {
1375   {
1376     -1,
1377     "org.project.Bar",
1378     (GDBusMethodInfo **) &_foo_igen_bar_method_info_pointers,
1379     (GDBusSignalInfo **) &_foo_igen_bar_signal_info_pointers,
1380     (GDBusPropertyInfo **) &_foo_igen_bar_property_info_pointers,
1381     (GDBusAnnotationInfo **) &_foo_igen_bar_annotation_info_pointers
1382   },
1383   "bar",
1384 };
1385
1386
1387 /**
1388  * foo_igen_bar_interface_info:
1389  *
1390  * Gets a machine-readable description of the <link linkend="gdbus-interface-org-project-Bar.top_of_page">org.project.Bar</link> D-Bus interface.
1391  *
1392  * Returns: (transfer none): A #GDBusInterfaceInfo. Do not free.
1393  */
1394 GDBusInterfaceInfo *
1395 foo_igen_bar_interface_info (void)
1396 {
1397   return (GDBusInterfaceInfo *) &_foo_igen_bar_interface_info;
1398 }
1399
1400 /**
1401  * foo_igen_bar_override_properties:
1402  * @klass: The class structure for a #GObject<!-- -->-derived class.
1403  * @property_id_begin: The property id to assign to the first overridden property.
1404  *
1405  * Overrides all #GObject properties in the #FooiGenBar interface for a concrete class.
1406  * The properties are overridden in the order they are defined.
1407  *
1408  * Returns: The last property id.
1409  */
1410 guint
1411 foo_igen_bar_override_properties (GObjectClass *klass, guint property_id_begin)
1412 {
1413   g_object_class_override_property (klass, property_id_begin++, "y");
1414   g_object_class_override_property (klass, property_id_begin++, "b");
1415   g_object_class_override_property (klass, property_id_begin++, "n");
1416   g_object_class_override_property (klass, property_id_begin++, "q");
1417   g_object_class_override_property (klass, property_id_begin++, "i");
1418   g_object_class_override_property (klass, property_id_begin++, "u");
1419   g_object_class_override_property (klass, property_id_begin++, "x");
1420   g_object_class_override_property (klass, property_id_begin++, "t");
1421   g_object_class_override_property (klass, property_id_begin++, "d");
1422   g_object_class_override_property (klass, property_id_begin++, "s");
1423   g_object_class_override_property (klass, property_id_begin++, "o");
1424   g_object_class_override_property (klass, property_id_begin++, "g");
1425   g_object_class_override_property (klass, property_id_begin++, "ay");
1426   g_object_class_override_property (klass, property_id_begin++, "as");
1427   g_object_class_override_property (klass, property_id_begin++, "aay");
1428   g_object_class_override_property (klass, property_id_begin++, "ao");
1429   g_object_class_override_property (klass, property_id_begin++, "ag");
1430   g_object_class_override_property (klass, property_id_begin++, "finally-normal-name");
1431   g_object_class_override_property (klass, property_id_begin++, "readonly-property");
1432   g_object_class_override_property (klass, property_id_begin++, "writeonly-property");
1433   g_object_class_override_property (klass, property_id_begin++, "unset-i");
1434   g_object_class_override_property (klass, property_id_begin++, "unset-d");
1435   g_object_class_override_property (klass, property_id_begin++, "unset-s");
1436   g_object_class_override_property (klass, property_id_begin++, "unset-o");
1437   g_object_class_override_property (klass, property_id_begin++, "unset-g");
1438   g_object_class_override_property (klass, property_id_begin++, "unset-ay");
1439   g_object_class_override_property (klass, property_id_begin++, "unset-as");
1440   g_object_class_override_property (klass, property_id_begin++, "unset-ao");
1441   g_object_class_override_property (klass, property_id_begin++, "unset-ag");
1442   g_object_class_override_property (klass, property_id_begin++, "unset-struct");
1443   return property_id_begin - 1;
1444 }
1445
1446
1447
1448 /**
1449  * FooiGenBar:
1450  *
1451  * Abstract interface type for the D-Bus interface <link linkend="gdbus-interface-org-project-Bar.top_of_page">org.project.Bar</link>.
1452  */
1453
1454 /**
1455  * FooiGenBarIface:
1456  * @parent_iface: The parent interface.
1457  * @handle_hello_world: Handler for the #FooiGenBar::handle-hello-world signal.
1458  * @handle_property_cancellation: Handler for the #FooiGenBar::handle-property-cancellation signal.
1459  * @handle_request_multi_property_mods: Handler for the #FooiGenBar::handle-request-multi-property-mods signal.
1460  * @handle_request_signal_emission: Handler for the #FooiGenBar::handle-request-signal-emission signal.
1461  * @handle_test_non_primitive_types: Handler for the #FooiGenBar::handle-test-non-primitive-types signal.
1462  * @handle_test_primitive_types: Handler for the #FooiGenBar::handle-test-primitive-types signal.
1463  * @handle_unimplemented_method: Handler for the #FooiGenBar::handle-unimplemented-method signal.
1464  * @get_aay: Getter for the #FooiGenBar:aay property.
1465  * @get_ag: Getter for the #FooiGenBar:ag property.
1466  * @get_ao: Getter for the #FooiGenBar:ao property.
1467  * @get_as: Getter for the #FooiGenBar:as property.
1468  * @get_ay: Getter for the #FooiGenBar:ay property.
1469  * @get_b: Getter for the #FooiGenBar:b property.
1470  * @get_d: Getter for the #FooiGenBar:d property.
1471  * @get_finally_normal_name: Getter for the #FooiGenBar:finally-normal-name property.
1472  * @get_g: Getter for the #FooiGenBar:g property.
1473  * @get_i: Getter for the #FooiGenBar:i property.
1474  * @get_n: Getter for the #FooiGenBar:n property.
1475  * @get_o: Getter for the #FooiGenBar:o property.
1476  * @get_q: Getter for the #FooiGenBar:q property.
1477  * @get_readonly_property: Getter for the #FooiGenBar:readonly-property property.
1478  * @get_s: Getter for the #FooiGenBar:s property.
1479  * @get_t: Getter for the #FooiGenBar:t property.
1480  * @get_u: Getter for the #FooiGenBar:u property.
1481  * @get_unset_ag: Getter for the #FooiGenBar:unset-ag property.
1482  * @get_unset_ao: Getter for the #FooiGenBar:unset-ao property.
1483  * @get_unset_as: Getter for the #FooiGenBar:unset-as property.
1484  * @get_unset_ay: Getter for the #FooiGenBar:unset-ay property.
1485  * @get_unset_d: Getter for the #FooiGenBar:unset-d property.
1486  * @get_unset_g: Getter for the #FooiGenBar:unset-g property.
1487  * @get_unset_i: Getter for the #FooiGenBar:unset-i property.
1488  * @get_unset_o: Getter for the #FooiGenBar:unset-o property.
1489  * @get_unset_s: Getter for the #FooiGenBar:unset-s property.
1490  * @get_unset_struct: Getter for the #FooiGenBar:unset-struct property.
1491  * @get_writeonly_property: Getter for the #FooiGenBar:writeonly-property property.
1492  * @get_x: Getter for the #FooiGenBar:x property.
1493  * @get_y: Getter for the #FooiGenBar:y property.
1494  * @another_signal: Handler for the #FooiGenBar::another-signal signal.
1495  * @test_signal: Handler for the #FooiGenBar::test-signal signal.
1496  *
1497  * Virtual table for the D-Bus interface <link linkend="gdbus-interface-org-project-Bar.top_of_page">org.project.Bar</link>.
1498  */
1499
1500 static void
1501 foo_igen_bar_default_init (FooiGenBarIface *iface)
1502 {
1503   /* GObject signals for incoming D-Bus method calls: */
1504   /**
1505    * FooiGenBar::handle-hello-world:
1506    * @object: A #FooiGenBar.
1507    * @invocation: A #GDBusMethodInvocation.
1508    * @arg_greeting: Argument passed by remote caller.
1509    *
1510    * Signal emitted when a remote caller is invoking the <link linkend="gdbus-method-org-project-Bar.HelloWorld">HelloWorld()</link> D-Bus method.
1511    *
1512    * If a signal handler returns %TRUE, it means the signal handler will handle the invocation (e.g. take a reference to @invocation and eventually call foo_igen_bar_complete_hello_world() or e.g. g_dbus_method_invocation_return_error() on it) and no order signal handlers will run. If no signal handler handles the invocation, the %G_DBUS_ERROR_UNKNOWN_METHOD error is returned.
1513    *
1514    * Returns: %TRUE if the invocation was handled, %FALSE to let other signal handlers run.
1515    */
1516   g_signal_new ("handle-hello-world",
1517     G_TYPE_FROM_INTERFACE (iface),
1518     G_SIGNAL_RUN_LAST,
1519     G_STRUCT_OFFSET (FooiGenBarIface, handle_hello_world),
1520     g_signal_accumulator_true_handled,
1521     NULL,
1522     g_cclosure_marshal_generic,
1523     G_TYPE_BOOLEAN,
1524     2,
1525     G_TYPE_DBUS_METHOD_INVOCATION, G_TYPE_STRING);
1526
1527   /**
1528    * FooiGenBar::handle-test-primitive-types:
1529    * @object: A #FooiGenBar.
1530    * @invocation: A #GDBusMethodInvocation.
1531    * @arg_val_byte: Argument passed by remote caller.
1532    * @arg_val_boolean: Argument passed by remote caller.
1533    * @arg_val_int16: Argument passed by remote caller.
1534    * @arg_val_uint16: Argument passed by remote caller.
1535    * @arg_val_int32: Argument passed by remote caller.
1536    * @arg_val_uint32: Argument passed by remote caller.
1537    * @arg_val_int64: Argument passed by remote caller.
1538    * @arg_val_uint64: Argument passed by remote caller.
1539    * @arg_val_double: Argument passed by remote caller.
1540    * @arg_val_string: Argument passed by remote caller.
1541    * @arg_val_objpath: Argument passed by remote caller.
1542    * @arg_val_signature: Argument passed by remote caller.
1543    * @arg_val_bytestring: Argument passed by remote caller.
1544    *
1545    * Signal emitted when a remote caller is invoking the <link linkend="gdbus-method-org-project-Bar.TestPrimitiveTypes">TestPrimitiveTypes()</link> D-Bus method.
1546    *
1547    * If a signal handler returns %TRUE, it means the signal handler will handle the invocation (e.g. take a reference to @invocation and eventually call foo_igen_bar_complete_test_primitive_types() or e.g. g_dbus_method_invocation_return_error() on it) and no order signal handlers will run. If no signal handler handles the invocation, the %G_DBUS_ERROR_UNKNOWN_METHOD error is returned.
1548    *
1549    * Returns: %TRUE if the invocation was handled, %FALSE to let other signal handlers run.
1550    */
1551   g_signal_new ("handle-test-primitive-types",
1552     G_TYPE_FROM_INTERFACE (iface),
1553     G_SIGNAL_RUN_LAST,
1554     G_STRUCT_OFFSET (FooiGenBarIface, handle_test_primitive_types),
1555     g_signal_accumulator_true_handled,
1556     NULL,
1557     g_cclosure_marshal_generic,
1558     G_TYPE_BOOLEAN,
1559     14,
1560     G_TYPE_DBUS_METHOD_INVOCATION, G_TYPE_UCHAR, G_TYPE_BOOLEAN, G_TYPE_INT, G_TYPE_UINT, G_TYPE_INT, G_TYPE_UINT, G_TYPE_INT64, G_TYPE_UINT64, G_TYPE_DOUBLE, G_TYPE_STRING, G_TYPE_STRING, G_TYPE_STRING, G_TYPE_STRING);
1561
1562   /**
1563    * FooiGenBar::handle-test-non-primitive-types:
1564    * @object: A #FooiGenBar.
1565    * @invocation: A #GDBusMethodInvocation.
1566    * @arg_dict_s_to_s: Argument passed by remote caller.
1567    * @arg_dict_s_to_pairs: Argument passed by remote caller.
1568    * @arg_a_struct: Argument passed by remote caller.
1569    * @arg_array_of_strings: Argument passed by remote caller.
1570    * @arg_array_of_objpaths: Argument passed by remote caller.
1571    * @arg_array_of_signatures: Argument passed by remote caller.
1572    * @arg_array_of_bytestrings: Argument passed by remote caller.
1573    *
1574    * Signal emitted when a remote caller is invoking the <link linkend="gdbus-method-org-project-Bar.TestNonPrimitiveTypes">TestNonPrimitiveTypes()</link> D-Bus method.
1575    *
1576    * If a signal handler returns %TRUE, it means the signal handler will handle the invocation (e.g. take a reference to @invocation and eventually call foo_igen_bar_complete_test_non_primitive_types() or e.g. g_dbus_method_invocation_return_error() on it) and no order signal handlers will run. If no signal handler handles the invocation, the %G_DBUS_ERROR_UNKNOWN_METHOD error is returned.
1577    *
1578    * Returns: %TRUE if the invocation was handled, %FALSE to let other signal handlers run.
1579    */
1580   g_signal_new ("handle-test-non-primitive-types",
1581     G_TYPE_FROM_INTERFACE (iface),
1582     G_SIGNAL_RUN_LAST,
1583     G_STRUCT_OFFSET (FooiGenBarIface, handle_test_non_primitive_types),
1584     g_signal_accumulator_true_handled,
1585     NULL,
1586     g_cclosure_marshal_generic,
1587     G_TYPE_BOOLEAN,
1588     8,
1589     G_TYPE_DBUS_METHOD_INVOCATION, G_TYPE_VARIANT, G_TYPE_VARIANT, G_TYPE_VARIANT, G_TYPE_STRV, G_TYPE_STRV, G_TYPE_VARIANT, G_TYPE_STRV);
1590
1591   /**
1592    * FooiGenBar::handle-request-signal-emission:
1593    * @object: A #FooiGenBar.
1594    * @invocation: A #GDBusMethodInvocation.
1595    * @arg_which_one: Argument passed by remote caller.
1596    *
1597    * Signal emitted when a remote caller is invoking the <link linkend="gdbus-method-org-project-Bar.RequestSignalEmission">RequestSignalEmission()</link> D-Bus method.
1598    *
1599    * If a signal handler returns %TRUE, it means the signal handler will handle the invocation (e.g. take a reference to @invocation and eventually call foo_igen_bar_complete_request_signal_emission() or e.g. g_dbus_method_invocation_return_error() on it) and no order signal handlers will run. If no signal handler handles the invocation, the %G_DBUS_ERROR_UNKNOWN_METHOD error is returned.
1600    *
1601    * Returns: %TRUE if the invocation was handled, %FALSE to let other signal handlers run.
1602    */
1603   g_signal_new ("handle-request-signal-emission",
1604     G_TYPE_FROM_INTERFACE (iface),
1605     G_SIGNAL_RUN_LAST,
1606     G_STRUCT_OFFSET (FooiGenBarIface, handle_request_signal_emission),
1607     g_signal_accumulator_true_handled,
1608     NULL,
1609     g_cclosure_marshal_generic,
1610     G_TYPE_BOOLEAN,
1611     2,
1612     G_TYPE_DBUS_METHOD_INVOCATION, G_TYPE_INT);
1613
1614   /**
1615    * FooiGenBar::handle-request-multi-property-mods:
1616    * @object: A #FooiGenBar.
1617    * @invocation: A #GDBusMethodInvocation.
1618    *
1619    * Signal emitted when a remote caller is invoking the <link linkend="gdbus-method-org-project-Bar.RequestMultiPropertyMods">RequestMultiPropertyMods()</link> D-Bus method.
1620    *
1621    * If a signal handler returns %TRUE, it means the signal handler will handle the invocation (e.g. take a reference to @invocation and eventually call foo_igen_bar_complete_request_multi_property_mods() or e.g. g_dbus_method_invocation_return_error() on it) and no order signal handlers will run. If no signal handler handles the invocation, the %G_DBUS_ERROR_UNKNOWN_METHOD error is returned.
1622    *
1623    * Returns: %TRUE if the invocation was handled, %FALSE to let other signal handlers run.
1624    */
1625   g_signal_new ("handle-request-multi-property-mods",
1626     G_TYPE_FROM_INTERFACE (iface),
1627     G_SIGNAL_RUN_LAST,
1628     G_STRUCT_OFFSET (FooiGenBarIface, handle_request_multi_property_mods),
1629     g_signal_accumulator_true_handled,
1630     NULL,
1631     g_cclosure_marshal_generic,
1632     G_TYPE_BOOLEAN,
1633     1,
1634     G_TYPE_DBUS_METHOD_INVOCATION);
1635
1636   /**
1637    * FooiGenBar::handle-unimplemented-method:
1638    * @object: A #FooiGenBar.
1639    * @invocation: A #GDBusMethodInvocation.
1640    *
1641    * Signal emitted when a remote caller is invoking the <link linkend="gdbus-method-org-project-Bar.UnimplementedMethod">UnimplementedMethod()</link> D-Bus method.
1642    *
1643    * If a signal handler returns %TRUE, it means the signal handler will handle the invocation (e.g. take a reference to @invocation and eventually call foo_igen_bar_complete_unimplemented_method() or e.g. g_dbus_method_invocation_return_error() on it) and no order signal handlers will run. If no signal handler handles the invocation, the %G_DBUS_ERROR_UNKNOWN_METHOD error is returned.
1644    *
1645    * Returns: %TRUE if the invocation was handled, %FALSE to let other signal handlers run.
1646    */
1647   g_signal_new ("handle-unimplemented-method",
1648     G_TYPE_FROM_INTERFACE (iface),
1649     G_SIGNAL_RUN_LAST,
1650     G_STRUCT_OFFSET (FooiGenBarIface, handle_unimplemented_method),
1651     g_signal_accumulator_true_handled,
1652     NULL,
1653     g_cclosure_marshal_generic,
1654     G_TYPE_BOOLEAN,
1655     1,
1656     G_TYPE_DBUS_METHOD_INVOCATION);
1657
1658   /**
1659    * FooiGenBar::handle-property-cancellation:
1660    * @object: A #FooiGenBar.
1661    * @invocation: A #GDBusMethodInvocation.
1662    *
1663    * Signal emitted when a remote caller is invoking the <link linkend="gdbus-method-org-project-Bar.PropertyCancellation">PropertyCancellation()</link> D-Bus method.
1664    *
1665    * If a signal handler returns %TRUE, it means the signal handler will handle the invocation (e.g. take a reference to @invocation and eventually call foo_igen_bar_complete_property_cancellation() or e.g. g_dbus_method_invocation_return_error() on it) and no order signal handlers will run. If no signal handler handles the invocation, the %G_DBUS_ERROR_UNKNOWN_METHOD error is returned.
1666    *
1667    * Returns: %TRUE if the invocation was handled, %FALSE to let other signal handlers run.
1668    */
1669   g_signal_new ("handle-property-cancellation",
1670     G_TYPE_FROM_INTERFACE (iface),
1671     G_SIGNAL_RUN_LAST,
1672     G_STRUCT_OFFSET (FooiGenBarIface, handle_property_cancellation),
1673     g_signal_accumulator_true_handled,
1674     NULL,
1675     g_cclosure_marshal_generic,
1676     G_TYPE_BOOLEAN,
1677     1,
1678     G_TYPE_DBUS_METHOD_INVOCATION);
1679
1680   /* GObject signals for received D-Bus signals: */
1681   /**
1682    * FooiGenBar::test-signal:
1683    * @object: A #FooiGenBar.
1684    * @arg_val_int32: Argument.
1685    * @arg_array_of_strings: Argument.
1686    * @arg_array_of_bytestrings: Argument.
1687    * @arg_dict_s_to_pairs: Argument.
1688    *
1689    * On the client-side, this signal is emitted whenever the D-Bus signal <link linkend="gdbus-signal-org-project-Bar.TestSignal">"TestSignal"</link> is received.
1690    *
1691    * On the service-side, this signal can be used with e.g. g_signal_emit_by_name() to make the object emit the D-Bus signal.
1692    */
1693   g_signal_new ("test-signal",
1694     G_TYPE_FROM_INTERFACE (iface),
1695     G_SIGNAL_RUN_LAST,
1696     G_STRUCT_OFFSET (FooiGenBarIface, test_signal),
1697     NULL,
1698     NULL,
1699     g_cclosure_marshal_generic,
1700     G_TYPE_NONE,
1701     4, G_TYPE_INT, G_TYPE_STRV, G_TYPE_STRV, G_TYPE_VARIANT);
1702
1703   /**
1704    * FooiGenBar::another-signal:
1705    * @object: A #FooiGenBar.
1706    * @arg_word: Argument.
1707    *
1708    * On the client-side, this signal is emitted whenever the D-Bus signal <link linkend="gdbus-signal-org-project-Bar.AnotherSignal">"AnotherSignal"</link> is received.
1709    *
1710    * On the service-side, this signal can be used with e.g. g_signal_emit_by_name() to make the object emit the D-Bus signal.
1711    */
1712   g_signal_new ("another-signal",
1713     G_TYPE_FROM_INTERFACE (iface),
1714     G_SIGNAL_RUN_LAST,
1715     G_STRUCT_OFFSET (FooiGenBarIface, another_signal),
1716     NULL,
1717     NULL,
1718     g_cclosure_marshal_generic,
1719     G_TYPE_NONE,
1720     1, G_TYPE_STRING);
1721
1722   /* GObject properties for D-Bus properties: */
1723   /**
1724    * FooiGenBar:y:
1725    *
1726    * Represents the D-Bus property <link linkend="gdbus-property-org-project-Bar.y">"y"</link>.
1727    *
1728    * Since the D-Bus property for this #GObject property is both readable and writable, it is meaningful to both read from it and write to it on both the service- and client-side.
1729    */
1730   g_object_interface_install_property (iface,
1731     g_param_spec_uchar ("y", "y", "y", 0, 255, 0, G_PARAM_READWRITE | G_PARAM_STATIC_STRINGS));
1732   /**
1733    * FooiGenBar:b:
1734    *
1735    * Represents the D-Bus property <link linkend="gdbus-property-org-project-Bar.b">"b"</link>.
1736    *
1737    * Since the D-Bus property for this #GObject property is both readable and writable, it is meaningful to both read from it and write to it on both the service- and client-side.
1738    */
1739   g_object_interface_install_property (iface,
1740     g_param_spec_boolean ("b", "b", "b", FALSE, G_PARAM_READWRITE | G_PARAM_STATIC_STRINGS));
1741   /**
1742    * FooiGenBar:n:
1743    *
1744    * Represents the D-Bus property <link linkend="gdbus-property-org-project-Bar.n">"n"</link>.
1745    *
1746    * Since the D-Bus property for this #GObject property is both readable and writable, it is meaningful to both read from it and write to it on both the service- and client-side.
1747    */
1748   g_object_interface_install_property (iface,
1749     g_param_spec_int ("n", "n", "n", G_MININT16, G_MAXINT16, 0, G_PARAM_READWRITE | G_PARAM_STATIC_STRINGS));
1750   /**
1751    * FooiGenBar:q:
1752    *
1753    * Represents the D-Bus property <link linkend="gdbus-property-org-project-Bar.q">"q"</link>.
1754    *
1755    * Since the D-Bus property for this #GObject property is both readable and writable, it is meaningful to both read from it and write to it on both the service- and client-side.
1756    */
1757   g_object_interface_install_property (iface,
1758     g_param_spec_uint ("q", "q", "q", 0, G_MAXUINT16, 0, G_PARAM_READWRITE | G_PARAM_STATIC_STRINGS));
1759   /**
1760    * FooiGenBar:i:
1761    *
1762    * Represents the D-Bus property <link linkend="gdbus-property-org-project-Bar.i">"i"</link>.
1763    *
1764    * Since the D-Bus property for this #GObject property is both readable and writable, it is meaningful to both read from it and write to it on both the service- and client-side.
1765    */
1766   g_object_interface_install_property (iface,
1767     g_param_spec_int ("i", "i", "i", G_MININT32, G_MAXINT32, 0, G_PARAM_READWRITE | G_PARAM_STATIC_STRINGS));
1768   /**
1769    * FooiGenBar:u:
1770    *
1771    * Represents the D-Bus property <link linkend="gdbus-property-org-project-Bar.u">"u"</link>.
1772    *
1773    * Since the D-Bus property for this #GObject property is both readable and writable, it is meaningful to both read from it and write to it on both the service- and client-side.
1774    */
1775   g_object_interface_install_property (iface,
1776     g_param_spec_uint ("u", "u", "u", 0, G_MAXUINT32, 0, G_PARAM_READWRITE | G_PARAM_STATIC_STRINGS));
1777   /**
1778    * FooiGenBar:x:
1779    *
1780    * Represents the D-Bus property <link linkend="gdbus-property-org-project-Bar.x">"x"</link>.
1781    *
1782    * Since the D-Bus property for this #GObject property is both readable and writable, it is meaningful to both read from it and write to it on both the service- and client-side.
1783    */
1784   g_object_interface_install_property (iface,
1785     g_param_spec_int64 ("x", "x", "x", G_MININT64, G_MAXINT64, 0, G_PARAM_READWRITE | G_PARAM_STATIC_STRINGS));
1786   /**
1787    * FooiGenBar:t:
1788    *
1789    * Represents the D-Bus property <link linkend="gdbus-property-org-project-Bar.t">"t"</link>.
1790    *
1791    * Since the D-Bus property for this #GObject property is both readable and writable, it is meaningful to both read from it and write to it on both the service- and client-side.
1792    */
1793   g_object_interface_install_property (iface,
1794     g_param_spec_uint64 ("t", "t", "t", 0, G_MAXUINT64, 0, G_PARAM_READWRITE | G_PARAM_STATIC_STRINGS));
1795   /**
1796    * FooiGenBar:d:
1797    *
1798    * Represents the D-Bus property <link linkend="gdbus-property-org-project-Bar.d">"d"</link>.
1799    *
1800    * Since the D-Bus property for this #GObject property is both readable and writable, it is meaningful to both read from it and write to it on both the service- and client-side.
1801    */
1802   g_object_interface_install_property (iface,
1803     g_param_spec_double ("d", "d", "d", -G_MAXDOUBLE, G_MAXDOUBLE, 0.0, G_PARAM_READWRITE | G_PARAM_STATIC_STRINGS));
1804   /**
1805    * FooiGenBar:s:
1806    *
1807    * Represents the D-Bus property <link linkend="gdbus-property-org-project-Bar.s">"s"</link>.
1808    *
1809    * Since the D-Bus property for this #GObject property is both readable and writable, it is meaningful to both read from it and write to it on both the service- and client-side.
1810    */
1811   g_object_interface_install_property (iface,
1812     g_param_spec_string ("s", "s", "s", NULL, G_PARAM_READWRITE | G_PARAM_STATIC_STRINGS));
1813   /**
1814    * FooiGenBar:o:
1815    *
1816    * Represents the D-Bus property <link linkend="gdbus-property-org-project-Bar.o">"o"</link>.
1817    *
1818    * Since the D-Bus property for this #GObject property is both readable and writable, it is meaningful to both read from it and write to it on both the service- and client-side.
1819    */
1820   g_object_interface_install_property (iface,
1821     g_param_spec_string ("o", "o", "o", NULL, G_PARAM_READWRITE | G_PARAM_STATIC_STRINGS));
1822   /**
1823    * FooiGenBar:g:
1824    *
1825    * Represents the D-Bus property <link linkend="gdbus-property-org-project-Bar.g">"g"</link>.
1826    *
1827    * Since the D-Bus property for this #GObject property is both readable and writable, it is meaningful to both read from it and write to it on both the service- and client-side.
1828    */
1829   g_object_interface_install_property (iface,
1830     g_param_spec_string ("g", "g", "g", NULL, G_PARAM_READWRITE | G_PARAM_STATIC_STRINGS));
1831   /**
1832    * FooiGenBar:ay:
1833    *
1834    * Represents the D-Bus property <link linkend="gdbus-property-org-project-Bar.ay">"ay"</link>.
1835    *
1836    * Since the D-Bus property for this #GObject property is both readable and writable, it is meaningful to both read from it and write to it on both the service- and client-side.
1837    */
1838   g_object_interface_install_property (iface,
1839     g_param_spec_string ("ay", "ay", "ay", NULL, G_PARAM_READWRITE | G_PARAM_STATIC_STRINGS));
1840   /**
1841    * FooiGenBar:as:
1842    *
1843    * Represents the D-Bus property <link linkend="gdbus-property-org-project-Bar.as">"as"</link>.
1844    *
1845    * Since the D-Bus property for this #GObject property is both readable and writable, it is meaningful to both read from it and write to it on both the service- and client-side.
1846    */
1847   g_object_interface_install_property (iface,
1848     g_param_spec_boxed ("as", "as", "as", G_TYPE_STRV, G_PARAM_READWRITE | G_PARAM_STATIC_STRINGS));
1849   /**
1850    * FooiGenBar:aay:
1851    *
1852    * Represents the D-Bus property <link linkend="gdbus-property-org-project-Bar.aay">"aay"</link>.
1853    *
1854    * Since the D-Bus property for this #GObject property is both readable and writable, it is meaningful to both read from it and write to it on both the service- and client-side.
1855    */
1856   g_object_interface_install_property (iface,
1857     g_param_spec_boxed ("aay", "aay", "aay", G_TYPE_STRV, G_PARAM_READWRITE | G_PARAM_STATIC_STRINGS));
1858   /**
1859    * FooiGenBar:ao:
1860    *
1861    * Represents the D-Bus property <link linkend="gdbus-property-org-project-Bar.ao">"ao"</link>.
1862    *
1863    * Since the D-Bus property for this #GObject property is both readable and writable, it is meaningful to both read from it and write to it on both the service- and client-side.
1864    */
1865   g_object_interface_install_property (iface,
1866     g_param_spec_boxed ("ao", "ao", "ao", G_TYPE_STRV, G_PARAM_READWRITE | G_PARAM_STATIC_STRINGS));
1867   /**
1868    * FooiGenBar:ag:
1869    *
1870    * Represents the D-Bus property <link linkend="gdbus-property-org-project-Bar.ag">"ag"</link>.
1871    *
1872    * Since the D-Bus property for this #GObject property is both readable and writable, it is meaningful to both read from it and write to it on both the service- and client-side.
1873    */
1874   g_object_interface_install_property (iface,
1875     g_param_spec_variant ("ag", "ag", "ag", G_VARIANT_TYPE ("ag"), NULL, G_PARAM_READWRITE | G_PARAM_STATIC_STRINGS));
1876   /**
1877    * FooiGenBar:finally-normal-name:
1878    *
1879    * Represents the D-Bus property <link linkend="gdbus-property-org-project-Bar.FinallyNormalName">"FinallyNormalName"</link>.
1880    *
1881    * Since the D-Bus property for this #GObject property is both readable and writable, it is meaningful to both read from it and write to it on both the service- and client-side.
1882    */
1883   g_object_interface_install_property (iface,
1884     g_param_spec_string ("finally-normal-name", "FinallyNormalName", "FinallyNormalName", NULL, G_PARAM_READWRITE | G_PARAM_STATIC_STRINGS));
1885   /**
1886    * FooiGenBar:readonly-property:
1887    *
1888    * Represents the D-Bus property <link linkend="gdbus-property-org-project-Bar.ReadonlyProperty">"ReadonlyProperty"</link>.
1889    *
1890    * Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
1891    */
1892   g_object_interface_install_property (iface,
1893     g_param_spec_string ("readonly-property", "ReadonlyProperty", "ReadonlyProperty", NULL, G_PARAM_READWRITE | G_PARAM_STATIC_STRINGS));
1894   /**
1895    * FooiGenBar:writeonly-property:
1896    *
1897    * Represents the D-Bus property <link linkend="gdbus-property-org-project-Bar.WriteonlyProperty">"WriteonlyProperty"</link>.
1898    *
1899    * Since the D-Bus property for this #GObject property is writable but not readable, it is meaningful to write to it on both the client- and service-side. It is only meaningful, however, to read from it on the service-side.
1900    */
1901   g_object_interface_install_property (iface,
1902     g_param_spec_string ("writeonly-property", "WriteonlyProperty", "WriteonlyProperty", NULL, G_PARAM_READWRITE | G_PARAM_STATIC_STRINGS));
1903   /**
1904    * FooiGenBar:unset-i:
1905    *
1906    * Represents the D-Bus property <link linkend="gdbus-property-org-project-Bar.unset_i">"unset_i"</link>.
1907    *
1908    * Since the D-Bus property for this #GObject property is both readable and writable, it is meaningful to both read from it and write to it on both the service- and client-side.
1909    */
1910   g_object_interface_install_property (iface,
1911     g_param_spec_int ("unset-i", "unset_i", "unset_i", G_MININT32, G_MAXINT32, 0, G_PARAM_READWRITE | G_PARAM_STATIC_STRINGS));
1912   /**
1913    * FooiGenBar:unset-d:
1914    *
1915    * Represents the D-Bus property <link linkend="gdbus-property-org-project-Bar.unset_d">"unset_d"</link>.
1916    *
1917    * Since the D-Bus property for this #GObject property is both readable and writable, it is meaningful to both read from it and write to it on both the service- and client-side.
1918    */
1919   g_object_interface_install_property (iface,
1920     g_param_spec_double ("unset-d", "unset_d", "unset_d", -G_MAXDOUBLE, G_MAXDOUBLE, 0.0, G_PARAM_READWRITE | G_PARAM_STATIC_STRINGS));
1921   /**
1922    * FooiGenBar:unset-s:
1923    *
1924    * Represents the D-Bus property <link linkend="gdbus-property-org-project-Bar.unset_s">"unset_s"</link>.
1925    *
1926    * Since the D-Bus property for this #GObject property is both readable and writable, it is meaningful to both read from it and write to it on both the service- and client-side.
1927    */
1928   g_object_interface_install_property (iface,
1929     g_param_spec_string ("unset-s", "unset_s", "unset_s", NULL, G_PARAM_READWRITE | G_PARAM_STATIC_STRINGS));
1930   /**
1931    * FooiGenBar:unset-o:
1932    *
1933    * Represents the D-Bus property <link linkend="gdbus-property-org-project-Bar.unset_o">"unset_o"</link>.
1934    *
1935    * Since the D-Bus property for this #GObject property is both readable and writable, it is meaningful to both read from it and write to it on both the service- and client-side.
1936    */
1937   g_object_interface_install_property (iface,
1938     g_param_spec_string ("unset-o", "unset_o", "unset_o", NULL, G_PARAM_READWRITE | G_PARAM_STATIC_STRINGS));
1939   /**
1940    * FooiGenBar:unset-g:
1941    *
1942    * Represents the D-Bus property <link linkend="gdbus-property-org-project-Bar.unset_g">"unset_g"</link>.
1943    *
1944    * Since the D-Bus property for this #GObject property is both readable and writable, it is meaningful to both read from it and write to it on both the service- and client-side.
1945    */
1946   g_object_interface_install_property (iface,
1947     g_param_spec_string ("unset-g", "unset_g", "unset_g", NULL, G_PARAM_READWRITE | G_PARAM_STATIC_STRINGS));
1948   /**
1949    * FooiGenBar:unset-ay:
1950    *
1951    * Represents the D-Bus property <link linkend="gdbus-property-org-project-Bar.unset_ay">"unset_ay"</link>.
1952    *
1953    * Since the D-Bus property for this #GObject property is both readable and writable, it is meaningful to both read from it and write to it on both the service- and client-side.
1954    */
1955   g_object_interface_install_property (iface,
1956     g_param_spec_string ("unset-ay", "unset_ay", "unset_ay", NULL, G_PARAM_READWRITE | G_PARAM_STATIC_STRINGS));
1957   /**
1958    * FooiGenBar:unset-as:
1959    *
1960    * Represents the D-Bus property <link linkend="gdbus-property-org-project-Bar.unset_as">"unset_as"</link>.
1961    *
1962    * Since the D-Bus property for this #GObject property is both readable and writable, it is meaningful to both read from it and write to it on both the service- and client-side.
1963    */
1964   g_object_interface_install_property (iface,
1965     g_param_spec_boxed ("unset-as", "unset_as", "unset_as", G_TYPE_STRV, G_PARAM_READWRITE | G_PARAM_STATIC_STRINGS));
1966   /**
1967    * FooiGenBar:unset-ao:
1968    *
1969    * Represents the D-Bus property <link linkend="gdbus-property-org-project-Bar.unset_ao">"unset_ao"</link>.
1970    *
1971    * Since the D-Bus property for this #GObject property is both readable and writable, it is meaningful to both read from it and write to it on both the service- and client-side.
1972    */
1973   g_object_interface_install_property (iface,
1974     g_param_spec_boxed ("unset-ao", "unset_ao", "unset_ao", G_TYPE_STRV, G_PARAM_READWRITE | G_PARAM_STATIC_STRINGS));
1975   /**
1976    * FooiGenBar:unset-ag:
1977    *
1978    * Represents the D-Bus property <link linkend="gdbus-property-org-project-Bar.unset_ag">"unset_ag"</link>.
1979    *
1980    * Since the D-Bus property for this #GObject property is both readable and writable, it is meaningful to both read from it and write to it on both the service- and client-side.
1981    */
1982   g_object_interface_install_property (iface,
1983     g_param_spec_variant ("unset-ag", "unset_ag", "unset_ag", G_VARIANT_TYPE ("ag"), NULL, G_PARAM_READWRITE | G_PARAM_STATIC_STRINGS));
1984   /**
1985    * FooiGenBar:unset-struct:
1986    *
1987    * Represents the D-Bus property <link linkend="gdbus-property-org-project-Bar.unset_struct">"unset_struct"</link>.
1988    *
1989    * Since the D-Bus property for this #GObject property is both readable and writable, it is meaningful to both read from it and write to it on both the service- and client-side.
1990    */
1991   g_object_interface_install_property (iface,
1992     g_param_spec_variant ("unset-struct", "unset_struct", "unset_struct", G_VARIANT_TYPE ("(idsogayasaoag)"), NULL, G_PARAM_READWRITE | G_PARAM_STATIC_STRINGS));
1993 }
1994
1995 typedef FooiGenBarIface FooiGenBarInterface;
1996 G_DEFINE_INTERFACE (FooiGenBar, foo_igen_bar, G_TYPE_OBJECT);
1997
1998 /**
1999  * foo_igen_bar_get_y: (skip)
2000  * @object: A #FooiGenBar.
2001  *
2002  * Gets the value of the <link linkend="gdbus-property-org-project-Bar.y">"y"</link> D-Bus property.
2003  *
2004  * Since this D-Bus property is both readable and writable, it is meaningful to use this function on both the client- and service-side.
2005  *
2006  * Returns: The property value.
2007  */
2008 guchar 
2009 foo_igen_bar_get_y (FooiGenBar *object)
2010 {
2011   return FOO_IGEN_BAR_GET_IFACE (object)->get_y (object);
2012 }
2013
2014 /**
2015  * foo_igen_bar_set_y: (skip)
2016  * @object: A #FooiGenBar.
2017  * @value: The value to set.
2018  *
2019  * Sets the <link linkend="gdbus-property-org-project-Bar.y">"y"</link> D-Bus property to @value.
2020  *
2021  * Since this D-Bus property is both readable and writable, it is meaningful to use this function on both the client- and service-side.
2022  */
2023 void
2024 foo_igen_bar_set_y (FooiGenBar *object, guchar value)
2025 {
2026   g_object_set (G_OBJECT (object), "y", value, NULL);
2027 }
2028
2029 /**
2030  * foo_igen_bar_get_b: (skip)
2031  * @object: A #FooiGenBar.
2032  *
2033  * Gets the value of the <link linkend="gdbus-property-org-project-Bar.b">"b"</link> D-Bus property.
2034  *
2035  * Since this D-Bus property is both readable and writable, it is meaningful to use this function on both the client- and service-side.
2036  *
2037  * Returns: The property value.
2038  */
2039 gboolean 
2040 foo_igen_bar_get_b (FooiGenBar *object)
2041 {
2042   return FOO_IGEN_BAR_GET_IFACE (object)->get_b (object);
2043 }
2044
2045 /**
2046  * foo_igen_bar_set_b: (skip)
2047  * @object: A #FooiGenBar.
2048  * @value: The value to set.
2049  *
2050  * Sets the <link linkend="gdbus-property-org-project-Bar.b">"b"</link> D-Bus property to @value.
2051  *
2052  * Since this D-Bus property is both readable and writable, it is meaningful to use this function on both the client- and service-side.
2053  */
2054 void
2055 foo_igen_bar_set_b (FooiGenBar *object, gboolean value)
2056 {
2057   g_object_set (G_OBJECT (object), "b", value, NULL);
2058 }
2059
2060 /**
2061  * foo_igen_bar_get_n: (skip)
2062  * @object: A #FooiGenBar.
2063  *
2064  * Gets the value of the <link linkend="gdbus-property-org-project-Bar.n">"n"</link> D-Bus property.
2065  *
2066  * Since this D-Bus property is both readable and writable, it is meaningful to use this function on both the client- and service-side.
2067  *
2068  * Returns: The property value.
2069  */
2070 gint16 
2071 foo_igen_bar_get_n (FooiGenBar *object)
2072 {
2073   return FOO_IGEN_BAR_GET_IFACE (object)->get_n (object);
2074 }
2075
2076 /**
2077  * foo_igen_bar_set_n: (skip)
2078  * @object: A #FooiGenBar.
2079  * @value: The value to set.
2080  *
2081  * Sets the <link linkend="gdbus-property-org-project-Bar.n">"n"</link> D-Bus property to @value.
2082  *
2083  * Since this D-Bus property is both readable and writable, it is meaningful to use this function on both the client- and service-side.
2084  */
2085 void
2086 foo_igen_bar_set_n (FooiGenBar *object, gint16 value)
2087 {
2088   g_object_set (G_OBJECT (object), "n", value, NULL);
2089 }
2090
2091 /**
2092  * foo_igen_bar_get_q: (skip)
2093  * @object: A #FooiGenBar.
2094  *
2095  * Gets the value of the <link linkend="gdbus-property-org-project-Bar.q">"q"</link> D-Bus property.
2096  *
2097  * Since this D-Bus property is both readable and writable, it is meaningful to use this function on both the client- and service-side.
2098  *
2099  * Returns: The property value.
2100  */
2101 guint16 
2102 foo_igen_bar_get_q (FooiGenBar *object)
2103 {
2104   return FOO_IGEN_BAR_GET_IFACE (object)->get_q (object);
2105 }
2106
2107 /**
2108  * foo_igen_bar_set_q: (skip)
2109  * @object: A #FooiGenBar.
2110  * @value: The value to set.
2111  *
2112  * Sets the <link linkend="gdbus-property-org-project-Bar.q">"q"</link> D-Bus property to @value.
2113  *
2114  * Since this D-Bus property is both readable and writable, it is meaningful to use this function on both the client- and service-side.
2115  */
2116 void
2117 foo_igen_bar_set_q (FooiGenBar *object, guint16 value)
2118 {
2119   g_object_set (G_OBJECT (object), "q", value, NULL);
2120 }
2121
2122 /**
2123  * foo_igen_bar_get_i: (skip)
2124  * @object: A #FooiGenBar.
2125  *
2126  * Gets the value of the <link linkend="gdbus-property-org-project-Bar.i">"i"</link> D-Bus property.
2127  *
2128  * Since this D-Bus property is both readable and writable, it is meaningful to use this function on both the client- and service-side.
2129  *
2130  * Returns: The property value.
2131  */
2132 gint 
2133 foo_igen_bar_get_i (FooiGenBar *object)
2134 {
2135   return FOO_IGEN_BAR_GET_IFACE (object)->get_i (object);
2136 }
2137
2138 /**
2139  * foo_igen_bar_set_i: (skip)
2140  * @object: A #FooiGenBar.
2141  * @value: The value to set.
2142  *
2143  * Sets the <link linkend="gdbus-property-org-project-Bar.i">"i"</link> D-Bus property to @value.
2144  *
2145  * Since this D-Bus property is both readable and writable, it is meaningful to use this function on both the client- and service-side.
2146  */
2147 void
2148 foo_igen_bar_set_i (FooiGenBar *object, gint value)
2149 {
2150   g_object_set (G_OBJECT (object), "i", value, NULL);
2151 }
2152
2153 /**
2154  * foo_igen_bar_get_u: (skip)
2155  * @object: A #FooiGenBar.
2156  *
2157  * Gets the value of the <link linkend="gdbus-property-org-project-Bar.u">"u"</link> D-Bus property.
2158  *
2159  * Since this D-Bus property is both readable and writable, it is meaningful to use this function on both the client- and service-side.
2160  *
2161  * Returns: The property value.
2162  */
2163 guint 
2164 foo_igen_bar_get_u (FooiGenBar *object)
2165 {
2166   return FOO_IGEN_BAR_GET_IFACE (object)->get_u (object);
2167 }
2168
2169 /**
2170  * foo_igen_bar_set_u: (skip)
2171  * @object: A #FooiGenBar.
2172  * @value: The value to set.
2173  *
2174  * Sets the <link linkend="gdbus-property-org-project-Bar.u">"u"</link> D-Bus property to @value.
2175  *
2176  * Since this D-Bus property is both readable and writable, it is meaningful to use this function on both the client- and service-side.
2177  */
2178 void
2179 foo_igen_bar_set_u (FooiGenBar *object, guint value)
2180 {
2181   g_object_set (G_OBJECT (object), "u", value, NULL);
2182 }
2183
2184 /**
2185  * foo_igen_bar_get_x: (skip)
2186  * @object: A #FooiGenBar.
2187  *
2188  * Gets the value of the <link linkend="gdbus-property-org-project-Bar.x">"x"</link> D-Bus property.
2189  *
2190  * Since this D-Bus property is both readable and writable, it is meaningful to use this function on both the client- and service-side.
2191  *
2192  * Returns: The property value.
2193  */
2194 gint64 
2195 foo_igen_bar_get_x (FooiGenBar *object)
2196 {
2197   return FOO_IGEN_BAR_GET_IFACE (object)->get_x (object);
2198 }
2199
2200 /**
2201  * foo_igen_bar_set_x: (skip)
2202  * @object: A #FooiGenBar.
2203  * @value: The value to set.
2204  *
2205  * Sets the <link linkend="gdbus-property-org-project-Bar.x">"x"</link> D-Bus property to @value.
2206  *
2207  * Since this D-Bus property is both readable and writable, it is meaningful to use this function on both the client- and service-side.
2208  */
2209 void
2210 foo_igen_bar_set_x (FooiGenBar *object, gint64 value)
2211 {
2212   g_object_set (G_OBJECT (object), "x", value, NULL);
2213 }
2214
2215 /**
2216  * foo_igen_bar_get_t: (skip)
2217  * @object: A #FooiGenBar.
2218  *
2219  * Gets the value of the <link linkend="gdbus-property-org-project-Bar.t">"t"</link> D-Bus property.
2220  *
2221  * Since this D-Bus property is both readable and writable, it is meaningful to use this function on both the client- and service-side.
2222  *
2223  * Returns: The property value.
2224  */
2225 guint64 
2226 foo_igen_bar_get_t (FooiGenBar *object)
2227 {
2228   return FOO_IGEN_BAR_GET_IFACE (object)->get_t (object);
2229 }
2230
2231 /**
2232  * foo_igen_bar_set_t: (skip)
2233  * @object: A #FooiGenBar.
2234  * @value: The value to set.
2235  *
2236  * Sets the <link linkend="gdbus-property-org-project-Bar.t">"t"</link> D-Bus property to @value.
2237  *
2238  * Since this D-Bus property is both readable and writable, it is meaningful to use this function on both the client- and service-side.
2239  */
2240 void
2241 foo_igen_bar_set_t (FooiGenBar *object, guint64 value)
2242 {
2243   g_object_set (G_OBJECT (object), "t", value, NULL);
2244 }
2245
2246 /**
2247  * foo_igen_bar_get_d: (skip)
2248  * @object: A #FooiGenBar.
2249  *
2250  * Gets the value of the <link linkend="gdbus-property-org-project-Bar.d">"d"</link> D-Bus property.
2251  *
2252  * Since this D-Bus property is both readable and writable, it is meaningful to use this function on both the client- and service-side.
2253  *
2254  * Returns: The property value.
2255  */
2256 gdouble 
2257 foo_igen_bar_get_d (FooiGenBar *object)
2258 {
2259   return FOO_IGEN_BAR_GET_IFACE (object)->get_d (object);
2260 }
2261
2262 /**
2263  * foo_igen_bar_set_d: (skip)
2264  * @object: A #FooiGenBar.
2265  * @value: The value to set.
2266  *
2267  * Sets the <link linkend="gdbus-property-org-project-Bar.d">"d"</link> D-Bus property to @value.
2268  *
2269  * Since this D-Bus property is both readable and writable, it is meaningful to use this function on both the client- and service-side.
2270  */
2271 void
2272 foo_igen_bar_set_d (FooiGenBar *object, gdouble value)
2273 {
2274   g_object_set (G_OBJECT (object), "d", value, NULL);
2275 }
2276
2277 /**
2278  * foo_igen_bar_get_s: (skip)
2279  * @object: A #FooiGenBar.
2280  *
2281  * Gets the value of the <link linkend="gdbus-property-org-project-Bar.s">"s"</link> D-Bus property.
2282  *
2283  * Since this D-Bus property is both readable and writable, it is meaningful to use this function on both the client- and service-side.
2284  *
2285  * <warning>The returned value is only valid until the property changes so on the client-side it is only safe to use this function on the thread where @object was constructed. Use foo_igen_bar_dup_s() if on another thread.</warning>
2286  *
2287  * Returns: (transfer none): The property value or %NULL if the property is not set. Do not free the returned value, it belongs to @object.
2288  */
2289 const gchar *
2290 foo_igen_bar_get_s (FooiGenBar *object)
2291 {
2292   return FOO_IGEN_BAR_GET_IFACE (object)->get_s (object);
2293 }
2294
2295 /**
2296  * foo_igen_bar_dup_s: (skip)
2297  * @object: A #FooiGenBar.
2298  *
2299  * Gets a copy of the <link linkend="gdbus-property-org-project-Bar.s">"s"</link> D-Bus property.
2300  *
2301  * Since this D-Bus property is both readable and writable, it is meaningful to use this function on both the client- and service-side.
2302  *
2303  * Returns: (transfer full): The property value or %NULL if the property is not set. The returned value should be freed with g_free().
2304  */
2305 gchar *
2306 foo_igen_bar_dup_s (FooiGenBar *object)
2307 {
2308   gchar *value;
2309   g_object_get (G_OBJECT (object), "s", &value, NULL);
2310   return value;
2311 }
2312
2313 /**
2314  * foo_igen_bar_set_s: (skip)
2315  * @object: A #FooiGenBar.
2316  * @value: The value to set.
2317  *
2318  * Sets the <link linkend="gdbus-property-org-project-Bar.s">"s"</link> D-Bus property to @value.
2319  *
2320  * Since this D-Bus property is both readable and writable, it is meaningful to use this function on both the client- and service-side.
2321  */
2322 void
2323 foo_igen_bar_set_s (FooiGenBar *object, const gchar *value)
2324 {
2325   g_object_set (G_OBJECT (object), "s", value, NULL);
2326 }
2327
2328 /**
2329  * foo_igen_bar_get_o: (skip)
2330  * @object: A #FooiGenBar.
2331  *
2332  * Gets the value of the <link linkend="gdbus-property-org-project-Bar.o">"o"</link> D-Bus property.
2333  *
2334  * Since this D-Bus property is both readable and writable, it is meaningful to use this function on both the client- and service-side.
2335  *
2336  * <warning>The returned value is only valid until the property changes so on the client-side it is only safe to use this function on the thread where @object was constructed. Use foo_igen_bar_dup_o() if on another thread.</warning>
2337  *
2338  * Returns: (transfer none): The property value or %NULL if the property is not set. Do not free the returned value, it belongs to @object.
2339  */
2340 const gchar *
2341 foo_igen_bar_get_o (FooiGenBar *object)
2342 {
2343   return FOO_IGEN_BAR_GET_IFACE (object)->get_o (object);
2344 }
2345
2346 /**
2347  * foo_igen_bar_dup_o: (skip)
2348  * @object: A #FooiGenBar.
2349  *
2350  * Gets a copy of the <link linkend="gdbus-property-org-project-Bar.o">"o"</link> D-Bus property.
2351  *
2352  * Since this D-Bus property is both readable and writable, it is meaningful to use this function on both the client- and service-side.
2353  *
2354  * Returns: (transfer full): The property value or %NULL if the property is not set. The returned value should be freed with g_free().
2355  */
2356 gchar *
2357 foo_igen_bar_dup_o (FooiGenBar *object)
2358 {
2359   gchar *value;
2360   g_object_get (G_OBJECT (object), "o", &value, NULL);
2361   return value;
2362 }
2363
2364 /**
2365  * foo_igen_bar_set_o: (skip)
2366  * @object: A #FooiGenBar.
2367  * @value: The value to set.
2368  *
2369  * Sets the <link linkend="gdbus-property-org-project-Bar.o">"o"</link> D-Bus property to @value.
2370  *
2371  * Since this D-Bus property is both readable and writable, it is meaningful to use this function on both the client- and service-side.
2372  */
2373 void
2374 foo_igen_bar_set_o (FooiGenBar *object, const gchar *value)
2375 {
2376   g_object_set (G_OBJECT (object), "o", value, NULL);
2377 }
2378
2379 /**
2380  * foo_igen_bar_get_g: (skip)
2381  * @object: A #FooiGenBar.
2382  *
2383  * Gets the value of the <link linkend="gdbus-property-org-project-Bar.g">"g"</link> D-Bus property.
2384  *
2385  * Since this D-Bus property is both readable and writable, it is meaningful to use this function on both the client- and service-side.
2386  *
2387  * <warning>The returned value is only valid until the property changes so on the client-side it is only safe to use this function on the thread where @object was constructed. Use foo_igen_bar_dup_g() if on another thread.</warning>
2388  *
2389  * Returns: (transfer none): The property value or %NULL if the property is not set. Do not free the returned value, it belongs to @object.
2390  */
2391 const gchar *
2392 foo_igen_bar_get_g (FooiGenBar *object)
2393 {
2394   return FOO_IGEN_BAR_GET_IFACE (object)->get_g (object);
2395 }
2396
2397 /**
2398  * foo_igen_bar_dup_g: (skip)
2399  * @object: A #FooiGenBar.
2400  *
2401  * Gets a copy of the <link linkend="gdbus-property-org-project-Bar.g">"g"</link> D-Bus property.
2402  *
2403  * Since this D-Bus property is both readable and writable, it is meaningful to use this function on both the client- and service-side.
2404  *
2405  * Returns: (transfer full): The property value or %NULL if the property is not set. The returned value should be freed with g_free().
2406  */
2407 gchar *
2408 foo_igen_bar_dup_g (FooiGenBar *object)
2409 {
2410   gchar *value;
2411   g_object_get (G_OBJECT (object), "g", &value, NULL);
2412   return value;
2413 }
2414
2415 /**
2416  * foo_igen_bar_set_g: (skip)
2417  * @object: A #FooiGenBar.
2418  * @value: The value to set.
2419  *
2420  * Sets the <link linkend="gdbus-property-org-project-Bar.g">"g"</link> D-Bus property to @value.
2421  *
2422  * Since this D-Bus property is both readable and writable, it is meaningful to use this function on both the client- and service-side.
2423  */
2424 void
2425 foo_igen_bar_set_g (FooiGenBar *object, const gchar *value)
2426 {
2427   g_object_set (G_OBJECT (object), "g", value, NULL);
2428 }
2429
2430 /**
2431  * foo_igen_bar_get_ay: (skip)
2432  * @object: A #FooiGenBar.
2433  *
2434  * Gets the value of the <link linkend="gdbus-property-org-project-Bar.ay">"ay"</link> D-Bus property.
2435  *
2436  * Since this D-Bus property is both readable and writable, it is meaningful to use this function on both the client- and service-side.
2437  *
2438  * <warning>The returned value is only valid until the property changes so on the client-side it is only safe to use this function on the thread where @object was constructed. Use foo_igen_bar_dup_ay() if on another thread.</warning>
2439  *
2440  * Returns: (transfer none): The property value or %NULL if the property is not set. Do not free the returned value, it belongs to @object.
2441  */
2442 const gchar *
2443 foo_igen_bar_get_ay (FooiGenBar *object)
2444 {
2445   return FOO_IGEN_BAR_GET_IFACE (object)->get_ay (object);
2446 }
2447
2448 /**
2449  * foo_igen_bar_dup_ay: (skip)
2450  * @object: A #FooiGenBar.
2451  *
2452  * Gets a copy of the <link linkend="gdbus-property-org-project-Bar.ay">"ay"</link> D-Bus property.
2453  *
2454  * Since this D-Bus property is both readable and writable, it is meaningful to use this function on both the client- and service-side.
2455  *
2456  * Returns: (transfer full): The property value or %NULL if the property is not set. The returned value should be freed with g_free().
2457  */
2458 gchar *
2459 foo_igen_bar_dup_ay (FooiGenBar *object)
2460 {
2461   gchar *value;
2462   g_object_get (G_OBJECT (object), "ay", &value, NULL);
2463   return value;
2464 }
2465
2466 /**
2467  * foo_igen_bar_set_ay: (skip)
2468  * @object: A #FooiGenBar.
2469  * @value: The value to set.
2470  *
2471  * Sets the <link linkend="gdbus-property-org-project-Bar.ay">"ay"</link> D-Bus property to @value.
2472  *
2473  * Since this D-Bus property is both readable and writable, it is meaningful to use this function on both the client- and service-side.
2474  */
2475 void
2476 foo_igen_bar_set_ay (FooiGenBar *object, const gchar *value)
2477 {
2478   g_object_set (G_OBJECT (object), "ay", value, NULL);
2479 }
2480
2481 /**
2482  * foo_igen_bar_get_as: (skip)
2483  * @object: A #FooiGenBar.
2484  *
2485  * Gets the value of the <link linkend="gdbus-property-org-project-Bar.as">"as"</link> D-Bus property.
2486  *
2487  * Since this D-Bus property is both readable and writable, it is meaningful to use this function on both the client- and service-side.
2488  *
2489  * <warning>The returned value is only valid until the property changes so on the client-side it is only safe to use this function on the thread where @object was constructed. Use foo_igen_bar_dup_as() if on another thread.</warning>
2490  *
2491  * Returns: (transfer none): The property value or %NULL if the property is not set. Do not free the returned value, it belongs to @object.
2492  */
2493 const gchar *const *
2494 foo_igen_bar_get_as (FooiGenBar *object)
2495 {
2496   return FOO_IGEN_BAR_GET_IFACE (object)->get_as (object);
2497 }
2498
2499 /**
2500  * foo_igen_bar_dup_as: (skip)
2501  * @object: A #FooiGenBar.
2502  *
2503  * Gets a copy of the <link linkend="gdbus-property-org-project-Bar.as">"as"</link> D-Bus property.
2504  *
2505  * Since this D-Bus property is both readable and writable, it is meaningful to use this function on both the client- and service-side.
2506  *
2507  * Returns: (transfer full): The property value or %NULL if the property is not set. The returned value should be freed with g_strfreev().
2508  */
2509 gchar **
2510 foo_igen_bar_dup_as (FooiGenBar *object)
2511 {
2512   gchar **value;
2513   g_object_get (G_OBJECT (object), "as", &value, NULL);
2514   return value;
2515 }
2516
2517 /**
2518  * foo_igen_bar_set_as: (skip)
2519  * @object: A #FooiGenBar.
2520  * @value: The value to set.
2521  *
2522  * Sets the <link linkend="gdbus-property-org-project-Bar.as">"as"</link> D-Bus property to @value.
2523  *
2524  * Since this D-Bus property is both readable and writable, it is meaningful to use this function on both the client- and service-side.
2525  */
2526 void
2527 foo_igen_bar_set_as (FooiGenBar *object, const gchar *const *value)
2528 {
2529   g_object_set (G_OBJECT (object), "as", value, NULL);
2530 }
2531
2532 /**
2533  * foo_igen_bar_get_aay: (skip)
2534  * @object: A #FooiGenBar.
2535  *
2536  * Gets the value of the <link linkend="gdbus-property-org-project-Bar.aay">"aay"</link> D-Bus property.
2537  *
2538  * Since this D-Bus property is both readable and writable, it is meaningful to use this function on both the client- and service-side.
2539  *
2540  * <warning>The returned value is only valid until the property changes so on the client-side it is only safe to use this function on the thread where @object was constructed. Use foo_igen_bar_dup_aay() if on another thread.</warning>
2541  *
2542  * Returns: (transfer none): The property value or %NULL if the property is not set. Do not free the returned value, it belongs to @object.
2543  */
2544 const gchar *const *
2545 foo_igen_bar_get_aay (FooiGenBar *object)
2546 {
2547   return FOO_IGEN_BAR_GET_IFACE (object)->get_aay (object);
2548 }
2549
2550 /**
2551  * foo_igen_bar_dup_aay: (skip)
2552  * @object: A #FooiGenBar.
2553  *
2554  * Gets a copy of the <link linkend="gdbus-property-org-project-Bar.aay">"aay"</link> D-Bus property.
2555  *
2556  * Since this D-Bus property is both readable and writable, it is meaningful to use this function on both the client- and service-side.
2557  *
2558  * Returns: (transfer full): The property value or %NULL if the property is not set. The returned value should be freed with g_strfreev().
2559  */
2560 gchar **
2561 foo_igen_bar_dup_aay (FooiGenBar *object)
2562 {
2563   gchar **value;
2564   g_object_get (G_OBJECT (object), "aay", &value, NULL);
2565   return value;
2566 }
2567
2568 /**
2569  * foo_igen_bar_set_aay: (skip)
2570  * @object: A #FooiGenBar.
2571  * @value: The value to set.
2572  *
2573  * Sets the <link linkend="gdbus-property-org-project-Bar.aay">"aay"</link> D-Bus property to @value.
2574  *
2575  * Since this D-Bus property is both readable and writable, it is meaningful to use this function on both the client- and service-side.
2576  */
2577 void
2578 foo_igen_bar_set_aay (FooiGenBar *object, const gchar *const *value)
2579 {
2580   g_object_set (G_OBJECT (object), "aay", value, NULL);
2581 }
2582
2583 /**
2584  * foo_igen_bar_get_ao: (skip)
2585  * @object: A #FooiGenBar.
2586  *
2587  * Gets the value of the <link linkend="gdbus-property-org-project-Bar.ao">"ao"</link> D-Bus property.
2588  *
2589  * Since this D-Bus property is both readable and writable, it is meaningful to use this function on both the client- and service-side.
2590  *
2591  * <warning>The returned value is only valid until the property changes so on the client-side it is only safe to use this function on the thread where @object was constructed. Use foo_igen_bar_dup_ao() if on another thread.</warning>
2592  *
2593  * Returns: (transfer none): The property value or %NULL if the property is not set. Do not free the returned value, it belongs to @object.
2594  */
2595 const gchar *const *
2596 foo_igen_bar_get_ao (FooiGenBar *object)
2597 {
2598   return FOO_IGEN_BAR_GET_IFACE (object)->get_ao (object);
2599 }
2600
2601 /**
2602  * foo_igen_bar_dup_ao: (skip)
2603  * @object: A #FooiGenBar.
2604  *
2605  * Gets a copy of the <link linkend="gdbus-property-org-project-Bar.ao">"ao"</link> D-Bus property.
2606  *
2607  * Since this D-Bus property is both readable and writable, it is meaningful to use this function on both the client- and service-side.
2608  *
2609  * Returns: (transfer full): The property value or %NULL if the property is not set. The returned value should be freed with g_strfreev().
2610  */
2611 gchar **
2612 foo_igen_bar_dup_ao (FooiGenBar *object)
2613 {
2614   gchar **value;
2615   g_object_get (G_OBJECT (object), "ao", &value, NULL);
2616   return value;
2617 }
2618
2619 /**
2620  * foo_igen_bar_set_ao: (skip)
2621  * @object: A #FooiGenBar.
2622  * @value: The value to set.
2623  *
2624  * Sets the <link linkend="gdbus-property-org-project-Bar.ao">"ao"</link> D-Bus property to @value.
2625  *
2626  * Since this D-Bus property is both readable and writable, it is meaningful to use this function on both the client- and service-side.
2627  */
2628 void
2629 foo_igen_bar_set_ao (FooiGenBar *object, const gchar *const *value)
2630 {
2631   g_object_set (G_OBJECT (object), "ao", value, NULL);
2632 }
2633
2634 /**
2635  * foo_igen_bar_get_ag: (skip)
2636  * @object: A #FooiGenBar.
2637  *
2638  * Gets the value of the <link linkend="gdbus-property-org-project-Bar.ag">"ag"</link> D-Bus property.
2639  *
2640  * Since this D-Bus property is both readable and writable, it is meaningful to use this function on both the client- and service-side.
2641  *
2642  * <warning>The returned value is only valid until the property changes so on the client-side it is only safe to use this function on the thread where @object was constructed. Use foo_igen_bar_dup_ag() if on another thread.</warning>
2643  *
2644  * Returns: (transfer none): The property value or %NULL if the property is not set. Do not free the returned value, it belongs to @object.
2645  */
2646 GVariant *
2647 foo_igen_bar_get_ag (FooiGenBar *object)
2648 {
2649   return FOO_IGEN_BAR_GET_IFACE (object)->get_ag (object);
2650 }
2651
2652 /**
2653  * foo_igen_bar_dup_ag: (skip)
2654  * @object: A #FooiGenBar.
2655  *
2656  * Gets a copy of the <link linkend="gdbus-property-org-project-Bar.ag">"ag"</link> D-Bus property.
2657  *
2658  * Since this D-Bus property is both readable and writable, it is meaningful to use this function on both the client- and service-side.
2659  *
2660  * Returns: (transfer full): The property value or %NULL if the property is not set. The returned value should be freed with g_variant_unref().
2661  */
2662 GVariant *
2663 foo_igen_bar_dup_ag (FooiGenBar *object)
2664 {
2665   GVariant *value;
2666   g_object_get (G_OBJECT (object), "ag", &value, NULL);
2667   return value;
2668 }
2669
2670 /**
2671  * foo_igen_bar_set_ag: (skip)
2672  * @object: A #FooiGenBar.
2673  * @value: The value to set.
2674  *
2675  * Sets the <link linkend="gdbus-property-org-project-Bar.ag">"ag"</link> D-Bus property to @value.
2676  *
2677  * Since this D-Bus property is both readable and writable, it is meaningful to use this function on both the client- and service-side.
2678  */
2679 void
2680 foo_igen_bar_set_ag (FooiGenBar *object, GVariant *value)
2681 {
2682   g_object_set (G_OBJECT (object), "ag", value, NULL);
2683 }
2684
2685 /**
2686  * foo_igen_bar_get_finally_normal_name: (skip)
2687  * @object: A #FooiGenBar.
2688  *
2689  * Gets the value of the <link linkend="gdbus-property-org-project-Bar.FinallyNormalName">"FinallyNormalName"</link> D-Bus property.
2690  *
2691  * Since this D-Bus property is both readable and writable, it is meaningful to use this function on both the client- and service-side.
2692  *
2693  * <warning>The returned value is only valid until the property changes so on the client-side it is only safe to use this function on the thread where @object was constructed. Use foo_igen_bar_dup_finally_normal_name() if on another thread.</warning>
2694  *
2695  * Returns: (transfer none): The property value or %NULL if the property is not set. Do not free the returned value, it belongs to @object.
2696  */
2697 const gchar *
2698 foo_igen_bar_get_finally_normal_name (FooiGenBar *object)
2699 {
2700   return FOO_IGEN_BAR_GET_IFACE (object)->get_finally_normal_name (object);
2701 }
2702
2703 /**
2704  * foo_igen_bar_dup_finally_normal_name: (skip)
2705  * @object: A #FooiGenBar.
2706  *
2707  * Gets a copy of the <link linkend="gdbus-property-org-project-Bar.FinallyNormalName">"FinallyNormalName"</link> D-Bus property.
2708  *
2709  * Since this D-Bus property is both readable and writable, it is meaningful to use this function on both the client- and service-side.
2710  *
2711  * Returns: (transfer full): The property value or %NULL if the property is not set. The returned value should be freed with g_free().
2712  */
2713 gchar *
2714 foo_igen_bar_dup_finally_normal_name (FooiGenBar *object)
2715 {
2716   gchar *value;
2717   g_object_get (G_OBJECT (object), "finally-normal-name", &value, NULL);
2718   return value;
2719 }
2720
2721 /**
2722  * foo_igen_bar_set_finally_normal_name: (skip)
2723  * @object: A #FooiGenBar.
2724  * @value: The value to set.
2725  *
2726  * Sets the <link linkend="gdbus-property-org-project-Bar.FinallyNormalName">"FinallyNormalName"</link> D-Bus property to @value.
2727  *
2728  * Since this D-Bus property is both readable and writable, it is meaningful to use this function on both the client- and service-side.
2729  */
2730 void
2731 foo_igen_bar_set_finally_normal_name (FooiGenBar *object, const gchar *value)
2732 {
2733   g_object_set (G_OBJECT (object), "finally-normal-name", value, NULL);
2734 }
2735
2736 /**
2737  * foo_igen_bar_get_readonly_property: (skip)
2738  * @object: A #FooiGenBar.
2739  *
2740  * Gets the value of the <link linkend="gdbus-property-org-project-Bar.ReadonlyProperty">"ReadonlyProperty"</link> D-Bus property.
2741  *
2742  * Since this D-Bus property is readable, it is meaningful to use this function on both the client- and service-side.
2743  *
2744  * <warning>The returned value is only valid until the property changes so on the client-side it is only safe to use this function on the thread where @object was constructed. Use foo_igen_bar_dup_readonly_property() if on another thread.</warning>
2745  *
2746  * Returns: (transfer none): The property value or %NULL if the property is not set. Do not free the returned value, it belongs to @object.
2747  */
2748 const gchar *
2749 foo_igen_bar_get_readonly_property (FooiGenBar *object)
2750 {
2751   return FOO_IGEN_BAR_GET_IFACE (object)->get_readonly_property (object);
2752 }
2753
2754 /**
2755  * foo_igen_bar_dup_readonly_property: (skip)
2756  * @object: A #FooiGenBar.
2757  *
2758  * Gets a copy of the <link linkend="gdbus-property-org-project-Bar.ReadonlyProperty">"ReadonlyProperty"</link> D-Bus property.
2759  *
2760  * Since this D-Bus property is readable, it is meaningful to use this function on both the client- and service-side.
2761  *
2762  * Returns: (transfer full): The property value or %NULL if the property is not set. The returned value should be freed with g_free().
2763  */
2764 gchar *
2765 foo_igen_bar_dup_readonly_property (FooiGenBar *object)
2766 {
2767   gchar *value;
2768   g_object_get (G_OBJECT (object), "readonly-property", &value, NULL);
2769   return value;
2770 }
2771
2772 /**
2773  * foo_igen_bar_set_readonly_property: (skip)
2774  * @object: A #FooiGenBar.
2775  * @value: The value to set.
2776  *
2777  * Sets the <link linkend="gdbus-property-org-project-Bar.ReadonlyProperty">"ReadonlyProperty"</link> D-Bus property to @value.
2778  *
2779  * Since this D-Bus property is not writable, it is only meaningful to use this function on the service-side.
2780  */
2781 void
2782 foo_igen_bar_set_readonly_property (FooiGenBar *object, const gchar *value)
2783 {
2784   g_object_set (G_OBJECT (object), "readonly-property", value, NULL);
2785 }
2786
2787 /**
2788  * foo_igen_bar_get_writeonly_property: (skip)
2789  * @object: A #FooiGenBar.
2790  *
2791  * Gets the value of the <link linkend="gdbus-property-org-project-Bar.WriteonlyProperty">"WriteonlyProperty"</link> D-Bus property.
2792  *
2793  * Since this D-Bus property is not readable, it is only meaningful to use this function on the service-side.
2794  *
2795  * <warning>The returned value is only valid until the property changes so on the client-side it is only safe to use this function on the thread where @object was constructed. Use foo_igen_bar_dup_writeonly_property() if on another thread.</warning>
2796  *
2797  * Returns: (transfer none): The property value or %NULL if the property is not set. Do not free the returned value, it belongs to @object.
2798  */
2799 const gchar *
2800 foo_igen_bar_get_writeonly_property (FooiGenBar *object)
2801 {
2802   return FOO_IGEN_BAR_GET_IFACE (object)->get_writeonly_property (object);
2803 }
2804
2805 /**
2806  * foo_igen_bar_dup_writeonly_property: (skip)
2807  * @object: A #FooiGenBar.
2808  *
2809  * Gets a copy of the <link linkend="gdbus-property-org-project-Bar.WriteonlyProperty">"WriteonlyProperty"</link> D-Bus property.
2810  *
2811  * Since this D-Bus property is not readable, it is only meaningful to use this function on the service-side.
2812  *
2813  * Returns: (transfer full): The property value or %NULL if the property is not set. The returned value should be freed with g_free().
2814  */
2815 gchar *
2816 foo_igen_bar_dup_writeonly_property (FooiGenBar *object)
2817 {
2818   gchar *value;
2819   g_object_get (G_OBJECT (object), "writeonly-property", &value, NULL);
2820   return value;
2821 }
2822
2823 /**
2824  * foo_igen_bar_set_writeonly_property: (skip)
2825  * @object: A #FooiGenBar.
2826  * @value: The value to set.
2827  *
2828  * Sets the <link linkend="gdbus-property-org-project-Bar.WriteonlyProperty">"WriteonlyProperty"</link> D-Bus property to @value.
2829  *
2830  * Since this D-Bus property is writable, it is meaningful to use this function on both the client- and service-side.
2831  */
2832 void
2833 foo_igen_bar_set_writeonly_property (FooiGenBar *object, const gchar *value)
2834 {
2835   g_object_set (G_OBJECT (object), "writeonly-property", value, NULL);
2836 }
2837
2838 /**
2839  * foo_igen_bar_get_unset_i: (skip)
2840  * @object: A #FooiGenBar.
2841  *
2842  * Gets the value of the <link linkend="gdbus-property-org-project-Bar.unset_i">"unset_i"</link> D-Bus property.
2843  *
2844  * Since this D-Bus property is both readable and writable, it is meaningful to use this function on both the client- and service-side.
2845  *
2846  * Returns: The property value.
2847  */
2848 gint 
2849 foo_igen_bar_get_unset_i (FooiGenBar *object)
2850 {
2851   return FOO_IGEN_BAR_GET_IFACE (object)->get_unset_i (object);
2852 }
2853
2854 /**
2855  * foo_igen_bar_set_unset_i: (skip)
2856  * @object: A #FooiGenBar.
2857  * @value: The value to set.
2858  *
2859  * Sets the <link linkend="gdbus-property-org-project-Bar.unset_i">"unset_i"</link> D-Bus property to @value.
2860  *
2861  * Since this D-Bus property is both readable and writable, it is meaningful to use this function on both the client- and service-side.
2862  */
2863 void
2864 foo_igen_bar_set_unset_i (FooiGenBar *object, gint value)
2865 {
2866   g_object_set (G_OBJECT (object), "unset-i", value, NULL);
2867 }
2868
2869 /**
2870  * foo_igen_bar_get_unset_d: (skip)
2871  * @object: A #FooiGenBar.
2872  *
2873  * Gets the value of the <link linkend="gdbus-property-org-project-Bar.unset_d">"unset_d"</link> D-Bus property.
2874  *
2875  * Since this D-Bus property is both readable and writable, it is meaningful to use this function on both the client- and service-side.
2876  *
2877  * Returns: The property value.
2878  */
2879 gdouble 
2880 foo_igen_bar_get_unset_d (FooiGenBar *object)
2881 {
2882   return FOO_IGEN_BAR_GET_IFACE (object)->get_unset_d (object);
2883 }
2884
2885 /**
2886  * foo_igen_bar_set_unset_d: (skip)
2887  * @object: A #FooiGenBar.
2888  * @value: The value to set.
2889  *
2890  * Sets the <link linkend="gdbus-property-org-project-Bar.unset_d">"unset_d"</link> D-Bus property to @value.
2891  *
2892  * Since this D-Bus property is both readable and writable, it is meaningful to use this function on both the client- and service-side.
2893  */
2894 void
2895 foo_igen_bar_set_unset_d (FooiGenBar *object, gdouble value)
2896 {
2897   g_object_set (G_OBJECT (object), "unset-d", value, NULL);
2898 }
2899
2900 /**
2901  * foo_igen_bar_get_unset_s: (skip)
2902  * @object: A #FooiGenBar.
2903  *
2904  * Gets the value of the <link linkend="gdbus-property-org-project-Bar.unset_s">"unset_s"</link> D-Bus property.
2905  *
2906  * Since this D-Bus property is both readable and writable, it is meaningful to use this function on both the client- and service-side.
2907  *
2908  * <warning>The returned value is only valid until the property changes so on the client-side it is only safe to use this function on the thread where @object was constructed. Use foo_igen_bar_dup_unset_s() if on another thread.</warning>
2909  *
2910  * Returns: (transfer none): The property value or %NULL if the property is not set. Do not free the returned value, it belongs to @object.
2911  */
2912 const gchar *
2913 foo_igen_bar_get_unset_s (FooiGenBar *object)
2914 {
2915   return FOO_IGEN_BAR_GET_IFACE (object)->get_unset_s (object);
2916 }
2917
2918 /**
2919  * foo_igen_bar_dup_unset_s: (skip)
2920  * @object: A #FooiGenBar.
2921  *
2922  * Gets a copy of the <link linkend="gdbus-property-org-project-Bar.unset_s">"unset_s"</link> D-Bus property.
2923  *
2924  * Since this D-Bus property is both readable and writable, it is meaningful to use this function on both the client- and service-side.
2925  *
2926  * Returns: (transfer full): The property value or %NULL if the property is not set. The returned value should be freed with g_free().
2927  */
2928 gchar *
2929 foo_igen_bar_dup_unset_s (FooiGenBar *object)
2930 {
2931   gchar *value;
2932   g_object_get (G_OBJECT (object), "unset-s", &value, NULL);
2933   return value;
2934 }
2935
2936 /**
2937  * foo_igen_bar_set_unset_s: (skip)
2938  * @object: A #FooiGenBar.
2939  * @value: The value to set.
2940  *
2941  * Sets the <link linkend="gdbus-property-org-project-Bar.unset_s">"unset_s"</link> D-Bus property to @value.
2942  *
2943  * Since this D-Bus property is both readable and writable, it is meaningful to use this function on both the client- and service-side.
2944  */
2945 void
2946 foo_igen_bar_set_unset_s (FooiGenBar *object, const gchar *value)
2947 {
2948   g_object_set (G_OBJECT (object), "unset-s", value, NULL);
2949 }
2950
2951 /**
2952  * foo_igen_bar_get_unset_o: (skip)
2953  * @object: A #FooiGenBar.
2954  *
2955  * Gets the value of the <link linkend="gdbus-property-org-project-Bar.unset_o">"unset_o"</link> D-Bus property.
2956  *
2957  * Since this D-Bus property is both readable and writable, it is meaningful to use this function on both the client- and service-side.
2958  *
2959  * <warning>The returned value is only valid until the property changes so on the client-side it is only safe to use this function on the thread where @object was constructed. Use foo_igen_bar_dup_unset_o() if on another thread.</warning>
2960  *
2961  * Returns: (transfer none): The property value or %NULL if the property is not set. Do not free the returned value, it belongs to @object.
2962  */
2963 const gchar *
2964 foo_igen_bar_get_unset_o (FooiGenBar *object)
2965 {
2966   return FOO_IGEN_BAR_GET_IFACE (object)->get_unset_o (object);
2967 }
2968
2969 /**
2970  * foo_igen_bar_dup_unset_o: (skip)
2971  * @object: A #FooiGenBar.
2972  *
2973  * Gets a copy of the <link linkend="gdbus-property-org-project-Bar.unset_o">"unset_o"</link> D-Bus property.
2974  *
2975  * Since this D-Bus property is both readable and writable, it is meaningful to use this function on both the client- and service-side.
2976  *
2977  * Returns: (transfer full): The property value or %NULL if the property is not set. The returned value should be freed with g_free().
2978  */
2979 gchar *
2980 foo_igen_bar_dup_unset_o (FooiGenBar *object)
2981 {
2982   gchar *value;
2983   g_object_get (G_OBJECT (object), "unset-o", &value, NULL);
2984   return value;
2985 }
2986
2987 /**
2988  * foo_igen_bar_set_unset_o: (skip)
2989  * @object: A #FooiGenBar.
2990  * @value: The value to set.
2991  *
2992  * Sets the <link linkend="gdbus-property-org-project-Bar.unset_o">"unset_o"</link> D-Bus property to @value.
2993  *
2994  * Since this D-Bus property is both readable and writable, it is meaningful to use this function on both the client- and service-side.
2995  */
2996 void
2997 foo_igen_bar_set_unset_o (FooiGenBar *object, const gchar *value)
2998 {
2999   g_object_set (G_OBJECT (object), "unset-o", value, NULL);
3000 }
3001
3002 /**
3003  * foo_igen_bar_get_unset_g: (skip)
3004  * @object: A #FooiGenBar.
3005  *
3006  * Gets the value of the <link linkend="gdbus-property-org-project-Bar.unset_g">"unset_g"</link> D-Bus property.
3007  *
3008  * Since this D-Bus property is both readable and writable, it is meaningful to use this function on both the client- and service-side.
3009  *
3010  * <warning>The returned value is only valid until the property changes so on the client-side it is only safe to use this function on the thread where @object was constructed. Use foo_igen_bar_dup_unset_g() if on another thread.</warning>
3011  *
3012  * Returns: (transfer none): The property value or %NULL if the property is not set. Do not free the returned value, it belongs to @object.
3013  */
3014 const gchar *
3015 foo_igen_bar_get_unset_g (FooiGenBar *object)
3016 {
3017   return FOO_IGEN_BAR_GET_IFACE (object)->get_unset_g (object);
3018 }
3019
3020 /**
3021  * foo_igen_bar_dup_unset_g: (skip)
3022  * @object: A #FooiGenBar.
3023  *
3024  * Gets a copy of the <link linkend="gdbus-property-org-project-Bar.unset_g">"unset_g"</link> D-Bus property.
3025  *
3026  * Since this D-Bus property is both readable and writable, it is meaningful to use this function on both the client- and service-side.
3027  *
3028  * Returns: (transfer full): The property value or %NULL if the property is not set. The returned value should be freed with g_free().
3029  */
3030 gchar *
3031 foo_igen_bar_dup_unset_g (FooiGenBar *object)
3032 {
3033   gchar *value;
3034   g_object_get (G_OBJECT (object), "unset-g", &value, NULL);
3035   return value;
3036 }
3037
3038 /**
3039  * foo_igen_bar_set_unset_g: (skip)
3040  * @object: A #FooiGenBar.
3041  * @value: The value to set.
3042  *
3043  * Sets the <link linkend="gdbus-property-org-project-Bar.unset_g">"unset_g"</link> D-Bus property to @value.
3044  *
3045  * Since this D-Bus property is both readable and writable, it is meaningful to use this function on both the client- and service-side.
3046  */
3047 void
3048 foo_igen_bar_set_unset_g (FooiGenBar *object, const gchar *value)
3049 {
3050   g_object_set (G_OBJECT (object), "unset-g", value, NULL);
3051 }
3052
3053 /**
3054  * foo_igen_bar_get_unset_ay: (skip)
3055  * @object: A #FooiGenBar.
3056  *
3057  * Gets the value of the <link linkend="gdbus-property-org-project-Bar.unset_ay">"unset_ay"</link> D-Bus property.
3058  *
3059  * Since this D-Bus property is both readable and writable, it is meaningful to use this function on both the client- and service-side.
3060  *
3061  * <warning>The returned value is only valid until the property changes so on the client-side it is only safe to use this function on the thread where @object was constructed. Use foo_igen_bar_dup_unset_ay() if on another thread.</warning>
3062  *
3063  * Returns: (transfer none): The property value or %NULL if the property is not set. Do not free the returned value, it belongs to @object.
3064  */
3065 const gchar *
3066 foo_igen_bar_get_unset_ay (FooiGenBar *object)
3067 {
3068   return FOO_IGEN_BAR_GET_IFACE (object)->get_unset_ay (object);
3069 }
3070
3071 /**
3072  * foo_igen_bar_dup_unset_ay: (skip)
3073  * @object: A #FooiGenBar.
3074  *
3075  * Gets a copy of the <link linkend="gdbus-property-org-project-Bar.unset_ay">"unset_ay"</link> D-Bus property.
3076  *
3077  * Since this D-Bus property is both readable and writable, it is meaningful to use this function on both the client- and service-side.
3078  *
3079  * Returns: (transfer full): The property value or %NULL if the property is not set. The returned value should be freed with g_free().
3080  */
3081 gchar *
3082 foo_igen_bar_dup_unset_ay (FooiGenBar *object)
3083 {
3084   gchar *value;
3085   g_object_get (G_OBJECT (object), "unset-ay", &value, NULL);
3086   return value;
3087 }
3088
3089 /**
3090  * foo_igen_bar_set_unset_ay: (skip)
3091  * @object: A #FooiGenBar.
3092  * @value: The value to set.
3093  *
3094  * Sets the <link linkend="gdbus-property-org-project-Bar.unset_ay">"unset_ay"</link> D-Bus property to @value.
3095  *
3096  * Since this D-Bus property is both readable and writable, it is meaningful to use this function on both the client- and service-side.
3097  */
3098 void
3099 foo_igen_bar_set_unset_ay (FooiGenBar *object, const gchar *value)
3100 {
3101   g_object_set (G_OBJECT (object), "unset-ay", value, NULL);
3102 }
3103
3104 /**
3105  * foo_igen_bar_get_unset_as: (skip)
3106  * @object: A #FooiGenBar.
3107  *
3108  * Gets the value of the <link linkend="gdbus-property-org-project-Bar.unset_as">"unset_as"</link> D-Bus property.
3109  *
3110  * Since this D-Bus property is both readable and writable, it is meaningful to use this function on both the client- and service-side.
3111  *
3112  * <warning>The returned value is only valid until the property changes so on the client-side it is only safe to use this function on the thread where @object was constructed. Use foo_igen_bar_dup_unset_as() if on another thread.</warning>
3113  *
3114  * Returns: (transfer none): The property value or %NULL if the property is not set. Do not free the returned value, it belongs to @object.
3115  */
3116 const gchar *const *
3117 foo_igen_bar_get_unset_as (FooiGenBar *object)
3118 {
3119   return FOO_IGEN_BAR_GET_IFACE (object)->get_unset_as (object);
3120 }
3121
3122 /**
3123  * foo_igen_bar_dup_unset_as: (skip)
3124  * @object: A #FooiGenBar.
3125  *
3126  * Gets a copy of the <link linkend="gdbus-property-org-project-Bar.unset_as">"unset_as"</link> D-Bus property.
3127  *
3128  * Since this D-Bus property is both readable and writable, it is meaningful to use this function on both the client- and service-side.
3129  *
3130  * Returns: (transfer full): The property value or %NULL if the property is not set. The returned value should be freed with g_strfreev().
3131  */
3132 gchar **
3133 foo_igen_bar_dup_unset_as (FooiGenBar *object)
3134 {
3135   gchar **value;
3136   g_object_get (G_OBJECT (object), "unset-as", &value, NULL);
3137   return value;
3138 }
3139
3140 /**
3141  * foo_igen_bar_set_unset_as: (skip)
3142  * @object: A #FooiGenBar.
3143  * @value: The value to set.
3144  *
3145  * Sets the <link linkend="gdbus-property-org-project-Bar.unset_as">"unset_as"</link> D-Bus property to @value.
3146  *
3147  * Since this D-Bus property is both readable and writable, it is meaningful to use this function on both the client- and service-side.
3148  */
3149 void
3150 foo_igen_bar_set_unset_as (FooiGenBar *object, const gchar *const *value)
3151 {
3152   g_object_set (G_OBJECT (object), "unset-as", value, NULL);
3153 }
3154
3155 /**
3156  * foo_igen_bar_get_unset_ao: (skip)
3157  * @object: A #FooiGenBar.
3158  *
3159  * Gets the value of the <link linkend="gdbus-property-org-project-Bar.unset_ao">"unset_ao"</link> D-Bus property.
3160  *
3161  * Since this D-Bus property is both readable and writable, it is meaningful to use this function on both the client- and service-side.
3162  *
3163  * <warning>The returned value is only valid until the property changes so on the client-side it is only safe to use this function on the thread where @object was constructed. Use foo_igen_bar_dup_unset_ao() if on another thread.</warning>
3164  *
3165  * Returns: (transfer none): The property value or %NULL if the property is not set. Do not free the returned value, it belongs to @object.
3166  */
3167 const gchar *const *
3168 foo_igen_bar_get_unset_ao (FooiGenBar *object)
3169 {
3170   return FOO_IGEN_BAR_GET_IFACE (object)->get_unset_ao (object);
3171 }
3172
3173 /**
3174  * foo_igen_bar_dup_unset_ao: (skip)
3175  * @object: A #FooiGenBar.
3176  *
3177  * Gets a copy of the <link linkend="gdbus-property-org-project-Bar.unset_ao">"unset_ao"</link> D-Bus property.
3178  *
3179  * Since this D-Bus property is both readable and writable, it is meaningful to use this function on both the client- and service-side.
3180  *
3181  * Returns: (transfer full): The property value or %NULL if the property is not set. The returned value should be freed with g_strfreev().
3182  */
3183 gchar **
3184 foo_igen_bar_dup_unset_ao (FooiGenBar *object)
3185 {
3186   gchar **value;
3187   g_object_get (G_OBJECT (object), "unset-ao", &value, NULL);
3188   return value;
3189 }
3190
3191 /**
3192  * foo_igen_bar_set_unset_ao: (skip)
3193  * @object: A #FooiGenBar.
3194  * @value: The value to set.
3195  *
3196  * Sets the <link linkend="gdbus-property-org-project-Bar.unset_ao">"unset_ao"</link> D-Bus property to @value.
3197  *
3198  * Since this D-Bus property is both readable and writable, it is meaningful to use this function on both the client- and service-side.
3199  */
3200 void
3201 foo_igen_bar_set_unset_ao (FooiGenBar *object, const gchar *const *value)
3202 {
3203   g_object_set (G_OBJECT (object), "unset-ao", value, NULL);
3204 }
3205
3206 /**
3207  * foo_igen_bar_get_unset_ag: (skip)
3208  * @object: A #FooiGenBar.
3209  *
3210  * Gets the value of the <link linkend="gdbus-property-org-project-Bar.unset_ag">"unset_ag"</link> D-Bus property.
3211  *
3212  * Since this D-Bus property is both readable and writable, it is meaningful to use this function on both the client- and service-side.
3213  *
3214  * <warning>The returned value is only valid until the property changes so on the client-side it is only safe to use this function on the thread where @object was constructed. Use foo_igen_bar_dup_unset_ag() if on another thread.</warning>
3215  *
3216  * Returns: (transfer none): The property value or %NULL if the property is not set. Do not free the returned value, it belongs to @object.
3217  */
3218 GVariant *
3219 foo_igen_bar_get_unset_ag (FooiGenBar *object)
3220 {
3221   return FOO_IGEN_BAR_GET_IFACE (object)->get_unset_ag (object);
3222 }
3223
3224 /**
3225  * foo_igen_bar_dup_unset_ag: (skip)
3226  * @object: A #FooiGenBar.
3227  *
3228  * Gets a copy of the <link linkend="gdbus-property-org-project-Bar.unset_ag">"unset_ag"</link> D-Bus property.
3229  *
3230  * Since this D-Bus property is both readable and writable, it is meaningful to use this function on both the client- and service-side.
3231  *
3232  * Returns: (transfer full): The property value or %NULL if the property is not set. The returned value should be freed with g_variant_unref().
3233  */
3234 GVariant *
3235 foo_igen_bar_dup_unset_ag (FooiGenBar *object)
3236 {
3237   GVariant *value;
3238   g_object_get (G_OBJECT (object), "unset-ag", &value, NULL);
3239   return value;
3240 }
3241
3242 /**
3243  * foo_igen_bar_set_unset_ag: (skip)
3244  * @object: A #FooiGenBar.
3245  * @value: The value to set.
3246  *
3247  * Sets the <link linkend="gdbus-property-org-project-Bar.unset_ag">"unset_ag"</link> D-Bus property to @value.
3248  *
3249  * Since this D-Bus property is both readable and writable, it is meaningful to use this function on both the client- and service-side.
3250  */
3251 void
3252 foo_igen_bar_set_unset_ag (FooiGenBar *object, GVariant *value)
3253 {
3254   g_object_set (G_OBJECT (object), "unset-ag", value, NULL);
3255 }
3256
3257 /**
3258  * foo_igen_bar_get_unset_struct: (skip)
3259  * @object: A #FooiGenBar.
3260  *
3261  * Gets the value of the <link linkend="gdbus-property-org-project-Bar.unset_struct">"unset_struct"</link> D-Bus property.
3262  *
3263  * Since this D-Bus property is both readable and writable, it is meaningful to use this function on both the client- and service-side.
3264  *
3265  * <warning>The returned value is only valid until the property changes so on the client-side it is only safe to use this function on the thread where @object was constructed. Use foo_igen_bar_dup_unset_struct() if on another thread.</warning>
3266  *
3267  * Returns: (transfer none): The property value or %NULL if the property is not set. Do not free the returned value, it belongs to @object.
3268  */
3269 GVariant *
3270 foo_igen_bar_get_unset_struct (FooiGenBar *object)
3271 {
3272   return FOO_IGEN_BAR_GET_IFACE (object)->get_unset_struct (object);
3273 }
3274
3275 /**
3276  * foo_igen_bar_dup_unset_struct: (skip)
3277  * @object: A #FooiGenBar.
3278  *
3279  * Gets a copy of the <link linkend="gdbus-property-org-project-Bar.unset_struct">"unset_struct"</link> D-Bus property.
3280  *
3281  * Since this D-Bus property is both readable and writable, it is meaningful to use this function on both the client- and service-side.
3282  *
3283  * Returns: (transfer full): The property value or %NULL if the property is not set. The returned value should be freed with g_variant_unref().
3284  */
3285 GVariant *
3286 foo_igen_bar_dup_unset_struct (FooiGenBar *object)
3287 {
3288   GVariant *value;
3289   g_object_get (G_OBJECT (object), "unset-struct", &value, NULL);
3290   return value;
3291 }
3292
3293 /**
3294  * foo_igen_bar_set_unset_struct: (skip)
3295  * @object: A #FooiGenBar.
3296  * @value: The value to set.
3297  *
3298  * Sets the <link linkend="gdbus-property-org-project-Bar.unset_struct">"unset_struct"</link> D-Bus property to @value.
3299  *
3300  * Since this D-Bus property is both readable and writable, it is meaningful to use this function on both the client- and service-side.
3301  */
3302 void
3303 foo_igen_bar_set_unset_struct (FooiGenBar *object, GVariant *value)
3304 {
3305   g_object_set (G_OBJECT (object), "unset-struct", value, NULL);
3306 }
3307
3308 /**
3309  * foo_igen_bar_emit_test_signal:
3310  * @object: A #FooiGenBar.
3311  * @arg_val_int32: Argument to pass with the signal.
3312  * @arg_array_of_strings: Argument to pass with the signal.
3313  * @arg_array_of_bytestrings: Argument to pass with the signal.
3314  * @arg_dict_s_to_pairs: Argument to pass with the signal.
3315  *
3316  * Emits the <link linkend="gdbus-signal-org-project-Bar.TestSignal">"TestSignal"</link> D-Bus signal.
3317  */
3318 void
3319 foo_igen_bar_emit_test_signal (
3320     FooiGenBar *object,
3321     gint arg_val_int32,
3322     const gchar *const *arg_array_of_strings,
3323     const gchar *const *arg_array_of_bytestrings,
3324     GVariant *arg_dict_s_to_pairs)
3325 {
3326   g_signal_emit_by_name (object, "test-signal", arg_val_int32, arg_array_of_strings, arg_array_of_bytestrings, arg_dict_s_to_pairs);
3327 }
3328
3329 /**
3330  * foo_igen_bar_emit_another_signal:
3331  * @object: A #FooiGenBar.
3332  * @arg_word: Argument to pass with the signal.
3333  *
3334  * Emits the <link linkend="gdbus-signal-org-project-Bar.AnotherSignal">"AnotherSignal"</link> D-Bus signal.
3335  */
3336 void
3337 foo_igen_bar_emit_another_signal (
3338     FooiGenBar *object,
3339     const gchar *arg_word)
3340 {
3341   g_signal_emit_by_name (object, "another-signal", arg_word);
3342 }
3343
3344 /**
3345  * foo_igen_bar_call_hello_world:
3346  * @proxy: A #FooiGenBarProxy.
3347  * @arg_greeting: Argument to pass with the method invocation.
3348  * @cancellable: (allow-none): A #GCancellable or %NULL.
3349  * @callback: A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
3350  * @user_data: User data to pass to @callback.
3351  *
3352  * Asynchronously invokes the <link linkend="gdbus-method-org-project-Bar.HelloWorld">HelloWorld()</link> D-Bus method on @proxy.
3353  * When the operation is finished, @callback will be invoked in the <link linkend="g-main-context-push-thread-default">thread-default main loop</link> of the thread you are calling this method from.
3354  * You can then call foo_igen_bar_call_hello_world_finish() to get the result of the operation.
3355  *
3356  * See foo_igen_bar_call_hello_world_sync() for the synchronous, blocking version of this method.
3357  */
3358 void
3359 foo_igen_bar_call_hello_world (
3360     FooiGenBar *proxy,
3361     const gchar *arg_greeting,
3362     GCancellable *cancellable,
3363     GAsyncReadyCallback callback,
3364     gpointer user_data)
3365 {
3366   g_dbus_proxy_call (G_DBUS_PROXY (proxy),
3367     "HelloWorld",
3368     g_variant_new ("(s)",
3369                    arg_greeting),
3370     G_DBUS_CALL_FLAGS_NONE,
3371     -1,
3372     cancellable,
3373     callback,
3374     user_data);
3375 }
3376
3377 /**
3378  * foo_igen_bar_call_hello_world_finish:
3379  * @proxy: A #FooiGenBarProxy.
3380  * @out_response: (out): Return location for return parameter or %NULL to ignore.
3381  * @res: The #GAsyncResult obtained from the #GAsyncReadyCallback passed to foo_igen_bar_call_hello_world().
3382  * @error: Return location for error or %NULL.
3383  *
3384  * Finishes an operation started with foo_igen_bar_call_hello_world().
3385  *
3386  * Returns: (skip): %TRUE if the call succeded, %FALSE if @error is set.
3387  */
3388 gboolean
3389 foo_igen_bar_call_hello_world_finish (
3390     FooiGenBar *proxy,
3391     gchar **out_response,
3392     GAsyncResult *res,
3393     GError **error)
3394 {
3395   GVariant *_ret;
3396   _ret = g_dbus_proxy_call_finish (G_DBUS_PROXY (proxy), res, error);
3397   if (_ret == NULL)
3398     goto _out;
3399   g_variant_get (_ret,
3400                  "(s)",
3401                  out_response);
3402   g_variant_unref (_ret);
3403 _out:
3404   return _ret != NULL;
3405 }
3406
3407 /**
3408  * foo_igen_bar_call_hello_world_sync:
3409  * @proxy: A #FooiGenBarProxy.
3410  * @arg_greeting: Argument to pass with the method invocation.
3411  * @out_response: (out): Return location for return parameter or %NULL to ignore.
3412  * @cancellable: (allow-none): A #GCancellable or %NULL.
3413  * @error: Return location for error or %NULL.
3414  *
3415  * Synchronously invokes the <link linkend="gdbus-method-org-project-Bar.HelloWorld">HelloWorld()</link> D-Bus method on @proxy. The calling thread is blocked until a reply is received.
3416  *
3417  * See foo_igen_bar_call_hello_world() for the asynchronous version of this method.
3418  *
3419  * Returns: (skip): %TRUE if the call succeded, %FALSE if @error is set.
3420  */
3421 gboolean
3422 foo_igen_bar_call_hello_world_sync (
3423     FooiGenBar *proxy,
3424     const gchar *arg_greeting,
3425     gchar **out_response,
3426     GCancellable *cancellable,
3427     GError **error)
3428 {
3429   GVariant *_ret;
3430   _ret = g_dbus_proxy_call_sync (G_DBUS_PROXY (proxy),
3431     "HelloWorld",
3432     g_variant_new ("(s)",
3433                    arg_greeting),
3434     G_DBUS_CALL_FLAGS_NONE,
3435     -1,
3436     cancellable,
3437     error);
3438   if (_ret == NULL)
3439     goto _out;
3440   g_variant_get (_ret,
3441                  "(s)",
3442                  out_response);
3443   g_variant_unref (_ret);
3444 _out:
3445   return _ret != NULL;
3446 }
3447
3448 /**
3449  * foo_igen_bar_call_test_primitive_types:
3450  * @proxy: A #FooiGenBarProxy.
3451  * @arg_val_byte: Argument to pass with the method invocation.
3452  * @arg_val_boolean: Argument to pass with the method invocation.
3453  * @arg_val_int16: Argument to pass with the method invocation.
3454  * @arg_val_uint16: Argument to pass with the method invocation.
3455  * @arg_val_int32: Argument to pass with the method invocation.
3456  * @arg_val_uint32: Argument to pass with the method invocation.
3457  * @arg_val_int64: Argument to pass with the method invocation.
3458  * @arg_val_uint64: Argument to pass with the method invocation.
3459  * @arg_val_double: Argument to pass with the method invocation.
3460  * @arg_val_string: Argument to pass with the method invocation.
3461  * @arg_val_objpath: Argument to pass with the method invocation.
3462  * @arg_val_signature: Argument to pass with the method invocation.
3463  * @arg_val_bytestring: Argument to pass with the method invocation.
3464  * @cancellable: (allow-none): A #GCancellable or %NULL.
3465  * @callback: A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
3466  * @user_data: User data to pass to @callback.
3467  *
3468  * Asynchronously invokes the <link linkend="gdbus-method-org-project-Bar.TestPrimitiveTypes">TestPrimitiveTypes()</link> D-Bus method on @proxy.
3469  * When the operation is finished, @callback will be invoked in the <link linkend="g-main-context-push-thread-default">thread-default main loop</link> of the thread you are calling this method from.
3470  * You can then call foo_igen_bar_call_test_primitive_types_finish() to get the result of the operation.
3471  *
3472  * See foo_igen_bar_call_test_primitive_types_sync() for the synchronous, blocking version of this method.
3473  */
3474 void
3475 foo_igen_bar_call_test_primitive_types (
3476     FooiGenBar *proxy,
3477     guchar arg_val_byte,
3478     gboolean arg_val_boolean,
3479     gint16 arg_val_int16,
3480     guint16 arg_val_uint16,
3481     gint arg_val_int32,
3482     guint arg_val_uint32,
3483     gint64 arg_val_int64,
3484     guint64 arg_val_uint64,
3485     gdouble arg_val_double,
3486     const gchar *arg_val_string,
3487     const gchar *arg_val_objpath,
3488     const gchar *arg_val_signature,
3489     const gchar *arg_val_bytestring,
3490     GCancellable *cancellable,
3491     GAsyncReadyCallback callback,
3492     gpointer user_data)
3493 {
3494   g_dbus_proxy_call (G_DBUS_PROXY (proxy),
3495     "TestPrimitiveTypes",
3496     g_variant_new ("(ybnqiuxtdsog^ay)",
3497                    arg_val_byte,
3498                    arg_val_boolean,
3499                    arg_val_int16,
3500                    arg_val_uint16,
3501                    arg_val_int32,
3502                    arg_val_uint32,
3503                    arg_val_int64,
3504                    arg_val_uint64,
3505                    arg_val_double,
3506                    arg_val_string,
3507                    arg_val_objpath,
3508                    arg_val_signature,
3509                    arg_val_bytestring),
3510     G_DBUS_CALL_FLAGS_NONE,
3511     -1,
3512     cancellable,
3513     callback,
3514     user_data);
3515 }
3516
3517 /**
3518  * foo_igen_bar_call_test_primitive_types_finish:
3519  * @proxy: A #FooiGenBarProxy.
3520  * @out_ret_byte: (out): Return location for return parameter or %NULL to ignore.
3521  * @out_ret_boolean: (out): Return location for return parameter or %NULL to ignore.
3522  * @out_ret_int16: (out): Return location for return parameter or %NULL to ignore.
3523  * @out_ret_uint16: (out): Return location for return parameter or %NULL to ignore.
3524  * @out_ret_int32: (out): Return location for return parameter or %NULL to ignore.
3525  * @out_ret_uint32: (out): Return location for return parameter or %NULL to ignore.
3526  * @out_ret_int64: (out): Return location for return parameter or %NULL to ignore.
3527  * @out_ret_uint64: (out): Return location for return parameter or %NULL to ignore.
3528  * @out_ret_double: (out): Return location for return parameter or %NULL to ignore.
3529  * @out_ret_string: (out): Return location for return parameter or %NULL to ignore.
3530  * @out_ret_objpath: (out): Return location for return parameter or %NULL to ignore.
3531  * @out_ret_signature: (out): Return location for return parameter or %NULL to ignore.
3532  * @out_ret_bytestring: (out): Return location for return parameter or %NULL to ignore.
3533  * @res: The #GAsyncResult obtained from the #GAsyncReadyCallback passed to foo_igen_bar_call_test_primitive_types().
3534  * @error: Return location for error or %NULL.
3535  *
3536  * Finishes an operation started with foo_igen_bar_call_test_primitive_types().
3537  *
3538  * Returns: (skip): %TRUE if the call succeded, %FALSE if @error is set.
3539  */
3540 gboolean
3541 foo_igen_bar_call_test_primitive_types_finish (
3542     FooiGenBar *proxy,
3543     guchar *out_ret_byte,
3544     gboolean *out_ret_boolean,
3545     gint16 *out_ret_int16,
3546     guint16 *out_ret_uint16,
3547     gint *out_ret_int32,
3548     guint *out_ret_uint32,
3549     gint64 *out_ret_int64,
3550     guint64 *out_ret_uint64,
3551     gdouble *out_ret_double,
3552     gchar **out_ret_string,
3553     gchar **out_ret_objpath,
3554     gchar **out_ret_signature,
3555     gchar **out_ret_bytestring,
3556     GAsyncResult *res,
3557     GError **error)
3558 {
3559   GVariant *_ret;
3560   _ret = g_dbus_proxy_call_finish (G_DBUS_PROXY (proxy), res, error);
3561   if (_ret == NULL)
3562     goto _out;
3563   g_variant_get (_ret,
3564                  "(ybnqiuxtdsog^ay)",
3565                  out_ret_byte,
3566                  out_ret_boolean,
3567                  out_ret_int16,
3568                  out_ret_uint16,
3569                  out_ret_int32,
3570                  out_ret_uint32,
3571                  out_ret_int64,
3572                  out_ret_uint64,
3573                  out_ret_double,
3574                  out_ret_string,
3575                  out_ret_objpath,
3576                  out_ret_signature,
3577                  out_ret_bytestring);
3578   g_variant_unref (_ret);
3579 _out:
3580   return _ret != NULL;
3581 }
3582
3583 /**
3584  * foo_igen_bar_call_test_primitive_types_sync:
3585  * @proxy: A #FooiGenBarProxy.
3586  * @arg_val_byte: Argument to pass with the method invocation.
3587  * @arg_val_boolean: Argument to pass with the method invocation.
3588  * @arg_val_int16: Argument to pass with the method invocation.
3589  * @arg_val_uint16: Argument to pass with the method invocation.
3590  * @arg_val_int32: Argument to pass with the method invocation.
3591  * @arg_val_uint32: Argument to pass with the method invocation.
3592  * @arg_val_int64: Argument to pass with the method invocation.
3593  * @arg_val_uint64: Argument to pass with the method invocation.
3594  * @arg_val_double: Argument to pass with the method invocation.
3595  * @arg_val_string: Argument to pass with the method invocation.
3596  * @arg_val_objpath: Argument to pass with the method invocation.
3597  * @arg_val_signature: Argument to pass with the method invocation.
3598  * @arg_val_bytestring: Argument to pass with the method invocation.
3599  * @out_ret_byte: (out): Return location for return parameter or %NULL to ignore.
3600  * @out_ret_boolean: (out): Return location for return parameter or %NULL to ignore.
3601  * @out_ret_int16: (out): Return location for return parameter or %NULL to ignore.
3602  * @out_ret_uint16: (out): Return location for return parameter or %NULL to ignore.
3603  * @out_ret_int32: (out): Return location for return parameter or %NULL to ignore.
3604  * @out_ret_uint32: (out): Return location for return parameter or %NULL to ignore.
3605  * @out_ret_int64: (out): Return location for return parameter or %NULL to ignore.
3606  * @out_ret_uint64: (out): Return location for return parameter or %NULL to ignore.
3607  * @out_ret_double: (out): Return location for return parameter or %NULL to ignore.
3608  * @out_ret_string: (out): Return location for return parameter or %NULL to ignore.
3609  * @out_ret_objpath: (out): Return location for return parameter or %NULL to ignore.
3610  * @out_ret_signature: (out): Return location for return parameter or %NULL to ignore.
3611  * @out_ret_bytestring: (out): Return location for return parameter or %NULL to ignore.
3612  * @cancellable: (allow-none): A #GCancellable or %NULL.
3613  * @error: Return location for error or %NULL.
3614  *
3615  * Synchronously invokes the <link linkend="gdbus-method-org-project-Bar.TestPrimitiveTypes">TestPrimitiveTypes()</link> D-Bus method on @proxy. The calling thread is blocked until a reply is received.
3616  *
3617  * See foo_igen_bar_call_test_primitive_types() for the asynchronous version of this method.
3618  *
3619  * Returns: (skip): %TRUE if the call succeded, %FALSE if @error is set.
3620  */
3621 gboolean
3622 foo_igen_bar_call_test_primitive_types_sync (
3623     FooiGenBar *proxy,
3624     guchar arg_val_byte,
3625     gboolean arg_val_boolean,
3626     gint16 arg_val_int16,
3627     guint16 arg_val_uint16,
3628     gint arg_val_int32,
3629     guint arg_val_uint32,
3630     gint64 arg_val_int64,
3631     guint64 arg_val_uint64,
3632     gdouble arg_val_double,
3633     const gchar *arg_val_string,
3634     const gchar *arg_val_objpath,
3635     const gchar *arg_val_signature,
3636     const gchar *arg_val_bytestring,
3637     guchar *out_ret_byte,
3638     gboolean *out_ret_boolean,
3639     gint16 *out_ret_int16,
3640     guint16 *out_ret_uint16,
3641     gint *out_ret_int32,
3642     guint *out_ret_uint32,
3643     gint64 *out_ret_int64,
3644     guint64 *out_ret_uint64,
3645     gdouble *out_ret_double,
3646     gchar **out_ret_string,
3647     gchar **out_ret_objpath,
3648     gchar **out_ret_signature,
3649     gchar **out_ret_bytestring,
3650     GCancellable *cancellable,
3651     GError **error)
3652 {
3653   GVariant *_ret;
3654   _ret = g_dbus_proxy_call_sync (G_DBUS_PROXY (proxy),
3655     "TestPrimitiveTypes",
3656     g_variant_new ("(ybnqiuxtdsog^ay)",
3657                    arg_val_byte,
3658                    arg_val_boolean,
3659                    arg_val_int16,
3660                    arg_val_uint16,
3661                    arg_val_int32,
3662                    arg_val_uint32,
3663                    arg_val_int64,
3664                    arg_val_uint64,
3665                    arg_val_double,
3666                    arg_val_string,
3667                    arg_val_objpath,
3668                    arg_val_signature,
3669                    arg_val_bytestring),
3670     G_DBUS_CALL_FLAGS_NONE,
3671     -1,
3672     cancellable,
3673     error);
3674   if (_ret == NULL)
3675     goto _out;
3676   g_variant_get (_ret,
3677                  "(ybnqiuxtdsog^ay)",
3678                  out_ret_byte,
3679                  out_ret_boolean,
3680                  out_ret_int16,
3681                  out_ret_uint16,
3682                  out_ret_int32,
3683                  out_ret_uint32,
3684                  out_ret_int64,
3685                  out_ret_uint64,
3686                  out_ret_double,
3687                  out_ret_string,
3688                  out_ret_objpath,
3689                  out_ret_signature,
3690                  out_ret_bytestring);
3691   g_variant_unref (_ret);
3692 _out:
3693   return _ret != NULL;
3694 }
3695
3696 /**
3697  * foo_igen_bar_call_test_non_primitive_types:
3698  * @proxy: A #FooiGenBarProxy.
3699  * @arg_dict_s_to_s: Argument to pass with the method invocation.
3700  * @arg_dict_s_to_pairs: Argument to pass with the method invocation.
3701  * @arg_a_struct: Argument to pass with the method invocation.
3702  * @arg_array_of_strings: Argument to pass with the method invocation.
3703  * @arg_array_of_objpaths: Argument to pass with the method invocation.
3704  * @arg_array_of_signatures: Argument to pass with the method invocation.
3705  * @arg_array_of_bytestrings: Argument to pass with the method invocation.
3706  * @cancellable: (allow-none): A #GCancellable or %NULL.
3707  * @callback: A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
3708  * @user_data: User data to pass to @callback.
3709  *
3710  * Asynchronously invokes the <link linkend="gdbus-method-org-project-Bar.TestNonPrimitiveTypes">TestNonPrimitiveTypes()</link> D-Bus method on @proxy.
3711  * When the operation is finished, @callback will be invoked in the <link linkend="g-main-context-push-thread-default">thread-default main loop</link> of the thread you are calling this method from.
3712  * You can then call foo_igen_bar_call_test_non_primitive_types_finish() to get the result of the operation.
3713  *
3714  * See foo_igen_bar_call_test_non_primitive_types_sync() for the synchronous, blocking version of this method.
3715  */
3716 void
3717 foo_igen_bar_call_test_non_primitive_types (
3718     FooiGenBar *proxy,
3719     GVariant *arg_dict_s_to_s,
3720     GVariant *arg_dict_s_to_pairs,
3721     GVariant *arg_a_struct,
3722     const gchar *const *arg_array_of_strings,
3723     const gchar *const *arg_array_of_objpaths,
3724     GVariant *arg_array_of_signatures,
3725     const gchar *const *arg_array_of_bytestrings,
3726     GCancellable *cancellable,
3727     GAsyncReadyCallback callback,
3728     gpointer user_data)
3729 {
3730   g_dbus_proxy_call (G_DBUS_PROXY (proxy),
3731     "TestNonPrimitiveTypes",
3732     g_variant_new ("(@a{ss}@a{s(ii)}@(iss)^as^ao@ag^aay)",
3733                    arg_dict_s_to_s,
3734                    arg_dict_s_to_pairs,
3735                    arg_a_struct,
3736                    arg_array_of_strings,
3737                    arg_array_of_objpaths,
3738                    arg_array_of_signatures,
3739                    arg_array_of_bytestrings),
3740     G_DBUS_CALL_FLAGS_NONE,
3741     -1,
3742     cancellable,
3743     callback,
3744     user_data);
3745 }
3746
3747 /**
3748  * foo_igen_bar_call_test_non_primitive_types_finish:
3749  * @proxy: A #FooiGenBarProxy.
3750  * @out_result: (out): Return location for return parameter or %NULL to ignore.
3751  * @res: The #GAsyncResult obtained from the #GAsyncReadyCallback passed to foo_igen_bar_call_test_non_primitive_types().
3752  * @error: Return location for error or %NULL.
3753  *
3754  * Finishes an operation started with foo_igen_bar_call_test_non_primitive_types().
3755  *
3756  * Returns: (skip): %TRUE if the call succeded, %FALSE if @error is set.
3757  */
3758 gboolean
3759 foo_igen_bar_call_test_non_primitive_types_finish (
3760     FooiGenBar *proxy,
3761     gchar **out_result,
3762     GAsyncResult *res,
3763     GError **error)
3764 {
3765   GVariant *_ret;
3766   _ret = g_dbus_proxy_call_finish (G_DBUS_PROXY (proxy), res, error);
3767   if (_ret == NULL)
3768     goto _out;
3769   g_variant_get (_ret,
3770                  "(^ay)",
3771                  out_result);
3772   g_variant_unref (_ret);
3773 _out:
3774   return _ret != NULL;
3775 }
3776
3777 /**
3778  * foo_igen_bar_call_test_non_primitive_types_sync:
3779  * @proxy: A #FooiGenBarProxy.
3780  * @arg_dict_s_to_s: Argument to pass with the method invocation.
3781  * @arg_dict_s_to_pairs: Argument to pass with the method invocation.
3782  * @arg_a_struct: Argument to pass with the method invocation.
3783  * @arg_array_of_strings: Argument to pass with the method invocation.
3784  * @arg_array_of_objpaths: Argument to pass with the method invocation.
3785  * @arg_array_of_signatures: Argument to pass with the method invocation.
3786  * @arg_array_of_bytestrings: Argument to pass with the method invocation.
3787  * @out_result: (out): Return location for return parameter or %NULL to ignore.
3788  * @cancellable: (allow-none): A #GCancellable or %NULL.
3789  * @error: Return location for error or %NULL.
3790  *
3791  * Synchronously invokes the <link linkend="gdbus-method-org-project-Bar.TestNonPrimitiveTypes">TestNonPrimitiveTypes()</link> D-Bus method on @proxy. The calling thread is blocked until a reply is received.
3792  *
3793  * See foo_igen_bar_call_test_non_primitive_types() for the asynchronous version of this method.
3794  *
3795  * Returns: (skip): %TRUE if the call succeded, %FALSE if @error is set.
3796  */
3797 gboolean
3798 foo_igen_bar_call_test_non_primitive_types_sync (
3799     FooiGenBar *proxy,
3800     GVariant *arg_dict_s_to_s,
3801     GVariant *arg_dict_s_to_pairs,
3802     GVariant *arg_a_struct,
3803     const gchar *const *arg_array_of_strings,
3804     const gchar *const *arg_array_of_objpaths,
3805     GVariant *arg_array_of_signatures,
3806     const gchar *const *arg_array_of_bytestrings,
3807     gchar **out_result,
3808     GCancellable *cancellable,
3809     GError **error)
3810 {
3811   GVariant *_ret;
3812   _ret = g_dbus_proxy_call_sync (G_DBUS_PROXY (proxy),
3813     "TestNonPrimitiveTypes",
3814     g_variant_new ("(@a{ss}@a{s(ii)}@(iss)^as^ao@ag^aay)",
3815                    arg_dict_s_to_s,
3816                    arg_dict_s_to_pairs,
3817                    arg_a_struct,
3818                    arg_array_of_strings,
3819                    arg_array_of_objpaths,
3820                    arg_array_of_signatures,
3821                    arg_array_of_bytestrings),
3822     G_DBUS_CALL_FLAGS_NONE,
3823     -1,
3824     cancellable,
3825     error);
3826   if (_ret == NULL)
3827     goto _out;
3828   g_variant_get (_ret,
3829                  "(^ay)",
3830                  out_result);
3831   g_variant_unref (_ret);
3832 _out:
3833   return _ret != NULL;
3834 }
3835
3836 /**
3837  * foo_igen_bar_call_request_signal_emission:
3838  * @proxy: A #FooiGenBarProxy.
3839  * @arg_which_one: Argument to pass with the method invocation.
3840  * @cancellable: (allow-none): A #GCancellable or %NULL.
3841  * @callback: A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
3842  * @user_data: User data to pass to @callback.
3843  *
3844  * Asynchronously invokes the <link linkend="gdbus-method-org-project-Bar.RequestSignalEmission">RequestSignalEmission()</link> D-Bus method on @proxy.
3845  * When the operation is finished, @callback will be invoked in the <link linkend="g-main-context-push-thread-default">thread-default main loop</link> of the thread you are calling this method from.
3846  * You can then call foo_igen_bar_call_request_signal_emission_finish() to get the result of the operation.
3847  *
3848  * See foo_igen_bar_call_request_signal_emission_sync() for the synchronous, blocking version of this method.
3849  */
3850 void
3851 foo_igen_bar_call_request_signal_emission (
3852     FooiGenBar *proxy,
3853     gint arg_which_one,
3854     GCancellable *cancellable,
3855     GAsyncReadyCallback callback,
3856     gpointer user_data)
3857 {
3858   g_dbus_proxy_call (G_DBUS_PROXY (proxy),
3859     "RequestSignalEmission",
3860     g_variant_new ("(i)",
3861                    arg_which_one),
3862     G_DBUS_CALL_FLAGS_NONE,
3863     -1,
3864     cancellable,
3865     callback,
3866     user_data);
3867 }
3868
3869 /**
3870  * foo_igen_bar_call_request_signal_emission_finish:
3871  * @proxy: A #FooiGenBarProxy.
3872  * @res: The #GAsyncResult obtained from the #GAsyncReadyCallback passed to foo_igen_bar_call_request_signal_emission().
3873  * @error: Return location for error or %NULL.
3874  *
3875  * Finishes an operation started with foo_igen_bar_call_request_signal_emission().
3876  *
3877  * Returns: (skip): %TRUE if the call succeded, %FALSE if @error is set.
3878  */
3879 gboolean
3880 foo_igen_bar_call_request_signal_emission_finish (
3881     FooiGenBar *proxy,
3882     GAsyncResult *res,
3883     GError **error)
3884 {
3885   GVariant *_ret;
3886   _ret = g_dbus_proxy_call_finish (G_DBUS_PROXY (proxy), res, error);
3887   if (_ret == NULL)
3888     goto _out;
3889   g_variant_get (_ret,
3890                  "()");
3891   g_variant_unref (_ret);
3892 _out:
3893   return _ret != NULL;
3894 }
3895
3896 /**
3897  * foo_igen_bar_call_request_signal_emission_sync:
3898  * @proxy: A #FooiGenBarProxy.
3899  * @arg_which_one: Argument to pass with the method invocation.
3900  * @cancellable: (allow-none): A #GCancellable or %NULL.
3901  * @error: Return location for error or %NULL.
3902  *
3903  * Synchronously invokes the <link linkend="gdbus-method-org-project-Bar.RequestSignalEmission">RequestSignalEmission()</link> D-Bus method on @proxy. The calling thread is blocked until a reply is received.
3904  *
3905  * See foo_igen_bar_call_request_signal_emission() for the asynchronous version of this method.
3906  *
3907  * Returns: (skip): %TRUE if the call succeded, %FALSE if @error is set.
3908  */
3909 gboolean
3910 foo_igen_bar_call_request_signal_emission_sync (
3911     FooiGenBar *proxy,
3912     gint arg_which_one,
3913     GCancellable *cancellable,
3914     GError **error)
3915 {
3916   GVariant *_ret;
3917   _ret = g_dbus_proxy_call_sync (G_DBUS_PROXY (proxy),
3918     "RequestSignalEmission",
3919     g_variant_new ("(i)",
3920                    arg_which_one),
3921     G_DBUS_CALL_FLAGS_NONE,
3922     -1,
3923     cancellable,
3924     error);
3925   if (_ret == NULL)
3926     goto _out;
3927   g_variant_get (_ret,
3928                  "()");
3929   g_variant_unref (_ret);
3930 _out:
3931   return _ret != NULL;
3932 }
3933
3934 /**
3935  * foo_igen_bar_call_request_multi_property_mods:
3936  * @proxy: A #FooiGenBarProxy.
3937  * @cancellable: (allow-none): A #GCancellable or %NULL.
3938  * @callback: A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
3939  * @user_data: User data to pass to @callback.
3940  *
3941  * Asynchronously invokes the <link linkend="gdbus-method-org-project-Bar.RequestMultiPropertyMods">RequestMultiPropertyMods()</link> D-Bus method on @proxy.
3942  * When the operation is finished, @callback will be invoked in the <link linkend="g-main-context-push-thread-default">thread-default main loop</link> of the thread you are calling this method from.
3943  * You can then call foo_igen_bar_call_request_multi_property_mods_finish() to get the result of the operation.
3944  *
3945  * See foo_igen_bar_call_request_multi_property_mods_sync() for the synchronous, blocking version of this method.
3946  */
3947 void
3948 foo_igen_bar_call_request_multi_property_mods (
3949     FooiGenBar *proxy,
3950     GCancellable *cancellable,
3951     GAsyncReadyCallback callback,
3952     gpointer user_data)
3953 {
3954   g_dbus_proxy_call (G_DBUS_PROXY (proxy),
3955     "RequestMultiPropertyMods",
3956     g_variant_new ("()"),
3957     G_DBUS_CALL_FLAGS_NONE,
3958     -1,
3959     cancellable,
3960     callback,
3961     user_data);
3962 }
3963
3964 /**
3965  * foo_igen_bar_call_request_multi_property_mods_finish:
3966  * @proxy: A #FooiGenBarProxy.
3967  * @res: The #GAsyncResult obtained from the #GAsyncReadyCallback passed to foo_igen_bar_call_request_multi_property_mods().
3968  * @error: Return location for error or %NULL.
3969  *
3970  * Finishes an operation started with foo_igen_bar_call_request_multi_property_mods().
3971  *
3972  * Returns: (skip): %TRUE if the call succeded, %FALSE if @error is set.
3973  */
3974 gboolean
3975 foo_igen_bar_call_request_multi_property_mods_finish (
3976     FooiGenBar *proxy,
3977     GAsyncResult *res,
3978     GError **error)
3979 {
3980   GVariant *_ret;
3981   _ret = g_dbus_proxy_call_finish (G_DBUS_PROXY (proxy), res, error);
3982   if (_ret == NULL)
3983     goto _out;
3984   g_variant_get (_ret,
3985                  "()");
3986   g_variant_unref (_ret);
3987 _out:
3988   return _ret != NULL;
3989 }
3990
3991 /**
3992  * foo_igen_bar_call_request_multi_property_mods_sync:
3993  * @proxy: A #FooiGenBarProxy.
3994  * @cancellable: (allow-none): A #GCancellable or %NULL.
3995  * @error: Return location for error or %NULL.
3996  *
3997  * Synchronously invokes the <link linkend="gdbus-method-org-project-Bar.RequestMultiPropertyMods">RequestMultiPropertyMods()</link> D-Bus method on @proxy. The calling thread is blocked until a reply is received.
3998  *
3999  * See foo_igen_bar_call_request_multi_property_mods() for the asynchronous version of this method.
4000  *
4001  * Returns: (skip): %TRUE if the call succeded, %FALSE if @error is set.
4002  */
4003 gboolean
4004 foo_igen_bar_call_request_multi_property_mods_sync (
4005     FooiGenBar *proxy,
4006     GCancellable *cancellable,
4007     GError **error)
4008 {
4009   GVariant *_ret;
4010   _ret = g_dbus_proxy_call_sync (G_DBUS_PROXY (proxy),
4011     "RequestMultiPropertyMods",
4012     g_variant_new ("()"),
4013     G_DBUS_CALL_FLAGS_NONE,
4014     -1,
4015     cancellable,
4016     error);
4017   if (_ret == NULL)
4018     goto _out;
4019   g_variant_get (_ret,
4020                  "()");
4021   g_variant_unref (_ret);
4022 _out:
4023   return _ret != NULL;
4024 }
4025
4026 /**
4027  * foo_igen_bar_call_unimplemented_method:
4028  * @proxy: A #FooiGenBarProxy.
4029  * @cancellable: (allow-none): A #GCancellable or %NULL.
4030  * @callback: A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
4031  * @user_data: User data to pass to @callback.
4032  *
4033  * Asynchronously invokes the <link linkend="gdbus-method-org-project-Bar.UnimplementedMethod">UnimplementedMethod()</link> D-Bus method on @proxy.
4034  * When the operation is finished, @callback will be invoked in the <link linkend="g-main-context-push-thread-default">thread-default main loop</link> of the thread you are calling this method from.
4035  * You can then call foo_igen_bar_call_unimplemented_method_finish() to get the result of the operation.
4036  *
4037  * See foo_igen_bar_call_unimplemented_method_sync() for the synchronous, blocking version of this method.
4038  */
4039 void
4040 foo_igen_bar_call_unimplemented_method (
4041     FooiGenBar *proxy,
4042     GCancellable *cancellable,
4043     GAsyncReadyCallback callback,
4044     gpointer user_data)
4045 {
4046   g_dbus_proxy_call (G_DBUS_PROXY (proxy),
4047     "UnimplementedMethod",
4048     g_variant_new ("()"),
4049     G_DBUS_CALL_FLAGS_NONE,
4050     -1,
4051     cancellable,
4052     callback,
4053     user_data);
4054 }
4055
4056 /**
4057  * foo_igen_bar_call_unimplemented_method_finish:
4058  * @proxy: A #FooiGenBarProxy.
4059  * @res: The #GAsyncResult obtained from the #GAsyncReadyCallback passed to foo_igen_bar_call_unimplemented_method().
4060  * @error: Return location for error or %NULL.
4061  *
4062  * Finishes an operation started with foo_igen_bar_call_unimplemented_method().
4063  *
4064  * Returns: (skip): %TRUE if the call succeded, %FALSE if @error is set.
4065  */
4066 gboolean
4067 foo_igen_bar_call_unimplemented_method_finish (
4068     FooiGenBar *proxy,
4069     GAsyncResult *res,
4070     GError **error)
4071 {
4072   GVariant *_ret;
4073   _ret = g_dbus_proxy_call_finish (G_DBUS_PROXY (proxy), res, error);
4074   if (_ret == NULL)
4075     goto _out;
4076   g_variant_get (_ret,
4077                  "()");
4078   g_variant_unref (_ret);
4079 _out:
4080   return _ret != NULL;
4081 }
4082
4083 /**
4084  * foo_igen_bar_call_unimplemented_method_sync:
4085  * @proxy: A #FooiGenBarProxy.
4086  * @cancellable: (allow-none): A #GCancellable or %NULL.
4087  * @error: Return location for error or %NULL.
4088  *
4089  * Synchronously invokes the <link linkend="gdbus-method-org-project-Bar.UnimplementedMethod">UnimplementedMethod()</link> D-Bus method on @proxy. The calling thread is blocked until a reply is received.
4090  *
4091  * See foo_igen_bar_call_unimplemented_method() for the asynchronous version of this method.
4092  *
4093  * Returns: (skip): %TRUE if the call succeded, %FALSE if @error is set.
4094  */
4095 gboolean
4096 foo_igen_bar_call_unimplemented_method_sync (
4097     FooiGenBar *proxy,
4098     GCancellable *cancellable,
4099     GError **error)
4100 {
4101   GVariant *_ret;
4102   _ret = g_dbus_proxy_call_sync (G_DBUS_PROXY (proxy),
4103     "UnimplementedMethod",
4104     g_variant_new ("()"),
4105     G_DBUS_CALL_FLAGS_NONE,
4106     -1,
4107     cancellable,
4108     error);
4109   if (_ret == NULL)
4110     goto _out;
4111   g_variant_get (_ret,
4112                  "()");
4113   g_variant_unref (_ret);
4114 _out:
4115   return _ret != NULL;
4116 }
4117
4118 /**
4119  * foo_igen_bar_call_property_cancellation:
4120  * @proxy: A #FooiGenBarProxy.
4121  * @cancellable: (allow-none): A #GCancellable or %NULL.
4122  * @callback: A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
4123  * @user_data: User data to pass to @callback.
4124  *
4125  * Asynchronously invokes the <link linkend="gdbus-method-org-project-Bar.PropertyCancellation">PropertyCancellation()</link> D-Bus method on @proxy.
4126  * When the operation is finished, @callback will be invoked in the <link linkend="g-main-context-push-thread-default">thread-default main loop</link> of the thread you are calling this method from.
4127  * You can then call foo_igen_bar_call_property_cancellation_finish() to get the result of the operation.
4128  *
4129  * See foo_igen_bar_call_property_cancellation_sync() for the synchronous, blocking version of this method.
4130  */
4131 void
4132 foo_igen_bar_call_property_cancellation (
4133     FooiGenBar *proxy,
4134     GCancellable *cancellable,
4135     GAsyncReadyCallback callback,
4136     gpointer user_data)
4137 {
4138   g_dbus_proxy_call (G_DBUS_PROXY (proxy),
4139     "PropertyCancellation",
4140     g_variant_new ("()"),
4141     G_DBUS_CALL_FLAGS_NONE,
4142     -1,
4143     cancellable,
4144     callback,
4145     user_data);
4146 }
4147
4148 /**
4149  * foo_igen_bar_call_property_cancellation_finish:
4150  * @proxy: A #FooiGenBarProxy.
4151  * @res: The #GAsyncResult obtained from the #GAsyncReadyCallback passed to foo_igen_bar_call_property_cancellation().
4152  * @error: Return location for error or %NULL.
4153  *
4154  * Finishes an operation started with foo_igen_bar_call_property_cancellation().
4155  *
4156  * Returns: (skip): %TRUE if the call succeded, %FALSE if @error is set.
4157  */
4158 gboolean
4159 foo_igen_bar_call_property_cancellation_finish (
4160     FooiGenBar *proxy,
4161     GAsyncResult *res,
4162     GError **error)
4163 {
4164   GVariant *_ret;
4165   _ret = g_dbus_proxy_call_finish (G_DBUS_PROXY (proxy), res, error);
4166   if (_ret == NULL)
4167     goto _out;
4168   g_variant_get (_ret,
4169                  "()");
4170   g_variant_unref (_ret);
4171 _out:
4172   return _ret != NULL;
4173 }
4174
4175 /**
4176  * foo_igen_bar_call_property_cancellation_sync:
4177  * @proxy: A #FooiGenBarProxy.
4178  * @cancellable: (allow-none): A #GCancellable or %NULL.
4179  * @error: Return location for error or %NULL.
4180  *
4181  * Synchronously invokes the <link linkend="gdbus-method-org-project-Bar.PropertyCancellation">PropertyCancellation()</link> D-Bus method on @proxy. The calling thread is blocked until a reply is received.
4182  *
4183  * See foo_igen_bar_call_property_cancellation() for the asynchronous version of this method.
4184  *
4185  * Returns: (skip): %TRUE if the call succeded, %FALSE if @error is set.
4186  */
4187 gboolean
4188 foo_igen_bar_call_property_cancellation_sync (
4189     FooiGenBar *proxy,
4190     GCancellable *cancellable,
4191     GError **error)
4192 {
4193   GVariant *_ret;
4194   _ret = g_dbus_proxy_call_sync (G_DBUS_PROXY (proxy),
4195     "PropertyCancellation",
4196     g_variant_new ("()"),
4197     G_DBUS_CALL_FLAGS_NONE,
4198     -1,
4199     cancellable,
4200     error);
4201   if (_ret == NULL)
4202     goto _out;
4203   g_variant_get (_ret,
4204                  "()");
4205   g_variant_unref (_ret);
4206 _out:
4207   return _ret != NULL;
4208 }
4209
4210 /**
4211  * foo_igen_bar_complete_hello_world:
4212  * @object: A #FooiGenBar.
4213  * @invocation: (transfer full): A #GDBusMethodInvocation.
4214  * @response: Parameter to return.
4215  *
4216  * Helper function used in service implementations to finish handling invocations of the <link linkend="gdbus-method-org-project-Bar.HelloWorld">HelloWorld()</link> D-Bus method. If you instead want to finish handling an invocation by returning an error, use g_dbus_method_invocation_return_error() or similar.
4217  *
4218  * This method will free @invocation, you cannot use it afterwards.
4219  */
4220 void
4221 foo_igen_bar_complete_hello_world (
4222     FooiGenBar *object,
4223     GDBusMethodInvocation *invocation,
4224     const gchar *response)
4225 {
4226   g_dbus_method_invocation_return_value (invocation,
4227     g_variant_new ("(s)",
4228                    response));
4229 }
4230
4231 /**
4232  * foo_igen_bar_complete_test_primitive_types:
4233  * @object: A #FooiGenBar.
4234  * @invocation: (transfer full): A #GDBusMethodInvocation.
4235  * @ret_byte: Parameter to return.
4236  * @ret_boolean: Parameter to return.
4237  * @ret_int16: Parameter to return.
4238  * @ret_uint16: Parameter to return.
4239  * @ret_int32: Parameter to return.
4240  * @ret_uint32: Parameter to return.
4241  * @ret_int64: Parameter to return.
4242  * @ret_uint64: Parameter to return.
4243  * @ret_double: Parameter to return.
4244  * @ret_string: Parameter to return.
4245  * @ret_objpath: Parameter to return.
4246  * @ret_signature: Parameter to return.
4247  * @ret_bytestring: Parameter to return.
4248  *
4249  * Helper function used in service implementations to finish handling invocations of the <link linkend="gdbus-method-org-project-Bar.TestPrimitiveTypes">TestPrimitiveTypes()</link> D-Bus method. If you instead want to finish handling an invocation by returning an error, use g_dbus_method_invocation_return_error() or similar.
4250  *
4251  * This method will free @invocation, you cannot use it afterwards.
4252  */
4253 void
4254 foo_igen_bar_complete_test_primitive_types (
4255     FooiGenBar *object,
4256     GDBusMethodInvocation *invocation,
4257     guchar ret_byte,
4258     gboolean ret_boolean,
4259     gint16 ret_int16,
4260     guint16 ret_uint16,
4261     gint ret_int32,
4262     guint ret_uint32,
4263     gint64 ret_int64,
4264     guint64 ret_uint64,
4265     gdouble ret_double,
4266     const gchar *ret_string,
4267     const gchar *ret_objpath,
4268     const gchar *ret_signature,
4269     const gchar *ret_bytestring)
4270 {
4271   g_dbus_method_invocation_return_value (invocation,
4272     g_variant_new ("(ybnqiuxtdsog^ay)",
4273                    ret_byte,
4274                    ret_boolean,
4275                    ret_int16,
4276                    ret_uint16,
4277                    ret_int32,
4278                    ret_uint32,
4279                    ret_int64,
4280                    ret_uint64,
4281                    ret_double,
4282                    ret_string,
4283                    ret_objpath,
4284                    ret_signature,
4285                    ret_bytestring));
4286 }
4287
4288 /**
4289  * foo_igen_bar_complete_test_non_primitive_types:
4290  * @object: A #FooiGenBar.
4291  * @invocation: (transfer full): A #GDBusMethodInvocation.
4292  * @result: Parameter to return.
4293  *
4294  * Helper function used in service implementations to finish handling invocations of the <link linkend="gdbus-method-org-project-Bar.TestNonPrimitiveTypes">TestNonPrimitiveTypes()</link> D-Bus method. If you instead want to finish handling an invocation by returning an error, use g_dbus_method_invocation_return_error() or similar.
4295  *
4296  * This method will free @invocation, you cannot use it afterwards.
4297  */
4298 void
4299 foo_igen_bar_complete_test_non_primitive_types (
4300     FooiGenBar *object,
4301     GDBusMethodInvocation *invocation,
4302     const gchar *result)
4303 {
4304   g_dbus_method_invocation_return_value (invocation,
4305     g_variant_new ("(^ay)",
4306                    result));
4307 }
4308
4309 /**
4310  * foo_igen_bar_complete_request_signal_emission:
4311  * @object: A #FooiGenBar.
4312  * @invocation: (transfer full): A #GDBusMethodInvocation.
4313  *
4314  * Helper function used in service implementations to finish handling invocations of the <link linkend="gdbus-method-org-project-Bar.RequestSignalEmission">RequestSignalEmission()</link> D-Bus method. If you instead want to finish handling an invocation by returning an error, use g_dbus_method_invocation_return_error() or similar.
4315  *
4316  * This method will free @invocation, you cannot use it afterwards.
4317  */
4318 void
4319 foo_igen_bar_complete_request_signal_emission (
4320     FooiGenBar *object,
4321     GDBusMethodInvocation *invocation)
4322 {
4323   g_dbus_method_invocation_return_value (invocation,
4324     g_variant_new ("()"));
4325 }
4326
4327 /**
4328  * foo_igen_bar_complete_request_multi_property_mods:
4329  * @object: A #FooiGenBar.
4330  * @invocation: (transfer full): A #GDBusMethodInvocation.
4331  *
4332  * Helper function used in service implementations to finish handling invocations of the <link linkend="gdbus-method-org-project-Bar.RequestMultiPropertyMods">RequestMultiPropertyMods()</link> D-Bus method. If you instead want to finish handling an invocation by returning an error, use g_dbus_method_invocation_return_error() or similar.
4333  *
4334  * This method will free @invocation, you cannot use it afterwards.
4335  */
4336 void
4337 foo_igen_bar_complete_request_multi_property_mods (
4338     FooiGenBar *object,
4339     GDBusMethodInvocation *invocation)
4340 {
4341   g_dbus_method_invocation_return_value (invocation,
4342     g_variant_new ("()"));
4343 }
4344
4345 /**
4346  * foo_igen_bar_complete_unimplemented_method:
4347  * @object: A #FooiGenBar.
4348  * @invocation: (transfer full): A #GDBusMethodInvocation.
4349  *
4350  * Helper function used in service implementations to finish handling invocations of the <link linkend="gdbus-method-org-project-Bar.UnimplementedMethod">UnimplementedMethod()</link> D-Bus method. If you instead want to finish handling an invocation by returning an error, use g_dbus_method_invocation_return_error() or similar.
4351  *
4352  * This method will free @invocation, you cannot use it afterwards.
4353  */
4354 void
4355 foo_igen_bar_complete_unimplemented_method (
4356     FooiGenBar *object,
4357     GDBusMethodInvocation *invocation)
4358 {
4359   g_dbus_method_invocation_return_value (invocation,
4360     g_variant_new ("()"));
4361 }
4362
4363 /**
4364  * foo_igen_bar_complete_property_cancellation:
4365  * @object: A #FooiGenBar.
4366  * @invocation: (transfer full): A #GDBusMethodInvocation.
4367  *
4368  * Helper function used in service implementations to finish handling invocations of the <link linkend="gdbus-method-org-project-Bar.PropertyCancellation">PropertyCancellation()</link> D-Bus method. If you instead want to finish handling an invocation by returning an error, use g_dbus_method_invocation_return_error() or similar.
4369  *
4370  * This method will free @invocation, you cannot use it afterwards.
4371  */
4372 void
4373 foo_igen_bar_complete_property_cancellation (
4374     FooiGenBar *object,
4375     GDBusMethodInvocation *invocation)
4376 {
4377   g_dbus_method_invocation_return_value (invocation,
4378     g_variant_new ("()"));
4379 }
4380
4381 /* ------------------------------------------------------------------------ */
4382
4383 /**
4384  * FooiGenBarProxy:
4385  *
4386  * The #FooiGenBarProxy structure contains only private data and should only be accessed using the provided API.
4387  */
4388
4389 /**
4390  * FooiGenBarProxyClass:
4391  * @parent_class: The parent class.
4392  *
4393  * Class structure for #FooiGenBarProxy.
4394  */
4395
4396 struct _FooiGenBarProxyPrivate
4397 {
4398   GData *qdata;
4399 };
4400
4401 static void foo_igen_bar_proxy_iface_init (FooiGenBarIface *iface);
4402
4403 G_DEFINE_TYPE_WITH_CODE (FooiGenBarProxy, foo_igen_bar_proxy, G_TYPE_DBUS_PROXY,
4404                          G_IMPLEMENT_INTERFACE (FOO_IGEN_TYPE_BAR, foo_igen_bar_proxy_iface_init));
4405
4406 static void
4407 foo_igen_bar_proxy_finalize (GObject *object)
4408 {
4409   FooiGenBarProxy *proxy = FOO_IGEN_BAR_PROXY (object);
4410   g_datalist_clear (&proxy->priv->qdata);
4411   G_OBJECT_CLASS (foo_igen_bar_proxy_parent_class)->finalize (object);
4412 }
4413
4414 static void
4415 foo_igen_bar_proxy_get_property (GObject      *object,
4416   guint         prop_id,
4417   GValue       *value,
4418   GParamSpec   *pspec)
4419 {
4420   const _ExtendedGDBusPropertyInfo *info;
4421   GVariant *variant;
4422   g_assert (prop_id != 0 && prop_id - 1 < 30);
4423   info = _foo_igen_bar_property_info_pointers[prop_id - 1];
4424   variant = g_dbus_proxy_get_cached_property (G_DBUS_PROXY (object), info->parent_struct.name);
4425   if (info->use_gvariant)
4426     {
4427       g_value_set_variant (value, variant);
4428     }
4429   else
4430     {
4431       if (variant != NULL)
4432         g_dbus_gvariant_to_gvalue (variant, value);
4433     }
4434   if (variant != NULL)
4435     g_variant_unref (variant);
4436 }
4437
4438 static void
4439 foo_igen_bar_proxy_set_property_cb (GDBusProxy *proxy,
4440   GAsyncResult *res,
4441   gpointer      user_data)
4442 {
4443   const _ExtendedGDBusPropertyInfo *info = user_data;
4444   GError *error;
4445   error = NULL;
4446   if (!g_dbus_proxy_call_finish (proxy, res, &error))
4447     {
4448       g_warning ("Error setting property `%s' on interface org.project.Bar: %s (%s, %d)",
4449                  info->parent_struct.name, 
4450                  error->message, g_quark_to_string (error->domain), error->code);
4451       g_error_free (error);
4452     }
4453 }
4454
4455 static void
4456 foo_igen_bar_proxy_set_property (GObject      *object,
4457   guint         prop_id,
4458   const GValue *value,
4459   GParamSpec   *pspec)
4460 {
4461   const _ExtendedGDBusPropertyInfo *info;
4462   GVariant *variant;
4463   g_assert (prop_id != 0 && prop_id - 1 < 30);
4464   info = _foo_igen_bar_property_info_pointers[prop_id - 1];
4465   variant = g_dbus_gvalue_to_gvariant (value, G_VARIANT_TYPE (info->parent_struct.signature));
4466   g_dbus_proxy_call (G_DBUS_PROXY (object),
4467     "org.freedesktop.DBus.Properties.Set",
4468     g_variant_new ("(ssv)", "org.project.Bar", info->parent_struct.name, variant),
4469     G_DBUS_CALL_FLAGS_NONE,
4470     -1,
4471     NULL, (GAsyncReadyCallback) foo_igen_bar_proxy_set_property_cb, (gpointer) info);
4472   g_variant_unref (variant);
4473 }
4474
4475 static void
4476 foo_igen_bar_proxy_g_signal (GDBusProxy *proxy,
4477   const gchar *sender_name,
4478   const gchar *signal_name,
4479   GVariant *parameters)
4480 {
4481   _ExtendedGDBusSignalInfo *info;
4482   GVariantIter iter;
4483   GVariant *child;
4484   GValue *paramv;
4485   guint num_params;
4486   guint n;
4487   guint signal_id;
4488   info = (_ExtendedGDBusSignalInfo *) g_dbus_interface_info_lookup_signal ((GDBusInterfaceInfo *) &_foo_igen_bar_interface_info, signal_name);
4489   if (info == NULL)
4490     return;
4491   num_params = g_variant_n_children (parameters);
4492   paramv = g_new0 (GValue, num_params + 1);
4493   g_value_init (&paramv[0], FOO_IGEN_TYPE_BAR);
4494   g_value_set_object (&paramv[0], proxy);
4495   g_variant_iter_init (&iter, parameters);
4496   n = 1;
4497   while ((child = g_variant_iter_next_value (&iter)) != NULL)
4498     {
4499       _ExtendedGDBusArgInfo *arg_info = (_ExtendedGDBusArgInfo *) info->parent_struct.args[n - 1];
4500       if (arg_info->use_gvariant)
4501         {
4502           g_value_init (&paramv[n], G_TYPE_VARIANT);
4503           g_value_set_variant (&paramv[n], child);
4504           n++;
4505         }
4506       else
4507         g_dbus_gvariant_to_gvalue (child, &paramv[n++]);
4508       g_variant_unref (child);
4509     }
4510   signal_id = g_signal_lookup (info->signal_name, FOO_IGEN_TYPE_BAR);
4511   g_signal_emitv (paramv, signal_id, 0, NULL);
4512   for (n = 0; n < num_params + 1; n++)
4513     g_value_unset (&paramv[n]);
4514   g_free (paramv);
4515 }
4516
4517 static void
4518 foo_igen_bar_proxy_g_properties_changed (GDBusProxy *_proxy,
4519   GVariant *changed_properties,
4520   const gchar *const *invalidated_properties)
4521 {
4522   FooiGenBarProxy *proxy = FOO_IGEN_BAR_PROXY (_proxy);
4523   guint n;
4524   const gchar *key;
4525   GVariantIter *iter;
4526   _ExtendedGDBusPropertyInfo *info;
4527   g_variant_get (changed_properties, "a{sv}", &iter);
4528   while (g_variant_iter_next (iter, "{&sv}", &key, NULL))
4529     {
4530       info = (_ExtendedGDBusPropertyInfo *) g_dbus_interface_info_lookup_property ((GDBusInterfaceInfo *) &_foo_igen_bar_interface_info, key);
4531       g_datalist_remove_data (&proxy->priv->qdata, key);
4532       if (info != NULL)
4533         g_object_notify (G_OBJECT (proxy), info->hyphen_name);
4534     }
4535   g_variant_iter_free (iter);
4536   for (n = 0; invalidated_properties[n] != NULL; n++)
4537     {
4538       info = (_ExtendedGDBusPropertyInfo *) g_dbus_interface_info_lookup_property ((GDBusInterfaceInfo *) &_foo_igen_bar_interface_info, invalidated_properties[n]);
4539       g_datalist_remove_data (&proxy->priv->qdata, invalidated_properties[n]);
4540       if (info != NULL)
4541         g_object_notify (G_OBJECT (proxy), info->hyphen_name);
4542     }
4543 }
4544
4545 static guchar 
4546 foo_igen_bar_proxy_get_y (FooiGenBar *object)
4547 {
4548   FooiGenBarProxy *proxy = FOO_IGEN_BAR_PROXY (object);
4549   GVariant *variant;
4550   guchar value = 0;
4551   variant = g_dbus_proxy_get_cached_property (G_DBUS_PROXY (proxy), "y");
4552   if (variant != NULL)
4553     {
4554       value = g_variant_get_byte (variant);
4555       g_variant_unref (variant);
4556     }
4557   return value;
4558 }
4559
4560 static gboolean 
4561 foo_igen_bar_proxy_get_b (FooiGenBar *object)
4562 {
4563   FooiGenBarProxy *proxy = FOO_IGEN_BAR_PROXY (object);
4564   GVariant *variant;
4565   gboolean value = 0;
4566   variant = g_dbus_proxy_get_cached_property (G_DBUS_PROXY (proxy), "b");
4567   if (variant != NULL)
4568     {
4569       value = g_variant_get_boolean (variant);
4570       g_variant_unref (variant);
4571     }
4572   return value;
4573 }
4574
4575 static gint16 
4576 foo_igen_bar_proxy_get_n (FooiGenBar *object)
4577 {
4578   FooiGenBarProxy *proxy = FOO_IGEN_BAR_PROXY (object);
4579   GVariant *variant;
4580   gint16 value = 0;
4581   variant = g_dbus_proxy_get_cached_property (G_DBUS_PROXY (proxy), "n");
4582   if (variant != NULL)
4583     {
4584       value = g_variant_get_int16 (variant);
4585       g_variant_unref (variant);
4586     }
4587   return value;
4588 }
4589
4590 static guint16 
4591 foo_igen_bar_proxy_get_q (FooiGenBar *object)
4592 {
4593   FooiGenBarProxy *proxy = FOO_IGEN_BAR_PROXY (object);
4594   GVariant *variant;
4595   guint16 value = 0;
4596   variant = g_dbus_proxy_get_cached_property (G_DBUS_PROXY (proxy), "q");
4597   if (variant != NULL)
4598     {
4599       value = g_variant_get_uint16 (variant);
4600       g_variant_unref (variant);
4601     }
4602   return value;
4603 }
4604
4605 static gint 
4606 foo_igen_bar_proxy_get_i (FooiGenBar *object)
4607 {
4608   FooiGenBarProxy *proxy = FOO_IGEN_BAR_PROXY (object);
4609   GVariant *variant;
4610   gint value = 0;
4611   variant = g_dbus_proxy_get_cached_property (G_DBUS_PROXY (proxy), "i");
4612   if (variant != NULL)
4613     {
4614       value = g_variant_get_int32 (variant);
4615       g_variant_unref (variant);
4616     }
4617   return value;
4618 }
4619
4620 static guint 
4621 foo_igen_bar_proxy_get_u (FooiGenBar *object)
4622 {
4623   FooiGenBarProxy *proxy = FOO_IGEN_BAR_PROXY (object);
4624   GVariant *variant;
4625   guint value = 0;
4626   variant = g_dbus_proxy_get_cached_property (G_DBUS_PROXY (proxy), "u");
4627   if (variant != NULL)
4628     {
4629       value = g_variant_get_uint32 (variant);
4630       g_variant_unref (variant);
4631     }
4632   return value;
4633 }
4634
4635 static gint64 
4636 foo_igen_bar_proxy_get_x (FooiGenBar *object)
4637 {
4638   FooiGenBarProxy *proxy = FOO_IGEN_BAR_PROXY (object);
4639   GVariant *variant;
4640   gint64 value = 0;
4641   variant = g_dbus_proxy_get_cached_property (G_DBUS_PROXY (proxy), "x");
4642   if (variant != NULL)
4643     {
4644       value = g_variant_get_int64 (variant);
4645       g_variant_unref (variant);
4646     }
4647   return value;
4648 }
4649
4650 static guint64 
4651 foo_igen_bar_proxy_get_t (FooiGenBar *object)
4652 {
4653   FooiGenBarProxy *proxy = FOO_IGEN_BAR_PROXY (object);
4654   GVariant *variant;
4655   guint64 value = 0;
4656   variant = g_dbus_proxy_get_cached_property (G_DBUS_PROXY (proxy), "t");
4657   if (variant != NULL)
4658     {
4659       value = g_variant_get_uint64 (variant);
4660       g_variant_unref (variant);
4661     }
4662   return value;
4663 }
4664
4665 static gdouble 
4666 foo_igen_bar_proxy_get_d (FooiGenBar *object)
4667 {
4668   FooiGenBarProxy *proxy = FOO_IGEN_BAR_PROXY (object);
4669   GVariant *variant;
4670   gdouble value = 0;
4671   variant = g_dbus_proxy_get_cached_property (G_DBUS_PROXY (proxy), "d");
4672   if (variant != NULL)
4673     {
4674       value = g_variant_get_double (variant);
4675       g_variant_unref (variant);
4676     }
4677   return value;
4678 }
4679
4680 static const gchar *
4681 foo_igen_bar_proxy_get_s (FooiGenBar *object)
4682 {
4683   FooiGenBarProxy *proxy = FOO_IGEN_BAR_PROXY (object);
4684   GVariant *variant;
4685   const gchar *value = NULL;
4686   variant = g_dbus_proxy_get_cached_property (G_DBUS_PROXY (proxy), "s");
4687   if (variant != NULL)
4688     {
4689       value = g_variant_get_string (variant, NULL);
4690       g_variant_unref (variant);
4691     }
4692   return value;
4693 }
4694
4695 static const gchar *
4696 foo_igen_bar_proxy_get_o (FooiGenBar *object)
4697 {
4698   FooiGenBarProxy *proxy = FOO_IGEN_BAR_PROXY (object);
4699   GVariant *variant;
4700   const gchar *value = NULL;
4701   variant = g_dbus_proxy_get_cached_property (G_DBUS_PROXY (proxy), "o");
4702   if (variant != NULL)
4703     {
4704       value = g_variant_get_string (variant, NULL);
4705       g_variant_unref (variant);
4706     }
4707   return value;
4708 }
4709
4710 static const gchar *
4711 foo_igen_bar_proxy_get_g (FooiGenBar *object)
4712 {
4713   FooiGenBarProxy *proxy = FOO_IGEN_BAR_PROXY (object);
4714   GVariant *variant;
4715   const gchar *value = NULL;
4716   variant = g_dbus_proxy_get_cached_property (G_DBUS_PROXY (proxy), "g");
4717   if (variant != NULL)
4718     {
4719       value = g_variant_get_string (variant, NULL);
4720       g_variant_unref (variant);
4721     }
4722   return value;
4723 }
4724
4725 static const gchar *
4726 foo_igen_bar_proxy_get_ay (FooiGenBar *object)
4727 {
4728   FooiGenBarProxy *proxy = FOO_IGEN_BAR_PROXY (object);
4729   GVariant *variant;
4730   const gchar *value = NULL;
4731   variant = g_dbus_proxy_get_cached_property (G_DBUS_PROXY (proxy), "ay");
4732   if (variant != NULL)
4733     {
4734       value = g_variant_get_bytestring (variant);
4735       g_variant_unref (variant);
4736     }
4737   return value;
4738 }
4739
4740 static const gchar *const *
4741 foo_igen_bar_proxy_get_as (FooiGenBar *object)
4742 {
4743   FooiGenBarProxy *proxy = FOO_IGEN_BAR_PROXY (object);
4744   GVariant *variant;
4745   const gchar *const *value = NULL;
4746   value = g_datalist_get_data (&proxy->priv->qdata, "as");
4747   if (value != NULL)
4748     return value;
4749   variant = g_dbus_proxy_get_cached_property (G_DBUS_PROXY (proxy), "as");
4750   if (variant != NULL)
4751     {
4752       value = g_variant_get_strv (variant, NULL);
4753       g_datalist_set_data_full (&proxy->priv->qdata, "as", (gpointer) value, g_free);
4754       g_variant_unref (variant);
4755     }
4756   return value;
4757 }
4758
4759 static const gchar *const *
4760 foo_igen_bar_proxy_get_aay (FooiGenBar *object)
4761 {
4762   FooiGenBarProxy *proxy = FOO_IGEN_BAR_PROXY (object);
4763   GVariant *variant;
4764   const gchar *const *value = NULL;
4765   value = g_datalist_get_data (&proxy->priv->qdata, "aay");
4766   if (value != NULL)
4767     return value;
4768   variant = g_dbus_proxy_get_cached_property (G_DBUS_PROXY (proxy), "aay");
4769   if (variant != NULL)
4770     {
4771       value = g_variant_get_bytestring_array (variant, NULL);
4772       g_datalist_set_data_full (&proxy->priv->qdata, "aay", (gpointer) value, g_free);
4773       g_variant_unref (variant);
4774     }
4775   return value;
4776 }
4777
4778 static const gchar *const *
4779 foo_igen_bar_proxy_get_ao (FooiGenBar *object)
4780 {
4781   FooiGenBarProxy *proxy = FOO_IGEN_BAR_PROXY (object);
4782   GVariant *variant;
4783   const gchar *const *value = NULL;
4784   variant = g_dbus_proxy_get_cached_property (G_DBUS_PROXY (proxy), "ao");
4785   if (variant != NULL)
4786     {
4787       value = g_variant_get_objv (variant, NULL);
4788       g_variant_unref (variant);
4789     }
4790   return value;
4791 }
4792
4793 static GVariant *
4794 foo_igen_bar_proxy_get_ag (FooiGenBar *object)
4795 {
4796   FooiGenBarProxy *proxy = FOO_IGEN_BAR_PROXY (object);
4797   GVariant *variant;
4798   GVariant *value = NULL;
4799   variant = g_dbus_proxy_get_cached_property (G_DBUS_PROXY (proxy), "ag");
4800   value = variant;
4801   if (variant != NULL)
4802     g_variant_unref (variant);
4803   return value;
4804 }
4805
4806 static const gchar *
4807 foo_igen_bar_proxy_get_finally_normal_name (FooiGenBar *object)
4808 {
4809   FooiGenBarProxy *proxy = FOO_IGEN_BAR_PROXY (object);
4810   GVariant *variant;
4811   const gchar *value = NULL;
4812   variant = g_dbus_proxy_get_cached_property (G_DBUS_PROXY (proxy), "FinallyNormalName");
4813   if (variant != NULL)
4814     {
4815       value = g_variant_get_string (variant, NULL);
4816       g_variant_unref (variant);
4817     }
4818   return value;
4819 }
4820
4821 static const gchar *
4822 foo_igen_bar_proxy_get_readonly_property (FooiGenBar *object)
4823 {
4824   FooiGenBarProxy *proxy = FOO_IGEN_BAR_PROXY (object);
4825   GVariant *variant;
4826   const gchar *value = NULL;
4827   variant = g_dbus_proxy_get_cached_property (G_DBUS_PROXY (proxy), "ReadonlyProperty");
4828   if (variant != NULL)
4829     {
4830       value = g_variant_get_string (variant, NULL);
4831       g_variant_unref (variant);
4832     }
4833   return value;
4834 }
4835
4836 static const gchar *
4837 foo_igen_bar_proxy_get_writeonly_property (FooiGenBar *object)
4838 {
4839   FooiGenBarProxy *proxy = FOO_IGEN_BAR_PROXY (object);
4840   GVariant *variant;
4841   const gchar *value = NULL;
4842   variant = g_dbus_proxy_get_cached_property (G_DBUS_PROXY (proxy), "WriteonlyProperty");
4843   if (variant != NULL)
4844     {
4845       value = g_variant_get_string (variant, NULL);
4846       g_variant_unref (variant);
4847     }
4848   return value;
4849 }
4850
4851 static gint 
4852 foo_igen_bar_proxy_get_unset_i (FooiGenBar *object)
4853 {
4854   FooiGenBarProxy *proxy = FOO_IGEN_BAR_PROXY (object);
4855   GVariant *variant;
4856   gint value = 0;
4857   variant = g_dbus_proxy_get_cached_property (G_DBUS_PROXY (proxy), "unset_i");
4858   if (variant != NULL)
4859     {
4860       value = g_variant_get_int32 (variant);
4861       g_variant_unref (variant);
4862     }
4863   return value;
4864 }
4865
4866 static gdouble 
4867 foo_igen_bar_proxy_get_unset_d (FooiGenBar *object)
4868 {
4869   FooiGenBarProxy *proxy = FOO_IGEN_BAR_PROXY (object);
4870   GVariant *variant;
4871   gdouble value = 0;
4872   variant = g_dbus_proxy_get_cached_property (G_DBUS_PROXY (proxy), "unset_d");
4873   if (variant != NULL)
4874     {
4875       value = g_variant_get_double (variant);
4876       g_variant_unref (variant);
4877     }
4878   return value;
4879 }
4880
4881 static const gchar *
4882 foo_igen_bar_proxy_get_unset_s (FooiGenBar *object)
4883 {
4884   FooiGenBarProxy *proxy = FOO_IGEN_BAR_PROXY (object);
4885   GVariant *variant;
4886   const gchar *value = NULL;
4887   variant = g_dbus_proxy_get_cached_property (G_DBUS_PROXY (proxy), "unset_s");
4888   if (variant != NULL)
4889     {
4890       value = g_variant_get_string (variant, NULL);
4891       g_variant_unref (variant);
4892     }
4893   return value;
4894 }
4895
4896 static const gchar *
4897 foo_igen_bar_proxy_get_unset_o (FooiGenBar *object)
4898 {
4899   FooiGenBarProxy *proxy = FOO_IGEN_BAR_PROXY (object);
4900   GVariant *variant;
4901   const gchar *value = NULL;
4902   variant = g_dbus_proxy_get_cached_property (G_DBUS_PROXY (proxy), "unset_o");
4903   if (variant != NULL)
4904     {
4905       value = g_variant_get_string (variant, NULL);
4906       g_variant_unref (variant);
4907     }
4908   return value;
4909 }
4910
4911 static const gchar *
4912 foo_igen_bar_proxy_get_unset_g (FooiGenBar *object)
4913 {
4914   FooiGenBarProxy *proxy = FOO_IGEN_BAR_PROXY (object);
4915   GVariant *variant;
4916   const gchar *value = NULL;
4917   variant = g_dbus_proxy_get_cached_property (G_DBUS_PROXY (proxy), "unset_g");
4918   if (variant != NULL)
4919     {
4920       value = g_variant_get_string (variant, NULL);
4921       g_variant_unref (variant);
4922     }
4923   return value;
4924 }
4925
4926 static const gchar *
4927 foo_igen_bar_proxy_get_unset_ay (FooiGenBar *object)
4928 {
4929   FooiGenBarProxy *proxy = FOO_IGEN_BAR_PROXY (object);
4930   GVariant *variant;
4931   const gchar *value = NULL;
4932   variant = g_dbus_proxy_get_cached_property (G_DBUS_PROXY (proxy), "unset_ay");
4933   if (variant != NULL)
4934     {
4935       value = g_variant_get_bytestring (variant);
4936       g_variant_unref (variant);
4937     }
4938   return value;
4939 }
4940
4941 static const gchar *const *
4942 foo_igen_bar_proxy_get_unset_as (FooiGenBar *object)
4943 {
4944   FooiGenBarProxy *proxy = FOO_IGEN_BAR_PROXY (object);
4945   GVariant *variant;
4946   const gchar *const *value = NULL;
4947   value = g_datalist_get_data (&proxy->priv->qdata, "unset_as");
4948   if (value != NULL)
4949     return value;
4950   variant = g_dbus_proxy_get_cached_property (G_DBUS_PROXY (proxy), "unset_as");
4951   if (variant != NULL)
4952     {
4953       value = g_variant_get_strv (variant, NULL);
4954       g_datalist_set_data_full (&proxy->priv->qdata, "unset_as", (gpointer) value, g_free);
4955       g_variant_unref (variant);
4956     }
4957   return value;
4958 }
4959
4960 static const gchar *const *
4961 foo_igen_bar_proxy_get_unset_ao (FooiGenBar *object)
4962 {
4963   FooiGenBarProxy *proxy = FOO_IGEN_BAR_PROXY (object);
4964   GVariant *variant;
4965   const gchar *const *value = NULL;
4966   variant = g_dbus_proxy_get_cached_property (G_DBUS_PROXY (proxy), "unset_ao");
4967   if (variant != NULL)
4968     {
4969       value = g_variant_get_objv (variant, NULL);
4970       g_variant_unref (variant);
4971     }
4972   return value;
4973 }
4974
4975 static GVariant *
4976 foo_igen_bar_proxy_get_unset_ag (FooiGenBar *object)
4977 {
4978   FooiGenBarProxy *proxy = FOO_IGEN_BAR_PROXY (object);
4979   GVariant *variant;
4980   GVariant *value = NULL;
4981   variant = g_dbus_proxy_get_cached_property (G_DBUS_PROXY (proxy), "unset_ag");
4982   value = variant;
4983   if (variant != NULL)
4984     g_variant_unref (variant);
4985   return value;
4986 }
4987
4988 static GVariant *
4989 foo_igen_bar_proxy_get_unset_struct (FooiGenBar *object)
4990 {
4991   FooiGenBarProxy *proxy = FOO_IGEN_BAR_PROXY (object);
4992   GVariant *variant;
4993   GVariant *value = NULL;
4994   variant = g_dbus_proxy_get_cached_property (G_DBUS_PROXY (proxy), "unset_struct");
4995   value = variant;
4996   if (variant != NULL)
4997     g_variant_unref (variant);
4998   return value;
4999 }
5000
5001 static void
5002 foo_igen_bar_proxy_init (FooiGenBarProxy *proxy)
5003 {
5004   proxy->priv = G_TYPE_INSTANCE_GET_PRIVATE (proxy, FOO_IGEN_TYPE_BAR_PROXY, FooiGenBarProxyPrivate);
5005   g_dbus_proxy_set_interface_info (G_DBUS_PROXY (proxy), foo_igen_bar_interface_info ());
5006 }
5007
5008 static void
5009 foo_igen_bar_proxy_class_init (FooiGenBarProxyClass *klass)
5010 {
5011   GObjectClass *gobject_class;
5012   GDBusProxyClass *proxy_class;
5013
5014   g_type_class_add_private (klass, sizeof (FooiGenBarProxyPrivate));
5015
5016   gobject_class = G_OBJECT_CLASS (klass);
5017   gobject_class->finalize     = foo_igen_bar_proxy_finalize;
5018   gobject_class->get_property = foo_igen_bar_proxy_get_property;
5019   gobject_class->set_property = foo_igen_bar_proxy_set_property;
5020
5021   proxy_class = G_DBUS_PROXY_CLASS (klass);
5022   proxy_class->g_signal = foo_igen_bar_proxy_g_signal;
5023   proxy_class->g_properties_changed = foo_igen_bar_proxy_g_properties_changed;
5024
5025
5026   foo_igen_bar_override_properties (gobject_class, 1);
5027 }
5028
5029 static void
5030 foo_igen_bar_proxy_iface_init (FooiGenBarIface *iface)
5031 {
5032   iface->get_y = foo_igen_bar_proxy_get_y;
5033   iface->get_b = foo_igen_bar_proxy_get_b;
5034   iface->get_n = foo_igen_bar_proxy_get_n;
5035   iface->get_q = foo_igen_bar_proxy_get_q;
5036   iface->get_i = foo_igen_bar_proxy_get_i;
5037   iface->get_u = foo_igen_bar_proxy_get_u;
5038   iface->get_x = foo_igen_bar_proxy_get_x;
5039   iface->get_t = foo_igen_bar_proxy_get_t;
5040   iface->get_d = foo_igen_bar_proxy_get_d;
5041   iface->get_s = foo_igen_bar_proxy_get_s;
5042   iface->get_o = foo_igen_bar_proxy_get_o;
5043   iface->get_g = foo_igen_bar_proxy_get_g;
5044   iface->get_ay = foo_igen_bar_proxy_get_ay;
5045   iface->get_as = foo_igen_bar_proxy_get_as;
5046   iface->get_aay = foo_igen_bar_proxy_get_aay;
5047   iface->get_ao = foo_igen_bar_proxy_get_ao;
5048   iface->get_ag = foo_igen_bar_proxy_get_ag;
5049   iface->get_finally_normal_name = foo_igen_bar_proxy_get_finally_normal_name;
5050   iface->get_readonly_property = foo_igen_bar_proxy_get_readonly_property;
5051   iface->get_writeonly_property = foo_igen_bar_proxy_get_writeonly_property;
5052   iface->get_unset_i = foo_igen_bar_proxy_get_unset_i;
5053   iface->get_unset_d = foo_igen_bar_proxy_get_unset_d;
5054   iface->get_unset_s = foo_igen_bar_proxy_get_unset_s;
5055   iface->get_unset_o = foo_igen_bar_proxy_get_unset_o;
5056   iface->get_unset_g = foo_igen_bar_proxy_get_unset_g;
5057   iface->get_unset_ay = foo_igen_bar_proxy_get_unset_ay;
5058   iface->get_unset_as = foo_igen_bar_proxy_get_unset_as;
5059   iface->get_unset_ao = foo_igen_bar_proxy_get_unset_ao;
5060   iface->get_unset_ag = foo_igen_bar_proxy_get_unset_ag;
5061   iface->get_unset_struct = foo_igen_bar_proxy_get_unset_struct;
5062 }
5063
5064 /**
5065  * foo_igen_bar_proxy_new:
5066  * @connection: A #GDBusConnection.
5067  * @flags: Flags from the #GDBusProxyFlags enumeration.
5068  * @name: (allow-none): A bus name (well-known or unique) or %NULL if @connection is not a message bus connection.
5069  * @object_path: An object path.
5070  * @cancellable: (allow-none): A #GCancellable or %NULL.
5071  * @callback: A #GAsyncReadyCallback to call when the request is satisfied.
5072  * @user_data: User data to pass to @callback.
5073  *
5074  * Asynchronously creates a proxy for the D-Bus interface <link linkend="gdbus-interface-org-project-Bar.top_of_page">org.project.Bar</link>. See g_dbus_proxy_new() for more details.
5075  *
5076  * When the operation is finished, @callback will be invoked in the <link linkend="g-main-context-push-thread-default">thread-default main loop</link> of the thread you are calling this method from.
5077  * You can then call foo_igen_bar_proxy_new_finish() to get the result of the operation.
5078  *
5079  * See foo_igen_bar_proxy_new_sync() for the synchronous, blocking version of this constructor.
5080  */
5081 void
5082 foo_igen_bar_proxy_new (
5083     GDBusConnection     *connection,
5084     GDBusProxyFlags      flags,
5085     const gchar         *name,
5086     const gchar         *object_path,
5087     GCancellable        *cancellable,
5088     GAsyncReadyCallback  callback,
5089     gpointer             user_data)
5090 {
5091   g_async_initable_new_async (FOO_IGEN_TYPE_BAR_PROXY, G_PRIORITY_DEFAULT, cancellable, callback, user_data, "g-flags", flags, "g-name", name, "g-connection", connection, "g-object-path", object_path, "g-interface-name", "org.project.Bar", NULL);
5092 }
5093
5094 /**
5095  * foo_igen_bar_proxy_new_finish:
5096  * @res: The #GAsyncResult obtained from the #GAsyncReadyCallback passed to foo_igen_bar_proxy_new().
5097  * @error: Return location for error or %NULL
5098  *
5099  * Finishes an operation started with foo_igen_bar_proxy_new().
5100  *
5101  * Returns: (transfer full) (type FooiGenBarProxy): The constructed proxy object or %NULL if @error is set.
5102  */
5103 FooiGenBar *
5104 foo_igen_bar_proxy_new_finish (
5105     GAsyncResult        *res,
5106     GError             **error)
5107 {
5108   GObject *ret;
5109   GObject *source_object;
5110   source_object = g_async_result_get_source_object (res);
5111   ret = g_async_initable_new_finish (G_ASYNC_INITABLE (source_object), res, error);
5112   g_object_unref (source_object);
5113   if (ret != NULL)
5114     return FOO_IGEN_BAR (ret);
5115   else
5116     return NULL;
5117 }
5118
5119 /**
5120  * foo_igen_bar_proxy_new_sync:
5121  * @connection: A #GDBusConnection.
5122  * @flags: Flags from the #GDBusProxyFlags enumeration.
5123  * @name: (allow-none): A bus name (well-known or unique) or %NULL if @connection is not a message bus connection.
5124  * @object_path: An object path.
5125  * @cancellable: (allow-none): A #GCancellable or %NULL.
5126  * @error: Return location for error or %NULL
5127  *
5128  * Synchronously creates a proxy for the D-Bus interface <link linkend="gdbus-interface-org-project-Bar.top_of_page">org.project.Bar</link>. See g_dbus_proxy_new_sync() for more details.
5129  *
5130  * The calling thread is blocked until a reply is received.
5131  *
5132  * See foo_igen_bar_proxy_new() for the asynchronous version of this constructor.
5133  *
5134  * Returns: (transfer full) (type FooiGenBarProxy): The constructed proxy object or %NULL if @error is set.
5135  */
5136 FooiGenBar *
5137 foo_igen_bar_proxy_new_sync (
5138     GDBusConnection     *connection,
5139     GDBusProxyFlags      flags,
5140     const gchar         *name,
5141     const gchar         *object_path,
5142     GCancellable        *cancellable,
5143     GError             **error)
5144 {
5145   GInitable *ret;
5146   ret = g_initable_new (FOO_IGEN_TYPE_BAR_PROXY, cancellable, error, "g-flags", flags, "g-name", name, "g-connection", connection, "g-object-path", object_path, "g-interface-name", "org.project.Bar", NULL);
5147   if (ret != NULL)
5148     return FOO_IGEN_BAR (ret);
5149   else
5150     return NULL;
5151 }
5152
5153
5154 /**
5155  * foo_igen_bar_proxy_new_for_bus:
5156  * @bus_type: A #GBusType.
5157  * @flags: Flags from the #GDBusProxyFlags enumeration.
5158  * @name: A bus name (well-known or unique).
5159  * @object_path: An object path.
5160  * @cancellable: (allow-none): A #GCancellable or %NULL.
5161  * @callback: A #GAsyncReadyCallback to call when the request is satisfied.
5162  * @user_data: User data to pass to @callback.
5163  *
5164  * Like foo_igen_bar_proxy_new() but takes a #GBusType instead of a #GDBusConnection.
5165  *
5166  * When the operation is finished, @callback will be invoked in the <link linkend="g-main-context-push-thread-default">thread-default main loop</link> of the thread you are calling this method from.
5167  * You can then call foo_igen_bar_proxy_new_for_bus_finish() to get the result of the operation.
5168  *
5169  * See foo_igen_bar_proxy_new_for_bus_sync() for the synchronous, blocking version of this constructor.
5170  */
5171 void
5172 foo_igen_bar_proxy_new_for_bus (
5173     GBusType             bus_type,
5174     GDBusProxyFlags      flags,
5175     const gchar         *name,
5176     const gchar         *object_path,
5177     GCancellable        *cancellable,
5178     GAsyncReadyCallback  callback,
5179     gpointer             user_data)
5180 {
5181   g_async_initable_new_async (FOO_IGEN_TYPE_BAR_PROXY, G_PRIORITY_DEFAULT, cancellable, callback, user_data, "g-flags", flags, "g-name", name, "g-bus-type", bus_type, "g-object-path", object_path, "g-interface-name", "org.project.Bar", NULL);
5182 }
5183
5184 /**
5185  * foo_igen_bar_proxy_new_for_bus_finish:
5186  * @res: The #GAsyncResult obtained from the #GAsyncReadyCallback passed to foo_igen_bar_proxy_new_for_bus().
5187  * @error: Return location for error or %NULL
5188  *
5189  * Finishes an operation started with foo_igen_bar_proxy_new_for_bus().
5190  *
5191  * Returns: (transfer full) (type FooiGenBarProxy): The constructed proxy object or %NULL if @error is set.
5192  */
5193 FooiGenBar *
5194 foo_igen_bar_proxy_new_for_bus_finish (
5195     GAsyncResult        *res,
5196     GError             **error)
5197 {
5198   GObject *ret;
5199   GObject *source_object;
5200   source_object = g_async_result_get_source_object (res);
5201   ret = g_async_initable_new_finish (G_ASYNC_INITABLE (source_object), res, error);
5202   g_object_unref (source_object);
5203   if (ret != NULL)
5204     return FOO_IGEN_BAR (ret);
5205   else
5206     return NULL;
5207 }
5208
5209 /**
5210  * foo_igen_bar_proxy_new_for_bus_sync:
5211  * @bus_type: A #GBusType.
5212  * @flags: Flags from the #GDBusProxyFlags enumeration.
5213  * @name: A bus name (well-known or unique).
5214  * @object_path: An object path.
5215  * @cancellable: (allow-none): A #GCancellable or %NULL.
5216  * @error: Return location for error or %NULL
5217  *
5218  * Like foo_igen_bar_proxy_new_sync() but takes a #GBusType instead of a #GDBusConnection.
5219  *
5220  * The calling thread is blocked until a reply is received.
5221  *
5222  * See foo_igen_bar_proxy_new_for_bus() for the asynchronous version of this constructor.
5223  *
5224  * Returns: (transfer full) (type FooiGenBarProxy): The constructed proxy object or %NULL if @error is set.
5225  */
5226 FooiGenBar *
5227 foo_igen_bar_proxy_new_for_bus_sync (
5228     GBusType             bus_type,
5229     GDBusProxyFlags      flags,
5230     const gchar         *name,
5231     const gchar         *object_path,
5232     GCancellable        *cancellable,
5233     GError             **error)
5234 {
5235   GInitable *ret;
5236   ret = g_initable_new (FOO_IGEN_TYPE_BAR_PROXY, cancellable, error, "g-flags", flags, "g-name", name, "g-bus-type", bus_type, "g-object-path", object_path, "g-interface-name", "org.project.Bar", NULL);
5237   if (ret != NULL)
5238     return FOO_IGEN_BAR (ret);
5239   else
5240     return NULL;
5241 }
5242
5243
5244 /* ------------------------------------------------------------------------ */
5245
5246 /**
5247  * FooiGenBarSkeleton:
5248  *
5249  * The #FooiGenBarSkeleton structure contains only private data and should only be accessed using the provided API.
5250  */
5251
5252 /**
5253  * FooiGenBarSkeletonClass:
5254  * @parent_class: The parent class.
5255  *
5256  * Class structure for #FooiGenBarSkeleton.
5257  */
5258
5259 struct _FooiGenBarSkeletonPrivate
5260 {
5261   GValue *properties;
5262   GList *changed_properties;
5263   GSource *changed_properties_idle_source;
5264   GMainContext *context;
5265   GMutex lock;
5266 };
5267
5268 static void
5269 _foo_igen_bar_skeleton_handle_method_call (
5270   GDBusConnection *connection,
5271   const gchar *sender,
5272   const gchar *object_path,
5273   const gchar *interface_name,
5274   const gchar *method_name,
5275   GVariant *parameters,
5276   GDBusMethodInvocation *invocation,
5277   gpointer user_data)
5278 {
5279   FooiGenBarSkeleton *skeleton = FOO_IGEN_BAR_SKELETON (user_data);
5280   _ExtendedGDBusMethodInfo *info;
5281   GVariantIter iter;
5282   GVariant *child;
5283   GValue *paramv;
5284   guint num_params;
5285   guint num_extra;
5286   guint n;
5287   guint signal_id;
5288   GValue return_value = G_VALUE_INIT;
5289   info = (_ExtendedGDBusMethodInfo *) g_dbus_method_invocation_get_method_info (invocation);
5290   g_assert (info != NULL);
5291   num_params = g_variant_n_children (parameters);
5292   num_extra = info->pass_fdlist ? 3 : 2;  paramv = g_new0 (GValue, num_params + num_extra);
5293   n = 0;
5294   g_value_init (&paramv[n], FOO_IGEN_TYPE_BAR);
5295   g_value_set_object (&paramv[n++], skeleton);
5296   g_value_init (&paramv[n], G_TYPE_DBUS_METHOD_INVOCATION);
5297   g_value_set_object (&paramv[n++], invocation);
5298   if (info->pass_fdlist)
5299     {
5300 #ifdef G_OS_UNIX
5301       g_value_init (&paramv[n], G_TYPE_UNIX_FD_LIST);
5302       g_value_set_object (&paramv[n++], g_dbus_message_get_unix_fd_list (g_dbus_method_invocation_get_message (invocation)));
5303 #else
5304       g_assert_not_reached ();
5305 #endif
5306     }
5307   g_variant_iter_init (&iter, parameters);
5308   while ((child = g_variant_iter_next_value (&iter)) != NULL)
5309     {
5310       _ExtendedGDBusArgInfo *arg_info = (_ExtendedGDBusArgInfo *) info->parent_struct.in_args[n - num_extra];
5311       if (arg_info->use_gvariant)
5312         {
5313           g_value_init (&paramv[n], G_TYPE_VARIANT);
5314           g_value_set_variant (&paramv[n], child);
5315           n++;
5316         }
5317       else
5318         g_dbus_gvariant_to_gvalue (child, &paramv[n++]);
5319       g_variant_unref (child);
5320     }
5321   signal_id = g_signal_lookup (info->signal_name, FOO_IGEN_TYPE_BAR);
5322   g_value_init (&return_value, G_TYPE_BOOLEAN);
5323   g_signal_emitv (paramv, signal_id, 0, &return_value);
5324   if (!g_value_get_boolean (&return_value))
5325     g_dbus_method_invocation_return_error (invocation, G_DBUS_ERROR, G_DBUS_ERROR_UNKNOWN_METHOD, "Method %s is not implemented on interface %s", method_name, interface_name);
5326   g_value_unset (&return_value);
5327   for (n = 0; n < num_params + num_extra; n++)
5328     g_value_unset (&paramv[n]);
5329   g_free (paramv);
5330 }
5331
5332 static GVariant *
5333 _foo_igen_bar_skeleton_handle_get_property (
5334   GDBusConnection *connection,
5335   const gchar *sender,
5336   const gchar *object_path,
5337   const gchar *interface_name,
5338   const gchar *property_name,
5339   GError **error,
5340   gpointer user_data)
5341 {
5342   FooiGenBarSkeleton *skeleton = FOO_IGEN_BAR_SKELETON (user_data);
5343   GValue value = G_VALUE_INIT;
5344   GParamSpec *pspec;
5345   _ExtendedGDBusPropertyInfo *info;
5346   GVariant *ret;
5347   ret = NULL;
5348   info = (_ExtendedGDBusPropertyInfo *) g_dbus_interface_info_lookup_property ((GDBusInterfaceInfo *) &_foo_igen_bar_interface_info, property_name);
5349   g_assert (info != NULL);
5350   pspec = g_object_class_find_property (G_OBJECT_GET_CLASS (skeleton), info->hyphen_name);
5351   if (pspec == NULL)
5352     {
5353       g_set_error (error, G_DBUS_ERROR, G_DBUS_ERROR_INVALID_ARGS, "No property with name %s", property_name);
5354     }
5355   else
5356     {
5357       g_value_init (&value, pspec->value_type);
5358       g_object_get_property (G_OBJECT (skeleton), info->hyphen_name, &value);
5359       ret = g_dbus_gvalue_to_gvariant (&value, G_VARIANT_TYPE (info->parent_struct.signature));
5360       g_value_unset (&value);
5361     }
5362   return ret;
5363 }
5364
5365 static gboolean
5366 _foo_igen_bar_skeleton_handle_set_property (
5367   GDBusConnection *connection,
5368   const gchar *sender,
5369   const gchar *object_path,
5370   const gchar *interface_name,
5371   const gchar *property_name,
5372   GVariant *variant,
5373   GError **error,
5374   gpointer user_data)
5375 {
5376   FooiGenBarSkeleton *skeleton = FOO_IGEN_BAR_SKELETON (user_data);
5377   GValue value = G_VALUE_INIT;
5378   GParamSpec *pspec;
5379   _ExtendedGDBusPropertyInfo *info;
5380   gboolean ret;
5381   ret = FALSE;
5382   info = (_ExtendedGDBusPropertyInfo *) g_dbus_interface_info_lookup_property ((GDBusInterfaceInfo *) &_foo_igen_bar_interface_info, property_name);
5383   g_assert (info != NULL);
5384   pspec = g_object_class_find_property (G_OBJECT_GET_CLASS (skeleton), info->hyphen_name);
5385   if (pspec == NULL)
5386     {
5387       g_set_error (error, G_DBUS_ERROR, G_DBUS_ERROR_INVALID_ARGS, "No property with name %s", property_name);
5388     }
5389   else
5390     {
5391       if (info->use_gvariant)
5392         g_value_set_variant (&value, variant);
5393       else
5394         g_dbus_gvariant_to_gvalue (variant, &value);
5395       g_object_set_property (G_OBJECT (skeleton), info->hyphen_name, &value);
5396       g_value_unset (&value);
5397       ret = TRUE;
5398     }
5399   return ret;
5400 }
5401
5402 static const GDBusInterfaceVTable _foo_igen_bar_skeleton_vtable =
5403 {
5404   _foo_igen_bar_skeleton_handle_method_call,
5405   _foo_igen_bar_skeleton_handle_get_property,
5406   _foo_igen_bar_skeleton_handle_set_property
5407 };
5408
5409 static GDBusInterfaceInfo *
5410 foo_igen_bar_skeleton_dbus_interface_get_info (GDBusInterfaceSkeleton *skeleton)
5411 {
5412   return foo_igen_bar_interface_info ();
5413 }
5414
5415 static GDBusInterfaceVTable *
5416 foo_igen_bar_skeleton_dbus_interface_get_vtable (GDBusInterfaceSkeleton *skeleton)
5417 {
5418   return (GDBusInterfaceVTable *) &_foo_igen_bar_skeleton_vtable;
5419 }
5420
5421 static GVariant *
5422 foo_igen_bar_skeleton_dbus_interface_get_properties (GDBusInterfaceSkeleton *_skeleton)
5423 {
5424   FooiGenBarSkeleton *skeleton = FOO_IGEN_BAR_SKELETON (_skeleton);
5425
5426   GVariantBuilder builder;
5427   guint n;
5428   g_variant_builder_init (&builder, G_VARIANT_TYPE ("a{sv}"));
5429   if (_foo_igen_bar_interface_info.parent_struct.properties == NULL)
5430     goto out;
5431   for (n = 0; _foo_igen_bar_interface_info.parent_struct.properties[n] != NULL; n++)
5432     {
5433       GDBusPropertyInfo *info = _foo_igen_bar_interface_info.parent_struct.properties[n];
5434       if (info->flags & G_DBUS_PROPERTY_INFO_FLAGS_READABLE)
5435         {
5436           GVariant *value;
5437           value = _foo_igen_bar_skeleton_handle_get_property (g_dbus_interface_skeleton_get_connection (G_DBUS_INTERFACE_SKELETON (skeleton)), NULL, g_dbus_interface_skeleton_get_object_path (G_DBUS_INTERFACE_SKELETON (skeleton)), "org.project.Bar", info->name, NULL, skeleton);
5438           if (value != NULL)
5439             {
5440               g_variant_take_ref (value);
5441               g_variant_builder_add (&builder, "{sv}", info->name, value);
5442               g_variant_unref (value);
5443             }
5444         }
5445     }
5446 out:
5447   return g_variant_builder_end (&builder);
5448 }
5449
5450 static gboolean _foo_igen_bar_emit_changed (gpointer user_data);
5451
5452 static void
5453 foo_igen_bar_skeleton_dbus_interface_flush (GDBusInterfaceSkeleton *_skeleton)
5454 {
5455   FooiGenBarSkeleton *skeleton = FOO_IGEN_BAR_SKELETON (_skeleton);
5456   gboolean emit_changed = FALSE;
5457
5458   g_mutex_lock (&skeleton->priv->lock);
5459   if (skeleton->priv->changed_properties_idle_source != NULL)
5460     {
5461       g_source_destroy (skeleton->priv->changed_properties_idle_source);
5462       skeleton->priv->changed_properties_idle_source = NULL;
5463       emit_changed = TRUE;
5464     }
5465   g_mutex_unlock (&skeleton->priv->lock);
5466
5467   if (emit_changed)
5468     _foo_igen_bar_emit_changed (skeleton);
5469 }
5470
5471 static void
5472 _foo_igen_bar_on_signal_test_signal (
5473     FooiGenBar *object,
5474     gint arg_val_int32,
5475     const gchar *const *arg_array_of_strings,
5476     const gchar *const *arg_array_of_bytestrings,
5477     GVariant *arg_dict_s_to_pairs)
5478 {
5479   FooiGenBarSkeleton *skeleton = FOO_IGEN_BAR_SKELETON (object);
5480
5481   GList      *connections, *l;
5482   GVariant   *signal_variant;
5483   connections = g_dbus_interface_skeleton_get_connections (G_DBUS_INTERFACE_SKELETON (skeleton));
5484
5485   signal_variant = g_variant_ref_sink (g_variant_new ("(i^as^aay@a{s(ii)})",
5486                    arg_val_int32,
5487                    arg_array_of_strings,
5488                    arg_array_of_bytestrings,
5489                    arg_dict_s_to_pairs));
5490   for (l = connections; l != NULL; l = l->next)
5491     {
5492       GDBusConnection *connection = l->data;
5493       g_dbus_connection_emit_signal (connection,
5494         NULL, g_dbus_interface_skeleton_get_object_path (G_DBUS_INTERFACE_SKELETON (skeleton)), "org.project.Bar", "TestSignal",
5495         signal_variant, NULL);
5496     }
5497   g_variant_unref (signal_variant);
5498   g_list_free_full (connections, g_object_unref);
5499 }
5500
5501 static void
5502 _foo_igen_bar_on_signal_another_signal (
5503     FooiGenBar *object,
5504     const gchar *arg_word)
5505 {
5506   FooiGenBarSkeleton *skeleton = FOO_IGEN_BAR_SKELETON (object);
5507
5508   GList      *connections, *l;
5509   GVariant   *signal_variant;
5510   connections = g_dbus_interface_skeleton_get_connections (G_DBUS_INTERFACE_SKELETON (skeleton));
5511
5512   signal_variant = g_variant_ref_sink (g_variant_new ("(s)",
5513                    arg_word));
5514   for (l = connections; l != NULL; l = l->next)
5515     {
5516       GDBusConnection *connection = l->data;
5517       g_dbus_connection_emit_signal (connection,
5518         NULL, g_dbus_interface_skeleton_get_object_path (G_DBUS_INTERFACE_SKELETON (skeleton)), "org.project.Bar", "AnotherSignal",
5519         signal_variant, NULL);
5520     }
5521   g_variant_unref (signal_variant);
5522   g_list_free_full (connections, g_object_unref);
5523 }
5524
5525 static void foo_igen_bar_skeleton_iface_init (FooiGenBarIface *iface);
5526 G_DEFINE_TYPE_WITH_CODE (FooiGenBarSkeleton, foo_igen_bar_skeleton, G_TYPE_DBUS_INTERFACE_SKELETON,
5527                          G_IMPLEMENT_INTERFACE (FOO_IGEN_TYPE_BAR, foo_igen_bar_skeleton_iface_init));
5528
5529 static void
5530 foo_igen_bar_skeleton_finalize (GObject *object)
5531 {
5532   FooiGenBarSkeleton *skeleton = FOO_IGEN_BAR_SKELETON (object);
5533   guint n;
5534   for (n = 0; n < 30; n++)
5535     g_value_unset (&skeleton->priv->properties[n]);
5536   g_free (skeleton->priv->properties);
5537   g_list_free_full (skeleton->priv->changed_properties, (GDestroyNotify) _changed_property_free);
5538   if (skeleton->priv->changed_properties_idle_source != NULL)
5539     g_source_destroy (skeleton->priv->changed_properties_idle_source);
5540   g_main_context_unref (skeleton->priv->context);
5541   g_mutex_clear (&skeleton->priv->lock);
5542   G_OBJECT_CLASS (foo_igen_bar_skeleton_parent_class)->finalize (object);
5543 }
5544
5545 static void
5546 foo_igen_bar_skeleton_get_property (GObject      *object,
5547   guint         prop_id,
5548   GValue       *value,
5549   GParamSpec   *pspec)
5550 {
5551   FooiGenBarSkeleton *skeleton = FOO_IGEN_BAR_SKELETON (object);
5552   g_assert (prop_id != 0 && prop_id - 1 < 30);
5553   g_mutex_lock (&skeleton->priv->lock);
5554   g_value_copy (&skeleton->priv->properties[prop_id - 1], value);
5555   g_mutex_unlock (&skeleton->priv->lock);
5556 }
5557
5558 static gboolean
5559 _foo_igen_bar_emit_changed (gpointer user_data)
5560 {
5561   FooiGenBarSkeleton *skeleton = FOO_IGEN_BAR_SKELETON (user_data);
5562   GList *l;
5563   GVariantBuilder builder;
5564   GVariantBuilder invalidated_builder;
5565   guint num_changes;
5566
5567   g_mutex_lock (&skeleton->priv->lock);
5568   g_variant_builder_init (&builder, G_VARIANT_TYPE ("a{sv}"));
5569   g_variant_builder_init (&invalidated_builder, G_VARIANT_TYPE ("as"));
5570   for (l = skeleton->priv->changed_properties, num_changes = 0; l != NULL; l = l->next)
5571     {
5572       ChangedProperty *cp = l->data;
5573       GVariant *variant;
5574       const GValue *cur_value;
5575
5576       cur_value = &skeleton->priv->properties[cp->prop_id - 1];
5577       if (!_g_value_equal (cur_value, &cp->orig_value))
5578         {
5579           variant = g_dbus_gvalue_to_gvariant (cur_value, G_VARIANT_TYPE (cp->info->parent_struct.signature));
5580           g_variant_builder_add (&builder, "{sv}", cp->info->parent_struct.name, variant);
5581           g_variant_unref (variant);
5582           num_changes++;
5583         }
5584     }
5585   if (num_changes > 0)
5586     {
5587       GList *connections, *l;
5588       GVariant *signal_variant;
5589       signal_variant = g_variant_ref_sink (g_variant_new ("(sa{sv}as)", "org.project.Bar",
5590                                            &builder, &invalidated_builder));
5591       connections = g_dbus_interface_skeleton_get_connections (G_DBUS_INTERFACE_SKELETON (skeleton));
5592       for (l = connections; l != NULL; l = l->next)
5593         {
5594           GDBusConnection *connection = l->data;
5595
5596           g_dbus_connection_emit_signal (connection,
5597                                          NULL, g_dbus_interface_skeleton_get_object_path (G_DBUS_INTERFACE_SKELETON (skeleton)),
5598                                          "org.freedesktop.DBus.Properties",
5599                                          "PropertiesChanged",
5600                                          signal_variant,
5601                                          NULL);
5602         }
5603       g_variant_unref (signal_variant);
5604       g_list_free_full (connections, g_object_unref);
5605     }
5606   else
5607     {
5608       g_variant_builder_clear (&builder);
5609       g_variant_builder_clear (&invalidated_builder);
5610     }
5611   g_list_free_full (skeleton->priv->changed_properties, (GDestroyNotify) _changed_property_free);
5612   skeleton->priv->changed_properties = NULL;
5613   skeleton->priv->changed_properties_idle_source = NULL;
5614   g_mutex_unlock (&skeleton->priv->lock);
5615   return FALSE;
5616 }
5617
5618 static void
5619 _foo_igen_bar_schedule_emit_changed (FooiGenBarSkeleton *skeleton, const _ExtendedGDBusPropertyInfo *info, guint prop_id, const GValue *orig_value)
5620 {
5621   ChangedProperty *cp;
5622   GList *l;
5623   cp = NULL;
5624   for (l = skeleton->priv->changed_properties; l != NULL; l = l->next)
5625     {
5626       ChangedProperty *i_cp = l->data;
5627       if (i_cp->info == info)
5628         {
5629           cp = i_cp;
5630           break;
5631         }
5632     }
5633   if (cp == NULL)
5634     {
5635       cp = g_new0 (ChangedProperty, 1);
5636       cp->prop_id = prop_id;
5637       cp->info = info;
5638       skeleton->priv->changed_properties = g_list_prepend (skeleton->priv->changed_properties, cp);
5639       g_value_init (&cp->orig_value, G_VALUE_TYPE (orig_value));
5640       g_value_copy (orig_value, &cp->orig_value);
5641     }
5642 }
5643
5644 static void
5645 foo_igen_bar_skeleton_notify (GObject      *object,
5646   GParamSpec *pspec)
5647 {
5648   FooiGenBarSkeleton *skeleton = FOO_IGEN_BAR_SKELETON (object);
5649   g_mutex_lock (&skeleton->priv->lock);
5650   if (skeleton->priv->changed_properties != NULL &&
5651       skeleton->priv->changed_properties_idle_source == NULL)
5652     {
5653       skeleton->priv->changed_properties_idle_source = g_idle_source_new ();
5654       g_source_set_priority (skeleton->priv->changed_properties_idle_source, G_PRIORITY_DEFAULT);
5655       g_source_set_callback (skeleton->priv->changed_properties_idle_source, _foo_igen_bar_emit_changed, g_object_ref (skeleton), (GDestroyNotify) g_object_unref);
5656       g_source_attach (skeleton->priv->changed_properties_idle_source, skeleton->priv->context);
5657       g_source_unref (skeleton->priv->changed_properties_idle_source);
5658     }
5659   g_mutex_unlock (&skeleton->priv->lock);
5660 }
5661
5662 static void
5663 foo_igen_bar_skeleton_set_property (GObject      *object,
5664   guint         prop_id,
5665   const GValue *value,
5666   GParamSpec   *pspec)
5667 {
5668   FooiGenBarSkeleton *skeleton = FOO_IGEN_BAR_SKELETON (object);
5669   g_assert (prop_id != 0 && prop_id - 1 < 30);
5670   g_mutex_lock (&skeleton->priv->lock);
5671   g_object_freeze_notify (object);
5672   if (!_g_value_equal (value, &skeleton->priv->properties[prop_id - 1]))
5673     {
5674       if (g_dbus_interface_skeleton_get_connection (G_DBUS_INTERFACE_SKELETON (skeleton)) != NULL)
5675         _foo_igen_bar_schedule_emit_changed (skeleton, _foo_igen_bar_property_info_pointers[prop_id - 1], prop_id, &skeleton->priv->properties[prop_id - 1]);
5676       g_value_copy (value, &skeleton->priv->properties[prop_id - 1]);
5677       g_object_notify_by_pspec (object, pspec);
5678     }
5679   g_mutex_unlock (&skeleton->priv->lock);
5680   g_object_thaw_notify (object);
5681 }
5682
5683 static void
5684 foo_igen_bar_skeleton_init (FooiGenBarSkeleton *skeleton)
5685 {
5686   skeleton->priv = G_TYPE_INSTANCE_GET_PRIVATE (skeleton, FOO_IGEN_TYPE_BAR_SKELETON, FooiGenBarSkeletonPrivate);
5687   g_mutex_init (&skeleton->priv->lock);
5688   skeleton->priv->context = g_main_context_ref_thread_default ();
5689   skeleton->priv->properties = g_new0 (GValue, 30);
5690   g_value_init (&skeleton->priv->properties[0], G_TYPE_UCHAR);
5691   g_value_init (&skeleton->priv->properties[1], G_TYPE_BOOLEAN);
5692   g_value_init (&skeleton->priv->properties[2], G_TYPE_INT);
5693   g_value_init (&skeleton->priv->properties[3], G_TYPE_UINT);
5694   g_value_init (&skeleton->priv->properties[4], G_TYPE_INT);
5695   g_value_init (&skeleton->priv->properties[5], G_TYPE_UINT);
5696   g_value_init (&skeleton->priv->properties[6], G_TYPE_INT64);
5697   g_value_init (&skeleton->priv->properties[7], G_TYPE_UINT64);
5698   g_value_init (&skeleton->priv->properties[8], G_TYPE_DOUBLE);
5699   g_value_init (&skeleton->priv->properties[9], G_TYPE_STRING);
5700   g_value_init (&skeleton->priv->properties[10], G_TYPE_STRING);
5701   g_value_init (&skeleton->priv->properties[11], G_TYPE_STRING);
5702   g_value_init (&skeleton->priv->properties[12], G_TYPE_STRING);
5703   g_value_init (&skeleton->priv->properties[13], G_TYPE_STRV);
5704   g_value_init (&skeleton->priv->properties[14], G_TYPE_STRV);
5705   g_value_init (&skeleton->priv->properties[15], G_TYPE_STRV);
5706   g_value_init (&skeleton->priv->properties[16], G_TYPE_VARIANT);
5707   g_value_init (&skeleton->priv->properties[17], G_TYPE_STRING);
5708   g_value_init (&skeleton->priv->properties[18], G_TYPE_STRING);
5709   g_value_init (&skeleton->priv->properties[19], G_TYPE_STRING);
5710   g_value_init (&skeleton->priv->properties[20], G_TYPE_INT);
5711   g_value_init (&skeleton->priv->properties[21], G_TYPE_DOUBLE);
5712   g_value_init (&skeleton->priv->properties[22], G_TYPE_STRING);
5713   g_value_init (&skeleton->priv->properties[23], G_TYPE_STRING);
5714   g_value_init (&skeleton->priv->properties[24], G_TYPE_STRING);
5715   g_value_init (&skeleton->priv->properties[25], G_TYPE_STRING);
5716   g_value_init (&skeleton->priv->properties[26], G_TYPE_STRV);
5717   g_value_init (&skeleton->priv->properties[27], G_TYPE_STRV);
5718   g_value_init (&skeleton->priv->properties[28], G_TYPE_VARIANT);
5719   g_value_init (&skeleton->priv->properties[29], G_TYPE_VARIANT);
5720 }
5721
5722 static guchar 
5723 foo_igen_bar_skeleton_get_y (FooiGenBar *object)
5724 {
5725   FooiGenBarSkeleton *skeleton = FOO_IGEN_BAR_SKELETON (object);
5726   guchar value;
5727   g_mutex_lock (&skeleton->priv->lock);
5728   value = g_value_get_uchar (&(skeleton->priv->properties[0]));
5729   g_mutex_unlock (&skeleton->priv->lock);
5730   return value;
5731 }
5732
5733 static gboolean 
5734 foo_igen_bar_skeleton_get_b (FooiGenBar *object)
5735 {
5736   FooiGenBarSkeleton *skeleton = FOO_IGEN_BAR_SKELETON (object);
5737   gboolean value;
5738   g_mutex_lock (&skeleton->priv->lock);
5739   value = g_value_get_boolean (&(skeleton->priv->properties[1]));
5740   g_mutex_unlock (&skeleton->priv->lock);
5741   return value;
5742 }
5743
5744 static gint16 
5745 foo_igen_bar_skeleton_get_n (FooiGenBar *object)
5746 {
5747   FooiGenBarSkeleton *skeleton = FOO_IGEN_BAR_SKELETON (object);
5748   gint value;
5749   g_mutex_lock (&skeleton->priv->lock);
5750   value = g_value_get_int (&(skeleton->priv->properties[2]));
5751   g_mutex_unlock (&skeleton->priv->lock);
5752   return value;
5753 }
5754
5755 static guint16 
5756 foo_igen_bar_skeleton_get_q (FooiGenBar *object)
5757 {
5758   FooiGenBarSkeleton *skeleton = FOO_IGEN_BAR_SKELETON (object);
5759   guint value;
5760   g_mutex_lock (&skeleton->priv->lock);
5761   value = g_value_get_uint (&(skeleton->priv->properties[3]));
5762   g_mutex_unlock (&skeleton->priv->lock);
5763   return value;
5764 }
5765
5766 static gint 
5767 foo_igen_bar_skeleton_get_i (FooiGenBar *object)
5768 {
5769   FooiGenBarSkeleton *skeleton = FOO_IGEN_BAR_SKELETON (object);
5770   gint value;
5771   g_mutex_lock (&skeleton->priv->lock);
5772   value = g_value_get_int (&(skeleton->priv->properties[4]));
5773   g_mutex_unlock (&skeleton->priv->lock);
5774   return value;
5775 }
5776
5777 static guint 
5778 foo_igen_bar_skeleton_get_u (FooiGenBar *object)
5779 {
5780   FooiGenBarSkeleton *skeleton = FOO_IGEN_BAR_SKELETON (object);
5781   guint value;
5782   g_mutex_lock (&skeleton->priv->lock);
5783   value = g_value_get_uint (&(skeleton->priv->properties[5]));
5784   g_mutex_unlock (&skeleton->priv->lock);
5785   return value;
5786 }
5787
5788 static gint64 
5789 foo_igen_bar_skeleton_get_x (FooiGenBar *object)
5790 {
5791   FooiGenBarSkeleton *skeleton = FOO_IGEN_BAR_SKELETON (object);
5792   gint64 value;
5793   g_mutex_lock (&skeleton->priv->lock);
5794   value = g_value_get_int64 (&(skeleton->priv->properties[6]));
5795   g_mutex_unlock (&skeleton->priv->lock);
5796   return value;
5797 }
5798
5799 static guint64 
5800 foo_igen_bar_skeleton_get_t (FooiGenBar *object)
5801 {
5802   FooiGenBarSkeleton *skeleton = FOO_IGEN_BAR_SKELETON (object);
5803   guint64 value;
5804   g_mutex_lock (&skeleton->priv->lock);
5805   value = g_value_get_uint64 (&(skeleton->priv->properties[7]));
5806   g_mutex_unlock (&skeleton->priv->lock);
5807   return value;
5808 }
5809
5810 static gdouble 
5811 foo_igen_bar_skeleton_get_d (FooiGenBar *object)
5812 {
5813   FooiGenBarSkeleton *skeleton = FOO_IGEN_BAR_SKELETON (object);
5814   gdouble value;
5815   g_mutex_lock (&skeleton->priv->lock);
5816   value = g_value_get_double (&(skeleton->priv->properties[8]));
5817   g_mutex_unlock (&skeleton->priv->lock);
5818   return value;
5819 }
5820
5821 static const gchar *
5822 foo_igen_bar_skeleton_get_s (FooiGenBar *object)
5823 {
5824   FooiGenBarSkeleton *skeleton = FOO_IGEN_BAR_SKELETON (object);
5825   const gchar *value;
5826   g_mutex_lock (&skeleton->priv->lock);
5827   value = g_value_get_string (&(skeleton->priv->properties[9]));
5828   g_mutex_unlock (&skeleton->priv->lock);
5829   return value;
5830 }
5831
5832 static const gchar *
5833 foo_igen_bar_skeleton_get_o (FooiGenBar *object)
5834 {
5835   FooiGenBarSkeleton *skeleton = FOO_IGEN_BAR_SKELETON (object);
5836   const gchar *value;
5837   g_mutex_lock (&skeleton->priv->lock);
5838   value = g_value_get_string (&(skeleton->priv->properties[10]));
5839   g_mutex_unlock (&skeleton->priv->lock);
5840   return value;
5841 }
5842
5843 static const gchar *
5844 foo_igen_bar_skeleton_get_g (FooiGenBar *object)
5845 {
5846   FooiGenBarSkeleton *skeleton = FOO_IGEN_BAR_SKELETON (object);
5847   const gchar *value;
5848   g_mutex_lock (&skeleton->priv->lock);
5849   value = g_value_get_string (&(skeleton->priv->properties[11]));
5850   g_mutex_unlock (&skeleton->priv->lock);
5851   return value;
5852 }
5853
5854 static const gchar *
5855 foo_igen_bar_skeleton_get_ay (FooiGenBar *object)
5856 {
5857   FooiGenBarSkeleton *skeleton = FOO_IGEN_BAR_SKELETON (object);
5858   const gchar *value;
5859   g_mutex_lock (&skeleton->priv->lock);
5860   value = g_value_get_string (&(skeleton->priv->properties[12]));
5861   g_mutex_unlock (&skeleton->priv->lock);
5862   return value;
5863 }
5864
5865 static const gchar *const *
5866 foo_igen_bar_skeleton_get_as (FooiGenBar *object)
5867 {
5868   FooiGenBarSkeleton *skeleton = FOO_IGEN_BAR_SKELETON (object);
5869   const gchar *const *value;
5870   g_mutex_lock (&skeleton->priv->lock);
5871   value = g_value_get_boxed (&(skeleton->priv->properties[13]));
5872   g_mutex_unlock (&skeleton->priv->lock);
5873   return value;
5874 }
5875
5876 static const gchar *const *
5877 foo_igen_bar_skeleton_get_aay (FooiGenBar *object)
5878 {
5879   FooiGenBarSkeleton *skeleton = FOO_IGEN_BAR_SKELETON (object);
5880   const gchar *const *value;
5881   g_mutex_lock (&skeleton->priv->lock);
5882   value = g_value_get_boxed (&(skeleton->priv->properties[14]));
5883   g_mutex_unlock (&skeleton->priv->lock);
5884   return value;
5885 }
5886
5887 static const gchar *const *
5888 foo_igen_bar_skeleton_get_ao (FooiGenBar *object)
5889 {
5890   FooiGenBarSkeleton *skeleton = FOO_IGEN_BAR_SKELETON (object);
5891   const gchar *const *value;
5892   g_mutex_lock (&skeleton->priv->lock);
5893   value = g_value_get_boxed (&(skeleton->priv->properties[15]));
5894   g_mutex_unlock (&skeleton->priv->lock);
5895   return value;
5896 }
5897
5898 static GVariant *
5899 foo_igen_bar_skeleton_get_ag (FooiGenBar *object)
5900 {
5901   FooiGenBarSkeleton *skeleton = FOO_IGEN_BAR_SKELETON (object);
5902   GVariant *value;
5903   g_mutex_lock (&skeleton->priv->lock);
5904   value = g_value_get_variant (&(skeleton->priv->properties[16]));
5905   g_mutex_unlock (&skeleton->priv->lock);
5906   return value;
5907 }
5908
5909 static const gchar *
5910 foo_igen_bar_skeleton_get_finally_normal_name (FooiGenBar *object)
5911 {
5912   FooiGenBarSkeleton *skeleton = FOO_IGEN_BAR_SKELETON (object);
5913   const gchar *value;
5914   g_mutex_lock (&skeleton->priv->lock);
5915   value = g_value_get_string (&(skeleton->priv->properties[17]));
5916   g_mutex_unlock (&skeleton->priv->lock);
5917   return value;
5918 }
5919
5920 static const gchar *
5921 foo_igen_bar_skeleton_get_readonly_property (FooiGenBar *object)
5922 {
5923   FooiGenBarSkeleton *skeleton = FOO_IGEN_BAR_SKELETON (object);
5924   const gchar *value;
5925   g_mutex_lock (&skeleton->priv->lock);
5926   value = g_value_get_string (&(skeleton->priv->properties[18]));
5927   g_mutex_unlock (&skeleton->priv->lock);
5928   return value;
5929 }
5930
5931 static const gchar *
5932 foo_igen_bar_skeleton_get_writeonly_property (FooiGenBar *object)
5933 {
5934   FooiGenBarSkeleton *skeleton = FOO_IGEN_BAR_SKELETON (object);
5935   const gchar *value;
5936   g_mutex_lock (&skeleton->priv->lock);
5937   value = g_value_get_string (&(skeleton->priv->properties[19]));
5938   g_mutex_unlock (&skeleton->priv->lock);
5939   return value;
5940 }
5941
5942 static gint 
5943 foo_igen_bar_skeleton_get_unset_i (FooiGenBar *object)
5944 {
5945   FooiGenBarSkeleton *skeleton = FOO_IGEN_BAR_SKELETON (object);
5946   gint value;
5947   g_mutex_lock (&skeleton->priv->lock);
5948   value = g_value_get_int (&(skeleton->priv->properties[20]));
5949   g_mutex_unlock (&skeleton->priv->lock);
5950   return value;
5951 }
5952
5953 static gdouble 
5954 foo_igen_bar_skeleton_get_unset_d (FooiGenBar *object)
5955 {
5956   FooiGenBarSkeleton *skeleton = FOO_IGEN_BAR_SKELETON (object);
5957   gdouble value;
5958   g_mutex_lock (&skeleton->priv->lock);
5959   value = g_value_get_double (&(skeleton->priv->properties[21]));
5960   g_mutex_unlock (&skeleton->priv->lock);
5961   return value;
5962 }
5963
5964 static const gchar *
5965 foo_igen_bar_skeleton_get_unset_s (FooiGenBar *object)
5966 {
5967   FooiGenBarSkeleton *skeleton = FOO_IGEN_BAR_SKELETON (object);
5968   const gchar *value;
5969   g_mutex_lock (&skeleton->priv->lock);
5970   value = g_value_get_string (&(skeleton->priv->properties[22]));
5971   g_mutex_unlock (&skeleton->priv->lock);
5972   return value;
5973 }
5974
5975 static const gchar *
5976 foo_igen_bar_skeleton_get_unset_o (FooiGenBar *object)
5977 {
5978   FooiGenBarSkeleton *skeleton = FOO_IGEN_BAR_SKELETON (object);
5979   const gchar *value;
5980   g_mutex_lock (&skeleton->priv->lock);
5981   value = g_value_get_string (&(skeleton->priv->properties[23]));
5982   g_mutex_unlock (&skeleton->priv->lock);
5983   return value;
5984 }
5985
5986 static const gchar *
5987 foo_igen_bar_skeleton_get_unset_g (FooiGenBar *object)
5988 {
5989   FooiGenBarSkeleton *skeleton = FOO_IGEN_BAR_SKELETON (object);
5990   const gchar *value;
5991   g_mutex_lock (&skeleton->priv->lock);
5992   value = g_value_get_string (&(skeleton->priv->properties[24]));
5993   g_mutex_unlock (&skeleton->priv->lock);
5994   return value;
5995 }
5996
5997 static const gchar *
5998 foo_igen_bar_skeleton_get_unset_ay (FooiGenBar *object)
5999 {
6000   FooiGenBarSkeleton *skeleton = FOO_IGEN_BAR_SKELETON (object);
6001   const gchar *value;
6002   g_mutex_lock (&skeleton->priv->lock);
6003   value = g_value_get_string (&(skeleton->priv->properties[25]));
6004   g_mutex_unlock (&skeleton->priv->lock);
6005   return value;
6006 }
6007
6008 static const gchar *const *
6009 foo_igen_bar_skeleton_get_unset_as (FooiGenBar *object)
6010 {
6011   FooiGenBarSkeleton *skeleton = FOO_IGEN_BAR_SKELETON (object);
6012   const gchar *const *value;
6013   g_mutex_lock (&skeleton->priv->lock);
6014   value = g_value_get_boxed (&(skeleton->priv->properties[26]));
6015   g_mutex_unlock (&skeleton->priv->lock);
6016   return value;
6017 }
6018
6019 static const gchar *const *
6020 foo_igen_bar_skeleton_get_unset_ao (FooiGenBar *object)
6021 {
6022   FooiGenBarSkeleton *skeleton = FOO_IGEN_BAR_SKELETON (object);
6023   const gchar *const *value;
6024   g_mutex_lock (&skeleton->priv->lock);
6025   value = g_value_get_boxed (&(skeleton->priv->properties[27]));
6026   g_mutex_unlock (&skeleton->priv->lock);
6027   return value;
6028 }
6029
6030 static GVariant *
6031 foo_igen_bar_skeleton_get_unset_ag (FooiGenBar *object)
6032 {
6033   FooiGenBarSkeleton *skeleton = FOO_IGEN_BAR_SKELETON (object);
6034   GVariant *value;
6035   g_mutex_lock (&skeleton->priv->lock);
6036   value = g_value_get_variant (&(skeleton->priv->properties[28]));
6037   g_mutex_unlock (&skeleton->priv->lock);
6038   return value;
6039 }
6040
6041 static GVariant *
6042 foo_igen_bar_skeleton_get_unset_struct (FooiGenBar *object)
6043 {
6044   FooiGenBarSkeleton *skeleton = FOO_IGEN_BAR_SKELETON (object);
6045   GVariant *value;
6046   g_mutex_lock (&skeleton->priv->lock);
6047   value = g_value_get_variant (&(skeleton->priv->properties[29]));
6048   g_mutex_unlock (&skeleton->priv->lock);
6049   return value;
6050 }
6051
6052 static void
6053 foo_igen_bar_skeleton_class_init (FooiGenBarSkeletonClass *klass)
6054 {
6055   GObjectClass *gobject_class;
6056   GDBusInterfaceSkeletonClass *skeleton_class;
6057
6058   g_type_class_add_private (klass, sizeof (FooiGenBarSkeletonPrivate));
6059
6060   gobject_class = G_OBJECT_CLASS (klass);
6061   gobject_class->finalize = foo_igen_bar_skeleton_finalize;
6062   gobject_class->get_property = foo_igen_bar_skeleton_get_property;
6063   gobject_class->set_property = foo_igen_bar_skeleton_set_property;
6064   gobject_class->notify       = foo_igen_bar_skeleton_notify;
6065
6066
6067   foo_igen_bar_override_properties (gobject_class, 1);
6068
6069   skeleton_class = G_DBUS_INTERFACE_SKELETON_CLASS (klass);
6070   skeleton_class->get_info = foo_igen_bar_skeleton_dbus_interface_get_info;
6071   skeleton_class->get_properties = foo_igen_bar_skeleton_dbus_interface_get_properties;
6072   skeleton_class->flush = foo_igen_bar_skeleton_dbus_interface_flush;
6073   skeleton_class->get_vtable = foo_igen_bar_skeleton_dbus_interface_get_vtable;
6074 }
6075
6076 static void
6077 foo_igen_bar_skeleton_iface_init (FooiGenBarIface *iface)
6078 {
6079   iface->test_signal = _foo_igen_bar_on_signal_test_signal;
6080   iface->another_signal = _foo_igen_bar_on_signal_another_signal;
6081   iface->get_y = foo_igen_bar_skeleton_get_y;
6082   iface->get_b = foo_igen_bar_skeleton_get_b;
6083   iface->get_n = foo_igen_bar_skeleton_get_n;
6084   iface->get_q = foo_igen_bar_skeleton_get_q;
6085   iface->get_i = foo_igen_bar_skeleton_get_i;
6086   iface->get_u = foo_igen_bar_skeleton_get_u;
6087   iface->get_x = foo_igen_bar_skeleton_get_x;
6088   iface->get_t = foo_igen_bar_skeleton_get_t;
6089   iface->get_d = foo_igen_bar_skeleton_get_d;
6090   iface->get_s = foo_igen_bar_skeleton_get_s;
6091   iface->get_o = foo_igen_bar_skeleton_get_o;
6092   iface->get_g = foo_igen_bar_skeleton_get_g;
6093   iface->get_ay = foo_igen_bar_skeleton_get_ay;
6094   iface->get_as = foo_igen_bar_skeleton_get_as;
6095   iface->get_aay = foo_igen_bar_skeleton_get_aay;
6096   iface->get_ao = foo_igen_bar_skeleton_get_ao;
6097   iface->get_ag = foo_igen_bar_skeleton_get_ag;
6098   iface->get_finally_normal_name = foo_igen_bar_skeleton_get_finally_normal_name;
6099   iface->get_readonly_property = foo_igen_bar_skeleton_get_readonly_property;
6100   iface->get_writeonly_property = foo_igen_bar_skeleton_get_writeonly_property;
6101   iface->get_unset_i = foo_igen_bar_skeleton_get_unset_i;
6102   iface->get_unset_d = foo_igen_bar_skeleton_get_unset_d;
6103   iface->get_unset_s = foo_igen_bar_skeleton_get_unset_s;
6104   iface->get_unset_o = foo_igen_bar_skeleton_get_unset_o;
6105   iface->get_unset_g = foo_igen_bar_skeleton_get_unset_g;
6106   iface->get_unset_ay = foo_igen_bar_skeleton_get_unset_ay;
6107   iface->get_unset_as = foo_igen_bar_skeleton_get_unset_as;
6108   iface->get_unset_ao = foo_igen_bar_skeleton_get_unset_ao;
6109   iface->get_unset_ag = foo_igen_bar_skeleton_get_unset_ag;
6110   iface->get_unset_struct = foo_igen_bar_skeleton_get_unset_struct;
6111 }
6112
6113 /**
6114  * foo_igen_bar_skeleton_new:
6115  *
6116  * Creates a skeleton object for the D-Bus interface <link linkend="gdbus-interface-org-project-Bar.top_of_page">org.project.Bar</link>.
6117  *
6118  * Returns: (transfer full) (type FooiGenBarSkeleton): The skeleton object.
6119  */
6120 FooiGenBar *
6121 foo_igen_bar_skeleton_new (void)
6122 {
6123   return FOO_IGEN_BAR (g_object_new (FOO_IGEN_TYPE_BAR_SKELETON, NULL));
6124 }
6125
6126 /* ------------------------------------------------------------------------
6127  * Code for interface org.project.Bar.Frobnicator
6128  * ------------------------------------------------------------------------
6129  */
6130
6131 /**
6132  * SECTION:FooiGenBarFrobnicator
6133  * @title: FooiGenBarFrobnicator
6134  * @short_description: Generated C code for the org.project.Bar.Frobnicator D-Bus interface
6135  *
6136  * This section contains code for working with the <link linkend="gdbus-interface-org-project-Bar-Frobnicator.top_of_page">org.project.Bar.Frobnicator</link> D-Bus interface in C.
6137  */
6138
6139 /* ---- Introspection data for org.project.Bar.Frobnicator ---- */
6140
6141 static const _ExtendedGDBusMethodInfo _foo_igen_bar_frobnicator_method_info_random_method =
6142 {
6143   {
6144     -1,
6145     "RandomMethod",
6146     NULL,
6147     NULL,
6148     NULL
6149   },
6150   "handle-random-method",
6151   FALSE
6152 };
6153
6154 static const _ExtendedGDBusMethodInfo * const _foo_igen_bar_frobnicator_method_info_pointers[] =
6155 {
6156   &_foo_igen_bar_frobnicator_method_info_random_method,
6157   NULL
6158 };
6159
6160 static const _ExtendedGDBusInterfaceInfo _foo_igen_bar_frobnicator_interface_info =
6161 {
6162   {
6163     -1,
6164     "org.project.Bar.Frobnicator",
6165     (GDBusMethodInfo **) &_foo_igen_bar_frobnicator_method_info_pointers,
6166     NULL,
6167     NULL,
6168     NULL
6169   },
6170   "bar-frobnicator",
6171 };
6172
6173
6174 /**
6175  * foo_igen_bar_frobnicator_interface_info:
6176  *
6177  * Gets a machine-readable description of the <link linkend="gdbus-interface-org-project-Bar-Frobnicator.top_of_page">org.project.Bar.Frobnicator</link> D-Bus interface.
6178  *
6179  * Returns: (transfer none): A #GDBusInterfaceInfo. Do not free.
6180  */
6181 GDBusInterfaceInfo *
6182 foo_igen_bar_frobnicator_interface_info (void)
6183 {
6184   return (GDBusInterfaceInfo *) &_foo_igen_bar_frobnicator_interface_info;
6185 }
6186
6187 /**
6188  * foo_igen_bar_frobnicator_override_properties:
6189  * @klass: The class structure for a #GObject<!-- -->-derived class.
6190  * @property_id_begin: The property id to assign to the first overridden property.
6191  *
6192  * Overrides all #GObject properties in the #FooiGenBarFrobnicator interface for a concrete class.
6193  * The properties are overridden in the order they are defined.
6194  *
6195  * Returns: The last property id.
6196  */
6197 guint
6198 foo_igen_bar_frobnicator_override_properties (GObjectClass *klass, guint property_id_begin)
6199 {
6200   return property_id_begin - 1;
6201 }
6202
6203
6204
6205 /**
6206  * FooiGenBarFrobnicator:
6207  *
6208  * Abstract interface type for the D-Bus interface <link linkend="gdbus-interface-org-project-Bar-Frobnicator.top_of_page">org.project.Bar.Frobnicator</link>.
6209  */
6210
6211 /**
6212  * FooiGenBarFrobnicatorIface:
6213  * @parent_iface: The parent interface.
6214  * @handle_random_method: Handler for the #FooiGenBarFrobnicator::handle-random-method signal.
6215  *
6216  * Virtual table for the D-Bus interface <link linkend="gdbus-interface-org-project-Bar-Frobnicator.top_of_page">org.project.Bar.Frobnicator</link>.
6217  */
6218
6219 static void
6220 foo_igen_bar_frobnicator_default_init (FooiGenBarFrobnicatorIface *iface)
6221 {
6222   /* GObject signals for incoming D-Bus method calls: */
6223   /**
6224    * FooiGenBarFrobnicator::handle-random-method:
6225    * @object: A #FooiGenBarFrobnicator.
6226    * @invocation: A #GDBusMethodInvocation.
6227    *
6228    * Signal emitted when a remote caller is invoking the <link linkend="gdbus-method-org-project-Bar-Frobnicator.RandomMethod">RandomMethod()</link> D-Bus method.
6229    *
6230    * If a signal handler returns %TRUE, it means the signal handler will handle the invocation (e.g. take a reference to @invocation and eventually call foo_igen_bar_frobnicator_complete_random_method() or e.g. g_dbus_method_invocation_return_error() on it) and no order signal handlers will run. If no signal handler handles the invocation, the %G_DBUS_ERROR_UNKNOWN_METHOD error is returned.
6231    *
6232    * Returns: %TRUE if the invocation was handled, %FALSE to let other signal handlers run.
6233    */
6234   g_signal_new ("handle-random-method",
6235     G_TYPE_FROM_INTERFACE (iface),
6236     G_SIGNAL_RUN_LAST,
6237     G_STRUCT_OFFSET (FooiGenBarFrobnicatorIface, handle_random_method),
6238     g_signal_accumulator_true_handled,
6239     NULL,
6240     g_cclosure_marshal_generic,
6241     G_TYPE_BOOLEAN,
6242     1,
6243     G_TYPE_DBUS_METHOD_INVOCATION);
6244
6245 }
6246
6247 typedef FooiGenBarFrobnicatorIface FooiGenBarFrobnicatorInterface;
6248 G_DEFINE_INTERFACE (FooiGenBarFrobnicator, foo_igen_bar_frobnicator, G_TYPE_OBJECT);
6249
6250 /**
6251  * foo_igen_bar_frobnicator_call_random_method:
6252  * @proxy: A #FooiGenBarFrobnicatorProxy.
6253  * @cancellable: (allow-none): A #GCancellable or %NULL.
6254  * @callback: A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
6255  * @user_data: User data to pass to @callback.
6256  *
6257  * Asynchronously invokes the <link linkend="gdbus-method-org-project-Bar-Frobnicator.RandomMethod">RandomMethod()</link> D-Bus method on @proxy.
6258  * When the operation is finished, @callback will be invoked in the <link linkend="g-main-context-push-thread-default">thread-default main loop</link> of the thread you are calling this method from.
6259  * You can then call foo_igen_bar_frobnicator_call_random_method_finish() to get the result of the operation.
6260  *
6261  * See foo_igen_bar_frobnicator_call_random_method_sync() for the synchronous, blocking version of this method.
6262  */
6263 void
6264 foo_igen_bar_frobnicator_call_random_method (
6265     FooiGenBarFrobnicator *proxy,
6266     GCancellable *cancellable,
6267     GAsyncReadyCallback callback,
6268     gpointer user_data)
6269 {
6270   g_dbus_proxy_call (G_DBUS_PROXY (proxy),
6271     "RandomMethod",
6272     g_variant_new ("()"),
6273     G_DBUS_CALL_FLAGS_NONE,
6274     -1,
6275     cancellable,
6276     callback,
6277     user_data);
6278 }
6279
6280 /**
6281  * foo_igen_bar_frobnicator_call_random_method_finish:
6282  * @proxy: A #FooiGenBarFrobnicatorProxy.
6283  * @res: The #GAsyncResult obtained from the #GAsyncReadyCallback passed to foo_igen_bar_frobnicator_call_random_method().
6284  * @error: Return location for error or %NULL.
6285  *
6286  * Finishes an operation started with foo_igen_bar_frobnicator_call_random_method().
6287  *
6288  * Returns: (skip): %TRUE if the call succeded, %FALSE if @error is set.
6289  */
6290 gboolean
6291 foo_igen_bar_frobnicator_call_random_method_finish (
6292     FooiGenBarFrobnicator *proxy,
6293     GAsyncResult *res,
6294     GError **error)
6295 {
6296   GVariant *_ret;
6297   _ret = g_dbus_proxy_call_finish (G_DBUS_PROXY (proxy), res, error);
6298   if (_ret == NULL)
6299     goto _out;
6300   g_variant_get (_ret,
6301                  "()");
6302   g_variant_unref (_ret);
6303 _out:
6304   return _ret != NULL;
6305 }
6306
6307 /**
6308  * foo_igen_bar_frobnicator_call_random_method_sync:
6309  * @proxy: A #FooiGenBarFrobnicatorProxy.
6310  * @cancellable: (allow-none): A #GCancellable or %NULL.
6311  * @error: Return location for error or %NULL.
6312  *
6313  * Synchronously invokes the <link linkend="gdbus-method-org-project-Bar-Frobnicator.RandomMethod">RandomMethod()</link> D-Bus method on @proxy. The calling thread is blocked until a reply is received.
6314  *
6315  * See foo_igen_bar_frobnicator_call_random_method() for the asynchronous version of this method.
6316  *
6317  * Returns: (skip): %TRUE if the call succeded, %FALSE if @error is set.
6318  */
6319 gboolean
6320 foo_igen_bar_frobnicator_call_random_method_sync (
6321     FooiGenBarFrobnicator *proxy,
6322     GCancellable *cancellable,
6323     GError **error)
6324 {
6325   GVariant *_ret;
6326   _ret = g_dbus_proxy_call_sync (G_DBUS_PROXY (proxy),
6327     "RandomMethod",
6328     g_variant_new ("()"),
6329     G_DBUS_CALL_FLAGS_NONE,
6330     -1,
6331     cancellable,
6332     error);
6333   if (_ret == NULL)
6334     goto _out;
6335   g_variant_get (_ret,
6336                  "()");
6337   g_variant_unref (_ret);
6338 _out:
6339   return _ret != NULL;
6340 }
6341
6342 /**
6343  * foo_igen_bar_frobnicator_complete_random_method:
6344  * @object: A #FooiGenBarFrobnicator.
6345  * @invocation: (transfer full): A #GDBusMethodInvocation.
6346  *
6347  * Helper function used in service implementations to finish handling invocations of the <link linkend="gdbus-method-org-project-Bar-Frobnicator.RandomMethod">RandomMethod()</link> D-Bus method. If you instead want to finish handling an invocation by returning an error, use g_dbus_method_invocation_return_error() or similar.
6348  *
6349  * This method will free @invocation, you cannot use it afterwards.
6350  */
6351 void
6352 foo_igen_bar_frobnicator_complete_random_method (
6353     FooiGenBarFrobnicator *object,
6354     GDBusMethodInvocation *invocation)
6355 {
6356   g_dbus_method_invocation_return_value (invocation,
6357     g_variant_new ("()"));
6358 }
6359
6360 /* ------------------------------------------------------------------------ */
6361
6362 /**
6363  * FooiGenBarFrobnicatorProxy:
6364  *
6365  * The #FooiGenBarFrobnicatorProxy structure contains only private data and should only be accessed using the provided API.
6366  */
6367
6368 /**
6369  * FooiGenBarFrobnicatorProxyClass:
6370  * @parent_class: The parent class.
6371  *
6372  * Class structure for #FooiGenBarFrobnicatorProxy.
6373  */
6374
6375 struct _FooiGenBarFrobnicatorProxyPrivate
6376 {
6377   GData *qdata;
6378 };
6379
6380 static void foo_igen_bar_frobnicator_proxy_iface_init (FooiGenBarFrobnicatorIface *iface);
6381
6382 G_DEFINE_TYPE_WITH_CODE (FooiGenBarFrobnicatorProxy, foo_igen_bar_frobnicator_proxy, G_TYPE_DBUS_PROXY,
6383                          G_IMPLEMENT_INTERFACE (FOO_IGEN_TYPE_BAR_FROBNICATOR, foo_igen_bar_frobnicator_proxy_iface_init));
6384
6385 static void
6386 foo_igen_bar_frobnicator_proxy_finalize (GObject *object)
6387 {
6388   FooiGenBarFrobnicatorProxy *proxy = FOO_IGEN_BAR_FROBNICATOR_PROXY (object);
6389   g_datalist_clear (&proxy->priv->qdata);
6390   G_OBJECT_CLASS (foo_igen_bar_frobnicator_proxy_parent_class)->finalize (object);
6391 }
6392
6393 static void
6394 foo_igen_bar_frobnicator_proxy_get_property (GObject      *object,
6395   guint         prop_id,
6396   GValue       *value,
6397   GParamSpec   *pspec)
6398 {
6399 }
6400
6401 static void
6402 foo_igen_bar_frobnicator_proxy_set_property (GObject      *object,
6403   guint         prop_id,
6404   const GValue *value,
6405   GParamSpec   *pspec)
6406 {
6407 }
6408
6409 static void
6410 foo_igen_bar_frobnicator_proxy_g_signal (GDBusProxy *proxy,
6411   const gchar *sender_name,
6412   const gchar *signal_name,
6413   GVariant *parameters)
6414 {
6415   _ExtendedGDBusSignalInfo *info;
6416   GVariantIter iter;
6417   GVariant *child;
6418   GValue *paramv;
6419   guint num_params;
6420   guint n;
6421   guint signal_id;
6422   info = (_ExtendedGDBusSignalInfo *) g_dbus_interface_info_lookup_signal ((GDBusInterfaceInfo *) &_foo_igen_bar_frobnicator_interface_info, signal_name);
6423   if (info == NULL)
6424     return;
6425   num_params = g_variant_n_children (parameters);
6426   paramv = g_new0 (GValue, num_params + 1);
6427   g_value_init (&paramv[0], FOO_IGEN_TYPE_BAR_FROBNICATOR);
6428   g_value_set_object (&paramv[0], proxy);
6429   g_variant_iter_init (&iter, parameters);
6430   n = 1;
6431   while ((child = g_variant_iter_next_value (&iter)) != NULL)
6432     {
6433       _ExtendedGDBusArgInfo *arg_info = (_ExtendedGDBusArgInfo *) info->parent_struct.args[n - 1];
6434       if (arg_info->use_gvariant)
6435         {
6436           g_value_init (&paramv[n], G_TYPE_VARIANT);
6437           g_value_set_variant (&paramv[n], child);
6438           n++;
6439         }
6440       else
6441         g_dbus_gvariant_to_gvalue (child, &paramv[n++]);
6442       g_variant_unref (child);
6443     }
6444   signal_id = g_signal_lookup (info->signal_name, FOO_IGEN_TYPE_BAR_FROBNICATOR);
6445   g_signal_emitv (paramv, signal_id, 0, NULL);
6446   for (n = 0; n < num_params + 1; n++)
6447     g_value_unset (&paramv[n]);
6448   g_free (paramv);
6449 }
6450
6451 static void
6452 foo_igen_bar_frobnicator_proxy_g_properties_changed (GDBusProxy *_proxy,
6453   GVariant *changed_properties,
6454   const gchar *const *invalidated_properties)
6455 {
6456   FooiGenBarFrobnicatorProxy *proxy = FOO_IGEN_BAR_FROBNICATOR_PROXY (_proxy);
6457   guint n;
6458   const gchar *key;
6459   GVariantIter *iter;
6460   _ExtendedGDBusPropertyInfo *info;
6461   g_variant_get (changed_properties, "a{sv}", &iter);
6462   while (g_variant_iter_next (iter, "{&sv}", &key, NULL))
6463     {
6464       info = (_ExtendedGDBusPropertyInfo *) g_dbus_interface_info_lookup_property ((GDBusInterfaceInfo *) &_foo_igen_bar_frobnicator_interface_info, key);
6465       g_datalist_remove_data (&proxy->priv->qdata, key);
6466       if (info != NULL)
6467         g_object_notify (G_OBJECT (proxy), info->hyphen_name);
6468     }
6469   g_variant_iter_free (iter);
6470   for (n = 0; invalidated_properties[n] != NULL; n++)
6471     {
6472       info = (_ExtendedGDBusPropertyInfo *) g_dbus_interface_info_lookup_property ((GDBusInterfaceInfo *) &_foo_igen_bar_frobnicator_interface_info, invalidated_properties[n]);
6473       g_datalist_remove_data (&proxy->priv->qdata, invalidated_properties[n]);
6474       if (info != NULL)
6475         g_object_notify (G_OBJECT (proxy), info->hyphen_name);
6476     }
6477 }
6478
6479 static void
6480 foo_igen_bar_frobnicator_proxy_init (FooiGenBarFrobnicatorProxy *proxy)
6481 {
6482   proxy->priv = G_TYPE_INSTANCE_GET_PRIVATE (proxy, FOO_IGEN_TYPE_BAR_FROBNICATOR_PROXY, FooiGenBarFrobnicatorProxyPrivate);
6483   g_dbus_proxy_set_interface_info (G_DBUS_PROXY (proxy), foo_igen_bar_frobnicator_interface_info ());
6484 }
6485
6486 static void
6487 foo_igen_bar_frobnicator_proxy_class_init (FooiGenBarFrobnicatorProxyClass *klass)
6488 {
6489   GObjectClass *gobject_class;
6490   GDBusProxyClass *proxy_class;
6491
6492   g_type_class_add_private (klass, sizeof (FooiGenBarFrobnicatorProxyPrivate));
6493
6494   gobject_class = G_OBJECT_CLASS (klass);
6495   gobject_class->finalize     = foo_igen_bar_frobnicator_proxy_finalize;
6496   gobject_class->get_property = foo_igen_bar_frobnicator_proxy_get_property;
6497   gobject_class->set_property = foo_igen_bar_frobnicator_proxy_set_property;
6498
6499   proxy_class = G_DBUS_PROXY_CLASS (klass);
6500   proxy_class->g_signal = foo_igen_bar_frobnicator_proxy_g_signal;
6501   proxy_class->g_properties_changed = foo_igen_bar_frobnicator_proxy_g_properties_changed;
6502
6503 }
6504
6505 static void
6506 foo_igen_bar_frobnicator_proxy_iface_init (FooiGenBarFrobnicatorIface *iface)
6507 {
6508 }
6509
6510 /**
6511  * foo_igen_bar_frobnicator_proxy_new:
6512  * @connection: A #GDBusConnection.
6513  * @flags: Flags from the #GDBusProxyFlags enumeration.
6514  * @name: (allow-none): A bus name (well-known or unique) or %NULL if @connection is not a message bus connection.
6515  * @object_path: An object path.
6516  * @cancellable: (allow-none): A #GCancellable or %NULL.
6517  * @callback: A #GAsyncReadyCallback to call when the request is satisfied.
6518  * @user_data: User data to pass to @callback.
6519  *
6520  * Asynchronously creates a proxy for the D-Bus interface <link linkend="gdbus-interface-org-project-Bar-Frobnicator.top_of_page">org.project.Bar.Frobnicator</link>. See g_dbus_proxy_new() for more details.
6521  *
6522  * When the operation is finished, @callback will be invoked in the <link linkend="g-main-context-push-thread-default">thread-default main loop</link> of the thread you are calling this method from.
6523  * You can then call foo_igen_bar_frobnicator_proxy_new_finish() to get the result of the operation.
6524  *
6525  * See foo_igen_bar_frobnicator_proxy_new_sync() for the synchronous, blocking version of this constructor.
6526  */
6527 void
6528 foo_igen_bar_frobnicator_proxy_new (
6529     GDBusConnection     *connection,
6530     GDBusProxyFlags      flags,
6531     const gchar         *name,
6532     const gchar         *object_path,
6533     GCancellable        *cancellable,
6534     GAsyncReadyCallback  callback,
6535     gpointer             user_data)
6536 {
6537   g_async_initable_new_async (FOO_IGEN_TYPE_BAR_FROBNICATOR_PROXY, G_PRIORITY_DEFAULT, cancellable, callback, user_data, "g-flags", flags, "g-name", name, "g-connection", connection, "g-object-path", object_path, "g-interface-name", "org.project.Bar.Frobnicator", NULL);
6538 }
6539
6540 /**
6541  * foo_igen_bar_frobnicator_proxy_new_finish:
6542  * @res: The #GAsyncResult obtained from the #GAsyncReadyCallback passed to foo_igen_bar_frobnicator_proxy_new().
6543  * @error: Return location for error or %NULL
6544  *
6545  * Finishes an operation started with foo_igen_bar_frobnicator_proxy_new().
6546  *
6547  * Returns: (transfer full) (type FooiGenBarFrobnicatorProxy): The constructed proxy object or %NULL if @error is set.
6548  */
6549 FooiGenBarFrobnicator *
6550 foo_igen_bar_frobnicator_proxy_new_finish (
6551     GAsyncResult        *res,
6552     GError             **error)
6553 {
6554   GObject *ret;
6555   GObject *source_object;
6556   source_object = g_async_result_get_source_object (res);
6557   ret = g_async_initable_new_finish (G_ASYNC_INITABLE (source_object), res, error);
6558   g_object_unref (source_object);
6559   if (ret != NULL)
6560     return FOO_IGEN_BAR_FROBNICATOR (ret);
6561   else
6562     return NULL;
6563 }
6564
6565 /**
6566  * foo_igen_bar_frobnicator_proxy_new_sync:
6567  * @connection: A #GDBusConnection.
6568  * @flags: Flags from the #GDBusProxyFlags enumeration.
6569  * @name: (allow-none): A bus name (well-known or unique) or %NULL if @connection is not a message bus connection.
6570  * @object_path: An object path.
6571  * @cancellable: (allow-none): A #GCancellable or %NULL.
6572  * @error: Return location for error or %NULL
6573  *
6574  * Synchronously creates a proxy for the D-Bus interface <link linkend="gdbus-interface-org-project-Bar-Frobnicator.top_of_page">org.project.Bar.Frobnicator</link>. See g_dbus_proxy_new_sync() for more details.
6575  *
6576  * The calling thread is blocked until a reply is received.
6577  *
6578  * See foo_igen_bar_frobnicator_proxy_new() for the asynchronous version of this constructor.
6579  *
6580  * Returns: (transfer full) (type FooiGenBarFrobnicatorProxy): The constructed proxy object or %NULL if @error is set.
6581  */
6582 FooiGenBarFrobnicator *
6583 foo_igen_bar_frobnicator_proxy_new_sync (
6584     GDBusConnection     *connection,
6585     GDBusProxyFlags      flags,
6586     const gchar         *name,
6587     const gchar         *object_path,
6588     GCancellable        *cancellable,
6589     GError             **error)
6590 {
6591   GInitable *ret;
6592   ret = g_initable_new (FOO_IGEN_TYPE_BAR_FROBNICATOR_PROXY, cancellable, error, "g-flags", flags, "g-name", name, "g-connection", connection, "g-object-path", object_path, "g-interface-name", "org.project.Bar.Frobnicator", NULL);
6593   if (ret != NULL)
6594     return FOO_IGEN_BAR_FROBNICATOR (ret);
6595   else
6596     return NULL;
6597 }
6598
6599
6600 /**
6601  * foo_igen_bar_frobnicator_proxy_new_for_bus:
6602  * @bus_type: A #GBusType.
6603  * @flags: Flags from the #GDBusProxyFlags enumeration.
6604  * @name: A bus name (well-known or unique).
6605  * @object_path: An object path.
6606  * @cancellable: (allow-none): A #GCancellable or %NULL.
6607  * @callback: A #GAsyncReadyCallback to call when the request is satisfied.
6608  * @user_data: User data to pass to @callback.
6609  *
6610  * Like foo_igen_bar_frobnicator_proxy_new() but takes a #GBusType instead of a #GDBusConnection.
6611  *
6612  * When the operation is finished, @callback will be invoked in the <link linkend="g-main-context-push-thread-default">thread-default main loop</link> of the thread you are calling this method from.
6613  * You can then call foo_igen_bar_frobnicator_proxy_new_for_bus_finish() to get the result of the operation.
6614  *
6615  * See foo_igen_bar_frobnicator_proxy_new_for_bus_sync() for the synchronous, blocking version of this constructor.
6616  */
6617 void
6618 foo_igen_bar_frobnicator_proxy_new_for_bus (
6619     GBusType             bus_type,
6620     GDBusProxyFlags      flags,
6621     const gchar         *name,
6622     const gchar         *object_path,
6623     GCancellable        *cancellable,
6624     GAsyncReadyCallback  callback,
6625     gpointer             user_data)
6626 {
6627   g_async_initable_new_async (FOO_IGEN_TYPE_BAR_FROBNICATOR_PROXY, G_PRIORITY_DEFAULT, cancellable, callback, user_data, "g-flags", flags, "g-name", name, "g-bus-type", bus_type, "g-object-path", object_path, "g-interface-name", "org.project.Bar.Frobnicator", NULL);
6628 }
6629
6630 /**
6631  * foo_igen_bar_frobnicator_proxy_new_for_bus_finish:
6632  * @res: The #GAsyncResult obtained from the #GAsyncReadyCallback passed to foo_igen_bar_frobnicator_proxy_new_for_bus().
6633  * @error: Return location for error or %NULL
6634  *
6635  * Finishes an operation started with foo_igen_bar_frobnicator_proxy_new_for_bus().
6636  *
6637  * Returns: (transfer full) (type FooiGenBarFrobnicatorProxy): The constructed proxy object or %NULL if @error is set.
6638  */
6639 FooiGenBarFrobnicator *
6640 foo_igen_bar_frobnicator_proxy_new_for_bus_finish (
6641     GAsyncResult        *res,
6642     GError             **error)
6643 {
6644   GObject *ret;
6645   GObject *source_object;
6646   source_object = g_async_result_get_source_object (res);
6647   ret = g_async_initable_new_finish (G_ASYNC_INITABLE (source_object), res, error);
6648   g_object_unref (source_object);
6649   if (ret != NULL)
6650     return FOO_IGEN_BAR_FROBNICATOR (ret);
6651   else
6652     return NULL;
6653 }
6654
6655 /**
6656  * foo_igen_bar_frobnicator_proxy_new_for_bus_sync:
6657  * @bus_type: A #GBusType.
6658  * @flags: Flags from the #GDBusProxyFlags enumeration.
6659  * @name: A bus name (well-known or unique).
6660  * @object_path: An object path.
6661  * @cancellable: (allow-none): A #GCancellable or %NULL.
6662  * @error: Return location for error or %NULL
6663  *
6664  * Like foo_igen_bar_frobnicator_proxy_new_sync() but takes a #GBusType instead of a #GDBusConnection.
6665  *
6666  * The calling thread is blocked until a reply is received.
6667  *
6668  * See foo_igen_bar_frobnicator_proxy_new_for_bus() for the asynchronous version of this constructor.
6669  *
6670  * Returns: (transfer full) (type FooiGenBarFrobnicatorProxy): The constructed proxy object or %NULL if @error is set.
6671  */
6672 FooiGenBarFrobnicator *
6673 foo_igen_bar_frobnicator_proxy_new_for_bus_sync (
6674     GBusType             bus_type,
6675     GDBusProxyFlags      flags,
6676     const gchar         *name,
6677     const gchar         *object_path,
6678     GCancellable        *cancellable,
6679     GError             **error)
6680 {
6681   GInitable *ret;
6682   ret = g_initable_new (FOO_IGEN_TYPE_BAR_FROBNICATOR_PROXY, cancellable, error, "g-flags", flags, "g-name", name, "g-bus-type", bus_type, "g-object-path", object_path, "g-interface-name", "org.project.Bar.Frobnicator", NULL);
6683   if (ret != NULL)
6684     return FOO_IGEN_BAR_FROBNICATOR (ret);
6685   else
6686     return NULL;
6687 }
6688
6689
6690 /* ------------------------------------------------------------------------ */
6691
6692 /**
6693  * FooiGenBarFrobnicatorSkeleton:
6694  *
6695  * The #FooiGenBarFrobnicatorSkeleton structure contains only private data and should only be accessed using the provided API.
6696  */
6697
6698 /**
6699  * FooiGenBarFrobnicatorSkeletonClass:
6700  * @parent_class: The parent class.
6701  *
6702  * Class structure for #FooiGenBarFrobnicatorSkeleton.
6703  */
6704
6705 struct _FooiGenBarFrobnicatorSkeletonPrivate
6706 {
6707   GValue *properties;
6708   GList *changed_properties;
6709   GSource *changed_properties_idle_source;
6710   GMainContext *context;
6711   GMutex lock;
6712 };
6713
6714 static void
6715 _foo_igen_bar_frobnicator_skeleton_handle_method_call (
6716   GDBusConnection *connection,
6717   const gchar *sender,
6718   const gchar *object_path,
6719   const gchar *interface_name,
6720   const gchar *method_name,
6721   GVariant *parameters,
6722   GDBusMethodInvocation *invocation,
6723   gpointer user_data)
6724 {
6725   FooiGenBarFrobnicatorSkeleton *skeleton = FOO_IGEN_BAR_FROBNICATOR_SKELETON (user_data);
6726   _ExtendedGDBusMethodInfo *info;
6727   GVariantIter iter;
6728   GVariant *child;
6729   GValue *paramv;
6730   guint num_params;
6731   guint num_extra;
6732   guint n;
6733   guint signal_id;
6734   GValue return_value = G_VALUE_INIT;
6735   info = (_ExtendedGDBusMethodInfo *) g_dbus_method_invocation_get_method_info (invocation);
6736   g_assert (info != NULL);
6737   num_params = g_variant_n_children (parameters);
6738   num_extra = info->pass_fdlist ? 3 : 2;  paramv = g_new0 (GValue, num_params + num_extra);
6739   n = 0;
6740   g_value_init (&paramv[n], FOO_IGEN_TYPE_BAR_FROBNICATOR);
6741   g_value_set_object (&paramv[n++], skeleton);
6742   g_value_init (&paramv[n], G_TYPE_DBUS_METHOD_INVOCATION);
6743   g_value_set_object (&paramv[n++], invocation);
6744   if (info->pass_fdlist)
6745     {
6746 #ifdef G_OS_UNIX
6747       g_value_init (&paramv[n], G_TYPE_UNIX_FD_LIST);
6748       g_value_set_object (&paramv[n++], g_dbus_message_get_unix_fd_list (g_dbus_method_invocation_get_message (invocation)));
6749 #else
6750       g_assert_not_reached ();
6751 #endif
6752     }
6753   g_variant_iter_init (&iter, parameters);
6754   while ((child = g_variant_iter_next_value (&iter)) != NULL)
6755     {
6756       _ExtendedGDBusArgInfo *arg_info = (_ExtendedGDBusArgInfo *) info->parent_struct.in_args[n - num_extra];
6757       if (arg_info->use_gvariant)
6758         {
6759           g_value_init (&paramv[n], G_TYPE_VARIANT);
6760           g_value_set_variant (&paramv[n], child);
6761           n++;
6762         }
6763       else
6764         g_dbus_gvariant_to_gvalue (child, &paramv[n++]);
6765       g_variant_unref (child);
6766     }
6767   signal_id = g_signal_lookup (info->signal_name, FOO_IGEN_TYPE_BAR_FROBNICATOR);
6768   g_value_init (&return_value, G_TYPE_BOOLEAN);
6769   g_signal_emitv (paramv, signal_id, 0, &return_value);
6770   if (!g_value_get_boolean (&return_value))
6771     g_dbus_method_invocation_return_error (invocation, G_DBUS_ERROR, G_DBUS_ERROR_UNKNOWN_METHOD, "Method %s is not implemented on interface %s", method_name, interface_name);
6772   g_value_unset (&return_value);
6773   for (n = 0; n < num_params + num_extra; n++)
6774     g_value_unset (&paramv[n]);
6775   g_free (paramv);
6776 }
6777
6778 static GVariant *
6779 _foo_igen_bar_frobnicator_skeleton_handle_get_property (
6780   GDBusConnection *connection,
6781   const gchar *sender,
6782   const gchar *object_path,
6783   const gchar *interface_name,
6784   const gchar *property_name,
6785   GError **error,
6786   gpointer user_data)
6787 {
6788   FooiGenBarFrobnicatorSkeleton *skeleton = FOO_IGEN_BAR_FROBNICATOR_SKELETON (user_data);
6789   GValue value = G_VALUE_INIT;
6790   GParamSpec *pspec;
6791   _ExtendedGDBusPropertyInfo *info;
6792   GVariant *ret;
6793   ret = NULL;
6794   info = (_ExtendedGDBusPropertyInfo *) g_dbus_interface_info_lookup_property ((GDBusInterfaceInfo *) &_foo_igen_bar_frobnicator_interface_info, property_name);
6795   g_assert (info != NULL);
6796   pspec = g_object_class_find_property (G_OBJECT_GET_CLASS (skeleton), info->hyphen_name);
6797   if (pspec == NULL)
6798     {
6799       g_set_error (error, G_DBUS_ERROR, G_DBUS_ERROR_INVALID_ARGS, "No property with name %s", property_name);
6800     }
6801   else
6802     {
6803       g_value_init (&value, pspec->value_type);
6804       g_object_get_property (G_OBJECT (skeleton), info->hyphen_name, &value);
6805       ret = g_dbus_gvalue_to_gvariant (&value, G_VARIANT_TYPE (info->parent_struct.signature));
6806       g_value_unset (&value);
6807     }
6808   return ret;
6809 }
6810
6811 static gboolean
6812 _foo_igen_bar_frobnicator_skeleton_handle_set_property (
6813   GDBusConnection *connection,
6814   const gchar *sender,
6815   const gchar *object_path,
6816   const gchar *interface_name,
6817   const gchar *property_name,
6818   GVariant *variant,
6819   GError **error,
6820   gpointer user_data)
6821 {
6822   FooiGenBarFrobnicatorSkeleton *skeleton = FOO_IGEN_BAR_FROBNICATOR_SKELETON (user_data);
6823   GValue value = G_VALUE_INIT;
6824   GParamSpec *pspec;
6825   _ExtendedGDBusPropertyInfo *info;
6826   gboolean ret;
6827   ret = FALSE;
6828   info = (_ExtendedGDBusPropertyInfo *) g_dbus_interface_info_lookup_property ((GDBusInterfaceInfo *) &_foo_igen_bar_frobnicator_interface_info, property_name);
6829   g_assert (info != NULL);
6830   pspec = g_object_class_find_property (G_OBJECT_GET_CLASS (skeleton), info->hyphen_name);
6831   if (pspec == NULL)
6832     {
6833       g_set_error (error, G_DBUS_ERROR, G_DBUS_ERROR_INVALID_ARGS, "No property with name %s", property_name);
6834     }
6835   else
6836     {
6837       if (info->use_gvariant)
6838         g_value_set_variant (&value, variant);
6839       else
6840         g_dbus_gvariant_to_gvalue (variant, &value);
6841       g_object_set_property (G_OBJECT (skeleton), info->hyphen_name, &value);
6842       g_value_unset (&value);
6843       ret = TRUE;
6844     }
6845   return ret;
6846 }
6847
6848 static const GDBusInterfaceVTable _foo_igen_bar_frobnicator_skeleton_vtable =
6849 {
6850   _foo_igen_bar_frobnicator_skeleton_handle_method_call,
6851   _foo_igen_bar_frobnicator_skeleton_handle_get_property,
6852   _foo_igen_bar_frobnicator_skeleton_handle_set_property
6853 };
6854
6855 static GDBusInterfaceInfo *
6856 foo_igen_bar_frobnicator_skeleton_dbus_interface_get_info (GDBusInterfaceSkeleton *skeleton)
6857 {
6858   return foo_igen_bar_frobnicator_interface_info ();
6859 }
6860
6861 static GDBusInterfaceVTable *
6862 foo_igen_bar_frobnicator_skeleton_dbus_interface_get_vtable (GDBusInterfaceSkeleton *skeleton)
6863 {
6864   return (GDBusInterfaceVTable *) &_foo_igen_bar_frobnicator_skeleton_vtable;
6865 }
6866
6867 static GVariant *
6868 foo_igen_bar_frobnicator_skeleton_dbus_interface_get_properties (GDBusInterfaceSkeleton *_skeleton)
6869 {
6870   FooiGenBarFrobnicatorSkeleton *skeleton = FOO_IGEN_BAR_FROBNICATOR_SKELETON (_skeleton);
6871
6872   GVariantBuilder builder;
6873   guint n;
6874   g_variant_builder_init (&builder, G_VARIANT_TYPE ("a{sv}"));
6875   if (_foo_igen_bar_frobnicator_interface_info.parent_struct.properties == NULL)
6876     goto out;
6877   for (n = 0; _foo_igen_bar_frobnicator_interface_info.parent_struct.properties[n] != NULL; n++)
6878     {
6879       GDBusPropertyInfo *info = _foo_igen_bar_frobnicator_interface_info.parent_struct.properties[n];
6880       if (info->flags & G_DBUS_PROPERTY_INFO_FLAGS_READABLE)
6881         {
6882           GVariant *value;
6883           value = _foo_igen_bar_frobnicator_skeleton_handle_get_property (g_dbus_interface_skeleton_get_connection (G_DBUS_INTERFACE_SKELETON (skeleton)), NULL, g_dbus_interface_skeleton_get_object_path (G_DBUS_INTERFACE_SKELETON (skeleton)), "org.project.Bar.Frobnicator", info->name, NULL, skeleton);
6884           if (value != NULL)
6885             {
6886               g_variant_take_ref (value);
6887               g_variant_builder_add (&builder, "{sv}", info->name, value);
6888               g_variant_unref (value);
6889             }
6890         }
6891     }
6892 out:
6893   return g_variant_builder_end (&builder);
6894 }
6895
6896 static void
6897 foo_igen_bar_frobnicator_skeleton_dbus_interface_flush (GDBusInterfaceSkeleton *_skeleton)
6898 {
6899 }
6900
6901 static void foo_igen_bar_frobnicator_skeleton_iface_init (FooiGenBarFrobnicatorIface *iface);
6902 G_DEFINE_TYPE_WITH_CODE (FooiGenBarFrobnicatorSkeleton, foo_igen_bar_frobnicator_skeleton, G_TYPE_DBUS_INTERFACE_SKELETON,
6903                          G_IMPLEMENT_INTERFACE (FOO_IGEN_TYPE_BAR_FROBNICATOR, foo_igen_bar_frobnicator_skeleton_iface_init));
6904
6905 static void
6906 foo_igen_bar_frobnicator_skeleton_finalize (GObject *object)
6907 {
6908   FooiGenBarFrobnicatorSkeleton *skeleton = FOO_IGEN_BAR_FROBNICATOR_SKELETON (object);
6909   g_list_free_full (skeleton->priv->changed_properties, (GDestroyNotify) _changed_property_free);
6910   if (skeleton->priv->changed_properties_idle_source != NULL)
6911     g_source_destroy (skeleton->priv->changed_properties_idle_source);
6912   g_main_context_unref (skeleton->priv->context);
6913   g_mutex_clear (&skeleton->priv->lock);
6914   G_OBJECT_CLASS (foo_igen_bar_frobnicator_skeleton_parent_class)->finalize (object);
6915 }
6916
6917 static void
6918 foo_igen_bar_frobnicator_skeleton_init (FooiGenBarFrobnicatorSkeleton *skeleton)
6919 {
6920   skeleton->priv = G_TYPE_INSTANCE_GET_PRIVATE (skeleton, FOO_IGEN_TYPE_BAR_FROBNICATOR_SKELETON, FooiGenBarFrobnicatorSkeletonPrivate);
6921   g_mutex_init (&skeleton->priv->lock);
6922   skeleton->priv->context = g_main_context_ref_thread_default ();
6923 }
6924
6925 static void
6926 foo_igen_bar_frobnicator_skeleton_class_init (FooiGenBarFrobnicatorSkeletonClass *klass)
6927 {
6928   GObjectClass *gobject_class;
6929   GDBusInterfaceSkeletonClass *skeleton_class;
6930
6931   g_type_class_add_private (klass, sizeof (FooiGenBarFrobnicatorSkeletonPrivate));
6932
6933   gobject_class = G_OBJECT_CLASS (klass);
6934   gobject_class->finalize = foo_igen_bar_frobnicator_skeleton_finalize;
6935
6936   skeleton_class = G_DBUS_INTERFACE_SKELETON_CLASS (klass);
6937   skeleton_class->get_info = foo_igen_bar_frobnicator_skeleton_dbus_interface_get_info;
6938   skeleton_class->get_properties = foo_igen_bar_frobnicator_skeleton_dbus_interface_get_properties;
6939   skeleton_class->flush = foo_igen_bar_frobnicator_skeleton_dbus_interface_flush;
6940   skeleton_class->get_vtable = foo_igen_bar_frobnicator_skeleton_dbus_interface_get_vtable;
6941 }
6942
6943 static void
6944 foo_igen_bar_frobnicator_skeleton_iface_init (FooiGenBarFrobnicatorIface *iface)
6945 {
6946 }
6947
6948 /**
6949  * foo_igen_bar_frobnicator_skeleton_new:
6950  *
6951  * Creates a skeleton object for the D-Bus interface <link linkend="gdbus-interface-org-project-Bar-Frobnicator.top_of_page">org.project.Bar.Frobnicator</link>.
6952  *
6953  * Returns: (transfer full) (type FooiGenBarFrobnicatorSkeleton): The skeleton object.
6954  */
6955 FooiGenBarFrobnicator *
6956 foo_igen_bar_frobnicator_skeleton_new (void)
6957 {
6958   return FOO_IGEN_BAR_FROBNICATOR (g_object_new (FOO_IGEN_TYPE_BAR_FROBNICATOR_SKELETON, NULL));
6959 }
6960
6961 /* ------------------------------------------------------------------------
6962  * Code for interface org.project.Baz
6963  * ------------------------------------------------------------------------
6964  */
6965
6966 /**
6967  * SECTION:FooiGenBaz
6968  * @title: FooiGenBaz
6969  * @short_description: Generated C code for the org.project.Baz D-Bus interface
6970  *
6971  * This section contains code for working with the <link linkend="gdbus-interface-org-project-Baz.top_of_page">org.project.Baz</link> D-Bus interface in C.
6972  */
6973
6974 /* ---- Introspection data for org.project.Baz ---- */
6975
6976 static const _ExtendedGDBusInterfaceInfo _foo_igen_baz_interface_info =
6977 {
6978   {
6979     -1,
6980     "org.project.Baz",
6981     NULL,
6982     NULL,
6983     NULL,
6984     NULL
6985   },
6986   "baz",
6987 };
6988
6989
6990 /**
6991  * foo_igen_baz_interface_info:
6992  *
6993  * Gets a machine-readable description of the <link linkend="gdbus-interface-org-project-Baz.top_of_page">org.project.Baz</link> D-Bus interface.
6994  *
6995  * Returns: (transfer none): A #GDBusInterfaceInfo. Do not free.
6996  */
6997 GDBusInterfaceInfo *
6998 foo_igen_baz_interface_info (void)
6999 {
7000   return (GDBusInterfaceInfo *) &_foo_igen_baz_interface_info;
7001 }
7002
7003 /**
7004  * foo_igen_baz_override_properties:
7005  * @klass: The class structure for a #GObject<!-- -->-derived class.
7006  * @property_id_begin: The property id to assign to the first overridden property.
7007  *
7008  * Overrides all #GObject properties in the #FooiGenBaz interface for a concrete class.
7009  * The properties are overridden in the order they are defined.
7010  *
7011  * Returns: The last property id.
7012  */
7013 guint
7014 foo_igen_baz_override_properties (GObjectClass *klass, guint property_id_begin)
7015 {
7016   return property_id_begin - 1;
7017 }
7018
7019
7020
7021 /**
7022  * FooiGenBaz:
7023  *
7024  * Abstract interface type for the D-Bus interface <link linkend="gdbus-interface-org-project-Baz.top_of_page">org.project.Baz</link>.
7025  */
7026
7027 /**
7028  * FooiGenBazIface:
7029  * @parent_iface: The parent interface.
7030  *
7031  * Virtual table for the D-Bus interface <link linkend="gdbus-interface-org-project-Baz.top_of_page">org.project.Baz</link>.
7032  */
7033
7034 static void
7035 foo_igen_baz_default_init (FooiGenBazIface *iface)
7036 {
7037 }
7038
7039 typedef FooiGenBazIface FooiGenBazInterface;
7040 G_DEFINE_INTERFACE (FooiGenBaz, foo_igen_baz, G_TYPE_OBJECT);
7041
7042 /* ------------------------------------------------------------------------ */
7043
7044 /**
7045  * FooiGenBazProxy:
7046  *
7047  * The #FooiGenBazProxy structure contains only private data and should only be accessed using the provided API.
7048  */
7049
7050 /**
7051  * FooiGenBazProxyClass:
7052  * @parent_class: The parent class.
7053  *
7054  * Class structure for #FooiGenBazProxy.
7055  */
7056
7057 struct _FooiGenBazProxyPrivate
7058 {
7059   GData *qdata;
7060 };
7061
7062 static void foo_igen_baz_proxy_iface_init (FooiGenBazIface *iface);
7063
7064 G_DEFINE_TYPE_WITH_CODE (FooiGenBazProxy, foo_igen_baz_proxy, G_TYPE_DBUS_PROXY,
7065                          G_IMPLEMENT_INTERFACE (FOO_IGEN_TYPE_BAZ, foo_igen_baz_proxy_iface_init));
7066
7067 static void
7068 foo_igen_baz_proxy_finalize (GObject *object)
7069 {
7070   FooiGenBazProxy *proxy = FOO_IGEN_BAZ_PROXY (object);
7071   g_datalist_clear (&proxy->priv->qdata);
7072   G_OBJECT_CLASS (foo_igen_baz_proxy_parent_class)->finalize (object);
7073 }
7074
7075 static void
7076 foo_igen_baz_proxy_get_property (GObject      *object,
7077   guint         prop_id,
7078   GValue       *value,
7079   GParamSpec   *pspec)
7080 {
7081 }
7082
7083 static void
7084 foo_igen_baz_proxy_set_property (GObject      *object,
7085   guint         prop_id,
7086   const GValue *value,
7087   GParamSpec   *pspec)
7088 {
7089 }
7090
7091 static void
7092 foo_igen_baz_proxy_g_signal (GDBusProxy *proxy,
7093   const gchar *sender_name,
7094   const gchar *signal_name,
7095   GVariant *parameters)
7096 {
7097   _ExtendedGDBusSignalInfo *info;
7098   GVariantIter iter;
7099   GVariant *child;
7100   GValue *paramv;
7101   guint num_params;
7102   guint n;
7103   guint signal_id;
7104   info = (_ExtendedGDBusSignalInfo *) g_dbus_interface_info_lookup_signal ((GDBusInterfaceInfo *) &_foo_igen_baz_interface_info, signal_name);
7105   if (info == NULL)
7106     return;
7107   num_params = g_variant_n_children (parameters);
7108   paramv = g_new0 (GValue, num_params + 1);
7109   g_value_init (&paramv[0], FOO_IGEN_TYPE_BAZ);
7110   g_value_set_object (&paramv[0], proxy);
7111   g_variant_iter_init (&iter, parameters);
7112   n = 1;
7113   while ((child = g_variant_iter_next_value (&iter)) != NULL)
7114     {
7115       _ExtendedGDBusArgInfo *arg_info = (_ExtendedGDBusArgInfo *) info->parent_struct.args[n - 1];
7116       if (arg_info->use_gvariant)
7117         {
7118           g_value_init (&paramv[n], G_TYPE_VARIANT);
7119           g_value_set_variant (&paramv[n], child);
7120           n++;
7121         }
7122       else
7123         g_dbus_gvariant_to_gvalue (child, &paramv[n++]);
7124       g_variant_unref (child);
7125     }
7126   signal_id = g_signal_lookup (info->signal_name, FOO_IGEN_TYPE_BAZ);
7127   g_signal_emitv (paramv, signal_id, 0, NULL);
7128   for (n = 0; n < num_params + 1; n++)
7129     g_value_unset (&paramv[n]);
7130   g_free (paramv);
7131 }
7132
7133 static void
7134 foo_igen_baz_proxy_g_properties_changed (GDBusProxy *_proxy,
7135   GVariant *changed_properties,
7136   const gchar *const *invalidated_properties)
7137 {
7138   FooiGenBazProxy *proxy = FOO_IGEN_BAZ_PROXY (_proxy);
7139   guint n;
7140   const gchar *key;
7141   GVariantIter *iter;
7142   _ExtendedGDBusPropertyInfo *info;
7143   g_variant_get (changed_properties, "a{sv}", &iter);
7144   while (g_variant_iter_next (iter, "{&sv}", &key, NULL))
7145     {
7146       info = (_ExtendedGDBusPropertyInfo *) g_dbus_interface_info_lookup_property ((GDBusInterfaceInfo *) &_foo_igen_baz_interface_info, key);
7147       g_datalist_remove_data (&proxy->priv->qdata, key);
7148       if (info != NULL)
7149         g_object_notify (G_OBJECT (proxy), info->hyphen_name);
7150     }
7151   g_variant_iter_free (iter);
7152   for (n = 0; invalidated_properties[n] != NULL; n++)
7153     {
7154       info = (_ExtendedGDBusPropertyInfo *) g_dbus_interface_info_lookup_property ((GDBusInterfaceInfo *) &_foo_igen_baz_interface_info, invalidated_properties[n]);
7155       g_datalist_remove_data (&proxy->priv->qdata, invalidated_properties[n]);
7156       if (info != NULL)
7157         g_object_notify (G_OBJECT (proxy), info->hyphen_name);
7158     }
7159 }
7160
7161 static void
7162 foo_igen_baz_proxy_init (FooiGenBazProxy *proxy)
7163 {
7164   proxy->priv = G_TYPE_INSTANCE_GET_PRIVATE (proxy, FOO_IGEN_TYPE_BAZ_PROXY, FooiGenBazProxyPrivate);
7165   g_dbus_proxy_set_interface_info (G_DBUS_PROXY (proxy), foo_igen_baz_interface_info ());
7166 }
7167
7168 static void
7169 foo_igen_baz_proxy_class_init (FooiGenBazProxyClass *klass)
7170 {
7171   GObjectClass *gobject_class;
7172   GDBusProxyClass *proxy_class;
7173
7174   g_type_class_add_private (klass, sizeof (FooiGenBazProxyPrivate));
7175
7176   gobject_class = G_OBJECT_CLASS (klass);
7177   gobject_class->finalize     = foo_igen_baz_proxy_finalize;
7178   gobject_class->get_property = foo_igen_baz_proxy_get_property;
7179   gobject_class->set_property = foo_igen_baz_proxy_set_property;
7180
7181   proxy_class = G_DBUS_PROXY_CLASS (klass);
7182   proxy_class->g_signal = foo_igen_baz_proxy_g_signal;
7183   proxy_class->g_properties_changed = foo_igen_baz_proxy_g_properties_changed;
7184
7185 }
7186
7187 static void
7188 foo_igen_baz_proxy_iface_init (FooiGenBazIface *iface)
7189 {
7190 }
7191
7192 /**
7193  * foo_igen_baz_proxy_new:
7194  * @connection: A #GDBusConnection.
7195  * @flags: Flags from the #GDBusProxyFlags enumeration.
7196  * @name: (allow-none): A bus name (well-known or unique) or %NULL if @connection is not a message bus connection.
7197  * @object_path: An object path.
7198  * @cancellable: (allow-none): A #GCancellable or %NULL.
7199  * @callback: A #GAsyncReadyCallback to call when the request is satisfied.
7200  * @user_data: User data to pass to @callback.
7201  *
7202  * Asynchronously creates a proxy for the D-Bus interface <link linkend="gdbus-interface-org-project-Baz.top_of_page">org.project.Baz</link>. See g_dbus_proxy_new() for more details.
7203  *
7204  * When the operation is finished, @callback will be invoked in the <link linkend="g-main-context-push-thread-default">thread-default main loop</link> of the thread you are calling this method from.
7205  * You can then call foo_igen_baz_proxy_new_finish() to get the result of the operation.
7206  *
7207  * See foo_igen_baz_proxy_new_sync() for the synchronous, blocking version of this constructor.
7208  */
7209 void
7210 foo_igen_baz_proxy_new (
7211     GDBusConnection     *connection,
7212     GDBusProxyFlags      flags,
7213     const gchar         *name,
7214     const gchar         *object_path,
7215     GCancellable        *cancellable,
7216     GAsyncReadyCallback  callback,
7217     gpointer             user_data)
7218 {
7219   g_async_initable_new_async (FOO_IGEN_TYPE_BAZ_PROXY, G_PRIORITY_DEFAULT, cancellable, callback, user_data, "g-flags", flags, "g-name", name, "g-connection", connection, "g-object-path", object_path, "g-interface-name", "org.project.Baz", NULL);
7220 }
7221
7222 /**
7223  * foo_igen_baz_proxy_new_finish:
7224  * @res: The #GAsyncResult obtained from the #GAsyncReadyCallback passed to foo_igen_baz_proxy_new().
7225  * @error: Return location for error or %NULL
7226  *
7227  * Finishes an operation started with foo_igen_baz_proxy_new().
7228  *
7229  * Returns: (transfer full) (type FooiGenBazProxy): The constructed proxy object or %NULL if @error is set.
7230  */
7231 FooiGenBaz *
7232 foo_igen_baz_proxy_new_finish (
7233     GAsyncResult        *res,
7234     GError             **error)
7235 {
7236   GObject *ret;
7237   GObject *source_object;
7238   source_object = g_async_result_get_source_object (res);
7239   ret = g_async_initable_new_finish (G_ASYNC_INITABLE (source_object), res, error);
7240   g_object_unref (source_object);
7241   if (ret != NULL)
7242     return FOO_IGEN_BAZ (ret);
7243   else
7244     return NULL;
7245 }
7246
7247 /**
7248  * foo_igen_baz_proxy_new_sync:
7249  * @connection: A #GDBusConnection.
7250  * @flags: Flags from the #GDBusProxyFlags enumeration.
7251  * @name: (allow-none): A bus name (well-known or unique) or %NULL if @connection is not a message bus connection.
7252  * @object_path: An object path.
7253  * @cancellable: (allow-none): A #GCancellable or %NULL.
7254  * @error: Return location for error or %NULL
7255  *
7256  * Synchronously creates a proxy for the D-Bus interface <link linkend="gdbus-interface-org-project-Baz.top_of_page">org.project.Baz</link>. See g_dbus_proxy_new_sync() for more details.
7257  *
7258  * The calling thread is blocked until a reply is received.
7259  *
7260  * See foo_igen_baz_proxy_new() for the asynchronous version of this constructor.
7261  *
7262  * Returns: (transfer full) (type FooiGenBazProxy): The constructed proxy object or %NULL if @error is set.
7263  */
7264 FooiGenBaz *
7265 foo_igen_baz_proxy_new_sync (
7266     GDBusConnection     *connection,
7267     GDBusProxyFlags      flags,
7268     const gchar         *name,
7269     const gchar         *object_path,
7270     GCancellable        *cancellable,
7271     GError             **error)
7272 {
7273   GInitable *ret;
7274   ret = g_initable_new (FOO_IGEN_TYPE_BAZ_PROXY, cancellable, error, "g-flags", flags, "g-name", name, "g-connection", connection, "g-object-path", object_path, "g-interface-name", "org.project.Baz", NULL);
7275   if (ret != NULL)
7276     return FOO_IGEN_BAZ (ret);
7277   else
7278     return NULL;
7279 }
7280
7281
7282 /**
7283  * foo_igen_baz_proxy_new_for_bus:
7284  * @bus_type: A #GBusType.
7285  * @flags: Flags from the #GDBusProxyFlags enumeration.
7286  * @name: A bus name (well-known or unique).
7287  * @object_path: An object path.
7288  * @cancellable: (allow-none): A #GCancellable or %NULL.
7289  * @callback: A #GAsyncReadyCallback to call when the request is satisfied.
7290  * @user_data: User data to pass to @callback.
7291  *
7292  * Like foo_igen_baz_proxy_new() but takes a #GBusType instead of a #GDBusConnection.
7293  *
7294  * When the operation is finished, @callback will be invoked in the <link linkend="g-main-context-push-thread-default">thread-default main loop</link> of the thread you are calling this method from.
7295  * You can then call foo_igen_baz_proxy_new_for_bus_finish() to get the result of the operation.
7296  *
7297  * See foo_igen_baz_proxy_new_for_bus_sync() for the synchronous, blocking version of this constructor.
7298  */
7299 void
7300 foo_igen_baz_proxy_new_for_bus (
7301     GBusType             bus_type,
7302     GDBusProxyFlags      flags,
7303     const gchar         *name,
7304     const gchar         *object_path,
7305     GCancellable        *cancellable,
7306     GAsyncReadyCallback  callback,
7307     gpointer             user_data)
7308 {
7309   g_async_initable_new_async (FOO_IGEN_TYPE_BAZ_PROXY, G_PRIORITY_DEFAULT, cancellable, callback, user_data, "g-flags", flags, "g-name", name, "g-bus-type", bus_type, "g-object-path", object_path, "g-interface-name", "org.project.Baz", NULL);
7310 }
7311
7312 /**
7313  * foo_igen_baz_proxy_new_for_bus_finish:
7314  * @res: The #GAsyncResult obtained from the #GAsyncReadyCallback passed to foo_igen_baz_proxy_new_for_bus().
7315  * @error: Return location for error or %NULL
7316  *
7317  * Finishes an operation started with foo_igen_baz_proxy_new_for_bus().
7318  *
7319  * Returns: (transfer full) (type FooiGenBazProxy): The constructed proxy object or %NULL if @error is set.
7320  */
7321 FooiGenBaz *
7322 foo_igen_baz_proxy_new_for_bus_finish (
7323     GAsyncResult        *res,
7324     GError             **error)
7325 {
7326   GObject *ret;
7327   GObject *source_object;
7328   source_object = g_async_result_get_source_object (res);
7329   ret = g_async_initable_new_finish (G_ASYNC_INITABLE (source_object), res, error);
7330   g_object_unref (source_object);
7331   if (ret != NULL)
7332     return FOO_IGEN_BAZ (ret);
7333   else
7334     return NULL;
7335 }
7336
7337 /**
7338  * foo_igen_baz_proxy_new_for_bus_sync:
7339  * @bus_type: A #GBusType.
7340  * @flags: Flags from the #GDBusProxyFlags enumeration.
7341  * @name: A bus name (well-known or unique).
7342  * @object_path: An object path.
7343  * @cancellable: (allow-none): A #GCancellable or %NULL.
7344  * @error: Return location for error or %NULL
7345  *
7346  * Like foo_igen_baz_proxy_new_sync() but takes a #GBusType instead of a #GDBusConnection.
7347  *
7348  * The calling thread is blocked until a reply is received.
7349  *
7350  * See foo_igen_baz_proxy_new_for_bus() for the asynchronous version of this constructor.
7351  *
7352  * Returns: (transfer full) (type FooiGenBazProxy): The constructed proxy object or %NULL if @error is set.
7353  */
7354 FooiGenBaz *
7355 foo_igen_baz_proxy_new_for_bus_sync (
7356     GBusType             bus_type,
7357     GDBusProxyFlags      flags,
7358     const gchar         *name,
7359     const gchar         *object_path,
7360     GCancellable        *cancellable,
7361     GError             **error)
7362 {
7363   GInitable *ret;
7364   ret = g_initable_new (FOO_IGEN_TYPE_BAZ_PROXY, cancellable, error, "g-flags", flags, "g-name", name, "g-bus-type", bus_type, "g-object-path", object_path, "g-interface-name", "org.project.Baz", NULL);
7365   if (ret != NULL)
7366     return FOO_IGEN_BAZ (ret);
7367   else
7368     return NULL;
7369 }
7370
7371
7372 /* ------------------------------------------------------------------------ */
7373
7374 /**
7375  * FooiGenBazSkeleton:
7376  *
7377  * The #FooiGenBazSkeleton structure contains only private data and should only be accessed using the provided API.
7378  */
7379
7380 /**
7381  * FooiGenBazSkeletonClass:
7382  * @parent_class: The parent class.
7383  *
7384  * Class structure for #FooiGenBazSkeleton.
7385  */
7386
7387 struct _FooiGenBazSkeletonPrivate
7388 {
7389   GValue *properties;
7390   GList *changed_properties;
7391   GSource *changed_properties_idle_source;
7392   GMainContext *context;
7393   GMutex lock;
7394 };
7395
7396 static void
7397 _foo_igen_baz_skeleton_handle_method_call (
7398   GDBusConnection *connection,
7399   const gchar *sender,
7400   const gchar *object_path,
7401   const gchar *interface_name,
7402   const gchar *method_name,
7403   GVariant *parameters,
7404   GDBusMethodInvocation *invocation,
7405   gpointer user_data)
7406 {
7407   FooiGenBazSkeleton *skeleton = FOO_IGEN_BAZ_SKELETON (user_data);
7408   _ExtendedGDBusMethodInfo *info;
7409   GVariantIter iter;
7410   GVariant *child;
7411   GValue *paramv;
7412   guint num_params;
7413   guint num_extra;
7414   guint n;
7415   guint signal_id;
7416   GValue return_value = G_VALUE_INIT;
7417   info = (_ExtendedGDBusMethodInfo *) g_dbus_method_invocation_get_method_info (invocation);
7418   g_assert (info != NULL);
7419   num_params = g_variant_n_children (parameters);
7420   num_extra = info->pass_fdlist ? 3 : 2;  paramv = g_new0 (GValue, num_params + num_extra);
7421   n = 0;
7422   g_value_init (&paramv[n], FOO_IGEN_TYPE_BAZ);
7423   g_value_set_object (&paramv[n++], skeleton);
7424   g_value_init (&paramv[n], G_TYPE_DBUS_METHOD_INVOCATION);
7425   g_value_set_object (&paramv[n++], invocation);
7426   if (info->pass_fdlist)
7427     {
7428 #ifdef G_OS_UNIX
7429       g_value_init (&paramv[n], G_TYPE_UNIX_FD_LIST);
7430       g_value_set_object (&paramv[n++], g_dbus_message_get_unix_fd_list (g_dbus_method_invocation_get_message (invocation)));
7431 #else
7432       g_assert_not_reached ();
7433 #endif
7434     }
7435   g_variant_iter_init (&iter, parameters);
7436   while ((child = g_variant_iter_next_value (&iter)) != NULL)
7437     {
7438       _ExtendedGDBusArgInfo *arg_info = (_ExtendedGDBusArgInfo *) info->parent_struct.in_args[n - num_extra];
7439       if (arg_info->use_gvariant)
7440         {
7441           g_value_init (&paramv[n], G_TYPE_VARIANT);
7442           g_value_set_variant (&paramv[n], child);
7443           n++;
7444         }
7445       else
7446         g_dbus_gvariant_to_gvalue (child, &paramv[n++]);
7447       g_variant_unref (child);
7448     }
7449   signal_id = g_signal_lookup (info->signal_name, FOO_IGEN_TYPE_BAZ);
7450   g_value_init (&return_value, G_TYPE_BOOLEAN);
7451   g_signal_emitv (paramv, signal_id, 0, &return_value);
7452   if (!g_value_get_boolean (&return_value))
7453     g_dbus_method_invocation_return_error (invocation, G_DBUS_ERROR, G_DBUS_ERROR_UNKNOWN_METHOD, "Method %s is not implemented on interface %s", method_name, interface_name);
7454   g_value_unset (&return_value);
7455   for (n = 0; n < num_params + num_extra; n++)
7456     g_value_unset (&paramv[n]);
7457   g_free (paramv);
7458 }
7459
7460 static GVariant *
7461 _foo_igen_baz_skeleton_handle_get_property (
7462   GDBusConnection *connection,
7463   const gchar *sender,
7464   const gchar *object_path,
7465   const gchar *interface_name,
7466   const gchar *property_name,
7467   GError **error,
7468   gpointer user_data)
7469 {
7470   FooiGenBazSkeleton *skeleton = FOO_IGEN_BAZ_SKELETON (user_data);
7471   GValue value = G_VALUE_INIT;
7472   GParamSpec *pspec;
7473   _ExtendedGDBusPropertyInfo *info;
7474   GVariant *ret;
7475   ret = NULL;
7476   info = (_ExtendedGDBusPropertyInfo *) g_dbus_interface_info_lookup_property ((GDBusInterfaceInfo *) &_foo_igen_baz_interface_info, property_name);
7477   g_assert (info != NULL);
7478   pspec = g_object_class_find_property (G_OBJECT_GET_CLASS (skeleton), info->hyphen_name);
7479   if (pspec == NULL)
7480     {
7481       g_set_error (error, G_DBUS_ERROR, G_DBUS_ERROR_INVALID_ARGS, "No property with name %s", property_name);
7482     }
7483   else
7484     {
7485       g_value_init (&value, pspec->value_type);
7486       g_object_get_property (G_OBJECT (skeleton), info->hyphen_name, &value);
7487       ret = g_dbus_gvalue_to_gvariant (&value, G_VARIANT_TYPE (info->parent_struct.signature));
7488       g_value_unset (&value);
7489     }
7490   return ret;
7491 }
7492
7493 static gboolean
7494 _foo_igen_baz_skeleton_handle_set_property (
7495   GDBusConnection *connection,
7496   const gchar *sender,
7497   const gchar *object_path,
7498   const gchar *interface_name,
7499   const gchar *property_name,
7500   GVariant *variant,
7501   GError **error,
7502   gpointer user_data)
7503 {
7504   FooiGenBazSkeleton *skeleton = FOO_IGEN_BAZ_SKELETON (user_data);
7505   GValue value = G_VALUE_INIT;
7506   GParamSpec *pspec;
7507   _ExtendedGDBusPropertyInfo *info;
7508   gboolean ret;
7509   ret = FALSE;
7510   info = (_ExtendedGDBusPropertyInfo *) g_dbus_interface_info_lookup_property ((GDBusInterfaceInfo *) &_foo_igen_baz_interface_info, property_name);
7511   g_assert (info != NULL);
7512   pspec = g_object_class_find_property (G_OBJECT_GET_CLASS (skeleton), info->hyphen_name);
7513   if (pspec == NULL)
7514     {
7515       g_set_error (error, G_DBUS_ERROR, G_DBUS_ERROR_INVALID_ARGS, "No property with name %s", property_name);
7516     }
7517   else
7518     {
7519       if (info->use_gvariant)
7520         g_value_set_variant (&value, variant);
7521       else
7522         g_dbus_gvariant_to_gvalue (variant, &value);
7523       g_object_set_property (G_OBJECT (skeleton), info->hyphen_name, &value);
7524       g_value_unset (&value);
7525       ret = TRUE;
7526     }
7527   return ret;
7528 }
7529
7530 static const GDBusInterfaceVTable _foo_igen_baz_skeleton_vtable =
7531 {
7532   _foo_igen_baz_skeleton_handle_method_call,
7533   _foo_igen_baz_skeleton_handle_get_property,
7534   _foo_igen_baz_skeleton_handle_set_property
7535 };
7536
7537 static GDBusInterfaceInfo *
7538 foo_igen_baz_skeleton_dbus_interface_get_info (GDBusInterfaceSkeleton *skeleton)
7539 {
7540   return foo_igen_baz_interface_info ();
7541 }
7542
7543 static GDBusInterfaceVTable *
7544 foo_igen_baz_skeleton_dbus_interface_get_vtable (GDBusInterfaceSkeleton *skeleton)
7545 {
7546   return (GDBusInterfaceVTable *) &_foo_igen_baz_skeleton_vtable;
7547 }
7548
7549 static GVariant *
7550 foo_igen_baz_skeleton_dbus_interface_get_properties (GDBusInterfaceSkeleton *_skeleton)
7551 {
7552   FooiGenBazSkeleton *skeleton = FOO_IGEN_BAZ_SKELETON (_skeleton);
7553
7554   GVariantBuilder builder;
7555   guint n;
7556   g_variant_builder_init (&builder, G_VARIANT_TYPE ("a{sv}"));
7557   if (_foo_igen_baz_interface_info.parent_struct.properties == NULL)
7558     goto out;
7559   for (n = 0; _foo_igen_baz_interface_info.parent_struct.properties[n] != NULL; n++)
7560     {
7561       GDBusPropertyInfo *info = _foo_igen_baz_interface_info.parent_struct.properties[n];
7562       if (info->flags & G_DBUS_PROPERTY_INFO_FLAGS_READABLE)
7563         {
7564           GVariant *value;
7565           value = _foo_igen_baz_skeleton_handle_get_property (g_dbus_interface_skeleton_get_connection (G_DBUS_INTERFACE_SKELETON (skeleton)), NULL, g_dbus_interface_skeleton_get_object_path (G_DBUS_INTERFACE_SKELETON (skeleton)), "org.project.Baz", info->name, NULL, skeleton);
7566           if (value != NULL)
7567             {
7568               g_variant_take_ref (value);
7569               g_variant_builder_add (&builder, "{sv}", info->name, value);
7570               g_variant_unref (value);
7571             }
7572         }
7573     }
7574 out:
7575   return g_variant_builder_end (&builder);
7576 }
7577
7578 static void
7579 foo_igen_baz_skeleton_dbus_interface_flush (GDBusInterfaceSkeleton *_skeleton)
7580 {
7581 }
7582
7583 static void foo_igen_baz_skeleton_iface_init (FooiGenBazIface *iface);
7584 G_DEFINE_TYPE_WITH_CODE (FooiGenBazSkeleton, foo_igen_baz_skeleton, G_TYPE_DBUS_INTERFACE_SKELETON,
7585                          G_IMPLEMENT_INTERFACE (FOO_IGEN_TYPE_BAZ, foo_igen_baz_skeleton_iface_init));
7586
7587 static void
7588 foo_igen_baz_skeleton_finalize (GObject *object)
7589 {
7590   FooiGenBazSkeleton *skeleton = FOO_IGEN_BAZ_SKELETON (object);
7591   g_list_free_full (skeleton->priv->changed_properties, (GDestroyNotify) _changed_property_free);
7592   if (skeleton->priv->changed_properties_idle_source != NULL)
7593     g_source_destroy (skeleton->priv->changed_properties_idle_source);
7594   g_main_context_unref (skeleton->priv->context);
7595   g_mutex_clear (&skeleton->priv->lock);
7596   G_OBJECT_CLASS (foo_igen_baz_skeleton_parent_class)->finalize (object);
7597 }
7598
7599 static void
7600 foo_igen_baz_skeleton_init (FooiGenBazSkeleton *skeleton)
7601 {
7602   skeleton->priv = G_TYPE_INSTANCE_GET_PRIVATE (skeleton, FOO_IGEN_TYPE_BAZ_SKELETON, FooiGenBazSkeletonPrivate);
7603   g_mutex_init (&skeleton->priv->lock);
7604   skeleton->priv->context = g_main_context_ref_thread_default ();
7605 }
7606
7607 static void
7608 foo_igen_baz_skeleton_class_init (FooiGenBazSkeletonClass *klass)
7609 {
7610   GObjectClass *gobject_class;
7611   GDBusInterfaceSkeletonClass *skeleton_class;
7612
7613   g_type_class_add_private (klass, sizeof (FooiGenBazSkeletonPrivate));
7614
7615   gobject_class = G_OBJECT_CLASS (klass);
7616   gobject_class->finalize = foo_igen_baz_skeleton_finalize;
7617
7618   skeleton_class = G_DBUS_INTERFACE_SKELETON_CLASS (klass);
7619   skeleton_class->get_info = foo_igen_baz_skeleton_dbus_interface_get_info;
7620   skeleton_class->get_properties = foo_igen_baz_skeleton_dbus_interface_get_properties;
7621   skeleton_class->flush = foo_igen_baz_skeleton_dbus_interface_flush;
7622   skeleton_class->get_vtable = foo_igen_baz_skeleton_dbus_interface_get_vtable;
7623 }
7624
7625 static void
7626 foo_igen_baz_skeleton_iface_init (FooiGenBazIface *iface)
7627 {
7628 }
7629
7630 /**
7631  * foo_igen_baz_skeleton_new:
7632  *
7633  * Creates a skeleton object for the D-Bus interface <link linkend="gdbus-interface-org-project-Baz.top_of_page">org.project.Baz</link>.
7634  *
7635  * Returns: (transfer full) (type FooiGenBazSkeleton): The skeleton object.
7636  */
7637 FooiGenBaz *
7638 foo_igen_baz_skeleton_new (void)
7639 {
7640   return FOO_IGEN_BAZ (g_object_new (FOO_IGEN_TYPE_BAZ_SKELETON, NULL));
7641 }
7642
7643 /* ------------------------------------------------------------------------
7644  * Code for interface com.acme.Coyote
7645  * ------------------------------------------------------------------------
7646  */
7647
7648 /**
7649  * SECTION:FooiGenComAcmeCoyote
7650  * @title: FooiGenComAcmeCoyote
7651  * @short_description: Generated C code for the com.acme.Coyote D-Bus interface
7652  *
7653  * This section contains code for working with the <link linkend="gdbus-interface-com-acme-Coyote.top_of_page">com.acme.Coyote</link> D-Bus interface in C.
7654  */
7655
7656 /* ---- Introspection data for com.acme.Coyote ---- */
7657
7658 static const _ExtendedGDBusMethodInfo _foo_igen_com_acme_coyote_method_info_run =
7659 {
7660   {
7661     -1,
7662     "Run",
7663     NULL,
7664     NULL,
7665     NULL
7666   },
7667   "handle-run",
7668   FALSE
7669 };
7670
7671 static const _ExtendedGDBusMethodInfo _foo_igen_com_acme_coyote_method_info_sleep =
7672 {
7673   {
7674     -1,
7675     "Sleep",
7676     NULL,
7677     NULL,
7678     NULL
7679   },
7680   "handle-sleep",
7681   FALSE
7682 };
7683
7684 static const _ExtendedGDBusMethodInfo _foo_igen_com_acme_coyote_method_info_attack =
7685 {
7686   {
7687     -1,
7688     "Attack",
7689     NULL,
7690     NULL,
7691     NULL
7692   },
7693   "handle-attack",
7694   FALSE
7695 };
7696
7697 static const _ExtendedGDBusMethodInfo * const _foo_igen_com_acme_coyote_method_info_pointers[] =
7698 {
7699   &_foo_igen_com_acme_coyote_method_info_run,
7700   &_foo_igen_com_acme_coyote_method_info_sleep,
7701   &_foo_igen_com_acme_coyote_method_info_attack,
7702   NULL
7703 };
7704
7705 static const _ExtendedGDBusSignalInfo _foo_igen_com_acme_coyote_signal_info_surprised =
7706 {
7707   {
7708     -1,
7709     "Surprised",
7710     NULL,
7711     NULL
7712   },
7713   "surprised"
7714 };
7715
7716 static const _ExtendedGDBusSignalInfo * const _foo_igen_com_acme_coyote_signal_info_pointers[] =
7717 {
7718   &_foo_igen_com_acme_coyote_signal_info_surprised,
7719   NULL
7720 };
7721
7722 static const _ExtendedGDBusPropertyInfo _foo_igen_com_acme_coyote_property_info_mood =
7723 {
7724   {
7725     -1,
7726     "Mood",
7727     "s",
7728     G_DBUS_PROPERTY_INFO_FLAGS_READABLE,
7729     NULL
7730   },
7731   "mood",
7732   FALSE
7733 };
7734
7735 static const _ExtendedGDBusPropertyInfo * const _foo_igen_com_acme_coyote_property_info_pointers[] =
7736 {
7737   &_foo_igen_com_acme_coyote_property_info_mood,
7738   NULL
7739 };
7740
7741 static const _ExtendedGDBusInterfaceInfo _foo_igen_com_acme_coyote_interface_info =
7742 {
7743   {
7744     -1,
7745     "com.acme.Coyote",
7746     (GDBusMethodInfo **) &_foo_igen_com_acme_coyote_method_info_pointers,
7747     (GDBusSignalInfo **) &_foo_igen_com_acme_coyote_signal_info_pointers,
7748     (GDBusPropertyInfo **) &_foo_igen_com_acme_coyote_property_info_pointers,
7749     NULL
7750   },
7751   "com-acme-coyote",
7752 };
7753
7754
7755 /**
7756  * foo_igen_com_acme_coyote_interface_info:
7757  *
7758  * Gets a machine-readable description of the <link linkend="gdbus-interface-com-acme-Coyote.top_of_page">com.acme.Coyote</link> D-Bus interface.
7759  *
7760  * Returns: (transfer none): A #GDBusInterfaceInfo. Do not free.
7761  */
7762 GDBusInterfaceInfo *
7763 foo_igen_com_acme_coyote_interface_info (void)
7764 {
7765   return (GDBusInterfaceInfo *) &_foo_igen_com_acme_coyote_interface_info;
7766 }
7767
7768 /**
7769  * foo_igen_com_acme_coyote_override_properties:
7770  * @klass: The class structure for a #GObject<!-- -->-derived class.
7771  * @property_id_begin: The property id to assign to the first overridden property.
7772  *
7773  * Overrides all #GObject properties in the #FooiGenComAcmeCoyote interface for a concrete class.
7774  * The properties are overridden in the order they are defined.
7775  *
7776  * Returns: The last property id.
7777  */
7778 guint
7779 foo_igen_com_acme_coyote_override_properties (GObjectClass *klass, guint property_id_begin)
7780 {
7781   g_object_class_override_property (klass, property_id_begin++, "mood");
7782   return property_id_begin - 1;
7783 }
7784
7785
7786
7787 /**
7788  * FooiGenComAcmeCoyote:
7789  *
7790  * Abstract interface type for the D-Bus interface <link linkend="gdbus-interface-com-acme-Coyote.top_of_page">com.acme.Coyote</link>.
7791  */
7792
7793 /**
7794  * FooiGenComAcmeCoyoteIface:
7795  * @parent_iface: The parent interface.
7796  * @handle_attack: Handler for the #FooiGenComAcmeCoyote::handle-attack signal.
7797  * @handle_run: Handler for the #FooiGenComAcmeCoyote::handle-run signal.
7798  * @handle_sleep: Handler for the #FooiGenComAcmeCoyote::handle-sleep signal.
7799  * @get_mood: Getter for the #FooiGenComAcmeCoyote:mood property.
7800  * @surprised: Handler for the #FooiGenComAcmeCoyote::surprised signal.
7801  *
7802  * Virtual table for the D-Bus interface <link linkend="gdbus-interface-com-acme-Coyote.top_of_page">com.acme.Coyote</link>.
7803  */
7804
7805 static void
7806 foo_igen_com_acme_coyote_default_init (FooiGenComAcmeCoyoteIface *iface)
7807 {
7808   /* GObject signals for incoming D-Bus method calls: */
7809   /**
7810    * FooiGenComAcmeCoyote::handle-run:
7811    * @object: A #FooiGenComAcmeCoyote.
7812    * @invocation: A #GDBusMethodInvocation.
7813    *
7814    * Signal emitted when a remote caller is invoking the <link linkend="gdbus-method-com-acme-Coyote.Run">Run()</link> D-Bus method.
7815    *
7816    * If a signal handler returns %TRUE, it means the signal handler will handle the invocation (e.g. take a reference to @invocation and eventually call foo_igen_com_acme_coyote_complete_run() or e.g. g_dbus_method_invocation_return_error() on it) and no order signal handlers will run. If no signal handler handles the invocation, the %G_DBUS_ERROR_UNKNOWN_METHOD error is returned.
7817    *
7818    * Returns: %TRUE if the invocation was handled, %FALSE to let other signal handlers run.
7819    */
7820   g_signal_new ("handle-run",
7821     G_TYPE_FROM_INTERFACE (iface),
7822     G_SIGNAL_RUN_LAST,
7823     G_STRUCT_OFFSET (FooiGenComAcmeCoyoteIface, handle_run),
7824     g_signal_accumulator_true_handled,
7825     NULL,
7826     g_cclosure_marshal_generic,
7827     G_TYPE_BOOLEAN,
7828     1,
7829     G_TYPE_DBUS_METHOD_INVOCATION);
7830
7831   /**
7832    * FooiGenComAcmeCoyote::handle-sleep:
7833    * @object: A #FooiGenComAcmeCoyote.
7834    * @invocation: A #GDBusMethodInvocation.
7835    *
7836    * Signal emitted when a remote caller is invoking the <link linkend="gdbus-method-com-acme-Coyote.Sleep">Sleep()</link> D-Bus method.
7837    *
7838    * If a signal handler returns %TRUE, it means the signal handler will handle the invocation (e.g. take a reference to @invocation and eventually call foo_igen_com_acme_coyote_complete_sleep() or e.g. g_dbus_method_invocation_return_error() on it) and no order signal handlers will run. If no signal handler handles the invocation, the %G_DBUS_ERROR_UNKNOWN_METHOD error is returned.
7839    *
7840    * Returns: %TRUE if the invocation was handled, %FALSE to let other signal handlers run.
7841    */
7842   g_signal_new ("handle-sleep",
7843     G_TYPE_FROM_INTERFACE (iface),
7844     G_SIGNAL_RUN_LAST,
7845     G_STRUCT_OFFSET (FooiGenComAcmeCoyoteIface, handle_sleep),
7846     g_signal_accumulator_true_handled,
7847     NULL,
7848     g_cclosure_marshal_generic,
7849     G_TYPE_BOOLEAN,
7850     1,
7851     G_TYPE_DBUS_METHOD_INVOCATION);
7852
7853   /**
7854    * FooiGenComAcmeCoyote::handle-attack:
7855    * @object: A #FooiGenComAcmeCoyote.
7856    * @invocation: A #GDBusMethodInvocation.
7857    *
7858    * Signal emitted when a remote caller is invoking the <link linkend="gdbus-method-com-acme-Coyote.Attack">Attack()</link> D-Bus method.
7859    *
7860    * If a signal handler returns %TRUE, it means the signal handler will handle the invocation (e.g. take a reference to @invocation and eventually call foo_igen_com_acme_coyote_complete_attack() or e.g. g_dbus_method_invocation_return_error() on it) and no order signal handlers will run. If no signal handler handles the invocation, the %G_DBUS_ERROR_UNKNOWN_METHOD error is returned.
7861    *
7862    * Returns: %TRUE if the invocation was handled, %FALSE to let other signal handlers run.
7863    */
7864   g_signal_new ("handle-attack",
7865     G_TYPE_FROM_INTERFACE (iface),
7866     G_SIGNAL_RUN_LAST,
7867     G_STRUCT_OFFSET (FooiGenComAcmeCoyoteIface, handle_attack),
7868     g_signal_accumulator_true_handled,
7869     NULL,
7870     g_cclosure_marshal_generic,
7871     G_TYPE_BOOLEAN,
7872     1,
7873     G_TYPE_DBUS_METHOD_INVOCATION);
7874
7875   /* GObject signals for received D-Bus signals: */
7876   /**
7877    * FooiGenComAcmeCoyote::surprised:
7878    * @object: A #FooiGenComAcmeCoyote.
7879    *
7880    * On the client-side, this signal is emitted whenever the D-Bus signal <link linkend="gdbus-signal-com-acme-Coyote.Surprised">"Surprised"</link> is received.
7881    *
7882    * On the service-side, this signal can be used with e.g. g_signal_emit_by_name() to make the object emit the D-Bus signal.
7883    */
7884   g_signal_new ("surprised",
7885     G_TYPE_FROM_INTERFACE (iface),
7886     G_SIGNAL_RUN_LAST,
7887     G_STRUCT_OFFSET (FooiGenComAcmeCoyoteIface, surprised),
7888     NULL,
7889     NULL,
7890     g_cclosure_marshal_generic,
7891     G_TYPE_NONE,
7892     0);
7893
7894   /* GObject properties for D-Bus properties: */
7895   /**
7896    * FooiGenComAcmeCoyote:mood:
7897    *
7898    * Represents the D-Bus property <link linkend="gdbus-property-com-acme-Coyote.Mood">"Mood"</link>.
7899    *
7900    * Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
7901    */
7902   g_object_interface_install_property (iface,
7903     g_param_spec_string ("mood", "Mood", "Mood", NULL, G_PARAM_READWRITE | G_PARAM_STATIC_STRINGS));
7904 }
7905
7906 typedef FooiGenComAcmeCoyoteIface FooiGenComAcmeCoyoteInterface;
7907 G_DEFINE_INTERFACE (FooiGenComAcmeCoyote, foo_igen_com_acme_coyote, G_TYPE_OBJECT);
7908
7909 /**
7910  * foo_igen_com_acme_coyote_get_mood: (skip)
7911  * @object: A #FooiGenComAcmeCoyote.
7912  *
7913  * Gets the value of the <link linkend="gdbus-property-com-acme-Coyote.Mood">"Mood"</link> D-Bus property.
7914  *
7915  * Since this D-Bus property is readable, it is meaningful to use this function on both the client- and service-side.
7916  *
7917  * <warning>The returned value is only valid until the property changes so on the client-side it is only safe to use this function on the thread where @object was constructed. Use foo_igen_com_acme_coyote_dup_mood() if on another thread.</warning>
7918  *
7919  * Returns: (transfer none): The property value or %NULL if the property is not set. Do not free the returned value, it belongs to @object.
7920  */
7921 const gchar *
7922 foo_igen_com_acme_coyote_get_mood (FooiGenComAcmeCoyote *object)
7923 {
7924   return FOO_IGEN_COM_ACME_COYOTE_GET_IFACE (object)->get_mood (object);
7925 }
7926
7927 /**
7928  * foo_igen_com_acme_coyote_dup_mood: (skip)
7929  * @object: A #FooiGenComAcmeCoyote.
7930  *
7931  * Gets a copy of the <link linkend="gdbus-property-com-acme-Coyote.Mood">"Mood"</link> D-Bus property.
7932  *
7933  * Since this D-Bus property is readable, it is meaningful to use this function on both the client- and service-side.
7934  *
7935  * Returns: (transfer full): The property value or %NULL if the property is not set. The returned value should be freed with g_free().
7936  */
7937 gchar *
7938 foo_igen_com_acme_coyote_dup_mood (FooiGenComAcmeCoyote *object)
7939 {
7940   gchar *value;
7941   g_object_get (G_OBJECT (object), "mood", &value, NULL);
7942   return value;
7943 }
7944
7945 /**
7946  * foo_igen_com_acme_coyote_set_mood: (skip)
7947  * @object: A #FooiGenComAcmeCoyote.
7948  * @value: The value to set.
7949  *
7950  * Sets the <link linkend="gdbus-property-com-acme-Coyote.Mood">"Mood"</link> D-Bus property to @value.
7951  *
7952  * Since this D-Bus property is not writable, it is only meaningful to use this function on the service-side.
7953  */
7954 void
7955 foo_igen_com_acme_coyote_set_mood (FooiGenComAcmeCoyote *object, const gchar *value)
7956 {
7957   g_object_set (G_OBJECT (object), "mood", value, NULL);
7958 }
7959
7960 /**
7961  * foo_igen_com_acme_coyote_emit_surprised:
7962  * @object: A #FooiGenComAcmeCoyote.
7963  *
7964  * Emits the <link linkend="gdbus-signal-com-acme-Coyote.Surprised">"Surprised"</link> D-Bus signal.
7965  */
7966 void
7967 foo_igen_com_acme_coyote_emit_surprised (
7968     FooiGenComAcmeCoyote *object)
7969 {
7970   g_signal_emit_by_name (object, "surprised");
7971 }
7972
7973 /**
7974  * foo_igen_com_acme_coyote_call_run:
7975  * @proxy: A #FooiGenComAcmeCoyoteProxy.
7976  * @cancellable: (allow-none): A #GCancellable or %NULL.
7977  * @callback: A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
7978  * @user_data: User data to pass to @callback.
7979  *
7980  * Asynchronously invokes the <link linkend="gdbus-method-com-acme-Coyote.Run">Run()</link> D-Bus method on @proxy.
7981  * When the operation is finished, @callback will be invoked in the <link linkend="g-main-context-push-thread-default">thread-default main loop</link> of the thread you are calling this method from.
7982  * You can then call foo_igen_com_acme_coyote_call_run_finish() to get the result of the operation.
7983  *
7984  * See foo_igen_com_acme_coyote_call_run_sync() for the synchronous, blocking version of this method.
7985  */
7986 void
7987 foo_igen_com_acme_coyote_call_run (
7988     FooiGenComAcmeCoyote *proxy,
7989     GCancellable *cancellable,
7990     GAsyncReadyCallback callback,
7991     gpointer user_data)
7992 {
7993   g_dbus_proxy_call (G_DBUS_PROXY (proxy),
7994     "Run",
7995     g_variant_new ("()"),
7996     G_DBUS_CALL_FLAGS_NONE,
7997     -1,
7998     cancellable,
7999     callback,
8000     user_data);
8001 }
8002
8003 /**
8004  * foo_igen_com_acme_coyote_call_run_finish:
8005  * @proxy: A #FooiGenComAcmeCoyoteProxy.
8006  * @res: The #GAsyncResult obtained from the #GAsyncReadyCallback passed to foo_igen_com_acme_coyote_call_run().
8007  * @error: Return location for error or %NULL.
8008  *
8009  * Finishes an operation started with foo_igen_com_acme_coyote_call_run().
8010  *
8011  * Returns: (skip): %TRUE if the call succeded, %FALSE if @error is set.
8012  */
8013 gboolean
8014 foo_igen_com_acme_coyote_call_run_finish (
8015     FooiGenComAcmeCoyote *proxy,
8016     GAsyncResult *res,
8017     GError **error)
8018 {
8019   GVariant *_ret;
8020   _ret = g_dbus_proxy_call_finish (G_DBUS_PROXY (proxy), res, error);
8021   if (_ret == NULL)
8022     goto _out;
8023   g_variant_get (_ret,
8024                  "()");
8025   g_variant_unref (_ret);
8026 _out:
8027   return _ret != NULL;
8028 }
8029
8030 /**
8031  * foo_igen_com_acme_coyote_call_run_sync:
8032  * @proxy: A #FooiGenComAcmeCoyoteProxy.
8033  * @cancellable: (allow-none): A #GCancellable or %NULL.
8034  * @error: Return location for error or %NULL.
8035  *
8036  * Synchronously invokes the <link linkend="gdbus-method-com-acme-Coyote.Run">Run()</link> D-Bus method on @proxy. The calling thread is blocked until a reply is received.
8037  *
8038  * See foo_igen_com_acme_coyote_call_run() for the asynchronous version of this method.
8039  *
8040  * Returns: (skip): %TRUE if the call succeded, %FALSE if @error is set.
8041  */
8042 gboolean
8043 foo_igen_com_acme_coyote_call_run_sync (
8044     FooiGenComAcmeCoyote *proxy,
8045     GCancellable *cancellable,
8046     GError **error)
8047 {
8048   GVariant *_ret;
8049   _ret = g_dbus_proxy_call_sync (G_DBUS_PROXY (proxy),
8050     "Run",
8051     g_variant_new ("()"),
8052     G_DBUS_CALL_FLAGS_NONE,
8053     -1,
8054     cancellable,
8055     error);
8056   if (_ret == NULL)
8057     goto _out;
8058   g_variant_get (_ret,
8059                  "()");
8060   g_variant_unref (_ret);
8061 _out:
8062   return _ret != NULL;
8063 }
8064
8065 /**
8066  * foo_igen_com_acme_coyote_call_sleep:
8067  * @proxy: A #FooiGenComAcmeCoyoteProxy.
8068  * @cancellable: (allow-none): A #GCancellable or %NULL.
8069  * @callback: A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
8070  * @user_data: User data to pass to @callback.
8071  *
8072  * Asynchronously invokes the <link linkend="gdbus-method-com-acme-Coyote.Sleep">Sleep()</link> D-Bus method on @proxy.
8073  * When the operation is finished, @callback will be invoked in the <link linkend="g-main-context-push-thread-default">thread-default main loop</link> of the thread you are calling this method from.
8074  * You can then call foo_igen_com_acme_coyote_call_sleep_finish() to get the result of the operation.
8075  *
8076  * See foo_igen_com_acme_coyote_call_sleep_sync() for the synchronous, blocking version of this method.
8077  */
8078 void
8079 foo_igen_com_acme_coyote_call_sleep (
8080     FooiGenComAcmeCoyote *proxy,
8081     GCancellable *cancellable,
8082     GAsyncReadyCallback callback,
8083     gpointer user_data)
8084 {
8085   g_dbus_proxy_call (G_DBUS_PROXY (proxy),
8086     "Sleep",
8087     g_variant_new ("()"),
8088     G_DBUS_CALL_FLAGS_NONE,
8089     -1,
8090     cancellable,
8091     callback,
8092     user_data);
8093 }
8094
8095 /**
8096  * foo_igen_com_acme_coyote_call_sleep_finish:
8097  * @proxy: A #FooiGenComAcmeCoyoteProxy.
8098  * @res: The #GAsyncResult obtained from the #GAsyncReadyCallback passed to foo_igen_com_acme_coyote_call_sleep().
8099  * @error: Return location for error or %NULL.
8100  *
8101  * Finishes an operation started with foo_igen_com_acme_coyote_call_sleep().
8102  *
8103  * Returns: (skip): %TRUE if the call succeded, %FALSE if @error is set.
8104  */
8105 gboolean
8106 foo_igen_com_acme_coyote_call_sleep_finish (
8107     FooiGenComAcmeCoyote *proxy,
8108     GAsyncResult *res,
8109     GError **error)
8110 {
8111   GVariant *_ret;
8112   _ret = g_dbus_proxy_call_finish (G_DBUS_PROXY (proxy), res, error);
8113   if (_ret == NULL)
8114     goto _out;
8115   g_variant_get (_ret,
8116                  "()");
8117   g_variant_unref (_ret);
8118 _out:
8119   return _ret != NULL;
8120 }
8121
8122 /**
8123  * foo_igen_com_acme_coyote_call_sleep_sync:
8124  * @proxy: A #FooiGenComAcmeCoyoteProxy.
8125  * @cancellable: (allow-none): A #GCancellable or %NULL.
8126  * @error: Return location for error or %NULL.
8127  *
8128  * Synchronously invokes the <link linkend="gdbus-method-com-acme-Coyote.Sleep">Sleep()</link> D-Bus method on @proxy. The calling thread is blocked until a reply is received.
8129  *
8130  * See foo_igen_com_acme_coyote_call_sleep() for the asynchronous version of this method.
8131  *
8132  * Returns: (skip): %TRUE if the call succeded, %FALSE if @error is set.
8133  */
8134 gboolean
8135 foo_igen_com_acme_coyote_call_sleep_sync (
8136     FooiGenComAcmeCoyote *proxy,
8137     GCancellable *cancellable,
8138     GError **error)
8139 {
8140   GVariant *_ret;
8141   _ret = g_dbus_proxy_call_sync (G_DBUS_PROXY (proxy),
8142     "Sleep",
8143     g_variant_new ("()"),
8144     G_DBUS_CALL_FLAGS_NONE,
8145     -1,
8146     cancellable,
8147     error);
8148   if (_ret == NULL)
8149     goto _out;
8150   g_variant_get (_ret,
8151                  "()");
8152   g_variant_unref (_ret);
8153 _out:
8154   return _ret != NULL;
8155 }
8156
8157 /**
8158  * foo_igen_com_acme_coyote_call_attack:
8159  * @proxy: A #FooiGenComAcmeCoyoteProxy.
8160  * @cancellable: (allow-none): A #GCancellable or %NULL.
8161  * @callback: A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
8162  * @user_data: User data to pass to @callback.
8163  *
8164  * Asynchronously invokes the <link linkend="gdbus-method-com-acme-Coyote.Attack">Attack()</link> D-Bus method on @proxy.
8165  * When the operation is finished, @callback will be invoked in the <link linkend="g-main-context-push-thread-default">thread-default main loop</link> of the thread you are calling this method from.
8166  * You can then call foo_igen_com_acme_coyote_call_attack_finish() to get the result of the operation.
8167  *
8168  * See foo_igen_com_acme_coyote_call_attack_sync() for the synchronous, blocking version of this method.
8169  */
8170 void
8171 foo_igen_com_acme_coyote_call_attack (
8172     FooiGenComAcmeCoyote *proxy,
8173     GCancellable *cancellable,
8174     GAsyncReadyCallback callback,
8175     gpointer user_data)
8176 {
8177   g_dbus_proxy_call (G_DBUS_PROXY (proxy),
8178     "Attack",
8179     g_variant_new ("()"),
8180     G_DBUS_CALL_FLAGS_NONE,
8181     -1,
8182     cancellable,
8183     callback,
8184     user_data);
8185 }
8186
8187 /**
8188  * foo_igen_com_acme_coyote_call_attack_finish:
8189  * @proxy: A #FooiGenComAcmeCoyoteProxy.
8190  * @res: The #GAsyncResult obtained from the #GAsyncReadyCallback passed to foo_igen_com_acme_coyote_call_attack().
8191  * @error: Return location for error or %NULL.
8192  *
8193  * Finishes an operation started with foo_igen_com_acme_coyote_call_attack().
8194  *
8195  * Returns: (skip): %TRUE if the call succeded, %FALSE if @error is set.
8196  */
8197 gboolean
8198 foo_igen_com_acme_coyote_call_attack_finish (
8199     FooiGenComAcmeCoyote *proxy,
8200     GAsyncResult *res,
8201     GError **error)
8202 {
8203   GVariant *_ret;
8204   _ret = g_dbus_proxy_call_finish (G_DBUS_PROXY (proxy), res, error);
8205   if (_ret == NULL)
8206     goto _out;
8207   g_variant_get (_ret,
8208                  "()");
8209   g_variant_unref (_ret);
8210 _out:
8211   return _ret != NULL;
8212 }
8213
8214 /**
8215  * foo_igen_com_acme_coyote_call_attack_sync:
8216  * @proxy: A #FooiGenComAcmeCoyoteProxy.
8217  * @cancellable: (allow-none): A #GCancellable or %NULL.
8218  * @error: Return location for error or %NULL.
8219  *
8220  * Synchronously invokes the <link linkend="gdbus-method-com-acme-Coyote.Attack">Attack()</link> D-Bus method on @proxy. The calling thread is blocked until a reply is received.
8221  *
8222  * See foo_igen_com_acme_coyote_call_attack() for the asynchronous version of this method.
8223  *
8224  * Returns: (skip): %TRUE if the call succeded, %FALSE if @error is set.
8225  */
8226 gboolean
8227 foo_igen_com_acme_coyote_call_attack_sync (
8228     FooiGenComAcmeCoyote *proxy,
8229     GCancellable *cancellable,
8230     GError **error)
8231 {
8232   GVariant *_ret;
8233   _ret = g_dbus_proxy_call_sync (G_DBUS_PROXY (proxy),
8234     "Attack",
8235     g_variant_new ("()"),
8236     G_DBUS_CALL_FLAGS_NONE,
8237     -1,
8238     cancellable,
8239     error);
8240   if (_ret == NULL)
8241     goto _out;
8242   g_variant_get (_ret,
8243                  "()");
8244   g_variant_unref (_ret);
8245 _out:
8246   return _ret != NULL;
8247 }
8248
8249 /**
8250  * foo_igen_com_acme_coyote_complete_run:
8251  * @object: A #FooiGenComAcmeCoyote.
8252  * @invocation: (transfer full): A #GDBusMethodInvocation.
8253  *
8254  * Helper function used in service implementations to finish handling invocations of the <link linkend="gdbus-method-com-acme-Coyote.Run">Run()</link> D-Bus method. If you instead want to finish handling an invocation by returning an error, use g_dbus_method_invocation_return_error() or similar.
8255  *
8256  * This method will free @invocation, you cannot use it afterwards.
8257  */
8258 void
8259 foo_igen_com_acme_coyote_complete_run (
8260     FooiGenComAcmeCoyote *object,
8261     GDBusMethodInvocation *invocation)
8262 {
8263   g_dbus_method_invocation_return_value (invocation,
8264     g_variant_new ("()"));
8265 }
8266
8267 /**
8268  * foo_igen_com_acme_coyote_complete_sleep:
8269  * @object: A #FooiGenComAcmeCoyote.
8270  * @invocation: (transfer full): A #GDBusMethodInvocation.
8271  *
8272  * Helper function used in service implementations to finish handling invocations of the <link linkend="gdbus-method-com-acme-Coyote.Sleep">Sleep()</link> D-Bus method. If you instead want to finish handling an invocation by returning an error, use g_dbus_method_invocation_return_error() or similar.
8273  *
8274  * This method will free @invocation, you cannot use it afterwards.
8275  */
8276 void
8277 foo_igen_com_acme_coyote_complete_sleep (
8278     FooiGenComAcmeCoyote *object,
8279     GDBusMethodInvocation *invocation)
8280 {
8281   g_dbus_method_invocation_return_value (invocation,
8282     g_variant_new ("()"));
8283 }
8284
8285 /**
8286  * foo_igen_com_acme_coyote_complete_attack:
8287  * @object: A #FooiGenComAcmeCoyote.
8288  * @invocation: (transfer full): A #GDBusMethodInvocation.
8289  *
8290  * Helper function used in service implementations to finish handling invocations of the <link linkend="gdbus-method-com-acme-Coyote.Attack">Attack()</link> D-Bus method. If you instead want to finish handling an invocation by returning an error, use g_dbus_method_invocation_return_error() or similar.
8291  *
8292  * This method will free @invocation, you cannot use it afterwards.
8293  */
8294 void
8295 foo_igen_com_acme_coyote_complete_attack (
8296     FooiGenComAcmeCoyote *object,
8297     GDBusMethodInvocation *invocation)
8298 {
8299   g_dbus_method_invocation_return_value (invocation,
8300     g_variant_new ("()"));
8301 }
8302
8303 /* ------------------------------------------------------------------------ */
8304
8305 /**
8306  * FooiGenComAcmeCoyoteProxy:
8307  *
8308  * The #FooiGenComAcmeCoyoteProxy structure contains only private data and should only be accessed using the provided API.
8309  */
8310
8311 /**
8312  * FooiGenComAcmeCoyoteProxyClass:
8313  * @parent_class: The parent class.
8314  *
8315  * Class structure for #FooiGenComAcmeCoyoteProxy.
8316  */
8317
8318 struct _FooiGenComAcmeCoyoteProxyPrivate
8319 {
8320   GData *qdata;
8321 };
8322
8323 static void foo_igen_com_acme_coyote_proxy_iface_init (FooiGenComAcmeCoyoteIface *iface);
8324
8325 G_DEFINE_TYPE_WITH_CODE (FooiGenComAcmeCoyoteProxy, foo_igen_com_acme_coyote_proxy, G_TYPE_DBUS_PROXY,
8326                          G_IMPLEMENT_INTERFACE (FOO_IGEN_TYPE_COM_ACME_COYOTE, foo_igen_com_acme_coyote_proxy_iface_init));
8327
8328 static void
8329 foo_igen_com_acme_coyote_proxy_finalize (GObject *object)
8330 {
8331   FooiGenComAcmeCoyoteProxy *proxy = FOO_IGEN_COM_ACME_COYOTE_PROXY (object);
8332   g_datalist_clear (&proxy->priv->qdata);
8333   G_OBJECT_CLASS (foo_igen_com_acme_coyote_proxy_parent_class)->finalize (object);
8334 }
8335
8336 static void
8337 foo_igen_com_acme_coyote_proxy_get_property (GObject      *object,
8338   guint         prop_id,
8339   GValue       *value,
8340   GParamSpec   *pspec)
8341 {
8342   const _ExtendedGDBusPropertyInfo *info;
8343   GVariant *variant;
8344   g_assert (prop_id != 0 && prop_id - 1 < 1);
8345   info = _foo_igen_com_acme_coyote_property_info_pointers[prop_id - 1];
8346   variant = g_dbus_proxy_get_cached_property (G_DBUS_PROXY (object), info->parent_struct.name);
8347   if (info->use_gvariant)
8348     {
8349       g_value_set_variant (value, variant);
8350     }
8351   else
8352     {
8353       if (variant != NULL)
8354         g_dbus_gvariant_to_gvalue (variant, value);
8355     }
8356   if (variant != NULL)
8357     g_variant_unref (variant);
8358 }
8359
8360 static void
8361 foo_igen_com_acme_coyote_proxy_set_property_cb (GDBusProxy *proxy,
8362   GAsyncResult *res,
8363   gpointer      user_data)
8364 {
8365   const _ExtendedGDBusPropertyInfo *info = user_data;
8366   GError *error;
8367   error = NULL;
8368   if (!g_dbus_proxy_call_finish (proxy, res, &error))
8369     {
8370       g_warning ("Error setting property `%s' on interface com.acme.Coyote: %s (%s, %d)",
8371                  info->parent_struct.name, 
8372                  error->message, g_quark_to_string (error->domain), error->code);
8373       g_error_free (error);
8374     }
8375 }
8376
8377 static void
8378 foo_igen_com_acme_coyote_proxy_set_property (GObject      *object,
8379   guint         prop_id,
8380   const GValue *value,
8381   GParamSpec   *pspec)
8382 {
8383   const _ExtendedGDBusPropertyInfo *info;
8384   GVariant *variant;
8385   g_assert (prop_id != 0 && prop_id - 1 < 1);
8386   info = _foo_igen_com_acme_coyote_property_info_pointers[prop_id - 1];
8387   variant = g_dbus_gvalue_to_gvariant (value, G_VARIANT_TYPE (info->parent_struct.signature));
8388   g_dbus_proxy_call (G_DBUS_PROXY (object),
8389     "org.freedesktop.DBus.Properties.Set",
8390     g_variant_new ("(ssv)", "com.acme.Coyote", info->parent_struct.name, variant),
8391     G_DBUS_CALL_FLAGS_NONE,
8392     -1,
8393     NULL, (GAsyncReadyCallback) foo_igen_com_acme_coyote_proxy_set_property_cb, (gpointer) info);
8394   g_variant_unref (variant);
8395 }
8396
8397 static void
8398 foo_igen_com_acme_coyote_proxy_g_signal (GDBusProxy *proxy,
8399   const gchar *sender_name,
8400   const gchar *signal_name,
8401   GVariant *parameters)
8402 {
8403   _ExtendedGDBusSignalInfo *info;
8404   GVariantIter iter;
8405   GVariant *child;
8406   GValue *paramv;
8407   guint num_params;
8408   guint n;
8409   guint signal_id;
8410   info = (_ExtendedGDBusSignalInfo *) g_dbus_interface_info_lookup_signal ((GDBusInterfaceInfo *) &_foo_igen_com_acme_coyote_interface_info, signal_name);
8411   if (info == NULL)
8412     return;
8413   num_params = g_variant_n_children (parameters);
8414   paramv = g_new0 (GValue, num_params + 1);
8415   g_value_init (&paramv[0], FOO_IGEN_TYPE_COM_ACME_COYOTE);
8416   g_value_set_object (&paramv[0], proxy);
8417   g_variant_iter_init (&iter, parameters);
8418   n = 1;
8419   while ((child = g_variant_iter_next_value (&iter)) != NULL)
8420     {
8421       _ExtendedGDBusArgInfo *arg_info = (_ExtendedGDBusArgInfo *) info->parent_struct.args[n - 1];
8422       if (arg_info->use_gvariant)
8423         {
8424           g_value_init (&paramv[n], G_TYPE_VARIANT);
8425           g_value_set_variant (&paramv[n], child);
8426           n++;
8427         }
8428       else
8429         g_dbus_gvariant_to_gvalue (child, &paramv[n++]);
8430       g_variant_unref (child);
8431     }
8432   signal_id = g_signal_lookup (info->signal_name, FOO_IGEN_TYPE_COM_ACME_COYOTE);
8433   g_signal_emitv (paramv, signal_id, 0, NULL);
8434   for (n = 0; n < num_params + 1; n++)
8435     g_value_unset (&paramv[n]);
8436   g_free (paramv);
8437 }
8438
8439 static void
8440 foo_igen_com_acme_coyote_proxy_g_properties_changed (GDBusProxy *_proxy,
8441   GVariant *changed_properties,
8442   const gchar *const *invalidated_properties)
8443 {
8444   FooiGenComAcmeCoyoteProxy *proxy = FOO_IGEN_COM_ACME_COYOTE_PROXY (_proxy);
8445   guint n;
8446   const gchar *key;
8447   GVariantIter *iter;
8448   _ExtendedGDBusPropertyInfo *info;
8449   g_variant_get (changed_properties, "a{sv}", &iter);
8450   while (g_variant_iter_next (iter, "{&sv}", &key, NULL))
8451     {
8452       info = (_ExtendedGDBusPropertyInfo *) g_dbus_interface_info_lookup_property ((GDBusInterfaceInfo *) &_foo_igen_com_acme_coyote_interface_info, key);
8453       g_datalist_remove_data (&proxy->priv->qdata, key);
8454       if (info != NULL)
8455         g_object_notify (G_OBJECT (proxy), info->hyphen_name);
8456     }
8457   g_variant_iter_free (iter);
8458   for (n = 0; invalidated_properties[n] != NULL; n++)
8459     {
8460       info = (_ExtendedGDBusPropertyInfo *) g_dbus_interface_info_lookup_property ((GDBusInterfaceInfo *) &_foo_igen_com_acme_coyote_interface_info, invalidated_properties[n]);
8461       g_datalist_remove_data (&proxy->priv->qdata, invalidated_properties[n]);
8462       if (info != NULL)
8463         g_object_notify (G_OBJECT (proxy), info->hyphen_name);
8464     }
8465 }
8466
8467 static const gchar *
8468 foo_igen_com_acme_coyote_proxy_get_mood (FooiGenComAcmeCoyote *object)
8469 {
8470   FooiGenComAcmeCoyoteProxy *proxy = FOO_IGEN_COM_ACME_COYOTE_PROXY (object);
8471   GVariant *variant;
8472   const gchar *value = NULL;
8473   variant = g_dbus_proxy_get_cached_property (G_DBUS_PROXY (proxy), "Mood");
8474   if (variant != NULL)
8475     {
8476       value = g_variant_get_string (variant, NULL);
8477       g_variant_unref (variant);
8478     }
8479   return value;
8480 }
8481
8482 static void
8483 foo_igen_com_acme_coyote_proxy_init (FooiGenComAcmeCoyoteProxy *proxy)
8484 {
8485   proxy->priv = G_TYPE_INSTANCE_GET_PRIVATE (proxy, FOO_IGEN_TYPE_COM_ACME_COYOTE_PROXY, FooiGenComAcmeCoyoteProxyPrivate);
8486   g_dbus_proxy_set_interface_info (G_DBUS_PROXY (proxy), foo_igen_com_acme_coyote_interface_info ());
8487 }
8488
8489 static void
8490 foo_igen_com_acme_coyote_proxy_class_init (FooiGenComAcmeCoyoteProxyClass *klass)
8491 {
8492   GObjectClass *gobject_class;
8493   GDBusProxyClass *proxy_class;
8494
8495   g_type_class_add_private (klass, sizeof (FooiGenComAcmeCoyoteProxyPrivate));
8496
8497   gobject_class = G_OBJECT_CLASS (klass);
8498   gobject_class->finalize     = foo_igen_com_acme_coyote_proxy_finalize;
8499   gobject_class->get_property = foo_igen_com_acme_coyote_proxy_get_property;
8500   gobject_class->set_property = foo_igen_com_acme_coyote_proxy_set_property;
8501
8502   proxy_class = G_DBUS_PROXY_CLASS (klass);
8503   proxy_class->g_signal = foo_igen_com_acme_coyote_proxy_g_signal;
8504   proxy_class->g_properties_changed = foo_igen_com_acme_coyote_proxy_g_properties_changed;
8505
8506
8507   foo_igen_com_acme_coyote_override_properties (gobject_class, 1);
8508 }
8509
8510 static void
8511 foo_igen_com_acme_coyote_proxy_iface_init (FooiGenComAcmeCoyoteIface *iface)
8512 {
8513   iface->get_mood = foo_igen_com_acme_coyote_proxy_get_mood;
8514 }
8515
8516 /**
8517  * foo_igen_com_acme_coyote_proxy_new:
8518  * @connection: A #GDBusConnection.
8519  * @flags: Flags from the #GDBusProxyFlags enumeration.
8520  * @name: (allow-none): A bus name (well-known or unique) or %NULL if @connection is not a message bus connection.
8521  * @object_path: An object path.
8522  * @cancellable: (allow-none): A #GCancellable or %NULL.
8523  * @callback: A #GAsyncReadyCallback to call when the request is satisfied.
8524  * @user_data: User data to pass to @callback.
8525  *
8526  * Asynchronously creates a proxy for the D-Bus interface <link linkend="gdbus-interface-com-acme-Coyote.top_of_page">com.acme.Coyote</link>. See g_dbus_proxy_new() for more details.
8527  *
8528  * When the operation is finished, @callback will be invoked in the <link linkend="g-main-context-push-thread-default">thread-default main loop</link> of the thread you are calling this method from.
8529  * You can then call foo_igen_com_acme_coyote_proxy_new_finish() to get the result of the operation.
8530  *
8531  * See foo_igen_com_acme_coyote_proxy_new_sync() for the synchronous, blocking version of this constructor.
8532  */
8533 void
8534 foo_igen_com_acme_coyote_proxy_new (
8535     GDBusConnection     *connection,
8536     GDBusProxyFlags      flags,
8537     const gchar         *name,
8538     const gchar         *object_path,
8539     GCancellable        *cancellable,
8540     GAsyncReadyCallback  callback,
8541     gpointer             user_data)
8542 {
8543   g_async_initable_new_async (FOO_IGEN_TYPE_COM_ACME_COYOTE_PROXY, G_PRIORITY_DEFAULT, cancellable, callback, user_data, "g-flags", flags, "g-name", name, "g-connection", connection, "g-object-path", object_path, "g-interface-name", "com.acme.Coyote", NULL);
8544 }
8545
8546 /**
8547  * foo_igen_com_acme_coyote_proxy_new_finish:
8548  * @res: The #GAsyncResult obtained from the #GAsyncReadyCallback passed to foo_igen_com_acme_coyote_proxy_new().
8549  * @error: Return location for error or %NULL
8550  *
8551  * Finishes an operation started with foo_igen_com_acme_coyote_proxy_new().
8552  *
8553  * Returns: (transfer full) (type FooiGenComAcmeCoyoteProxy): The constructed proxy object or %NULL if @error is set.
8554  */
8555 FooiGenComAcmeCoyote *
8556 foo_igen_com_acme_coyote_proxy_new_finish (
8557     GAsyncResult        *res,
8558     GError             **error)
8559 {
8560   GObject *ret;
8561   GObject *source_object;
8562   source_object = g_async_result_get_source_object (res);
8563   ret = g_async_initable_new_finish (G_ASYNC_INITABLE (source_object), res, error);
8564   g_object_unref (source_object);
8565   if (ret != NULL)
8566     return FOO_IGEN_COM_ACME_COYOTE (ret);
8567   else
8568     return NULL;
8569 }
8570
8571 /**
8572  * foo_igen_com_acme_coyote_proxy_new_sync:
8573  * @connection: A #GDBusConnection.
8574  * @flags: Flags from the #GDBusProxyFlags enumeration.
8575  * @name: (allow-none): A bus name (well-known or unique) or %NULL if @connection is not a message bus connection.
8576  * @object_path: An object path.
8577  * @cancellable: (allow-none): A #GCancellable or %NULL.
8578  * @error: Return location for error or %NULL
8579  *
8580  * Synchronously creates a proxy for the D-Bus interface <link linkend="gdbus-interface-com-acme-Coyote.top_of_page">com.acme.Coyote</link>. See g_dbus_proxy_new_sync() for more details.
8581  *
8582  * The calling thread is blocked until a reply is received.
8583  *
8584  * See foo_igen_com_acme_coyote_proxy_new() for the asynchronous version of this constructor.
8585  *
8586  * Returns: (transfer full) (type FooiGenComAcmeCoyoteProxy): The constructed proxy object or %NULL if @error is set.
8587  */
8588 FooiGenComAcmeCoyote *
8589 foo_igen_com_acme_coyote_proxy_new_sync (
8590     GDBusConnection     *connection,
8591     GDBusProxyFlags      flags,
8592     const gchar         *name,
8593     const gchar         *object_path,
8594     GCancellable        *cancellable,
8595     GError             **error)
8596 {
8597   GInitable *ret;
8598   ret = g_initable_new (FOO_IGEN_TYPE_COM_ACME_COYOTE_PROXY, cancellable, error, "g-flags", flags, "g-name", name, "g-connection", connection, "g-object-path", object_path, "g-interface-name", "com.acme.Coyote", NULL);
8599   if (ret != NULL)
8600     return FOO_IGEN_COM_ACME_COYOTE (ret);
8601   else
8602     return NULL;
8603 }
8604
8605
8606 /**
8607  * foo_igen_com_acme_coyote_proxy_new_for_bus:
8608  * @bus_type: A #GBusType.
8609  * @flags: Flags from the #GDBusProxyFlags enumeration.
8610  * @name: A bus name (well-known or unique).
8611  * @object_path: An object path.
8612  * @cancellable: (allow-none): A #GCancellable or %NULL.
8613  * @callback: A #GAsyncReadyCallback to call when the request is satisfied.
8614  * @user_data: User data to pass to @callback.
8615  *
8616  * Like foo_igen_com_acme_coyote_proxy_new() but takes a #GBusType instead of a #GDBusConnection.
8617  *
8618  * When the operation is finished, @callback will be invoked in the <link linkend="g-main-context-push-thread-default">thread-default main loop</link> of the thread you are calling this method from.
8619  * You can then call foo_igen_com_acme_coyote_proxy_new_for_bus_finish() to get the result of the operation.
8620  *
8621  * See foo_igen_com_acme_coyote_proxy_new_for_bus_sync() for the synchronous, blocking version of this constructor.
8622  */
8623 void
8624 foo_igen_com_acme_coyote_proxy_new_for_bus (
8625     GBusType             bus_type,
8626     GDBusProxyFlags      flags,
8627     const gchar         *name,
8628     const gchar         *object_path,
8629     GCancellable        *cancellable,
8630     GAsyncReadyCallback  callback,
8631     gpointer             user_data)
8632 {
8633   g_async_initable_new_async (FOO_IGEN_TYPE_COM_ACME_COYOTE_PROXY, G_PRIORITY_DEFAULT, cancellable, callback, user_data, "g-flags", flags, "g-name", name, "g-bus-type", bus_type, "g-object-path", object_path, "g-interface-name", "com.acme.Coyote", NULL);
8634 }
8635
8636 /**
8637  * foo_igen_com_acme_coyote_proxy_new_for_bus_finish:
8638  * @res: The #GAsyncResult obtained from the #GAsyncReadyCallback passed to foo_igen_com_acme_coyote_proxy_new_for_bus().
8639  * @error: Return location for error or %NULL
8640  *
8641  * Finishes an operation started with foo_igen_com_acme_coyote_proxy_new_for_bus().
8642  *
8643  * Returns: (transfer full) (type FooiGenComAcmeCoyoteProxy): The constructed proxy object or %NULL if @error is set.
8644  */
8645 FooiGenComAcmeCoyote *
8646 foo_igen_com_acme_coyote_proxy_new_for_bus_finish (
8647     GAsyncResult        *res,
8648     GError             **error)
8649 {
8650   GObject *ret;
8651   GObject *source_object;
8652   source_object = g_async_result_get_source_object (res);
8653   ret = g_async_initable_new_finish (G_ASYNC_INITABLE (source_object), res, error);
8654   g_object_unref (source_object);
8655   if (ret != NULL)
8656     return FOO_IGEN_COM_ACME_COYOTE (ret);
8657   else
8658     return NULL;
8659 }
8660
8661 /**
8662  * foo_igen_com_acme_coyote_proxy_new_for_bus_sync:
8663  * @bus_type: A #GBusType.
8664  * @flags: Flags from the #GDBusProxyFlags enumeration.
8665  * @name: A bus name (well-known or unique).
8666  * @object_path: An object path.
8667  * @cancellable: (allow-none): A #GCancellable or %NULL.
8668  * @error: Return location for error or %NULL
8669  *
8670  * Like foo_igen_com_acme_coyote_proxy_new_sync() but takes a #GBusType instead of a #GDBusConnection.
8671  *
8672  * The calling thread is blocked until a reply is received.
8673  *
8674  * See foo_igen_com_acme_coyote_proxy_new_for_bus() for the asynchronous version of this constructor.
8675  *
8676  * Returns: (transfer full) (type FooiGenComAcmeCoyoteProxy): The constructed proxy object or %NULL if @error is set.
8677  */
8678 FooiGenComAcmeCoyote *
8679 foo_igen_com_acme_coyote_proxy_new_for_bus_sync (
8680     GBusType             bus_type,
8681     GDBusProxyFlags      flags,
8682     const gchar         *name,
8683     const gchar         *object_path,
8684     GCancellable        *cancellable,
8685     GError             **error)
8686 {
8687   GInitable *ret;
8688   ret = g_initable_new (FOO_IGEN_TYPE_COM_ACME_COYOTE_PROXY, cancellable, error, "g-flags", flags, "g-name", name, "g-bus-type", bus_type, "g-object-path", object_path, "g-interface-name", "com.acme.Coyote", NULL);
8689   if (ret != NULL)
8690     return FOO_IGEN_COM_ACME_COYOTE (ret);
8691   else
8692     return NULL;
8693 }
8694
8695
8696 /* ------------------------------------------------------------------------ */
8697
8698 /**
8699  * FooiGenComAcmeCoyoteSkeleton:
8700  *
8701  * The #FooiGenComAcmeCoyoteSkeleton structure contains only private data and should only be accessed using the provided API.
8702  */
8703
8704 /**
8705  * FooiGenComAcmeCoyoteSkeletonClass:
8706  * @parent_class: The parent class.
8707  *
8708  * Class structure for #FooiGenComAcmeCoyoteSkeleton.
8709  */
8710
8711 struct _FooiGenComAcmeCoyoteSkeletonPrivate
8712 {
8713   GValue *properties;
8714   GList *changed_properties;
8715   GSource *changed_properties_idle_source;
8716   GMainContext *context;
8717   GMutex lock;
8718 };
8719
8720 static void
8721 _foo_igen_com_acme_coyote_skeleton_handle_method_call (
8722   GDBusConnection *connection,
8723   const gchar *sender,
8724   const gchar *object_path,
8725   const gchar *interface_name,
8726   const gchar *method_name,
8727   GVariant *parameters,
8728   GDBusMethodInvocation *invocation,
8729   gpointer user_data)
8730 {
8731   FooiGenComAcmeCoyoteSkeleton *skeleton = FOO_IGEN_COM_ACME_COYOTE_SKELETON (user_data);
8732   _ExtendedGDBusMethodInfo *info;
8733   GVariantIter iter;
8734   GVariant *child;
8735   GValue *paramv;
8736   guint num_params;
8737   guint num_extra;
8738   guint n;
8739   guint signal_id;
8740   GValue return_value = G_VALUE_INIT;
8741   info = (_ExtendedGDBusMethodInfo *) g_dbus_method_invocation_get_method_info (invocation);
8742   g_assert (info != NULL);
8743   num_params = g_variant_n_children (parameters);
8744   num_extra = info->pass_fdlist ? 3 : 2;  paramv = g_new0 (GValue, num_params + num_extra);
8745   n = 0;
8746   g_value_init (&paramv[n], FOO_IGEN_TYPE_COM_ACME_COYOTE);
8747   g_value_set_object (&paramv[n++], skeleton);
8748   g_value_init (&paramv[n], G_TYPE_DBUS_METHOD_INVOCATION);
8749   g_value_set_object (&paramv[n++], invocation);
8750   if (info->pass_fdlist)
8751     {
8752 #ifdef G_OS_UNIX
8753       g_value_init (&paramv[n], G_TYPE_UNIX_FD_LIST);
8754       g_value_set_object (&paramv[n++], g_dbus_message_get_unix_fd_list (g_dbus_method_invocation_get_message (invocation)));
8755 #else
8756       g_assert_not_reached ();
8757 #endif
8758     }
8759   g_variant_iter_init (&iter, parameters);
8760   while ((child = g_variant_iter_next_value (&iter)) != NULL)
8761     {
8762       _ExtendedGDBusArgInfo *arg_info = (_ExtendedGDBusArgInfo *) info->parent_struct.in_args[n - num_extra];
8763       if (arg_info->use_gvariant)
8764         {
8765           g_value_init (&paramv[n], G_TYPE_VARIANT);
8766           g_value_set_variant (&paramv[n], child);
8767           n++;
8768         }
8769       else
8770         g_dbus_gvariant_to_gvalue (child, &paramv[n++]);
8771       g_variant_unref (child);
8772     }
8773   signal_id = g_signal_lookup (info->signal_name, FOO_IGEN_TYPE_COM_ACME_COYOTE);
8774   g_value_init (&return_value, G_TYPE_BOOLEAN);
8775   g_signal_emitv (paramv, signal_id, 0, &return_value);
8776   if (!g_value_get_boolean (&return_value))
8777     g_dbus_method_invocation_return_error (invocation, G_DBUS_ERROR, G_DBUS_ERROR_UNKNOWN_METHOD, "Method %s is not implemented on interface %s", method_name, interface_name);
8778   g_value_unset (&return_value);
8779   for (n = 0; n < num_params + num_extra; n++)
8780     g_value_unset (&paramv[n]);
8781   g_free (paramv);
8782 }
8783
8784 static GVariant *
8785 _foo_igen_com_acme_coyote_skeleton_handle_get_property (
8786   GDBusConnection *connection,
8787   const gchar *sender,
8788   const gchar *object_path,
8789   const gchar *interface_name,
8790   const gchar *property_name,
8791   GError **error,
8792   gpointer user_data)
8793 {
8794   FooiGenComAcmeCoyoteSkeleton *skeleton = FOO_IGEN_COM_ACME_COYOTE_SKELETON (user_data);
8795   GValue value = G_VALUE_INIT;
8796   GParamSpec *pspec;
8797   _ExtendedGDBusPropertyInfo *info;
8798   GVariant *ret;
8799   ret = NULL;
8800   info = (_ExtendedGDBusPropertyInfo *) g_dbus_interface_info_lookup_property ((GDBusInterfaceInfo *) &_foo_igen_com_acme_coyote_interface_info, property_name);
8801   g_assert (info != NULL);
8802   pspec = g_object_class_find_property (G_OBJECT_GET_CLASS (skeleton), info->hyphen_name);
8803   if (pspec == NULL)
8804     {
8805       g_set_error (error, G_DBUS_ERROR, G_DBUS_ERROR_INVALID_ARGS, "No property with name %s", property_name);
8806     }
8807   else
8808     {
8809       g_value_init (&value, pspec->value_type);
8810       g_object_get_property (G_OBJECT (skeleton), info->hyphen_name, &value);
8811       ret = g_dbus_gvalue_to_gvariant (&value, G_VARIANT_TYPE (info->parent_struct.signature));
8812       g_value_unset (&value);
8813     }
8814   return ret;
8815 }
8816
8817 static gboolean
8818 _foo_igen_com_acme_coyote_skeleton_handle_set_property (
8819   GDBusConnection *connection,
8820   const gchar *sender,
8821   const gchar *object_path,
8822   const gchar *interface_name,
8823   const gchar *property_name,
8824   GVariant *variant,
8825   GError **error,
8826   gpointer user_data)
8827 {
8828   FooiGenComAcmeCoyoteSkeleton *skeleton = FOO_IGEN_COM_ACME_COYOTE_SKELETON (user_data);
8829   GValue value = G_VALUE_INIT;
8830   GParamSpec *pspec;
8831   _ExtendedGDBusPropertyInfo *info;
8832   gboolean ret;
8833   ret = FALSE;
8834   info = (_ExtendedGDBusPropertyInfo *) g_dbus_interface_info_lookup_property ((GDBusInterfaceInfo *) &_foo_igen_com_acme_coyote_interface_info, property_name);
8835   g_assert (info != NULL);
8836   pspec = g_object_class_find_property (G_OBJECT_GET_CLASS (skeleton), info->hyphen_name);
8837   if (pspec == NULL)
8838     {
8839       g_set_error (error, G_DBUS_ERROR, G_DBUS_ERROR_INVALID_ARGS, "No property with name %s", property_name);
8840     }
8841   else
8842     {
8843       if (info->use_gvariant)
8844         g_value_set_variant (&value, variant);
8845       else
8846         g_dbus_gvariant_to_gvalue (variant, &value);
8847       g_object_set_property (G_OBJECT (skeleton), info->hyphen_name, &value);
8848       g_value_unset (&value);
8849       ret = TRUE;
8850     }
8851   return ret;
8852 }
8853
8854 static const GDBusInterfaceVTable _foo_igen_com_acme_coyote_skeleton_vtable =
8855 {
8856   _foo_igen_com_acme_coyote_skeleton_handle_method_call,
8857   _foo_igen_com_acme_coyote_skeleton_handle_get_property,
8858   _foo_igen_com_acme_coyote_skeleton_handle_set_property
8859 };
8860
8861 static GDBusInterfaceInfo *
8862 foo_igen_com_acme_coyote_skeleton_dbus_interface_get_info (GDBusInterfaceSkeleton *skeleton)
8863 {
8864   return foo_igen_com_acme_coyote_interface_info ();
8865 }
8866
8867 static GDBusInterfaceVTable *
8868 foo_igen_com_acme_coyote_skeleton_dbus_interface_get_vtable (GDBusInterfaceSkeleton *skeleton)
8869 {
8870   return (GDBusInterfaceVTable *) &_foo_igen_com_acme_coyote_skeleton_vtable;
8871 }
8872
8873 static GVariant *
8874 foo_igen_com_acme_coyote_skeleton_dbus_interface_get_properties (GDBusInterfaceSkeleton *_skeleton)
8875 {
8876   FooiGenComAcmeCoyoteSkeleton *skeleton = FOO_IGEN_COM_ACME_COYOTE_SKELETON (_skeleton);
8877
8878   GVariantBuilder builder;
8879   guint n;
8880   g_variant_builder_init (&builder, G_VARIANT_TYPE ("a{sv}"));
8881   if (_foo_igen_com_acme_coyote_interface_info.parent_struct.properties == NULL)
8882     goto out;
8883   for (n = 0; _foo_igen_com_acme_coyote_interface_info.parent_struct.properties[n] != NULL; n++)
8884     {
8885       GDBusPropertyInfo *info = _foo_igen_com_acme_coyote_interface_info.parent_struct.properties[n];
8886       if (info->flags & G_DBUS_PROPERTY_INFO_FLAGS_READABLE)
8887         {
8888           GVariant *value;
8889           value = _foo_igen_com_acme_coyote_skeleton_handle_get_property (g_dbus_interface_skeleton_get_connection (G_DBUS_INTERFACE_SKELETON (skeleton)), NULL, g_dbus_interface_skeleton_get_object_path (G_DBUS_INTERFACE_SKELETON (skeleton)), "com.acme.Coyote", info->name, NULL, skeleton);
8890           if (value != NULL)
8891             {
8892               g_variant_take_ref (value);
8893               g_variant_builder_add (&builder, "{sv}", info->name, value);
8894               g_variant_unref (value);
8895             }
8896         }
8897     }
8898 out:
8899   return g_variant_builder_end (&builder);
8900 }
8901
8902 static gboolean _foo_igen_com_acme_coyote_emit_changed (gpointer user_data);
8903
8904 static void
8905 foo_igen_com_acme_coyote_skeleton_dbus_interface_flush (GDBusInterfaceSkeleton *_skeleton)
8906 {
8907   FooiGenComAcmeCoyoteSkeleton *skeleton = FOO_IGEN_COM_ACME_COYOTE_SKELETON (_skeleton);
8908   gboolean emit_changed = FALSE;
8909
8910   g_mutex_lock (&skeleton->priv->lock);
8911   if (skeleton->priv->changed_properties_idle_source != NULL)
8912     {
8913       g_source_destroy (skeleton->priv->changed_properties_idle_source);
8914       skeleton->priv->changed_properties_idle_source = NULL;
8915       emit_changed = TRUE;
8916     }
8917   g_mutex_unlock (&skeleton->priv->lock);
8918
8919   if (emit_changed)
8920     _foo_igen_com_acme_coyote_emit_changed (skeleton);
8921 }
8922
8923 static void
8924 _foo_igen_com_acme_coyote_on_signal_surprised (
8925     FooiGenComAcmeCoyote *object)
8926 {
8927   FooiGenComAcmeCoyoteSkeleton *skeleton = FOO_IGEN_COM_ACME_COYOTE_SKELETON (object);
8928
8929   GList      *connections, *l;
8930   GVariant   *signal_variant;
8931   connections = g_dbus_interface_skeleton_get_connections (G_DBUS_INTERFACE_SKELETON (skeleton));
8932
8933   signal_variant = g_variant_ref_sink (g_variant_new ("()"));
8934   for (l = connections; l != NULL; l = l->next)
8935     {
8936       GDBusConnection *connection = l->data;
8937       g_dbus_connection_emit_signal (connection,
8938         NULL, g_dbus_interface_skeleton_get_object_path (G_DBUS_INTERFACE_SKELETON (skeleton)), "com.acme.Coyote", "Surprised",
8939         signal_variant, NULL);
8940     }
8941   g_variant_unref (signal_variant);
8942   g_list_free_full (connections, g_object_unref);
8943 }
8944
8945 static void foo_igen_com_acme_coyote_skeleton_iface_init (FooiGenComAcmeCoyoteIface *iface);
8946 G_DEFINE_TYPE_WITH_CODE (FooiGenComAcmeCoyoteSkeleton, foo_igen_com_acme_coyote_skeleton, G_TYPE_DBUS_INTERFACE_SKELETON,
8947                          G_IMPLEMENT_INTERFACE (FOO_IGEN_TYPE_COM_ACME_COYOTE, foo_igen_com_acme_coyote_skeleton_iface_init));
8948
8949 static void
8950 foo_igen_com_acme_coyote_skeleton_finalize (GObject *object)
8951 {
8952   FooiGenComAcmeCoyoteSkeleton *skeleton = FOO_IGEN_COM_ACME_COYOTE_SKELETON (object);
8953   guint n;
8954   for (n = 0; n < 1; n++)
8955     g_value_unset (&skeleton->priv->properties[n]);
8956   g_free (skeleton->priv->properties);
8957   g_list_free_full (skeleton->priv->changed_properties, (GDestroyNotify) _changed_property_free);
8958   if (skeleton->priv->changed_properties_idle_source != NULL)
8959     g_source_destroy (skeleton->priv->changed_properties_idle_source);
8960   g_main_context_unref (skeleton->priv->context);
8961   g_mutex_clear (&skeleton->priv->lock);
8962   G_OBJECT_CLASS (foo_igen_com_acme_coyote_skeleton_parent_class)->finalize (object);
8963 }
8964
8965 static void
8966 foo_igen_com_acme_coyote_skeleton_get_property (GObject      *object,
8967   guint         prop_id,
8968   GValue       *value,
8969   GParamSpec   *pspec)
8970 {
8971   FooiGenComAcmeCoyoteSkeleton *skeleton = FOO_IGEN_COM_ACME_COYOTE_SKELETON (object);
8972   g_assert (prop_id != 0 && prop_id - 1 < 1);
8973   g_mutex_lock (&skeleton->priv->lock);
8974   g_value_copy (&skeleton->priv->properties[prop_id - 1], value);
8975   g_mutex_unlock (&skeleton->priv->lock);
8976 }
8977
8978 static gboolean
8979 _foo_igen_com_acme_coyote_emit_changed (gpointer user_data)
8980 {
8981   FooiGenComAcmeCoyoteSkeleton *skeleton = FOO_IGEN_COM_ACME_COYOTE_SKELETON (user_data);
8982   GList *l;
8983   GVariantBuilder builder;
8984   GVariantBuilder invalidated_builder;
8985   guint num_changes;
8986
8987   g_mutex_lock (&skeleton->priv->lock);
8988   g_variant_builder_init (&builder, G_VARIANT_TYPE ("a{sv}"));
8989   g_variant_builder_init (&invalidated_builder, G_VARIANT_TYPE ("as"));
8990   for (l = skeleton->priv->changed_properties, num_changes = 0; l != NULL; l = l->next)
8991     {
8992       ChangedProperty *cp = l->data;
8993       GVariant *variant;
8994       const GValue *cur_value;
8995
8996       cur_value = &skeleton->priv->properties[cp->prop_id - 1];
8997       if (!_g_value_equal (cur_value, &cp->orig_value))
8998         {
8999           variant = g_dbus_gvalue_to_gvariant (cur_value, G_VARIANT_TYPE (cp->info->parent_struct.signature));
9000           g_variant_builder_add (&builder, "{sv}", cp->info->parent_struct.name, variant);
9001           g_variant_unref (variant);
9002           num_changes++;
9003         }
9004     }
9005   if (num_changes > 0)
9006     {
9007       GList *connections, *l;
9008       GVariant *signal_variant;
9009       signal_variant = g_variant_ref_sink (g_variant_new ("(sa{sv}as)", "com.acme.Coyote",
9010                                            &builder, &invalidated_builder));
9011       connections = g_dbus_interface_skeleton_get_connections (G_DBUS_INTERFACE_SKELETON (skeleton));
9012       for (l = connections; l != NULL; l = l->next)
9013         {
9014           GDBusConnection *connection = l->data;
9015
9016           g_dbus_connection_emit_signal (connection,
9017                                          NULL, g_dbus_interface_skeleton_get_object_path (G_DBUS_INTERFACE_SKELETON (skeleton)),
9018                                          "org.freedesktop.DBus.Properties",
9019                                          "PropertiesChanged",
9020                                          signal_variant,
9021                                          NULL);
9022         }
9023       g_variant_unref (signal_variant);
9024       g_list_free_full (connections, g_object_unref);
9025     }
9026   else
9027     {
9028       g_variant_builder_clear (&builder);
9029       g_variant_builder_clear (&invalidated_builder);
9030     }
9031   g_list_free_full (skeleton->priv->changed_properties, (GDestroyNotify) _changed_property_free);
9032   skeleton->priv->changed_properties = NULL;
9033   skeleton->priv->changed_properties_idle_source = NULL;
9034   g_mutex_unlock (&skeleton->priv->lock);
9035   return FALSE;
9036 }
9037
9038 static void
9039 _foo_igen_com_acme_coyote_schedule_emit_changed (FooiGenComAcmeCoyoteSkeleton *skeleton, const _ExtendedGDBusPropertyInfo *info, guint prop_id, const GValue *orig_value)
9040 {
9041   ChangedProperty *cp;
9042   GList *l;
9043   cp = NULL;
9044   for (l = skeleton->priv->changed_properties; l != NULL; l = l->next)
9045     {
9046       ChangedProperty *i_cp = l->data;
9047       if (i_cp->info == info)
9048         {
9049           cp = i_cp;
9050           break;
9051         }
9052     }
9053   if (cp == NULL)
9054     {
9055       cp = g_new0 (ChangedProperty, 1);
9056       cp->prop_id = prop_id;
9057       cp->info = info;
9058       skeleton->priv->changed_properties = g_list_prepend (skeleton->priv->changed_properties, cp);
9059       g_value_init (&cp->orig_value, G_VALUE_TYPE (orig_value));
9060       g_value_copy (orig_value, &cp->orig_value);
9061     }
9062 }
9063
9064 static void
9065 foo_igen_com_acme_coyote_skeleton_notify (GObject      *object,
9066   GParamSpec *pspec)
9067 {
9068   FooiGenComAcmeCoyoteSkeleton *skeleton = FOO_IGEN_COM_ACME_COYOTE_SKELETON (object);
9069   g_mutex_lock (&skeleton->priv->lock);
9070   if (skeleton->priv->changed_properties != NULL &&
9071       skeleton->priv->changed_properties_idle_source == NULL)
9072     {
9073       skeleton->priv->changed_properties_idle_source = g_idle_source_new ();
9074       g_source_set_priority (skeleton->priv->changed_properties_idle_source, G_PRIORITY_DEFAULT);
9075       g_source_set_callback (skeleton->priv->changed_properties_idle_source, _foo_igen_com_acme_coyote_emit_changed, g_object_ref (skeleton), (GDestroyNotify) g_object_unref);
9076       g_source_attach (skeleton->priv->changed_properties_idle_source, skeleton->priv->context);
9077       g_source_unref (skeleton->priv->changed_properties_idle_source);
9078     }
9079   g_mutex_unlock (&skeleton->priv->lock);
9080 }
9081
9082 static void
9083 foo_igen_com_acme_coyote_skeleton_set_property (GObject      *object,
9084   guint         prop_id,
9085   const GValue *value,
9086   GParamSpec   *pspec)
9087 {
9088   FooiGenComAcmeCoyoteSkeleton *skeleton = FOO_IGEN_COM_ACME_COYOTE_SKELETON (object);
9089   g_assert (prop_id != 0 && prop_id - 1 < 1);
9090   g_mutex_lock (&skeleton->priv->lock);
9091   g_object_freeze_notify (object);
9092   if (!_g_value_equal (value, &skeleton->priv->properties[prop_id - 1]))
9093     {
9094       if (g_dbus_interface_skeleton_get_connection (G_DBUS_INTERFACE_SKELETON (skeleton)) != NULL)
9095         _foo_igen_com_acme_coyote_schedule_emit_changed (skeleton, _foo_igen_com_acme_coyote_property_info_pointers[prop_id - 1], prop_id, &skeleton->priv->properties[prop_id - 1]);
9096       g_value_copy (value, &skeleton->priv->properties[prop_id - 1]);
9097       g_object_notify_by_pspec (object, pspec);
9098     }
9099   g_mutex_unlock (&skeleton->priv->lock);
9100   g_object_thaw_notify (object);
9101 }
9102
9103 static void
9104 foo_igen_com_acme_coyote_skeleton_init (FooiGenComAcmeCoyoteSkeleton *skeleton)
9105 {
9106   skeleton->priv = G_TYPE_INSTANCE_GET_PRIVATE (skeleton, FOO_IGEN_TYPE_COM_ACME_COYOTE_SKELETON, FooiGenComAcmeCoyoteSkeletonPrivate);
9107   g_mutex_init (&skeleton->priv->lock);
9108   skeleton->priv->context = g_main_context_ref_thread_default ();
9109   skeleton->priv->properties = g_new0 (GValue, 1);
9110   g_value_init (&skeleton->priv->properties[0], G_TYPE_STRING);
9111 }
9112
9113 static const gchar *
9114 foo_igen_com_acme_coyote_skeleton_get_mood (FooiGenComAcmeCoyote *object)
9115 {
9116   FooiGenComAcmeCoyoteSkeleton *skeleton = FOO_IGEN_COM_ACME_COYOTE_SKELETON (object);
9117   const gchar *value;
9118   g_mutex_lock (&skeleton->priv->lock);
9119   value = g_value_get_string (&(skeleton->priv->properties[0]));
9120   g_mutex_unlock (&skeleton->priv->lock);
9121   return value;
9122 }
9123
9124 static void
9125 foo_igen_com_acme_coyote_skeleton_class_init (FooiGenComAcmeCoyoteSkeletonClass *klass)
9126 {
9127   GObjectClass *gobject_class;
9128   GDBusInterfaceSkeletonClass *skeleton_class;
9129
9130   g_type_class_add_private (klass, sizeof (FooiGenComAcmeCoyoteSkeletonPrivate));
9131
9132   gobject_class = G_OBJECT_CLASS (klass);
9133   gobject_class->finalize = foo_igen_com_acme_coyote_skeleton_finalize;
9134   gobject_class->get_property = foo_igen_com_acme_coyote_skeleton_get_property;
9135   gobject_class->set_property = foo_igen_com_acme_coyote_skeleton_set_property;
9136   gobject_class->notify       = foo_igen_com_acme_coyote_skeleton_notify;
9137
9138
9139   foo_igen_com_acme_coyote_override_properties (gobject_class, 1);
9140
9141   skeleton_class = G_DBUS_INTERFACE_SKELETON_CLASS (klass);
9142   skeleton_class->get_info = foo_igen_com_acme_coyote_skeleton_dbus_interface_get_info;
9143   skeleton_class->get_properties = foo_igen_com_acme_coyote_skeleton_dbus_interface_get_properties;
9144   skeleton_class->flush = foo_igen_com_acme_coyote_skeleton_dbus_interface_flush;
9145   skeleton_class->get_vtable = foo_igen_com_acme_coyote_skeleton_dbus_interface_get_vtable;
9146 }
9147
9148 static void
9149 foo_igen_com_acme_coyote_skeleton_iface_init (FooiGenComAcmeCoyoteIface *iface)
9150 {
9151   iface->surprised = _foo_igen_com_acme_coyote_on_signal_surprised;
9152   iface->get_mood = foo_igen_com_acme_coyote_skeleton_get_mood;
9153 }
9154
9155 /**
9156  * foo_igen_com_acme_coyote_skeleton_new:
9157  *
9158  * Creates a skeleton object for the D-Bus interface <link linkend="gdbus-interface-com-acme-Coyote.top_of_page">com.acme.Coyote</link>.
9159  *
9160  * Returns: (transfer full) (type FooiGenComAcmeCoyoteSkeleton): The skeleton object.
9161  */
9162 FooiGenComAcmeCoyote *
9163 foo_igen_com_acme_coyote_skeleton_new (void)
9164 {
9165   return FOO_IGEN_COM_ACME_COYOTE (g_object_new (FOO_IGEN_TYPE_COM_ACME_COYOTE_SKELETON, NULL));
9166 }
9167
9168 /* ------------------------------------------------------------------------
9169  * Code for interface com.acme.Rocket
9170  * ------------------------------------------------------------------------
9171  */
9172
9173 /**
9174  * SECTION:FooiGenRocket123
9175  * @title: FooiGenRocket123
9176  * @short_description: Generated C code for the com.acme.Rocket D-Bus interface
9177  *
9178  * This section contains code for working with the <link linkend="gdbus-interface-com-acme-Rocket.top_of_page">com.acme.Rocket</link> D-Bus interface in C.
9179  */
9180
9181 /* ---- Introspection data for com.acme.Rocket ---- */
9182
9183 static const _ExtendedGDBusMethodInfo _foo_igen_rocket123_method_info_ignite_xyz =
9184 {
9185   {
9186     -1,
9187     "Ignite",
9188     NULL,
9189     NULL,
9190     NULL
9191   },
9192   "handle-ignite-xyz",
9193   FALSE
9194 };
9195
9196 static const _ExtendedGDBusMethodInfo * const _foo_igen_rocket123_method_info_pointers[] =
9197 {
9198   &_foo_igen_rocket123_method_info_ignite_xyz,
9199   NULL
9200 };
9201
9202 static const _ExtendedGDBusSignalInfo _foo_igen_rocket123_signal_info_exploded_xyz =
9203 {
9204   {
9205     -1,
9206     "Exploded",
9207     NULL,
9208     NULL
9209   },
9210   "exploded-xyz"
9211 };
9212
9213 static const _ExtendedGDBusSignalInfo * const _foo_igen_rocket123_signal_info_pointers[] =
9214 {
9215   &_foo_igen_rocket123_signal_info_exploded_xyz,
9216   NULL
9217 };
9218
9219 static const _ExtendedGDBusPropertyInfo _foo_igen_rocket123_property_info_speed_xyz =
9220 {
9221   {
9222     -1,
9223     "Speed",
9224     "d",
9225     G_DBUS_PROPERTY_INFO_FLAGS_READABLE,
9226     NULL
9227   },
9228   "speed-xyz",
9229   FALSE
9230 };
9231
9232 static const _ExtendedGDBusPropertyInfo _foo_igen_rocket123_property_info_direction =
9233 {
9234   {
9235     -1,
9236     "Direction",
9237     "(ddd)",
9238     G_DBUS_PROPERTY_INFO_FLAGS_READABLE,
9239     NULL
9240   },
9241   "direction",
9242   FALSE
9243 };
9244
9245 static const _ExtendedGDBusPropertyInfo _foo_igen_rocket123_property_info_type_ =
9246 {
9247   {
9248     -1,
9249     "Type",
9250     "s",
9251     G_DBUS_PROPERTY_INFO_FLAGS_READABLE,
9252     NULL
9253   },
9254   "type-",
9255   FALSE
9256 };
9257
9258 static const _ExtendedGDBusPropertyInfo * const _foo_igen_rocket123_property_info_pointers[] =
9259 {
9260   &_foo_igen_rocket123_property_info_speed_xyz,
9261   &_foo_igen_rocket123_property_info_direction,
9262   &_foo_igen_rocket123_property_info_type_,
9263   NULL
9264 };
9265
9266 static const _ExtendedGDBusInterfaceInfo _foo_igen_rocket123_interface_info =
9267 {
9268   {
9269     -1,
9270     "com.acme.Rocket",
9271     (GDBusMethodInfo **) &_foo_igen_rocket123_method_info_pointers,
9272     (GDBusSignalInfo **) &_foo_igen_rocket123_signal_info_pointers,
9273     (GDBusPropertyInfo **) &_foo_igen_rocket123_property_info_pointers,
9274     NULL
9275   },
9276   "rocket123",
9277 };
9278
9279
9280 /**
9281  * foo_igen_rocket123_interface_info:
9282  *
9283  * Gets a machine-readable description of the <link linkend="gdbus-interface-com-acme-Rocket.top_of_page">com.acme.Rocket</link> D-Bus interface.
9284  *
9285  * Returns: (transfer none): A #GDBusInterfaceInfo. Do not free.
9286  */
9287 GDBusInterfaceInfo *
9288 foo_igen_rocket123_interface_info (void)
9289 {
9290   return (GDBusInterfaceInfo *) &_foo_igen_rocket123_interface_info;
9291 }
9292
9293 /**
9294  * foo_igen_rocket123_override_properties:
9295  * @klass: The class structure for a #GObject<!-- -->-derived class.
9296  * @property_id_begin: The property id to assign to the first overridden property.
9297  *
9298  * Overrides all #GObject properties in the #FooiGenRocket123 interface for a concrete class.
9299  * The properties are overridden in the order they are defined.
9300  *
9301  * Returns: The last property id.
9302  */
9303 guint
9304 foo_igen_rocket123_override_properties (GObjectClass *klass, guint property_id_begin)
9305 {
9306   g_object_class_override_property (klass, property_id_begin++, "speed-xyz");
9307   g_object_class_override_property (klass, property_id_begin++, "direction");
9308   g_object_class_override_property (klass, property_id_begin++, "type-");
9309   return property_id_begin - 1;
9310 }
9311
9312
9313
9314 /**
9315  * FooiGenRocket123:
9316  *
9317  * Abstract interface type for the D-Bus interface <link linkend="gdbus-interface-com-acme-Rocket.top_of_page">com.acme.Rocket</link>.
9318  */
9319
9320 /**
9321  * FooiGenRocket123Iface:
9322  * @parent_iface: The parent interface.
9323  * @handle_ignite_xyz: Handler for the #FooiGenRocket123::handle-ignite-xyz signal.
9324  * @get_direction: Getter for the #FooiGenRocket123:direction property.
9325  * @get_speed_xyz: Getter for the #FooiGenRocket123:speed-xyz property.
9326  * @get_type_: Getter for the #FooiGenRocket123:type- property.
9327  * @exploded_xyz: Handler for the #FooiGenRocket123::exploded-xyz signal.
9328  *
9329  * Virtual table for the D-Bus interface <link linkend="gdbus-interface-com-acme-Rocket.top_of_page">com.acme.Rocket</link>.
9330  */
9331
9332 static void
9333 foo_igen_rocket123_default_init (FooiGenRocket123Iface *iface)
9334 {
9335   /* GObject signals for incoming D-Bus method calls: */
9336   /**
9337    * FooiGenRocket123::handle-ignite-xyz:
9338    * @object: A #FooiGenRocket123.
9339    * @invocation: A #GDBusMethodInvocation.
9340    *
9341    * Signal emitted when a remote caller is invoking the <link linkend="gdbus-method-com-acme-Rocket.Ignite">Ignite()</link> D-Bus method.
9342    *
9343    * If a signal handler returns %TRUE, it means the signal handler will handle the invocation (e.g. take a reference to @invocation and eventually call foo_igen_rocket123_complete_ignite_xyz() or e.g. g_dbus_method_invocation_return_error() on it) and no order signal handlers will run. If no signal handler handles the invocation, the %G_DBUS_ERROR_UNKNOWN_METHOD error is returned.
9344    *
9345    * Returns: %TRUE if the invocation was handled, %FALSE to let other signal handlers run.
9346    */
9347   g_signal_new ("handle-ignite-xyz",
9348     G_TYPE_FROM_INTERFACE (iface),
9349     G_SIGNAL_RUN_LAST,
9350     G_STRUCT_OFFSET (FooiGenRocket123Iface, handle_ignite_xyz),
9351     g_signal_accumulator_true_handled,
9352     NULL,
9353     g_cclosure_marshal_generic,
9354     G_TYPE_BOOLEAN,
9355     1,
9356     G_TYPE_DBUS_METHOD_INVOCATION);
9357
9358   /* GObject signals for received D-Bus signals: */
9359   /**
9360    * FooiGenRocket123::exploded-xyz:
9361    * @object: A #FooiGenRocket123.
9362    *
9363    * On the client-side, this signal is emitted whenever the D-Bus signal <link linkend="gdbus-signal-com-acme-Rocket.Exploded">"Exploded"</link> is received.
9364    *
9365    * On the service-side, this signal can be used with e.g. g_signal_emit_by_name() to make the object emit the D-Bus signal.
9366    */
9367   g_signal_new ("exploded-xyz",
9368     G_TYPE_FROM_INTERFACE (iface),
9369     G_SIGNAL_RUN_LAST,
9370     G_STRUCT_OFFSET (FooiGenRocket123Iface, exploded_xyz),
9371     NULL,
9372     NULL,
9373     g_cclosure_marshal_generic,
9374     G_TYPE_NONE,
9375     0);
9376
9377   /* GObject properties for D-Bus properties: */
9378   /**
9379    * FooiGenRocket123:speed-xyz:
9380    *
9381    * Represents the D-Bus property <link linkend="gdbus-property-com-acme-Rocket.Speed">"Speed"</link>.
9382    *
9383    * Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
9384    */
9385   g_object_interface_install_property (iface,
9386     g_param_spec_double ("speed-xyz", "Speed", "Speed", -G_MAXDOUBLE, G_MAXDOUBLE, 0.0, G_PARAM_READWRITE | G_PARAM_STATIC_STRINGS));
9387   /**
9388    * FooiGenRocket123:direction:
9389    *
9390    * Represents the D-Bus property <link linkend="gdbus-property-com-acme-Rocket.Direction">"Direction"</link>.
9391    *
9392    * Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
9393    */
9394   g_object_interface_install_property (iface,
9395     g_param_spec_variant ("direction", "Direction", "Direction", G_VARIANT_TYPE ("(ddd)"), NULL, G_PARAM_READWRITE | G_PARAM_STATIC_STRINGS));
9396   /**
9397    * FooiGenRocket123:type-:
9398    *
9399    * Represents the D-Bus property <link linkend="gdbus-property-com-acme-Rocket.Type">"Type"</link>.
9400    *
9401    * Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
9402    */
9403   g_object_interface_install_property (iface,
9404     g_param_spec_string ("type-", "Type", "Type", NULL, G_PARAM_READWRITE | G_PARAM_STATIC_STRINGS));
9405 }
9406
9407 typedef FooiGenRocket123Iface FooiGenRocket123Interface;
9408 G_DEFINE_INTERFACE (FooiGenRocket123, foo_igen_rocket123, G_TYPE_OBJECT);
9409
9410 /**
9411  * foo_igen_rocket123_get_speed_xyz: (skip)
9412  * @object: A #FooiGenRocket123.
9413  *
9414  * Gets the value of the <link linkend="gdbus-property-com-acme-Rocket.Speed">"Speed"</link> D-Bus property.
9415  *
9416  * Since this D-Bus property is readable, it is meaningful to use this function on both the client- and service-side.
9417  *
9418  * Returns: The property value.
9419  */
9420 gdouble 
9421 foo_igen_rocket123_get_speed_xyz (FooiGenRocket123 *object)
9422 {
9423   return FOO_IGEN_ROCKET123_GET_IFACE (object)->get_speed_xyz (object);
9424 }
9425
9426 /**
9427  * foo_igen_rocket123_set_speed_xyz: (skip)
9428  * @object: A #FooiGenRocket123.
9429  * @value: The value to set.
9430  *
9431  * Sets the <link linkend="gdbus-property-com-acme-Rocket.Speed">"Speed"</link> D-Bus property to @value.
9432  *
9433  * Since this D-Bus property is not writable, it is only meaningful to use this function on the service-side.
9434  */
9435 void
9436 foo_igen_rocket123_set_speed_xyz (FooiGenRocket123 *object, gdouble value)
9437 {
9438   g_object_set (G_OBJECT (object), "speed-xyz", value, NULL);
9439 }
9440
9441 /**
9442  * foo_igen_rocket123_get_direction: (skip)
9443  * @object: A #FooiGenRocket123.
9444  *
9445  * Gets the value of the <link linkend="gdbus-property-com-acme-Rocket.Direction">"Direction"</link> D-Bus property.
9446  *
9447  * Since this D-Bus property is readable, it is meaningful to use this function on both the client- and service-side.
9448  *
9449  * <warning>The returned value is only valid until the property changes so on the client-side it is only safe to use this function on the thread where @object was constructed. Use foo_igen_rocket123_dup_direction() if on another thread.</warning>
9450  *
9451  * Returns: (transfer none): The property value or %NULL if the property is not set. Do not free the returned value, it belongs to @object.
9452  */
9453 GVariant *
9454 foo_igen_rocket123_get_direction (FooiGenRocket123 *object)
9455 {
9456   return FOO_IGEN_ROCKET123_GET_IFACE (object)->get_direction (object);
9457 }
9458
9459 /**
9460  * foo_igen_rocket123_dup_direction: (skip)
9461  * @object: A #FooiGenRocket123.
9462  *
9463  * Gets a copy of the <link linkend="gdbus-property-com-acme-Rocket.Direction">"Direction"</link> D-Bus property.
9464  *
9465  * Since this D-Bus property is readable, it is meaningful to use this function on both the client- and service-side.
9466  *
9467  * Returns: (transfer full): The property value or %NULL if the property is not set. The returned value should be freed with g_variant_unref().
9468  */
9469 GVariant *
9470 foo_igen_rocket123_dup_direction (FooiGenRocket123 *object)
9471 {
9472   GVariant *value;
9473   g_object_get (G_OBJECT (object), "direction", &value, NULL);
9474   return value;
9475 }
9476
9477 /**
9478  * foo_igen_rocket123_set_direction: (skip)
9479  * @object: A #FooiGenRocket123.
9480  * @value: The value to set.
9481  *
9482  * Sets the <link linkend="gdbus-property-com-acme-Rocket.Direction">"Direction"</link> D-Bus property to @value.
9483  *
9484  * Since this D-Bus property is not writable, it is only meaningful to use this function on the service-side.
9485  */
9486 void
9487 foo_igen_rocket123_set_direction (FooiGenRocket123 *object, GVariant *value)
9488 {
9489   g_object_set (G_OBJECT (object), "direction", value, NULL);
9490 }
9491
9492 /**
9493  * foo_igen_rocket123_get_type_: (skip)
9494  * @object: A #FooiGenRocket123.
9495  *
9496  * Gets the value of the <link linkend="gdbus-property-com-acme-Rocket.Type">"Type"</link> D-Bus property.
9497  *
9498  * Since this D-Bus property is readable, it is meaningful to use this function on both the client- and service-side.
9499  *
9500  * <warning>The returned value is only valid until the property changes so on the client-side it is only safe to use this function on the thread where @object was constructed. Use foo_igen_rocket123_dup_type_() if on another thread.</warning>
9501  *
9502  * Returns: (transfer none): The property value or %NULL if the property is not set. Do not free the returned value, it belongs to @object.
9503  */
9504 const gchar *
9505 foo_igen_rocket123_get_type_ (FooiGenRocket123 *object)
9506 {
9507   return FOO_IGEN_ROCKET123_GET_IFACE (object)->get_type_ (object);
9508 }
9509
9510 /**
9511  * foo_igen_rocket123_dup_type_: (skip)
9512  * @object: A #FooiGenRocket123.
9513  *
9514  * Gets a copy of the <link linkend="gdbus-property-com-acme-Rocket.Type">"Type"</link> D-Bus property.
9515  *
9516  * Since this D-Bus property is readable, it is meaningful to use this function on both the client- and service-side.
9517  *
9518  * Returns: (transfer full): The property value or %NULL if the property is not set. The returned value should be freed with g_free().
9519  */
9520 gchar *
9521 foo_igen_rocket123_dup_type_ (FooiGenRocket123 *object)
9522 {
9523   gchar *value;
9524   g_object_get (G_OBJECT (object), "type-", &value, NULL);
9525   return value;
9526 }
9527
9528 /**
9529  * foo_igen_rocket123_set_type_: (skip)
9530  * @object: A #FooiGenRocket123.
9531  * @value: The value to set.
9532  *
9533  * Sets the <link linkend="gdbus-property-com-acme-Rocket.Type">"Type"</link> D-Bus property to @value.
9534  *
9535  * Since this D-Bus property is not writable, it is only meaningful to use this function on the service-side.
9536  */
9537 void
9538 foo_igen_rocket123_set_type_ (FooiGenRocket123 *object, const gchar *value)
9539 {
9540   g_object_set (G_OBJECT (object), "type-", value, NULL);
9541 }
9542
9543 /**
9544  * foo_igen_rocket123_emit_exploded_xyz:
9545  * @object: A #FooiGenRocket123.
9546  *
9547  * Emits the <link linkend="gdbus-signal-com-acme-Rocket.Exploded">"Exploded"</link> D-Bus signal.
9548  */
9549 void
9550 foo_igen_rocket123_emit_exploded_xyz (
9551     FooiGenRocket123 *object)
9552 {
9553   g_signal_emit_by_name (object, "exploded-xyz");
9554 }
9555
9556 /**
9557  * foo_igen_rocket123_call_ignite_xyz:
9558  * @proxy: A #FooiGenRocket123Proxy.
9559  * @cancellable: (allow-none): A #GCancellable or %NULL.
9560  * @callback: A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
9561  * @user_data: User data to pass to @callback.
9562  *
9563  * Asynchronously invokes the <link linkend="gdbus-method-com-acme-Rocket.Ignite">Ignite()</link> D-Bus method on @proxy.
9564  * When the operation is finished, @callback will be invoked in the <link linkend="g-main-context-push-thread-default">thread-default main loop</link> of the thread you are calling this method from.
9565  * You can then call foo_igen_rocket123_call_ignite_xyz_finish() to get the result of the operation.
9566  *
9567  * See foo_igen_rocket123_call_ignite_xyz_sync() for the synchronous, blocking version of this method.
9568  */
9569 void
9570 foo_igen_rocket123_call_ignite_xyz (
9571     FooiGenRocket123 *proxy,
9572     GCancellable *cancellable,
9573     GAsyncReadyCallback callback,
9574     gpointer user_data)
9575 {
9576   g_dbus_proxy_call (G_DBUS_PROXY (proxy),
9577     "Ignite",
9578     g_variant_new ("()"),
9579     G_DBUS_CALL_FLAGS_NONE,
9580     -1,
9581     cancellable,
9582     callback,
9583     user_data);
9584 }
9585
9586 /**
9587  * foo_igen_rocket123_call_ignite_xyz_finish:
9588  * @proxy: A #FooiGenRocket123Proxy.
9589  * @res: The #GAsyncResult obtained from the #GAsyncReadyCallback passed to foo_igen_rocket123_call_ignite_xyz().
9590  * @error: Return location for error or %NULL.
9591  *
9592  * Finishes an operation started with foo_igen_rocket123_call_ignite_xyz().
9593  *
9594  * Returns: (skip): %TRUE if the call succeded, %FALSE if @error is set.
9595  */
9596 gboolean
9597 foo_igen_rocket123_call_ignite_xyz_finish (
9598     FooiGenRocket123 *proxy,
9599     GAsyncResult *res,
9600     GError **error)
9601 {
9602   GVariant *_ret;
9603   _ret = g_dbus_proxy_call_finish (G_DBUS_PROXY (proxy), res, error);
9604   if (_ret == NULL)
9605     goto _out;
9606   g_variant_get (_ret,
9607                  "()");
9608   g_variant_unref (_ret);
9609 _out:
9610   return _ret != NULL;
9611 }
9612
9613 /**
9614  * foo_igen_rocket123_call_ignite_xyz_sync:
9615  * @proxy: A #FooiGenRocket123Proxy.
9616  * @cancellable: (allow-none): A #GCancellable or %NULL.
9617  * @error: Return location for error or %NULL.
9618  *
9619  * Synchronously invokes the <link linkend="gdbus-method-com-acme-Rocket.Ignite">Ignite()</link> D-Bus method on @proxy. The calling thread is blocked until a reply is received.
9620  *
9621  * See foo_igen_rocket123_call_ignite_xyz() for the asynchronous version of this method.
9622  *
9623  * Returns: (skip): %TRUE if the call succeded, %FALSE if @error is set.
9624  */
9625 gboolean
9626 foo_igen_rocket123_call_ignite_xyz_sync (
9627     FooiGenRocket123 *proxy,
9628     GCancellable *cancellable,
9629     GError **error)
9630 {
9631   GVariant *_ret;
9632   _ret = g_dbus_proxy_call_sync (G_DBUS_PROXY (proxy),
9633     "Ignite",
9634     g_variant_new ("()"),
9635     G_DBUS_CALL_FLAGS_NONE,
9636     -1,
9637     cancellable,
9638     error);
9639   if (_ret == NULL)
9640     goto _out;
9641   g_variant_get (_ret,
9642                  "()");
9643   g_variant_unref (_ret);
9644 _out:
9645   return _ret != NULL;
9646 }
9647
9648 /**
9649  * foo_igen_rocket123_complete_ignite_xyz:
9650  * @object: A #FooiGenRocket123.
9651  * @invocation: (transfer full): A #GDBusMethodInvocation.
9652  *
9653  * Helper function used in service implementations to finish handling invocations of the <link linkend="gdbus-method-com-acme-Rocket.Ignite">Ignite()</link> D-Bus method. If you instead want to finish handling an invocation by returning an error, use g_dbus_method_invocation_return_error() or similar.
9654  *
9655  * This method will free @invocation, you cannot use it afterwards.
9656  */
9657 void
9658 foo_igen_rocket123_complete_ignite_xyz (
9659     FooiGenRocket123 *object,
9660     GDBusMethodInvocation *invocation)
9661 {
9662   g_dbus_method_invocation_return_value (invocation,
9663     g_variant_new ("()"));
9664 }
9665
9666 /* ------------------------------------------------------------------------ */
9667
9668 /**
9669  * FooiGenRocket123Proxy:
9670  *
9671  * The #FooiGenRocket123Proxy structure contains only private data and should only be accessed using the provided API.
9672  */
9673
9674 /**
9675  * FooiGenRocket123ProxyClass:
9676  * @parent_class: The parent class.
9677  *
9678  * Class structure for #FooiGenRocket123Proxy.
9679  */
9680
9681 struct _FooiGenRocket123ProxyPrivate
9682 {
9683   GData *qdata;
9684 };
9685
9686 static void foo_igen_rocket123_proxy_iface_init (FooiGenRocket123Iface *iface);
9687
9688 G_DEFINE_TYPE_WITH_CODE (FooiGenRocket123Proxy, foo_igen_rocket123_proxy, G_TYPE_DBUS_PROXY,
9689                          G_IMPLEMENT_INTERFACE (FOO_IGEN_TYPE_ROCKET123, foo_igen_rocket123_proxy_iface_init));
9690
9691 static void
9692 foo_igen_rocket123_proxy_finalize (GObject *object)
9693 {
9694   FooiGenRocket123Proxy *proxy = FOO_IGEN_ROCKET123_PROXY (object);
9695   g_datalist_clear (&proxy->priv->qdata);
9696   G_OBJECT_CLASS (foo_igen_rocket123_proxy_parent_class)->finalize (object);
9697 }
9698
9699 static void
9700 foo_igen_rocket123_proxy_get_property (GObject      *object,
9701   guint         prop_id,
9702   GValue       *value,
9703   GParamSpec   *pspec)
9704 {
9705   const _ExtendedGDBusPropertyInfo *info;
9706   GVariant *variant;
9707   g_assert (prop_id != 0 && prop_id - 1 < 3);
9708   info = _foo_igen_rocket123_property_info_pointers[prop_id - 1];
9709   variant = g_dbus_proxy_get_cached_property (G_DBUS_PROXY (object), info->parent_struct.name);
9710   if (info->use_gvariant)
9711     {
9712       g_value_set_variant (value, variant);
9713     }
9714   else
9715     {
9716       if (variant != NULL)
9717         g_dbus_gvariant_to_gvalue (variant, value);
9718     }
9719   if (variant != NULL)
9720     g_variant_unref (variant);
9721 }
9722
9723 static void
9724 foo_igen_rocket123_proxy_set_property_cb (GDBusProxy *proxy,
9725   GAsyncResult *res,
9726   gpointer      user_data)
9727 {
9728   const _ExtendedGDBusPropertyInfo *info = user_data;
9729   GError *error;
9730   error = NULL;
9731   if (!g_dbus_proxy_call_finish (proxy, res, &error))
9732     {
9733       g_warning ("Error setting property `%s' on interface com.acme.Rocket: %s (%s, %d)",
9734                  info->parent_struct.name, 
9735                  error->message, g_quark_to_string (error->domain), error->code);
9736       g_error_free (error);
9737     }
9738 }
9739
9740 static void
9741 foo_igen_rocket123_proxy_set_property (GObject      *object,
9742   guint         prop_id,
9743   const GValue *value,
9744   GParamSpec   *pspec)
9745 {
9746   const _ExtendedGDBusPropertyInfo *info;
9747   GVariant *variant;
9748   g_assert (prop_id != 0 && prop_id - 1 < 3);
9749   info = _foo_igen_rocket123_property_info_pointers[prop_id - 1];
9750   variant = g_dbus_gvalue_to_gvariant (value, G_VARIANT_TYPE (info->parent_struct.signature));
9751   g_dbus_proxy_call (G_DBUS_PROXY (object),
9752     "org.freedesktop.DBus.Properties.Set",
9753     g_variant_new ("(ssv)", "com.acme.Rocket", info->parent_struct.name, variant),
9754     G_DBUS_CALL_FLAGS_NONE,
9755     -1,
9756     NULL, (GAsyncReadyCallback) foo_igen_rocket123_proxy_set_property_cb, (gpointer) info);
9757   g_variant_unref (variant);
9758 }
9759
9760 static void
9761 foo_igen_rocket123_proxy_g_signal (GDBusProxy *proxy,
9762   const gchar *sender_name,
9763   const gchar *signal_name,
9764   GVariant *parameters)
9765 {
9766   _ExtendedGDBusSignalInfo *info;
9767   GVariantIter iter;
9768   GVariant *child;
9769   GValue *paramv;
9770   guint num_params;
9771   guint n;
9772   guint signal_id;
9773   info = (_ExtendedGDBusSignalInfo *) g_dbus_interface_info_lookup_signal ((GDBusInterfaceInfo *) &_foo_igen_rocket123_interface_info, signal_name);
9774   if (info == NULL)
9775     return;
9776   num_params = g_variant_n_children (parameters);
9777   paramv = g_new0 (GValue, num_params + 1);
9778   g_value_init (&paramv[0], FOO_IGEN_TYPE_ROCKET123);
9779   g_value_set_object (&paramv[0], proxy);
9780   g_variant_iter_init (&iter, parameters);
9781   n = 1;
9782   while ((child = g_variant_iter_next_value (&iter)) != NULL)
9783     {
9784       _ExtendedGDBusArgInfo *arg_info = (_ExtendedGDBusArgInfo *) info->parent_struct.args[n - 1];
9785       if (arg_info->use_gvariant)
9786         {
9787           g_value_init (&paramv[n], G_TYPE_VARIANT);
9788           g_value_set_variant (&paramv[n], child);
9789           n++;
9790         }
9791       else
9792         g_dbus_gvariant_to_gvalue (child, &paramv[n++]);
9793       g_variant_unref (child);
9794     }
9795   signal_id = g_signal_lookup (info->signal_name, FOO_IGEN_TYPE_ROCKET123);
9796   g_signal_emitv (paramv, signal_id, 0, NULL);
9797   for (n = 0; n < num_params + 1; n++)
9798     g_value_unset (&paramv[n]);
9799   g_free (paramv);
9800 }
9801
9802 static void
9803 foo_igen_rocket123_proxy_g_properties_changed (GDBusProxy *_proxy,
9804   GVariant *changed_properties,
9805   const gchar *const *invalidated_properties)
9806 {
9807   FooiGenRocket123Proxy *proxy = FOO_IGEN_ROCKET123_PROXY (_proxy);
9808   guint n;
9809   const gchar *key;
9810   GVariantIter *iter;
9811   _ExtendedGDBusPropertyInfo *info;
9812   g_variant_get (changed_properties, "a{sv}", &iter);
9813   while (g_variant_iter_next (iter, "{&sv}", &key, NULL))
9814     {
9815       info = (_ExtendedGDBusPropertyInfo *) g_dbus_interface_info_lookup_property ((GDBusInterfaceInfo *) &_foo_igen_rocket123_interface_info, key);
9816       g_datalist_remove_data (&proxy->priv->qdata, key);
9817       if (info != NULL)
9818         g_object_notify (G_OBJECT (proxy), info->hyphen_name);
9819     }
9820   g_variant_iter_free (iter);
9821   for (n = 0; invalidated_properties[n] != NULL; n++)
9822     {
9823       info = (_ExtendedGDBusPropertyInfo *) g_dbus_interface_info_lookup_property ((GDBusInterfaceInfo *) &_foo_igen_rocket123_interface_info, invalidated_properties[n]);
9824       g_datalist_remove_data (&proxy->priv->qdata, invalidated_properties[n]);
9825       if (info != NULL)
9826         g_object_notify (G_OBJECT (proxy), info->hyphen_name);
9827     }
9828 }
9829
9830 static gdouble 
9831 foo_igen_rocket123_proxy_get_speed_xyz (FooiGenRocket123 *object)
9832 {
9833   FooiGenRocket123Proxy *proxy = FOO_IGEN_ROCKET123_PROXY (object);
9834   GVariant *variant;
9835   gdouble value = 0;
9836   variant = g_dbus_proxy_get_cached_property (G_DBUS_PROXY (proxy), "Speed");
9837   if (variant != NULL)
9838     {
9839       value = g_variant_get_double (variant);
9840       g_variant_unref (variant);
9841     }
9842   return value;
9843 }
9844
9845 static GVariant *
9846 foo_igen_rocket123_proxy_get_direction (FooiGenRocket123 *object)
9847 {
9848   FooiGenRocket123Proxy *proxy = FOO_IGEN_ROCKET123_PROXY (object);
9849   GVariant *variant;
9850   GVariant *value = NULL;
9851   variant = g_dbus_proxy_get_cached_property (G_DBUS_PROXY (proxy), "Direction");
9852   value = variant;
9853   if (variant != NULL)
9854     g_variant_unref (variant);
9855   return value;
9856 }
9857
9858 static const gchar *
9859 foo_igen_rocket123_proxy_get_type_ (FooiGenRocket123 *object)
9860 {
9861   FooiGenRocket123Proxy *proxy = FOO_IGEN_ROCKET123_PROXY (object);
9862   GVariant *variant;
9863   const gchar *value = NULL;
9864   variant = g_dbus_proxy_get_cached_property (G_DBUS_PROXY (proxy), "Type");
9865   if (variant != NULL)
9866     {
9867       value = g_variant_get_string (variant, NULL);
9868       g_variant_unref (variant);
9869     }
9870   return value;
9871 }
9872
9873 static void
9874 foo_igen_rocket123_proxy_init (FooiGenRocket123Proxy *proxy)
9875 {
9876   proxy->priv = G_TYPE_INSTANCE_GET_PRIVATE (proxy, FOO_IGEN_TYPE_ROCKET123_PROXY, FooiGenRocket123ProxyPrivate);
9877   g_dbus_proxy_set_interface_info (G_DBUS_PROXY (proxy), foo_igen_rocket123_interface_info ());
9878 }
9879
9880 static void
9881 foo_igen_rocket123_proxy_class_init (FooiGenRocket123ProxyClass *klass)
9882 {
9883   GObjectClass *gobject_class;
9884   GDBusProxyClass *proxy_class;
9885
9886   g_type_class_add_private (klass, sizeof (FooiGenRocket123ProxyPrivate));
9887
9888   gobject_class = G_OBJECT_CLASS (klass);
9889   gobject_class->finalize     = foo_igen_rocket123_proxy_finalize;
9890   gobject_class->get_property = foo_igen_rocket123_proxy_get_property;
9891   gobject_class->set_property = foo_igen_rocket123_proxy_set_property;
9892
9893   proxy_class = G_DBUS_PROXY_CLASS (klass);
9894   proxy_class->g_signal = foo_igen_rocket123_proxy_g_signal;
9895   proxy_class->g_properties_changed = foo_igen_rocket123_proxy_g_properties_changed;
9896
9897
9898   foo_igen_rocket123_override_properties (gobject_class, 1);
9899 }
9900
9901 static void
9902 foo_igen_rocket123_proxy_iface_init (FooiGenRocket123Iface *iface)
9903 {
9904   iface->get_speed_xyz = foo_igen_rocket123_proxy_get_speed_xyz;
9905   iface->get_direction = foo_igen_rocket123_proxy_get_direction;
9906   iface->get_type_ = foo_igen_rocket123_proxy_get_type_;
9907 }
9908
9909 /**
9910  * foo_igen_rocket123_proxy_new:
9911  * @connection: A #GDBusConnection.
9912  * @flags: Flags from the #GDBusProxyFlags enumeration.
9913  * @name: (allow-none): A bus name (well-known or unique) or %NULL if @connection is not a message bus connection.
9914  * @object_path: An object path.
9915  * @cancellable: (allow-none): A #GCancellable or %NULL.
9916  * @callback: A #GAsyncReadyCallback to call when the request is satisfied.
9917  * @user_data: User data to pass to @callback.
9918  *
9919  * Asynchronously creates a proxy for the D-Bus interface <link linkend="gdbus-interface-com-acme-Rocket.top_of_page">com.acme.Rocket</link>. See g_dbus_proxy_new() for more details.
9920  *
9921  * When the operation is finished, @callback will be invoked in the <link linkend="g-main-context-push-thread-default">thread-default main loop</link> of the thread you are calling this method from.
9922  * You can then call foo_igen_rocket123_proxy_new_finish() to get the result of the operation.
9923  *
9924  * See foo_igen_rocket123_proxy_new_sync() for the synchronous, blocking version of this constructor.
9925  */
9926 void
9927 foo_igen_rocket123_proxy_new (
9928     GDBusConnection     *connection,
9929     GDBusProxyFlags      flags,
9930     const gchar         *name,
9931     const gchar         *object_path,
9932     GCancellable        *cancellable,
9933     GAsyncReadyCallback  callback,
9934     gpointer             user_data)
9935 {
9936   g_async_initable_new_async (FOO_IGEN_TYPE_ROCKET123_PROXY, G_PRIORITY_DEFAULT, cancellable, callback, user_data, "g-flags", flags, "g-name", name, "g-connection", connection, "g-object-path", object_path, "g-interface-name", "com.acme.Rocket", NULL);
9937 }
9938
9939 /**
9940  * foo_igen_rocket123_proxy_new_finish:
9941  * @res: The #GAsyncResult obtained from the #GAsyncReadyCallback passed to foo_igen_rocket123_proxy_new().
9942  * @error: Return location for error or %NULL
9943  *
9944  * Finishes an operation started with foo_igen_rocket123_proxy_new().
9945  *
9946  * Returns: (transfer full) (type FooiGenRocket123Proxy): The constructed proxy object or %NULL if @error is set.
9947  */
9948 FooiGenRocket123 *
9949 foo_igen_rocket123_proxy_new_finish (
9950     GAsyncResult        *res,
9951     GError             **error)
9952 {
9953   GObject *ret;
9954   GObject *source_object;
9955   source_object = g_async_result_get_source_object (res);
9956   ret = g_async_initable_new_finish (G_ASYNC_INITABLE (source_object), res, error);
9957   g_object_unref (source_object);
9958   if (ret != NULL)
9959     return FOO_IGEN_ROCKET123 (ret);
9960   else
9961     return NULL;
9962 }
9963
9964 /**
9965  * foo_igen_rocket123_proxy_new_sync:
9966  * @connection: A #GDBusConnection.
9967  * @flags: Flags from the #GDBusProxyFlags enumeration.
9968  * @name: (allow-none): A bus name (well-known or unique) or %NULL if @connection is not a message bus connection.
9969  * @object_path: An object path.
9970  * @cancellable: (allow-none): A #GCancellable or %NULL.
9971  * @error: Return location for error or %NULL
9972  *
9973  * Synchronously creates a proxy for the D-Bus interface <link linkend="gdbus-interface-com-acme-Rocket.top_of_page">com.acme.Rocket</link>. See g_dbus_proxy_new_sync() for more details.
9974  *
9975  * The calling thread is blocked until a reply is received.
9976  *
9977  * See foo_igen_rocket123_proxy_new() for the asynchronous version of this constructor.
9978  *
9979  * Returns: (transfer full) (type FooiGenRocket123Proxy): The constructed proxy object or %NULL if @error is set.
9980  */
9981 FooiGenRocket123 *
9982 foo_igen_rocket123_proxy_new_sync (
9983     GDBusConnection     *connection,
9984     GDBusProxyFlags      flags,
9985     const gchar         *name,
9986     const gchar         *object_path,
9987     GCancellable        *cancellable,
9988     GError             **error)
9989 {
9990   GInitable *ret;
9991   ret = g_initable_new (FOO_IGEN_TYPE_ROCKET123_PROXY, cancellable, error, "g-flags", flags, "g-name", name, "g-connection", connection, "g-object-path", object_path, "g-interface-name", "com.acme.Rocket", NULL);
9992   if (ret != NULL)
9993     return FOO_IGEN_ROCKET123 (ret);
9994   else
9995     return NULL;
9996 }
9997
9998
9999 /**
10000  * foo_igen_rocket123_proxy_new_for_bus:
10001  * @bus_type: A #GBusType.
10002  * @flags: Flags from the #GDBusProxyFlags enumeration.
10003  * @name: A bus name (well-known or unique).
10004  * @object_path: An object path.
10005  * @cancellable: (allow-none): A #GCancellable or %NULL.
10006  * @callback: A #GAsyncReadyCallback to call when the request is satisfied.
10007  * @user_data: User data to pass to @callback.
10008  *
10009  * Like foo_igen_rocket123_proxy_new() but takes a #GBusType instead of a #GDBusConnection.
10010  *
10011  * When the operation is finished, @callback will be invoked in the <link linkend="g-main-context-push-thread-default">thread-default main loop</link> of the thread you are calling this method from.
10012  * You can then call foo_igen_rocket123_proxy_new_for_bus_finish() to get the result of the operation.
10013  *
10014  * See foo_igen_rocket123_proxy_new_for_bus_sync() for the synchronous, blocking version of this constructor.
10015  */
10016 void
10017 foo_igen_rocket123_proxy_new_for_bus (
10018     GBusType             bus_type,
10019     GDBusProxyFlags      flags,
10020     const gchar         *name,
10021     const gchar         *object_path,
10022     GCancellable        *cancellable,
10023     GAsyncReadyCallback  callback,
10024     gpointer             user_data)
10025 {
10026   g_async_initable_new_async (FOO_IGEN_TYPE_ROCKET123_PROXY, G_PRIORITY_DEFAULT, cancellable, callback, user_data, "g-flags", flags, "g-name", name, "g-bus-type", bus_type, "g-object-path", object_path, "g-interface-name", "com.acme.Rocket", NULL);
10027 }
10028
10029 /**
10030  * foo_igen_rocket123_proxy_new_for_bus_finish:
10031  * @res: The #GAsyncResult obtained from the #GAsyncReadyCallback passed to foo_igen_rocket123_proxy_new_for_bus().
10032  * @error: Return location for error or %NULL
10033  *
10034  * Finishes an operation started with foo_igen_rocket123_proxy_new_for_bus().
10035  *
10036  * Returns: (transfer full) (type FooiGenRocket123Proxy): The constructed proxy object or %NULL if @error is set.
10037  */
10038 FooiGenRocket123 *
10039 foo_igen_rocket123_proxy_new_for_bus_finish (
10040     GAsyncResult        *res,
10041     GError             **error)
10042 {
10043   GObject *ret;
10044   GObject *source_object;
10045   source_object = g_async_result_get_source_object (res);
10046   ret = g_async_initable_new_finish (G_ASYNC_INITABLE (source_object), res, error);
10047   g_object_unref (source_object);
10048   if (ret != NULL)
10049     return FOO_IGEN_ROCKET123 (ret);
10050   else
10051     return NULL;
10052 }
10053
10054 /**
10055  * foo_igen_rocket123_proxy_new_for_bus_sync:
10056  * @bus_type: A #GBusType.
10057  * @flags: Flags from the #GDBusProxyFlags enumeration.
10058  * @name: A bus name (well-known or unique).
10059  * @object_path: An object path.
10060  * @cancellable: (allow-none): A #GCancellable or %NULL.
10061  * @error: Return location for error or %NULL
10062  *
10063  * Like foo_igen_rocket123_proxy_new_sync() but takes a #GBusType instead of a #GDBusConnection.
10064  *
10065  * The calling thread is blocked until a reply is received.
10066  *
10067  * See foo_igen_rocket123_proxy_new_for_bus() for the asynchronous version of this constructor.
10068  *
10069  * Returns: (transfer full) (type FooiGenRocket123Proxy): The constructed proxy object or %NULL if @error is set.
10070  */
10071 FooiGenRocket123 *
10072 foo_igen_rocket123_proxy_new_for_bus_sync (
10073     GBusType             bus_type,
10074     GDBusProxyFlags      flags,
10075     const gchar         *name,
10076     const gchar         *object_path,
10077     GCancellable        *cancellable,
10078     GError             **error)
10079 {
10080   GInitable *ret;
10081   ret = g_initable_new (FOO_IGEN_TYPE_ROCKET123_PROXY, cancellable, error, "g-flags", flags, "g-name", name, "g-bus-type", bus_type, "g-object-path", object_path, "g-interface-name", "com.acme.Rocket", NULL);
10082   if (ret != NULL)
10083     return FOO_IGEN_ROCKET123 (ret);
10084   else
10085     return NULL;
10086 }
10087
10088
10089 /* ------------------------------------------------------------------------ */
10090
10091 /**
10092  * FooiGenRocket123Skeleton:
10093  *
10094  * The #FooiGenRocket123Skeleton structure contains only private data and should only be accessed using the provided API.
10095  */
10096
10097 /**
10098  * FooiGenRocket123SkeletonClass:
10099  * @parent_class: The parent class.
10100  *
10101  * Class structure for #FooiGenRocket123Skeleton.
10102  */
10103
10104 struct _FooiGenRocket123SkeletonPrivate
10105 {
10106   GValue *properties;
10107   GList *changed_properties;
10108   GSource *changed_properties_idle_source;
10109   GMainContext *context;
10110   GMutex lock;
10111 };
10112
10113 static void
10114 _foo_igen_rocket123_skeleton_handle_method_call (
10115   GDBusConnection *connection,
10116   const gchar *sender,
10117   const gchar *object_path,
10118   const gchar *interface_name,
10119   const gchar *method_name,
10120   GVariant *parameters,
10121   GDBusMethodInvocation *invocation,
10122   gpointer user_data)
10123 {
10124   FooiGenRocket123Skeleton *skeleton = FOO_IGEN_ROCKET123_SKELETON (user_data);
10125   _ExtendedGDBusMethodInfo *info;
10126   GVariantIter iter;
10127   GVariant *child;
10128   GValue *paramv;
10129   guint num_params;
10130   guint num_extra;
10131   guint n;
10132   guint signal_id;
10133   GValue return_value = G_VALUE_INIT;
10134   info = (_ExtendedGDBusMethodInfo *) g_dbus_method_invocation_get_method_info (invocation);
10135   g_assert (info != NULL);
10136   num_params = g_variant_n_children (parameters);
10137   num_extra = info->pass_fdlist ? 3 : 2;  paramv = g_new0 (GValue, num_params + num_extra);
10138   n = 0;
10139   g_value_init (&paramv[n], FOO_IGEN_TYPE_ROCKET123);
10140   g_value_set_object (&paramv[n++], skeleton);
10141   g_value_init (&paramv[n], G_TYPE_DBUS_METHOD_INVOCATION);
10142   g_value_set_object (&paramv[n++], invocation);
10143   if (info->pass_fdlist)
10144     {
10145 #ifdef G_OS_UNIX
10146       g_value_init (&paramv[n], G_TYPE_UNIX_FD_LIST);
10147       g_value_set_object (&paramv[n++], g_dbus_message_get_unix_fd_list (g_dbus_method_invocation_get_message (invocation)));
10148 #else
10149       g_assert_not_reached ();
10150 #endif
10151     }
10152   g_variant_iter_init (&iter, parameters);
10153   while ((child = g_variant_iter_next_value (&iter)) != NULL)
10154     {
10155       _ExtendedGDBusArgInfo *arg_info = (_ExtendedGDBusArgInfo *) info->parent_struct.in_args[n - num_extra];
10156       if (arg_info->use_gvariant)
10157         {
10158           g_value_init (&paramv[n], G_TYPE_VARIANT);
10159           g_value_set_variant (&paramv[n], child);
10160           n++;
10161         }
10162       else
10163         g_dbus_gvariant_to_gvalue (child, &paramv[n++]);
10164       g_variant_unref (child);
10165     }
10166   signal_id = g_signal_lookup (info->signal_name, FOO_IGEN_TYPE_ROCKET123);
10167   g_value_init (&return_value, G_TYPE_BOOLEAN);
10168   g_signal_emitv (paramv, signal_id, 0, &return_value);
10169   if (!g_value_get_boolean (&return_value))
10170     g_dbus_method_invocation_return_error (invocation, G_DBUS_ERROR, G_DBUS_ERROR_UNKNOWN_METHOD, "Method %s is not implemented on interface %s", method_name, interface_name);
10171   g_value_unset (&return_value);
10172   for (n = 0; n < num_params + num_extra; n++)
10173     g_value_unset (&paramv[n]);
10174   g_free (paramv);
10175 }
10176
10177 static GVariant *
10178 _foo_igen_rocket123_skeleton_handle_get_property (
10179   GDBusConnection *connection,
10180   const gchar *sender,
10181   const gchar *object_path,
10182   const gchar *interface_name,
10183   const gchar *property_name,
10184   GError **error,
10185   gpointer user_data)
10186 {
10187   FooiGenRocket123Skeleton *skeleton = FOO_IGEN_ROCKET123_SKELETON (user_data);
10188   GValue value = G_VALUE_INIT;
10189   GParamSpec *pspec;
10190   _ExtendedGDBusPropertyInfo *info;
10191   GVariant *ret;
10192   ret = NULL;
10193   info = (_ExtendedGDBusPropertyInfo *) g_dbus_interface_info_lookup_property ((GDBusInterfaceInfo *) &_foo_igen_rocket123_interface_info, property_name);
10194   g_assert (info != NULL);
10195   pspec = g_object_class_find_property (G_OBJECT_GET_CLASS (skeleton), info->hyphen_name);
10196   if (pspec == NULL)
10197     {
10198       g_set_error (error, G_DBUS_ERROR, G_DBUS_ERROR_INVALID_ARGS, "No property with name %s", property_name);
10199     }
10200   else
10201     {
10202       g_value_init (&value, pspec->value_type);
10203       g_object_get_property (G_OBJECT (skeleton), info->hyphen_name, &value);
10204       ret = g_dbus_gvalue_to_gvariant (&value, G_VARIANT_TYPE (info->parent_struct.signature));
10205       g_value_unset (&value);
10206     }
10207   return ret;
10208 }
10209
10210 static gboolean
10211 _foo_igen_rocket123_skeleton_handle_set_property (
10212   GDBusConnection *connection,
10213   const gchar *sender,
10214   const gchar *object_path,
10215   const gchar *interface_name,
10216   const gchar *property_name,
10217   GVariant *variant,
10218   GError **error,
10219   gpointer user_data)
10220 {
10221   FooiGenRocket123Skeleton *skeleton = FOO_IGEN_ROCKET123_SKELETON (user_data);
10222   GValue value = G_VALUE_INIT;
10223   GParamSpec *pspec;
10224   _ExtendedGDBusPropertyInfo *info;
10225   gboolean ret;
10226   ret = FALSE;
10227   info = (_ExtendedGDBusPropertyInfo *) g_dbus_interface_info_lookup_property ((GDBusInterfaceInfo *) &_foo_igen_rocket123_interface_info, property_name);
10228   g_assert (info != NULL);
10229   pspec = g_object_class_find_property (G_OBJECT_GET_CLASS (skeleton), info->hyphen_name);
10230   if (pspec == NULL)
10231     {
10232       g_set_error (error, G_DBUS_ERROR, G_DBUS_ERROR_INVALID_ARGS, "No property with name %s", property_name);
10233     }
10234   else
10235     {
10236       if (info->use_gvariant)
10237         g_value_set_variant (&value, variant);
10238       else
10239         g_dbus_gvariant_to_gvalue (variant, &value);
10240       g_object_set_property (G_OBJECT (skeleton), info->hyphen_name, &value);
10241       g_value_unset (&value);
10242       ret = TRUE;
10243     }
10244   return ret;
10245 }
10246
10247 static const GDBusInterfaceVTable _foo_igen_rocket123_skeleton_vtable =
10248 {
10249   _foo_igen_rocket123_skeleton_handle_method_call,
10250   _foo_igen_rocket123_skeleton_handle_get_property,
10251   _foo_igen_rocket123_skeleton_handle_set_property
10252 };
10253
10254 static GDBusInterfaceInfo *
10255 foo_igen_rocket123_skeleton_dbus_interface_get_info (GDBusInterfaceSkeleton *skeleton)
10256 {
10257   return foo_igen_rocket123_interface_info ();
10258 }
10259
10260 static GDBusInterfaceVTable *
10261 foo_igen_rocket123_skeleton_dbus_interface_get_vtable (GDBusInterfaceSkeleton *skeleton)
10262 {
10263   return (GDBusInterfaceVTable *) &_foo_igen_rocket123_skeleton_vtable;
10264 }
10265
10266 static GVariant *
10267 foo_igen_rocket123_skeleton_dbus_interface_get_properties (GDBusInterfaceSkeleton *_skeleton)
10268 {
10269   FooiGenRocket123Skeleton *skeleton = FOO_IGEN_ROCKET123_SKELETON (_skeleton);
10270
10271   GVariantBuilder builder;
10272   guint n;
10273   g_variant_builder_init (&builder, G_VARIANT_TYPE ("a{sv}"));
10274   if (_foo_igen_rocket123_interface_info.parent_struct.properties == NULL)
10275     goto out;
10276   for (n = 0; _foo_igen_rocket123_interface_info.parent_struct.properties[n] != NULL; n++)
10277     {
10278       GDBusPropertyInfo *info = _foo_igen_rocket123_interface_info.parent_struct.properties[n];
10279       if (info->flags & G_DBUS_PROPERTY_INFO_FLAGS_READABLE)
10280         {
10281           GVariant *value;
10282           value = _foo_igen_rocket123_skeleton_handle_get_property (g_dbus_interface_skeleton_get_connection (G_DBUS_INTERFACE_SKELETON (skeleton)), NULL, g_dbus_interface_skeleton_get_object_path (G_DBUS_INTERFACE_SKELETON (skeleton)), "com.acme.Rocket", info->name, NULL, skeleton);
10283           if (value != NULL)
10284             {
10285               g_variant_take_ref (value);
10286               g_variant_builder_add (&builder, "{sv}", info->name, value);
10287               g_variant_unref (value);
10288             }
10289         }
10290     }
10291 out:
10292   return g_variant_builder_end (&builder);
10293 }
10294
10295 static gboolean _foo_igen_rocket123_emit_changed (gpointer user_data);
10296
10297 static void
10298 foo_igen_rocket123_skeleton_dbus_interface_flush (GDBusInterfaceSkeleton *_skeleton)
10299 {
10300   FooiGenRocket123Skeleton *skeleton = FOO_IGEN_ROCKET123_SKELETON (_skeleton);
10301   gboolean emit_changed = FALSE;
10302
10303   g_mutex_lock (&skeleton->priv->lock);
10304   if (skeleton->priv->changed_properties_idle_source != NULL)
10305     {
10306       g_source_destroy (skeleton->priv->changed_properties_idle_source);
10307       skeleton->priv->changed_properties_idle_source = NULL;
10308       emit_changed = TRUE;
10309     }
10310   g_mutex_unlock (&skeleton->priv->lock);
10311
10312   if (emit_changed)
10313     _foo_igen_rocket123_emit_changed (skeleton);
10314 }
10315
10316 static void
10317 _foo_igen_rocket123_on_signal_exploded_xyz (
10318     FooiGenRocket123 *object)
10319 {
10320   FooiGenRocket123Skeleton *skeleton = FOO_IGEN_ROCKET123_SKELETON (object);
10321
10322   GList      *connections, *l;
10323   GVariant   *signal_variant;
10324   connections = g_dbus_interface_skeleton_get_connections (G_DBUS_INTERFACE_SKELETON (skeleton));
10325
10326   signal_variant = g_variant_ref_sink (g_variant_new ("()"));
10327   for (l = connections; l != NULL; l = l->next)
10328     {
10329       GDBusConnection *connection = l->data;
10330       g_dbus_connection_emit_signal (connection,
10331         NULL, g_dbus_interface_skeleton_get_object_path (G_DBUS_INTERFACE_SKELETON (skeleton)), "com.acme.Rocket", "Exploded",
10332         signal_variant, NULL);
10333     }
10334   g_variant_unref (signal_variant);
10335   g_list_free_full (connections, g_object_unref);
10336 }
10337
10338 static void foo_igen_rocket123_skeleton_iface_init (FooiGenRocket123Iface *iface);
10339 G_DEFINE_TYPE_WITH_CODE (FooiGenRocket123Skeleton, foo_igen_rocket123_skeleton, G_TYPE_DBUS_INTERFACE_SKELETON,
10340                          G_IMPLEMENT_INTERFACE (FOO_IGEN_TYPE_ROCKET123, foo_igen_rocket123_skeleton_iface_init));
10341
10342 static void
10343 foo_igen_rocket123_skeleton_finalize (GObject *object)
10344 {
10345   FooiGenRocket123Skeleton *skeleton = FOO_IGEN_ROCKET123_SKELETON (object);
10346   guint n;
10347   for (n = 0; n < 3; n++)
10348     g_value_unset (&skeleton->priv->properties[n]);
10349   g_free (skeleton->priv->properties);
10350   g_list_free_full (skeleton->priv->changed_properties, (GDestroyNotify) _changed_property_free);
10351   if (skeleton->priv->changed_properties_idle_source != NULL)
10352     g_source_destroy (skeleton->priv->changed_properties_idle_source);
10353   g_main_context_unref (skeleton->priv->context);
10354   g_mutex_clear (&skeleton->priv->lock);
10355   G_OBJECT_CLASS (foo_igen_rocket123_skeleton_parent_class)->finalize (object);
10356 }
10357
10358 static void
10359 foo_igen_rocket123_skeleton_get_property (GObject      *object,
10360   guint         prop_id,
10361   GValue       *value,
10362   GParamSpec   *pspec)
10363 {
10364   FooiGenRocket123Skeleton *skeleton = FOO_IGEN_ROCKET123_SKELETON (object);
10365   g_assert (prop_id != 0 && prop_id - 1 < 3);
10366   g_mutex_lock (&skeleton->priv->lock);
10367   g_value_copy (&skeleton->priv->properties[prop_id - 1], value);
10368   g_mutex_unlock (&skeleton->priv->lock);
10369 }
10370
10371 static gboolean
10372 _foo_igen_rocket123_emit_changed (gpointer user_data)
10373 {
10374   FooiGenRocket123Skeleton *skeleton = FOO_IGEN_ROCKET123_SKELETON (user_data);
10375   GList *l;
10376   GVariantBuilder builder;
10377   GVariantBuilder invalidated_builder;
10378   guint num_changes;
10379
10380   g_mutex_lock (&skeleton->priv->lock);
10381   g_variant_builder_init (&builder, G_VARIANT_TYPE ("a{sv}"));
10382   g_variant_builder_init (&invalidated_builder, G_VARIANT_TYPE ("as"));
10383   for (l = skeleton->priv->changed_properties, num_changes = 0; l != NULL; l = l->next)
10384     {
10385       ChangedProperty *cp = l->data;
10386       GVariant *variant;
10387       const GValue *cur_value;
10388
10389       cur_value = &skeleton->priv->properties[cp->prop_id - 1];
10390       if (!_g_value_equal (cur_value, &cp->orig_value))
10391         {
10392           variant = g_dbus_gvalue_to_gvariant (cur_value, G_VARIANT_TYPE (cp->info->parent_struct.signature));
10393           g_variant_builder_add (&builder, "{sv}", cp->info->parent_struct.name, variant);
10394           g_variant_unref (variant);
10395           num_changes++;
10396         }
10397     }
10398   if (num_changes > 0)
10399     {
10400       GList *connections, *l;
10401       GVariant *signal_variant;
10402       signal_variant = g_variant_ref_sink (g_variant_new ("(sa{sv}as)", "com.acme.Rocket",
10403                                            &builder, &invalidated_builder));
10404       connections = g_dbus_interface_skeleton_get_connections (G_DBUS_INTERFACE_SKELETON (skeleton));
10405       for (l = connections; l != NULL; l = l->next)
10406         {
10407           GDBusConnection *connection = l->data;
10408
10409           g_dbus_connection_emit_signal (connection,
10410                                          NULL, g_dbus_interface_skeleton_get_object_path (G_DBUS_INTERFACE_SKELETON (skeleton)),
10411                                          "org.freedesktop.DBus.Properties",
10412                                          "PropertiesChanged",
10413                                          signal_variant,
10414                                          NULL);
10415         }
10416       g_variant_unref (signal_variant);
10417       g_list_free_full (connections, g_object_unref);
10418     }
10419   else
10420     {
10421       g_variant_builder_clear (&builder);
10422       g_variant_builder_clear (&invalidated_builder);
10423     }
10424   g_list_free_full (skeleton->priv->changed_properties, (GDestroyNotify) _changed_property_free);
10425   skeleton->priv->changed_properties = NULL;
10426   skeleton->priv->changed_properties_idle_source = NULL;
10427   g_mutex_unlock (&skeleton->priv->lock);
10428   return FALSE;
10429 }
10430
10431 static void
10432 _foo_igen_rocket123_schedule_emit_changed (FooiGenRocket123Skeleton *skeleton, const _ExtendedGDBusPropertyInfo *info, guint prop_id, const GValue *orig_value)
10433 {
10434   ChangedProperty *cp;
10435   GList *l;
10436   cp = NULL;
10437   for (l = skeleton->priv->changed_properties; l != NULL; l = l->next)
10438     {
10439       ChangedProperty *i_cp = l->data;
10440       if (i_cp->info == info)
10441         {
10442           cp = i_cp;
10443           break;
10444         }
10445     }
10446   if (cp == NULL)
10447     {
10448       cp = g_new0 (ChangedProperty, 1);
10449       cp->prop_id = prop_id;
10450       cp->info = info;
10451       skeleton->priv->changed_properties = g_list_prepend (skeleton->priv->changed_properties, cp);
10452       g_value_init (&cp->orig_value, G_VALUE_TYPE (orig_value));
10453       g_value_copy (orig_value, &cp->orig_value);
10454     }
10455 }
10456
10457 static void
10458 foo_igen_rocket123_skeleton_notify (GObject      *object,
10459   GParamSpec *pspec)
10460 {
10461   FooiGenRocket123Skeleton *skeleton = FOO_IGEN_ROCKET123_SKELETON (object);
10462   g_mutex_lock (&skeleton->priv->lock);
10463   if (skeleton->priv->changed_properties != NULL &&
10464       skeleton->priv->changed_properties_idle_source == NULL)
10465     {
10466       skeleton->priv->changed_properties_idle_source = g_idle_source_new ();
10467       g_source_set_priority (skeleton->priv->changed_properties_idle_source, G_PRIORITY_DEFAULT);
10468       g_source_set_callback (skeleton->priv->changed_properties_idle_source, _foo_igen_rocket123_emit_changed, g_object_ref (skeleton), (GDestroyNotify) g_object_unref);
10469       g_source_attach (skeleton->priv->changed_properties_idle_source, skeleton->priv->context);
10470       g_source_unref (skeleton->priv->changed_properties_idle_source);
10471     }
10472   g_mutex_unlock (&skeleton->priv->lock);
10473 }
10474
10475 static void
10476 foo_igen_rocket123_skeleton_set_property (GObject      *object,
10477   guint         prop_id,
10478   const GValue *value,
10479   GParamSpec   *pspec)
10480 {
10481   FooiGenRocket123Skeleton *skeleton = FOO_IGEN_ROCKET123_SKELETON (object);
10482   g_assert (prop_id != 0 && prop_id - 1 < 3);
10483   g_mutex_lock (&skeleton->priv->lock);
10484   g_object_freeze_notify (object);
10485   if (!_g_value_equal (value, &skeleton->priv->properties[prop_id - 1]))
10486     {
10487       if (g_dbus_interface_skeleton_get_connection (G_DBUS_INTERFACE_SKELETON (skeleton)) != NULL)
10488         _foo_igen_rocket123_schedule_emit_changed (skeleton, _foo_igen_rocket123_property_info_pointers[prop_id - 1], prop_id, &skeleton->priv->properties[prop_id - 1]);
10489       g_value_copy (value, &skeleton->priv->properties[prop_id - 1]);
10490       g_object_notify_by_pspec (object, pspec);
10491     }
10492   g_mutex_unlock (&skeleton->priv->lock);
10493   g_object_thaw_notify (object);
10494 }
10495
10496 static void
10497 foo_igen_rocket123_skeleton_init (FooiGenRocket123Skeleton *skeleton)
10498 {
10499   skeleton->priv = G_TYPE_INSTANCE_GET_PRIVATE (skeleton, FOO_IGEN_TYPE_ROCKET123_SKELETON, FooiGenRocket123SkeletonPrivate);
10500   g_mutex_init (&skeleton->priv->lock);
10501   skeleton->priv->context = g_main_context_ref_thread_default ();
10502   skeleton->priv->properties = g_new0 (GValue, 3);
10503   g_value_init (&skeleton->priv->properties[0], G_TYPE_DOUBLE);
10504   g_value_init (&skeleton->priv->properties[1], G_TYPE_VARIANT);
10505   g_value_init (&skeleton->priv->properties[2], G_TYPE_STRING);
10506 }
10507
10508 static gdouble 
10509 foo_igen_rocket123_skeleton_get_speed_xyz (FooiGenRocket123 *object)
10510 {
10511   FooiGenRocket123Skeleton *skeleton = FOO_IGEN_ROCKET123_SKELETON (object);
10512   gdouble value;
10513   g_mutex_lock (&skeleton->priv->lock);
10514   value = g_value_get_double (&(skeleton->priv->properties[0]));
10515   g_mutex_unlock (&skeleton->priv->lock);
10516   return value;
10517 }
10518
10519 static GVariant *
10520 foo_igen_rocket123_skeleton_get_direction (FooiGenRocket123 *object)
10521 {
10522   FooiGenRocket123Skeleton *skeleton = FOO_IGEN_ROCKET123_SKELETON (object);
10523   GVariant *value;
10524   g_mutex_lock (&skeleton->priv->lock);
10525   value = g_value_get_variant (&(skeleton->priv->properties[1]));
10526   g_mutex_unlock (&skeleton->priv->lock);
10527   return value;
10528 }
10529
10530 static const gchar *
10531 foo_igen_rocket123_skeleton_get_type_ (FooiGenRocket123 *object)
10532 {
10533   FooiGenRocket123Skeleton *skeleton = FOO_IGEN_ROCKET123_SKELETON (object);
10534   const gchar *value;
10535   g_mutex_lock (&skeleton->priv->lock);
10536   value = g_value_get_string (&(skeleton->priv->properties[2]));
10537   g_mutex_unlock (&skeleton->priv->lock);
10538   return value;
10539 }
10540
10541 static void
10542 foo_igen_rocket123_skeleton_class_init (FooiGenRocket123SkeletonClass *klass)
10543 {
10544   GObjectClass *gobject_class;
10545   GDBusInterfaceSkeletonClass *skeleton_class;
10546
10547   g_type_class_add_private (klass, sizeof (FooiGenRocket123SkeletonPrivate));
10548
10549   gobject_class = G_OBJECT_CLASS (klass);
10550   gobject_class->finalize = foo_igen_rocket123_skeleton_finalize;
10551   gobject_class->get_property = foo_igen_rocket123_skeleton_get_property;
10552   gobject_class->set_property = foo_igen_rocket123_skeleton_set_property;
10553   gobject_class->notify       = foo_igen_rocket123_skeleton_notify;
10554
10555
10556   foo_igen_rocket123_override_properties (gobject_class, 1);
10557
10558   skeleton_class = G_DBUS_INTERFACE_SKELETON_CLASS (klass);
10559   skeleton_class->get_info = foo_igen_rocket123_skeleton_dbus_interface_get_info;
10560   skeleton_class->get_properties = foo_igen_rocket123_skeleton_dbus_interface_get_properties;
10561   skeleton_class->flush = foo_igen_rocket123_skeleton_dbus_interface_flush;
10562   skeleton_class->get_vtable = foo_igen_rocket123_skeleton_dbus_interface_get_vtable;
10563 }
10564
10565 static void
10566 foo_igen_rocket123_skeleton_iface_init (FooiGenRocket123Iface *iface)
10567 {
10568   iface->exploded_xyz = _foo_igen_rocket123_on_signal_exploded_xyz;
10569   iface->get_speed_xyz = foo_igen_rocket123_skeleton_get_speed_xyz;
10570   iface->get_direction = foo_igen_rocket123_skeleton_get_direction;
10571   iface->get_type_ = foo_igen_rocket123_skeleton_get_type_;
10572 }
10573
10574 /**
10575  * foo_igen_rocket123_skeleton_new:
10576  *
10577  * Creates a skeleton object for the D-Bus interface <link linkend="gdbus-interface-com-acme-Rocket.top_of_page">com.acme.Rocket</link>.
10578  *
10579  * Returns: (transfer full) (type FooiGenRocket123Skeleton): The skeleton object.
10580  */
10581 FooiGenRocket123 *
10582 foo_igen_rocket123_skeleton_new (void)
10583 {
10584   return FOO_IGEN_ROCKET123 (g_object_new (FOO_IGEN_TYPE_ROCKET123_SKELETON, NULL));
10585 }
10586
10587 /* ------------------------------------------------------------------------
10588  * Code for interface org.project.Bat
10589  * ------------------------------------------------------------------------
10590  */
10591
10592 /**
10593  * SECTION:FooiGenBat
10594  * @title: FooiGenBat
10595  * @short_description: Generated C code for the org.project.Bat D-Bus interface
10596  *
10597  * This section contains code for working with the <link linkend="gdbus-interface-org-project-Bat.top_of_page">org.project.Bat</link> D-Bus interface in C.
10598  */
10599
10600 /* ---- Introspection data for org.project.Bat ---- */
10601
10602 static const _ExtendedGDBusArgInfo _foo_igen_bat_method_info_force_method_IN_ARG_force_in_i =
10603 {
10604   {
10605     -1,
10606     "force_in_i",
10607     "i",
10608     NULL
10609   },
10610   TRUE
10611 };
10612
10613 static const _ExtendedGDBusArgInfo _foo_igen_bat_method_info_force_method_IN_ARG_force_in_s =
10614 {
10615   {
10616     -1,
10617     "force_in_s",
10618     "s",
10619     NULL
10620   },
10621   TRUE
10622 };
10623
10624 static const _ExtendedGDBusArgInfo _foo_igen_bat_method_info_force_method_IN_ARG_force_in_ay =
10625 {
10626   {
10627     -1,
10628     "force_in_ay",
10629     "ay",
10630     NULL
10631   },
10632   TRUE
10633 };
10634
10635 static const _ExtendedGDBusArgInfo _foo_igen_bat_method_info_force_method_IN_ARG_force_in_struct =
10636 {
10637   {
10638     -1,
10639     "force_in_struct",
10640     "(i)",
10641     NULL
10642   },
10643   TRUE
10644 };
10645
10646 static const _ExtendedGDBusArgInfo * const _foo_igen_bat_method_info_force_method_IN_ARG_pointers[] =
10647 {
10648   &_foo_igen_bat_method_info_force_method_IN_ARG_force_in_i,
10649   &_foo_igen_bat_method_info_force_method_IN_ARG_force_in_s,
10650   &_foo_igen_bat_method_info_force_method_IN_ARG_force_in_ay,
10651   &_foo_igen_bat_method_info_force_method_IN_ARG_force_in_struct,
10652   NULL
10653 };
10654
10655 static const _ExtendedGDBusArgInfo _foo_igen_bat_method_info_force_method_OUT_ARG_force_out_i =
10656 {
10657   {
10658     -1,
10659     "force_out_i",
10660     "i",
10661     NULL
10662   },
10663   TRUE
10664 };
10665
10666 static const _ExtendedGDBusArgInfo _foo_igen_bat_method_info_force_method_OUT_ARG_force_out_s =
10667 {
10668   {
10669     -1,
10670     "force_out_s",
10671     "s",
10672     NULL
10673   },
10674   TRUE
10675 };
10676
10677 static const _ExtendedGDBusArgInfo _foo_igen_bat_method_info_force_method_OUT_ARG_force_out_ay =
10678 {
10679   {
10680     -1,
10681     "force_out_ay",
10682     "ay",
10683     NULL
10684   },
10685   TRUE
10686 };
10687
10688 static const _ExtendedGDBusArgInfo _foo_igen_bat_method_info_force_method_OUT_ARG_force_out_struct =
10689 {
10690   {
10691     -1,
10692     "force_out_struct",
10693     "(i)",
10694     NULL
10695   },
10696   TRUE
10697 };
10698
10699 static const _ExtendedGDBusArgInfo * const _foo_igen_bat_method_info_force_method_OUT_ARG_pointers[] =
10700 {
10701   &_foo_igen_bat_method_info_force_method_OUT_ARG_force_out_i,
10702   &_foo_igen_bat_method_info_force_method_OUT_ARG_force_out_s,
10703   &_foo_igen_bat_method_info_force_method_OUT_ARG_force_out_ay,
10704   &_foo_igen_bat_method_info_force_method_OUT_ARG_force_out_struct,
10705   NULL
10706 };
10707
10708 static const _ExtendedGDBusMethodInfo _foo_igen_bat_method_info_force_method =
10709 {
10710   {
10711     -1,
10712     "ForceMethod",
10713     (GDBusArgInfo **) &_foo_igen_bat_method_info_force_method_IN_ARG_pointers,
10714     (GDBusArgInfo **) &_foo_igen_bat_method_info_force_method_OUT_ARG_pointers,
10715     NULL
10716   },
10717   "handle-force-method",
10718   FALSE
10719 };
10720
10721 static const _ExtendedGDBusMethodInfo * const _foo_igen_bat_method_info_pointers[] =
10722 {
10723   &_foo_igen_bat_method_info_force_method,
10724   NULL
10725 };
10726
10727 static const _ExtendedGDBusArgInfo _foo_igen_bat_signal_info_force_signal_ARG_force_i =
10728 {
10729   {
10730     -1,
10731     "force_i",
10732     "i",
10733     NULL
10734   },
10735   TRUE
10736 };
10737
10738 static const _ExtendedGDBusArgInfo _foo_igen_bat_signal_info_force_signal_ARG_force_s =
10739 {
10740   {
10741     -1,
10742     "force_s",
10743     "s",
10744     NULL
10745   },
10746   TRUE
10747 };
10748
10749 static const _ExtendedGDBusArgInfo _foo_igen_bat_signal_info_force_signal_ARG_force_ay =
10750 {
10751   {
10752     -1,
10753     "force_ay",
10754     "ay",
10755     NULL
10756   },
10757   TRUE
10758 };
10759
10760 static const _ExtendedGDBusArgInfo _foo_igen_bat_signal_info_force_signal_ARG_force_struct =
10761 {
10762   {
10763     -1,
10764     "force_struct",
10765     "(i)",
10766     NULL
10767   },
10768   TRUE
10769 };
10770
10771 static const _ExtendedGDBusArgInfo * const _foo_igen_bat_signal_info_force_signal_ARG_pointers[] =
10772 {
10773   &_foo_igen_bat_signal_info_force_signal_ARG_force_i,
10774   &_foo_igen_bat_signal_info_force_signal_ARG_force_s,
10775   &_foo_igen_bat_signal_info_force_signal_ARG_force_ay,
10776   &_foo_igen_bat_signal_info_force_signal_ARG_force_struct,
10777   NULL
10778 };
10779
10780 static const _ExtendedGDBusSignalInfo _foo_igen_bat_signal_info_force_signal =
10781 {
10782   {
10783     -1,
10784     "ForceSignal",
10785     (GDBusArgInfo **) &_foo_igen_bat_signal_info_force_signal_ARG_pointers,
10786     NULL
10787   },
10788   "force-signal"
10789 };
10790
10791 static const _ExtendedGDBusSignalInfo * const _foo_igen_bat_signal_info_pointers[] =
10792 {
10793   &_foo_igen_bat_signal_info_force_signal,
10794   NULL
10795 };
10796
10797 static const _ExtendedGDBusPropertyInfo _foo_igen_bat_property_info_force_i =
10798 {
10799   {
10800     -1,
10801     "force_i",
10802     "i",
10803     G_DBUS_PROPERTY_INFO_FLAGS_READABLE | G_DBUS_PROPERTY_INFO_FLAGS_WRITABLE,
10804     NULL
10805   },
10806   "force-i",
10807   TRUE
10808 };
10809
10810 static const _ExtendedGDBusPropertyInfo _foo_igen_bat_property_info_force_s =
10811 {
10812   {
10813     -1,
10814     "force_s",
10815     "s",
10816     G_DBUS_PROPERTY_INFO_FLAGS_READABLE | G_DBUS_PROPERTY_INFO_FLAGS_WRITABLE,
10817     NULL
10818   },
10819   "force-s",
10820   TRUE
10821 };
10822
10823 static const _ExtendedGDBusPropertyInfo _foo_igen_bat_property_info_force_ay =
10824 {
10825   {
10826     -1,
10827     "force_ay",
10828     "ay",
10829     G_DBUS_PROPERTY_INFO_FLAGS_READABLE | G_DBUS_PROPERTY_INFO_FLAGS_WRITABLE,
10830     NULL
10831   },
10832   "force-ay",
10833   TRUE
10834 };
10835
10836 static const _ExtendedGDBusPropertyInfo _foo_igen_bat_property_info_force_struct =
10837 {
10838   {
10839     -1,
10840     "force_struct",
10841     "(i)",
10842     G_DBUS_PROPERTY_INFO_FLAGS_READABLE | G_DBUS_PROPERTY_INFO_FLAGS_WRITABLE,
10843     NULL
10844   },
10845   "force-struct",
10846   TRUE
10847 };
10848
10849 static const _ExtendedGDBusPropertyInfo * const _foo_igen_bat_property_info_pointers[] =
10850 {
10851   &_foo_igen_bat_property_info_force_i,
10852   &_foo_igen_bat_property_info_force_s,
10853   &_foo_igen_bat_property_info_force_ay,
10854   &_foo_igen_bat_property_info_force_struct,
10855   NULL
10856 };
10857
10858 static const _ExtendedGDBusInterfaceInfo _foo_igen_bat_interface_info =
10859 {
10860   {
10861     -1,
10862     "org.project.Bat",
10863     (GDBusMethodInfo **) &_foo_igen_bat_method_info_pointers,
10864     (GDBusSignalInfo **) &_foo_igen_bat_signal_info_pointers,
10865     (GDBusPropertyInfo **) &_foo_igen_bat_property_info_pointers,
10866     NULL
10867   },
10868   "bat",
10869 };
10870
10871
10872 /**
10873  * foo_igen_bat_interface_info:
10874  *
10875  * Gets a machine-readable description of the <link linkend="gdbus-interface-org-project-Bat.top_of_page">org.project.Bat</link> D-Bus interface.
10876  *
10877  * Returns: (transfer none): A #GDBusInterfaceInfo. Do not free.
10878  */
10879 GDBusInterfaceInfo *
10880 foo_igen_bat_interface_info (void)
10881 {
10882   return (GDBusInterfaceInfo *) &_foo_igen_bat_interface_info;
10883 }
10884
10885 /**
10886  * foo_igen_bat_override_properties:
10887  * @klass: The class structure for a #GObject<!-- -->-derived class.
10888  * @property_id_begin: The property id to assign to the first overridden property.
10889  *
10890  * Overrides all #GObject properties in the #FooiGenBat interface for a concrete class.
10891  * The properties are overridden in the order they are defined.
10892  *
10893  * Returns: The last property id.
10894  */
10895 guint
10896 foo_igen_bat_override_properties (GObjectClass *klass, guint property_id_begin)
10897 {
10898   g_object_class_override_property (klass, property_id_begin++, "force-i");
10899   g_object_class_override_property (klass, property_id_begin++, "force-s");
10900   g_object_class_override_property (klass, property_id_begin++, "force-ay");
10901   g_object_class_override_property (klass, property_id_begin++, "force-struct");
10902   return property_id_begin - 1;
10903 }
10904
10905
10906
10907 /**
10908  * FooiGenBat:
10909  *
10910  * Abstract interface type for the D-Bus interface <link linkend="gdbus-interface-org-project-Bat.top_of_page">org.project.Bat</link>.
10911  */
10912
10913 /**
10914  * FooiGenBatIface:
10915  * @parent_iface: The parent interface.
10916  * @handle_force_method: Handler for the #FooiGenBat::handle-force-method signal.
10917  * @get_force_ay: Getter for the #FooiGenBat:force-ay property.
10918  * @get_force_i: Getter for the #FooiGenBat:force-i property.
10919  * @get_force_s: Getter for the #FooiGenBat:force-s property.
10920  * @get_force_struct: Getter for the #FooiGenBat:force-struct property.
10921  * @force_signal: Handler for the #FooiGenBat::force-signal signal.
10922  *
10923  * Virtual table for the D-Bus interface <link linkend="gdbus-interface-org-project-Bat.top_of_page">org.project.Bat</link>.
10924  */
10925
10926 static void
10927 foo_igen_bat_default_init (FooiGenBatIface *iface)
10928 {
10929   /* GObject signals for incoming D-Bus method calls: */
10930   /**
10931    * FooiGenBat::handle-force-method:
10932    * @object: A #FooiGenBat.
10933    * @invocation: A #GDBusMethodInvocation.
10934    * @arg_force_in_i: Argument passed by remote caller.
10935    * @arg_force_in_s: Argument passed by remote caller.
10936    * @arg_force_in_ay: Argument passed by remote caller.
10937    * @arg_force_in_struct: Argument passed by remote caller.
10938    *
10939    * Signal emitted when a remote caller is invoking the <link linkend="gdbus-method-org-project-Bat.ForceMethod">ForceMethod()</link> D-Bus method.
10940    *
10941    * If a signal handler returns %TRUE, it means the signal handler will handle the invocation (e.g. take a reference to @invocation and eventually call foo_igen_bat_complete_force_method() or e.g. g_dbus_method_invocation_return_error() on it) and no order signal handlers will run. If no signal handler handles the invocation, the %G_DBUS_ERROR_UNKNOWN_METHOD error is returned.
10942    *
10943    * Returns: %TRUE if the invocation was handled, %FALSE to let other signal handlers run.
10944    */
10945   g_signal_new ("handle-force-method",
10946     G_TYPE_FROM_INTERFACE (iface),
10947     G_SIGNAL_RUN_LAST,
10948     G_STRUCT_OFFSET (FooiGenBatIface, handle_force_method),
10949     g_signal_accumulator_true_handled,
10950     NULL,
10951     g_cclosure_marshal_generic,
10952     G_TYPE_BOOLEAN,
10953     5,
10954     G_TYPE_DBUS_METHOD_INVOCATION, G_TYPE_VARIANT, G_TYPE_VARIANT, G_TYPE_VARIANT, G_TYPE_VARIANT);
10955
10956   /* GObject signals for received D-Bus signals: */
10957   /**
10958    * FooiGenBat::force-signal:
10959    * @object: A #FooiGenBat.
10960    * @arg_force_i: Argument.
10961    * @arg_force_s: Argument.
10962    * @arg_force_ay: Argument.
10963    * @arg_force_struct: Argument.
10964    *
10965    * On the client-side, this signal is emitted whenever the D-Bus signal <link linkend="gdbus-signal-org-project-Bat.ForceSignal">"ForceSignal"</link> is received.
10966    *
10967    * On the service-side, this signal can be used with e.g. g_signal_emit_by_name() to make the object emit the D-Bus signal.
10968    */
10969   g_signal_new ("force-signal",
10970     G_TYPE_FROM_INTERFACE (iface),
10971     G_SIGNAL_RUN_LAST,
10972     G_STRUCT_OFFSET (FooiGenBatIface, force_signal),
10973     NULL,
10974     NULL,
10975     g_cclosure_marshal_generic,
10976     G_TYPE_NONE,
10977     4, G_TYPE_VARIANT, G_TYPE_VARIANT, G_TYPE_VARIANT, G_TYPE_VARIANT);
10978
10979   /* GObject properties for D-Bus properties: */
10980   /**
10981    * FooiGenBat:force-i:
10982    *
10983    * Represents the D-Bus property <link linkend="gdbus-property-org-project-Bat.force_i">"force_i"</link>.
10984    *
10985    * Since the D-Bus property for this #GObject property is both readable and writable, it is meaningful to both read from it and write to it on both the service- and client-side.
10986    */
10987   g_object_interface_install_property (iface,
10988     g_param_spec_variant ("force-i", "force_i", "force_i", G_VARIANT_TYPE ("i"), NULL, G_PARAM_READWRITE | G_PARAM_STATIC_STRINGS));
10989   /**
10990    * FooiGenBat:force-s:
10991    *
10992    * Represents the D-Bus property <link linkend="gdbus-property-org-project-Bat.force_s">"force_s"</link>.
10993    *
10994    * Since the D-Bus property for this #GObject property is both readable and writable, it is meaningful to both read from it and write to it on both the service- and client-side.
10995    */
10996   g_object_interface_install_property (iface,
10997     g_param_spec_variant ("force-s", "force_s", "force_s", G_VARIANT_TYPE ("s"), NULL, G_PARAM_READWRITE | G_PARAM_STATIC_STRINGS));
10998   /**
10999    * FooiGenBat:force-ay:
11000    *
11001    * Represents the D-Bus property <link linkend="gdbus-property-org-project-Bat.force_ay">"force_ay"</link>.
11002    *
11003    * Since the D-Bus property for this #GObject property is both readable and writable, it is meaningful to both read from it and write to it on both the service- and client-side.
11004    */
11005   g_object_interface_install_property (iface,
11006     g_param_spec_variant ("force-ay", "force_ay", "force_ay", G_VARIANT_TYPE ("ay"), NULL, G_PARAM_READWRITE | G_PARAM_STATIC_STRINGS));
11007   /**
11008    * FooiGenBat:force-struct:
11009    *
11010    * Represents the D-Bus property <link linkend="gdbus-property-org-project-Bat.force_struct">"force_struct"</link>.
11011    *
11012    * Since the D-Bus property for this #GObject property is both readable and writable, it is meaningful to both read from it and write to it on both the service- and client-side.
11013    */
11014   g_object_interface_install_property (iface,
11015     g_param_spec_variant ("force-struct", "force_struct", "force_struct", G_VARIANT_TYPE ("(i)"), NULL, G_PARAM_READWRITE | G_PARAM_STATIC_STRINGS));
11016 }
11017
11018 typedef FooiGenBatIface FooiGenBatInterface;
11019 G_DEFINE_INTERFACE (FooiGenBat, foo_igen_bat, G_TYPE_OBJECT);
11020
11021 /**
11022  * foo_igen_bat_get_force_i: (skip)
11023  * @object: A #FooiGenBat.
11024  *
11025  * Gets the value of the <link linkend="gdbus-property-org-project-Bat.force_i">"force_i"</link> D-Bus property.
11026  *
11027  * Since this D-Bus property is both readable and writable, it is meaningful to use this function on both the client- and service-side.
11028  *
11029  * <warning>The returned value is only valid until the property changes so on the client-side it is only safe to use this function on the thread where @object was constructed. Use foo_igen_bat_dup_force_i() if on another thread.</warning>
11030  *
11031  * Returns: (transfer none): The property value or %NULL if the property is not set. Do not free the returned value, it belongs to @object.
11032  */
11033 GVariant *
11034 foo_igen_bat_get_force_i (FooiGenBat *object)
11035 {
11036   return FOO_IGEN_BAT_GET_IFACE (object)->get_force_i (object);
11037 }
11038
11039 /**
11040  * foo_igen_bat_dup_force_i: (skip)
11041  * @object: A #FooiGenBat.
11042  *
11043  * Gets a copy of the <link linkend="gdbus-property-org-project-Bat.force_i">"force_i"</link> D-Bus property.
11044  *
11045  * Since this D-Bus property is both readable and writable, it is meaningful to use this function on both the client- and service-side.
11046  *
11047  * Returns: (transfer full): The property value or %NULL if the property is not set. The returned value should be freed with g_variant_unref().
11048  */
11049 GVariant *
11050 foo_igen_bat_dup_force_i (FooiGenBat *object)
11051 {
11052   GVariant *value;
11053   g_object_get (G_OBJECT (object), "force-i", &value, NULL);
11054   return value;
11055 }
11056
11057 /**
11058  * foo_igen_bat_set_force_i: (skip)
11059  * @object: A #FooiGenBat.
11060  * @value: The value to set.
11061  *
11062  * Sets the <link linkend="gdbus-property-org-project-Bat.force_i">"force_i"</link> D-Bus property to @value.
11063  *
11064  * Since this D-Bus property is both readable and writable, it is meaningful to use this function on both the client- and service-side.
11065  */
11066 void
11067 foo_igen_bat_set_force_i (FooiGenBat *object, GVariant *value)
11068 {
11069   g_object_set (G_OBJECT (object), "force-i", value, NULL);
11070 }
11071
11072 /**
11073  * foo_igen_bat_get_force_s: (skip)
11074  * @object: A #FooiGenBat.
11075  *
11076  * Gets the value of the <link linkend="gdbus-property-org-project-Bat.force_s">"force_s"</link> D-Bus property.
11077  *
11078  * Since this D-Bus property is both readable and writable, it is meaningful to use this function on both the client- and service-side.
11079  *
11080  * <warning>The returned value is only valid until the property changes so on the client-side it is only safe to use this function on the thread where @object was constructed. Use foo_igen_bat_dup_force_s() if on another thread.</warning>
11081  *
11082  * Returns: (transfer none): The property value or %NULL if the property is not set. Do not free the returned value, it belongs to @object.
11083  */
11084 GVariant *
11085 foo_igen_bat_get_force_s (FooiGenBat *object)
11086 {
11087   return FOO_IGEN_BAT_GET_IFACE (object)->get_force_s (object);
11088 }
11089
11090 /**
11091  * foo_igen_bat_dup_force_s: (skip)
11092  * @object: A #FooiGenBat.
11093  *
11094  * Gets a copy of the <link linkend="gdbus-property-org-project-Bat.force_s">"force_s"</link> D-Bus property.
11095  *
11096  * Since this D-Bus property is both readable and writable, it is meaningful to use this function on both the client- and service-side.
11097  *
11098  * Returns: (transfer full): The property value or %NULL if the property is not set. The returned value should be freed with g_variant_unref().
11099  */
11100 GVariant *
11101 foo_igen_bat_dup_force_s (FooiGenBat *object)
11102 {
11103   GVariant *value;
11104   g_object_get (G_OBJECT (object), "force-s", &value, NULL);
11105   return value;
11106 }
11107
11108 /**
11109  * foo_igen_bat_set_force_s: (skip)
11110  * @object: A #FooiGenBat.
11111  * @value: The value to set.
11112  *
11113  * Sets the <link linkend="gdbus-property-org-project-Bat.force_s">"force_s"</link> D-Bus property to @value.
11114  *
11115  * Since this D-Bus property is both readable and writable, it is meaningful to use this function on both the client- and service-side.
11116  */
11117 void
11118 foo_igen_bat_set_force_s (FooiGenBat *object, GVariant *value)
11119 {
11120   g_object_set (G_OBJECT (object), "force-s", value, NULL);
11121 }
11122
11123 /**
11124  * foo_igen_bat_get_force_ay: (skip)
11125  * @object: A #FooiGenBat.
11126  *
11127  * Gets the value of the <link linkend="gdbus-property-org-project-Bat.force_ay">"force_ay"</link> D-Bus property.
11128  *
11129  * Since this D-Bus property is both readable and writable, it is meaningful to use this function on both the client- and service-side.
11130  *
11131  * <warning>The returned value is only valid until the property changes so on the client-side it is only safe to use this function on the thread where @object was constructed. Use foo_igen_bat_dup_force_ay() if on another thread.</warning>
11132  *
11133  * Returns: (transfer none): The property value or %NULL if the property is not set. Do not free the returned value, it belongs to @object.
11134  */
11135 GVariant *
11136 foo_igen_bat_get_force_ay (FooiGenBat *object)
11137 {
11138   return FOO_IGEN_BAT_GET_IFACE (object)->get_force_ay (object);
11139 }
11140
11141 /**
11142  * foo_igen_bat_dup_force_ay: (skip)
11143  * @object: A #FooiGenBat.
11144  *
11145  * Gets a copy of the <link linkend="gdbus-property-org-project-Bat.force_ay">"force_ay"</link> D-Bus property.
11146  *
11147  * Since this D-Bus property is both readable and writable, it is meaningful to use this function on both the client- and service-side.
11148  *
11149  * Returns: (transfer full): The property value or %NULL if the property is not set. The returned value should be freed with g_variant_unref().
11150  */
11151 GVariant *
11152 foo_igen_bat_dup_force_ay (FooiGenBat *object)
11153 {
11154   GVariant *value;
11155   g_object_get (G_OBJECT (object), "force-ay", &value, NULL);
11156   return value;
11157 }
11158
11159 /**
11160  * foo_igen_bat_set_force_ay: (skip)
11161  * @object: A #FooiGenBat.
11162  * @value: The value to set.
11163  *
11164  * Sets the <link linkend="gdbus-property-org-project-Bat.force_ay">"force_ay"</link> D-Bus property to @value.
11165  *
11166  * Since this D-Bus property is both readable and writable, it is meaningful to use this function on both the client- and service-side.
11167  */
11168 void
11169 foo_igen_bat_set_force_ay (FooiGenBat *object, GVariant *value)
11170 {
11171   g_object_set (G_OBJECT (object), "force-ay", value, NULL);
11172 }
11173
11174 /**
11175  * foo_igen_bat_get_force_struct: (skip)
11176  * @object: A #FooiGenBat.
11177  *
11178  * Gets the value of the <link linkend="gdbus-property-org-project-Bat.force_struct">"force_struct"</link> D-Bus property.
11179  *
11180  * Since this D-Bus property is both readable and writable, it is meaningful to use this function on both the client- and service-side.
11181  *
11182  * <warning>The returned value is only valid until the property changes so on the client-side it is only safe to use this function on the thread where @object was constructed. Use foo_igen_bat_dup_force_struct() if on another thread.</warning>
11183  *
11184  * Returns: (transfer none): The property value or %NULL if the property is not set. Do not free the returned value, it belongs to @object.
11185  */
11186 GVariant *
11187 foo_igen_bat_get_force_struct (FooiGenBat *object)
11188 {
11189   return FOO_IGEN_BAT_GET_IFACE (object)->get_force_struct (object);
11190 }
11191
11192 /**
11193  * foo_igen_bat_dup_force_struct: (skip)
11194  * @object: A #FooiGenBat.
11195  *
11196  * Gets a copy of the <link linkend="gdbus-property-org-project-Bat.force_struct">"force_struct"</link> D-Bus property.
11197  *
11198  * Since this D-Bus property is both readable and writable, it is meaningful to use this function on both the client- and service-side.
11199  *
11200  * Returns: (transfer full): The property value or %NULL if the property is not set. The returned value should be freed with g_variant_unref().
11201  */
11202 GVariant *
11203 foo_igen_bat_dup_force_struct (FooiGenBat *object)
11204 {
11205   GVariant *value;
11206   g_object_get (G_OBJECT (object), "force-struct", &value, NULL);
11207   return value;
11208 }
11209
11210 /**
11211  * foo_igen_bat_set_force_struct: (skip)
11212  * @object: A #FooiGenBat.
11213  * @value: The value to set.
11214  *
11215  * Sets the <link linkend="gdbus-property-org-project-Bat.force_struct">"force_struct"</link> D-Bus property to @value.
11216  *
11217  * Since this D-Bus property is both readable and writable, it is meaningful to use this function on both the client- and service-side.
11218  */
11219 void
11220 foo_igen_bat_set_force_struct (FooiGenBat *object, GVariant *value)
11221 {
11222   g_object_set (G_OBJECT (object), "force-struct", value, NULL);
11223 }
11224
11225 /**
11226  * foo_igen_bat_emit_force_signal:
11227  * @object: A #FooiGenBat.
11228  * @arg_force_i: Argument to pass with the signal.
11229  * @arg_force_s: Argument to pass with the signal.
11230  * @arg_force_ay: Argument to pass with the signal.
11231  * @arg_force_struct: Argument to pass with the signal.
11232  *
11233  * Emits the <link linkend="gdbus-signal-org-project-Bat.ForceSignal">"ForceSignal"</link> D-Bus signal.
11234  */
11235 void
11236 foo_igen_bat_emit_force_signal (
11237     FooiGenBat *object,
11238     GVariant *arg_force_i,
11239     GVariant *arg_force_s,
11240     GVariant *arg_force_ay,
11241     GVariant *arg_force_struct)
11242 {
11243   g_signal_emit_by_name (object, "force-signal", arg_force_i, arg_force_s, arg_force_ay, arg_force_struct);
11244 }
11245
11246 /**
11247  * foo_igen_bat_call_force_method:
11248  * @proxy: A #FooiGenBatProxy.
11249  * @arg_force_in_i: Argument to pass with the method invocation.
11250  * @arg_force_in_s: Argument to pass with the method invocation.
11251  * @arg_force_in_ay: Argument to pass with the method invocation.
11252  * @arg_force_in_struct: Argument to pass with the method invocation.
11253  * @cancellable: (allow-none): A #GCancellable or %NULL.
11254  * @callback: A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
11255  * @user_data: User data to pass to @callback.
11256  *
11257  * Asynchronously invokes the <link linkend="gdbus-method-org-project-Bat.ForceMethod">ForceMethod()</link> D-Bus method on @proxy.
11258  * When the operation is finished, @callback will be invoked in the <link linkend="g-main-context-push-thread-default">thread-default main loop</link> of the thread you are calling this method from.
11259  * You can then call foo_igen_bat_call_force_method_finish() to get the result of the operation.
11260  *
11261  * See foo_igen_bat_call_force_method_sync() for the synchronous, blocking version of this method.
11262  */
11263 void
11264 foo_igen_bat_call_force_method (
11265     FooiGenBat *proxy,
11266     GVariant *arg_force_in_i,
11267     GVariant *arg_force_in_s,
11268     GVariant *arg_force_in_ay,
11269     GVariant *arg_force_in_struct,
11270     GCancellable *cancellable,
11271     GAsyncReadyCallback callback,
11272     gpointer user_data)
11273 {
11274   g_dbus_proxy_call (G_DBUS_PROXY (proxy),
11275     "ForceMethod",
11276     g_variant_new ("(@i@s@ay@(i))",
11277                    arg_force_in_i,
11278                    arg_force_in_s,
11279                    arg_force_in_ay,
11280                    arg_force_in_struct),
11281     G_DBUS_CALL_FLAGS_NONE,
11282     -1,
11283     cancellable,
11284     callback,
11285     user_data);
11286 }
11287
11288 /**
11289  * foo_igen_bat_call_force_method_finish:
11290  * @proxy: A #FooiGenBatProxy.
11291  * @out_force_out_i: (out): Return location for return parameter or %NULL to ignore.
11292  * @out_force_out_s: (out): Return location for return parameter or %NULL to ignore.
11293  * @out_force_out_ay: (out): Return location for return parameter or %NULL to ignore.
11294  * @out_force_out_struct: (out): Return location for return parameter or %NULL to ignore.
11295  * @res: The #GAsyncResult obtained from the #GAsyncReadyCallback passed to foo_igen_bat_call_force_method().
11296  * @error: Return location for error or %NULL.
11297  *
11298  * Finishes an operation started with foo_igen_bat_call_force_method().
11299  *
11300  * Returns: (skip): %TRUE if the call succeded, %FALSE if @error is set.
11301  */
11302 gboolean
11303 foo_igen_bat_call_force_method_finish (
11304     FooiGenBat *proxy,
11305     GVariant **out_force_out_i,
11306     GVariant **out_force_out_s,
11307     GVariant **out_force_out_ay,
11308     GVariant **out_force_out_struct,
11309     GAsyncResult *res,
11310     GError **error)
11311 {
11312   GVariant *_ret;
11313   _ret = g_dbus_proxy_call_finish (G_DBUS_PROXY (proxy), res, error);
11314   if (_ret == NULL)
11315     goto _out;
11316   g_variant_get (_ret,
11317                  "(@i@s@ay@(i))",
11318                  out_force_out_i,
11319                  out_force_out_s,
11320                  out_force_out_ay,
11321                  out_force_out_struct);
11322   g_variant_unref (_ret);
11323 _out:
11324   return _ret != NULL;
11325 }
11326
11327 /**
11328  * foo_igen_bat_call_force_method_sync:
11329  * @proxy: A #FooiGenBatProxy.
11330  * @arg_force_in_i: Argument to pass with the method invocation.
11331  * @arg_force_in_s: Argument to pass with the method invocation.
11332  * @arg_force_in_ay: Argument to pass with the method invocation.
11333  * @arg_force_in_struct: Argument to pass with the method invocation.
11334  * @out_force_out_i: (out): Return location for return parameter or %NULL to ignore.
11335  * @out_force_out_s: (out): Return location for return parameter or %NULL to ignore.
11336  * @out_force_out_ay: (out): Return location for return parameter or %NULL to ignore.
11337  * @out_force_out_struct: (out): Return location for return parameter or %NULL to ignore.
11338  * @cancellable: (allow-none): A #GCancellable or %NULL.
11339  * @error: Return location for error or %NULL.
11340  *
11341  * Synchronously invokes the <link linkend="gdbus-method-org-project-Bat.ForceMethod">ForceMethod()</link> D-Bus method on @proxy. The calling thread is blocked until a reply is received.
11342  *
11343  * See foo_igen_bat_call_force_method() for the asynchronous version of this method.
11344  *
11345  * Returns: (skip): %TRUE if the call succeded, %FALSE if @error is set.
11346  */
11347 gboolean
11348 foo_igen_bat_call_force_method_sync (
11349     FooiGenBat *proxy,
11350     GVariant *arg_force_in_i,
11351     GVariant *arg_force_in_s,
11352     GVariant *arg_force_in_ay,
11353     GVariant *arg_force_in_struct,
11354     GVariant **out_force_out_i,
11355     GVariant **out_force_out_s,
11356     GVariant **out_force_out_ay,
11357     GVariant **out_force_out_struct,
11358     GCancellable *cancellable,
11359     GError **error)
11360 {
11361   GVariant *_ret;
11362   _ret = g_dbus_proxy_call_sync (G_DBUS_PROXY (proxy),
11363     "ForceMethod",
11364     g_variant_new ("(@i@s@ay@(i))",
11365                    arg_force_in_i,
11366                    arg_force_in_s,
11367                    arg_force_in_ay,
11368                    arg_force_in_struct),
11369     G_DBUS_CALL_FLAGS_NONE,
11370     -1,
11371     cancellable,
11372     error);
11373   if (_ret == NULL)
11374     goto _out;
11375   g_variant_get (_ret,
11376                  "(@i@s@ay@(i))",
11377                  out_force_out_i,
11378                  out_force_out_s,
11379                  out_force_out_ay,
11380                  out_force_out_struct);
11381   g_variant_unref (_ret);
11382 _out:
11383   return _ret != NULL;
11384 }
11385
11386 /**
11387  * foo_igen_bat_complete_force_method:
11388  * @object: A #FooiGenBat.
11389  * @invocation: (transfer full): A #GDBusMethodInvocation.
11390  * @force_out_i: Parameter to return.
11391  * @force_out_s: Parameter to return.
11392  * @force_out_ay: Parameter to return.
11393  * @force_out_struct: Parameter to return.
11394  *
11395  * Helper function used in service implementations to finish handling invocations of the <link linkend="gdbus-method-org-project-Bat.ForceMethod">ForceMethod()</link> D-Bus method. If you instead want to finish handling an invocation by returning an error, use g_dbus_method_invocation_return_error() or similar.
11396  *
11397  * This method will free @invocation, you cannot use it afterwards.
11398  */
11399 void
11400 foo_igen_bat_complete_force_method (
11401     FooiGenBat *object,
11402     GDBusMethodInvocation *invocation,
11403     GVariant *force_out_i,
11404     GVariant *force_out_s,
11405     GVariant *force_out_ay,
11406     GVariant *force_out_struct)
11407 {
11408   g_dbus_method_invocation_return_value (invocation,
11409     g_variant_new ("(@i@s@ay@(i))",
11410                    force_out_i,
11411                    force_out_s,
11412                    force_out_ay,
11413                    force_out_struct));
11414 }
11415
11416 /* ------------------------------------------------------------------------ */
11417
11418 /**
11419  * FooiGenBatProxy:
11420  *
11421  * The #FooiGenBatProxy structure contains only private data and should only be accessed using the provided API.
11422  */
11423
11424 /**
11425  * FooiGenBatProxyClass:
11426  * @parent_class: The parent class.
11427  *
11428  * Class structure for #FooiGenBatProxy.
11429  */
11430
11431 struct _FooiGenBatProxyPrivate
11432 {
11433   GData *qdata;
11434 };
11435
11436 static void foo_igen_bat_proxy_iface_init (FooiGenBatIface *iface);
11437
11438 G_DEFINE_TYPE_WITH_CODE (FooiGenBatProxy, foo_igen_bat_proxy, G_TYPE_DBUS_PROXY,
11439                          G_IMPLEMENT_INTERFACE (FOO_IGEN_TYPE_BAT, foo_igen_bat_proxy_iface_init));
11440
11441 static void
11442 foo_igen_bat_proxy_finalize (GObject *object)
11443 {
11444   FooiGenBatProxy *proxy = FOO_IGEN_BAT_PROXY (object);
11445   g_datalist_clear (&proxy->priv->qdata);
11446   G_OBJECT_CLASS (foo_igen_bat_proxy_parent_class)->finalize (object);
11447 }
11448
11449 static void
11450 foo_igen_bat_proxy_get_property (GObject      *object,
11451   guint         prop_id,
11452   GValue       *value,
11453   GParamSpec   *pspec)
11454 {
11455   const _ExtendedGDBusPropertyInfo *info;
11456   GVariant *variant;
11457   g_assert (prop_id != 0 && prop_id - 1 < 4);
11458   info = _foo_igen_bat_property_info_pointers[prop_id - 1];
11459   variant = g_dbus_proxy_get_cached_property (G_DBUS_PROXY (object), info->parent_struct.name);
11460   if (info->use_gvariant)
11461     {
11462       g_value_set_variant (value, variant);
11463     }
11464   else
11465     {
11466       if (variant != NULL)
11467         g_dbus_gvariant_to_gvalue (variant, value);
11468     }
11469   if (variant != NULL)
11470     g_variant_unref (variant);
11471 }
11472
11473 static void
11474 foo_igen_bat_proxy_set_property_cb (GDBusProxy *proxy,
11475   GAsyncResult *res,
11476   gpointer      user_data)
11477 {
11478   const _ExtendedGDBusPropertyInfo *info = user_data;
11479   GError *error;
11480   error = NULL;
11481   if (!g_dbus_proxy_call_finish (proxy, res, &error))
11482     {
11483       g_warning ("Error setting property `%s' on interface org.project.Bat: %s (%s, %d)",
11484                  info->parent_struct.name, 
11485                  error->message, g_quark_to_string (error->domain), error->code);
11486       g_error_free (error);
11487     }
11488 }
11489
11490 static void
11491 foo_igen_bat_proxy_set_property (GObject      *object,
11492   guint         prop_id,
11493   const GValue *value,
11494   GParamSpec   *pspec)
11495 {
11496   const _ExtendedGDBusPropertyInfo *info;
11497   GVariant *variant;
11498   g_assert (prop_id != 0 && prop_id - 1 < 4);
11499   info = _foo_igen_bat_property_info_pointers[prop_id - 1];
11500   variant = g_dbus_gvalue_to_gvariant (value, G_VARIANT_TYPE (info->parent_struct.signature));
11501   g_dbus_proxy_call (G_DBUS_PROXY (object),
11502     "org.freedesktop.DBus.Properties.Set",
11503     g_variant_new ("(ssv)", "org.project.Bat", info->parent_struct.name, variant),
11504     G_DBUS_CALL_FLAGS_NONE,
11505     -1,
11506     NULL, (GAsyncReadyCallback) foo_igen_bat_proxy_set_property_cb, (gpointer) info);
11507   g_variant_unref (variant);
11508 }
11509
11510 static void
11511 foo_igen_bat_proxy_g_signal (GDBusProxy *proxy,
11512   const gchar *sender_name,
11513   const gchar *signal_name,
11514   GVariant *parameters)
11515 {
11516   _ExtendedGDBusSignalInfo *info;
11517   GVariantIter iter;
11518   GVariant *child;
11519   GValue *paramv;
11520   guint num_params;
11521   guint n;
11522   guint signal_id;
11523   info = (_ExtendedGDBusSignalInfo *) g_dbus_interface_info_lookup_signal ((GDBusInterfaceInfo *) &_foo_igen_bat_interface_info, signal_name);
11524   if (info == NULL)
11525     return;
11526   num_params = g_variant_n_children (parameters);
11527   paramv = g_new0 (GValue, num_params + 1);
11528   g_value_init (&paramv[0], FOO_IGEN_TYPE_BAT);
11529   g_value_set_object (&paramv[0], proxy);
11530   g_variant_iter_init (&iter, parameters);
11531   n = 1;
11532   while ((child = g_variant_iter_next_value (&iter)) != NULL)
11533     {
11534       _ExtendedGDBusArgInfo *arg_info = (_ExtendedGDBusArgInfo *) info->parent_struct.args[n - 1];
11535       if (arg_info->use_gvariant)
11536         {
11537           g_value_init (&paramv[n], G_TYPE_VARIANT);
11538           g_value_set_variant (&paramv[n], child);
11539           n++;
11540         }
11541       else
11542         g_dbus_gvariant_to_gvalue (child, &paramv[n++]);
11543       g_variant_unref (child);
11544     }
11545   signal_id = g_signal_lookup (info->signal_name, FOO_IGEN_TYPE_BAT);
11546   g_signal_emitv (paramv, signal_id, 0, NULL);
11547   for (n = 0; n < num_params + 1; n++)
11548     g_value_unset (&paramv[n]);
11549   g_free (paramv);
11550 }
11551
11552 static void
11553 foo_igen_bat_proxy_g_properties_changed (GDBusProxy *_proxy,
11554   GVariant *changed_properties,
11555   const gchar *const *invalidated_properties)
11556 {
11557   FooiGenBatProxy *proxy = FOO_IGEN_BAT_PROXY (_proxy);
11558   guint n;
11559   const gchar *key;
11560   GVariantIter *iter;
11561   _ExtendedGDBusPropertyInfo *info;
11562   g_variant_get (changed_properties, "a{sv}", &iter);
11563   while (g_variant_iter_next (iter, "{&sv}", &key, NULL))
11564     {
11565       info = (_ExtendedGDBusPropertyInfo *) g_dbus_interface_info_lookup_property ((GDBusInterfaceInfo *) &_foo_igen_bat_interface_info, key);
11566       g_datalist_remove_data (&proxy->priv->qdata, key);
11567       if (info != NULL)
11568         g_object_notify (G_OBJECT (proxy), info->hyphen_name);
11569     }
11570   g_variant_iter_free (iter);
11571   for (n = 0; invalidated_properties[n] != NULL; n++)
11572     {
11573       info = (_ExtendedGDBusPropertyInfo *) g_dbus_interface_info_lookup_property ((GDBusInterfaceInfo *) &_foo_igen_bat_interface_info, invalidated_properties[n]);
11574       g_datalist_remove_data (&proxy->priv->qdata, invalidated_properties[n]);
11575       if (info != NULL)
11576         g_object_notify (G_OBJECT (proxy), info->hyphen_name);
11577     }
11578 }
11579
11580 static GVariant *
11581 foo_igen_bat_proxy_get_force_i (FooiGenBat *object)
11582 {
11583   FooiGenBatProxy *proxy = FOO_IGEN_BAT_PROXY (object);
11584   GVariant *variant;
11585   GVariant *value = NULL;
11586   variant = g_dbus_proxy_get_cached_property (G_DBUS_PROXY (proxy), "force_i");
11587   value = variant;
11588   if (variant != NULL)
11589     g_variant_unref (variant);
11590   return value;
11591 }
11592
11593 static GVariant *
11594 foo_igen_bat_proxy_get_force_s (FooiGenBat *object)
11595 {
11596   FooiGenBatProxy *proxy = FOO_IGEN_BAT_PROXY (object);
11597   GVariant *variant;
11598   GVariant *value = NULL;
11599   variant = g_dbus_proxy_get_cached_property (G_DBUS_PROXY (proxy), "force_s");
11600   value = variant;
11601   if (variant != NULL)
11602     g_variant_unref (variant);
11603   return value;
11604 }
11605
11606 static GVariant *
11607 foo_igen_bat_proxy_get_force_ay (FooiGenBat *object)
11608 {
11609   FooiGenBatProxy *proxy = FOO_IGEN_BAT_PROXY (object);
11610   GVariant *variant;
11611   GVariant *value = NULL;
11612   variant = g_dbus_proxy_get_cached_property (G_DBUS_PROXY (proxy), "force_ay");
11613   value = variant;
11614   if (variant != NULL)
11615     g_variant_unref (variant);
11616   return value;
11617 }
11618
11619 static GVariant *
11620 foo_igen_bat_proxy_get_force_struct (FooiGenBat *object)
11621 {
11622   FooiGenBatProxy *proxy = FOO_IGEN_BAT_PROXY (object);
11623   GVariant *variant;
11624   GVariant *value = NULL;
11625   variant = g_dbus_proxy_get_cached_property (G_DBUS_PROXY (proxy), "force_struct");
11626   value = variant;
11627   if (variant != NULL)
11628     g_variant_unref (variant);
11629   return value;
11630 }
11631
11632 static void
11633 foo_igen_bat_proxy_init (FooiGenBatProxy *proxy)
11634 {
11635   proxy->priv = G_TYPE_INSTANCE_GET_PRIVATE (proxy, FOO_IGEN_TYPE_BAT_PROXY, FooiGenBatProxyPrivate);
11636   g_dbus_proxy_set_interface_info (G_DBUS_PROXY (proxy), foo_igen_bat_interface_info ());
11637 }
11638
11639 static void
11640 foo_igen_bat_proxy_class_init (FooiGenBatProxyClass *klass)
11641 {
11642   GObjectClass *gobject_class;
11643   GDBusProxyClass *proxy_class;
11644
11645   g_type_class_add_private (klass, sizeof (FooiGenBatProxyPrivate));
11646
11647   gobject_class = G_OBJECT_CLASS (klass);
11648   gobject_class->finalize     = foo_igen_bat_proxy_finalize;
11649   gobject_class->get_property = foo_igen_bat_proxy_get_property;
11650   gobject_class->set_property = foo_igen_bat_proxy_set_property;
11651
11652   proxy_class = G_DBUS_PROXY_CLASS (klass);
11653   proxy_class->g_signal = foo_igen_bat_proxy_g_signal;
11654   proxy_class->g_properties_changed = foo_igen_bat_proxy_g_properties_changed;
11655
11656
11657   foo_igen_bat_override_properties (gobject_class, 1);
11658 }
11659
11660 static void
11661 foo_igen_bat_proxy_iface_init (FooiGenBatIface *iface)
11662 {
11663   iface->get_force_i = foo_igen_bat_proxy_get_force_i;
11664   iface->get_force_s = foo_igen_bat_proxy_get_force_s;
11665   iface->get_force_ay = foo_igen_bat_proxy_get_force_ay;
11666   iface->get_force_struct = foo_igen_bat_proxy_get_force_struct;
11667 }
11668
11669 /**
11670  * foo_igen_bat_proxy_new:
11671  * @connection: A #GDBusConnection.
11672  * @flags: Flags from the #GDBusProxyFlags enumeration.
11673  * @name: (allow-none): A bus name (well-known or unique) or %NULL if @connection is not a message bus connection.
11674  * @object_path: An object path.
11675  * @cancellable: (allow-none): A #GCancellable or %NULL.
11676  * @callback: A #GAsyncReadyCallback to call when the request is satisfied.
11677  * @user_data: User data to pass to @callback.
11678  *
11679  * Asynchronously creates a proxy for the D-Bus interface <link linkend="gdbus-interface-org-project-Bat.top_of_page">org.project.Bat</link>. See g_dbus_proxy_new() for more details.
11680  *
11681  * When the operation is finished, @callback will be invoked in the <link linkend="g-main-context-push-thread-default">thread-default main loop</link> of the thread you are calling this method from.
11682  * You can then call foo_igen_bat_proxy_new_finish() to get the result of the operation.
11683  *
11684  * See foo_igen_bat_proxy_new_sync() for the synchronous, blocking version of this constructor.
11685  */
11686 void
11687 foo_igen_bat_proxy_new (
11688     GDBusConnection     *connection,
11689     GDBusProxyFlags      flags,
11690     const gchar         *name,
11691     const gchar         *object_path,
11692     GCancellable        *cancellable,
11693     GAsyncReadyCallback  callback,
11694     gpointer             user_data)
11695 {
11696   g_async_initable_new_async (FOO_IGEN_TYPE_BAT_PROXY, G_PRIORITY_DEFAULT, cancellable, callback, user_data, "g-flags", flags, "g-name", name, "g-connection", connection, "g-object-path", object_path, "g-interface-name", "org.project.Bat", NULL);
11697 }
11698
11699 /**
11700  * foo_igen_bat_proxy_new_finish:
11701  * @res: The #GAsyncResult obtained from the #GAsyncReadyCallback passed to foo_igen_bat_proxy_new().
11702  * @error: Return location for error or %NULL
11703  *
11704  * Finishes an operation started with foo_igen_bat_proxy_new().
11705  *
11706  * Returns: (transfer full) (type FooiGenBatProxy): The constructed proxy object or %NULL if @error is set.
11707  */
11708 FooiGenBat *
11709 foo_igen_bat_proxy_new_finish (
11710     GAsyncResult        *res,
11711     GError             **error)
11712 {
11713   GObject *ret;
11714   GObject *source_object;
11715   source_object = g_async_result_get_source_object (res);
11716   ret = g_async_initable_new_finish (G_ASYNC_INITABLE (source_object), res, error);
11717   g_object_unref (source_object);
11718   if (ret != NULL)
11719     return FOO_IGEN_BAT (ret);
11720   else
11721     return NULL;
11722 }
11723
11724 /**
11725  * foo_igen_bat_proxy_new_sync:
11726  * @connection: A #GDBusConnection.
11727  * @flags: Flags from the #GDBusProxyFlags enumeration.
11728  * @name: (allow-none): A bus name (well-known or unique) or %NULL if @connection is not a message bus connection.
11729  * @object_path: An object path.
11730  * @cancellable: (allow-none): A #GCancellable or %NULL.
11731  * @error: Return location for error or %NULL
11732  *
11733  * Synchronously creates a proxy for the D-Bus interface <link linkend="gdbus-interface-org-project-Bat.top_of_page">org.project.Bat</link>. See g_dbus_proxy_new_sync() for more details.
11734  *
11735  * The calling thread is blocked until a reply is received.
11736  *
11737  * See foo_igen_bat_proxy_new() for the asynchronous version of this constructor.
11738  *
11739  * Returns: (transfer full) (type FooiGenBatProxy): The constructed proxy object or %NULL if @error is set.
11740  */
11741 FooiGenBat *
11742 foo_igen_bat_proxy_new_sync (
11743     GDBusConnection     *connection,
11744     GDBusProxyFlags      flags,
11745     const gchar         *name,
11746     const gchar         *object_path,
11747     GCancellable        *cancellable,
11748     GError             **error)
11749 {
11750   GInitable *ret;
11751   ret = g_initable_new (FOO_IGEN_TYPE_BAT_PROXY, cancellable, error, "g-flags", flags, "g-name", name, "g-connection", connection, "g-object-path", object_path, "g-interface-name", "org.project.Bat", NULL);
11752   if (ret != NULL)
11753     return FOO_IGEN_BAT (ret);
11754   else
11755     return NULL;
11756 }
11757
11758
11759 /**
11760  * foo_igen_bat_proxy_new_for_bus:
11761  * @bus_type: A #GBusType.
11762  * @flags: Flags from the #GDBusProxyFlags enumeration.
11763  * @name: A bus name (well-known or unique).
11764  * @object_path: An object path.
11765  * @cancellable: (allow-none): A #GCancellable or %NULL.
11766  * @callback: A #GAsyncReadyCallback to call when the request is satisfied.
11767  * @user_data: User data to pass to @callback.
11768  *
11769  * Like foo_igen_bat_proxy_new() but takes a #GBusType instead of a #GDBusConnection.
11770  *
11771  * When the operation is finished, @callback will be invoked in the <link linkend="g-main-context-push-thread-default">thread-default main loop</link> of the thread you are calling this method from.
11772  * You can then call foo_igen_bat_proxy_new_for_bus_finish() to get the result of the operation.
11773  *
11774  * See foo_igen_bat_proxy_new_for_bus_sync() for the synchronous, blocking version of this constructor.
11775  */
11776 void
11777 foo_igen_bat_proxy_new_for_bus (
11778     GBusType             bus_type,
11779     GDBusProxyFlags      flags,
11780     const gchar         *name,
11781     const gchar         *object_path,
11782     GCancellable        *cancellable,
11783     GAsyncReadyCallback  callback,
11784     gpointer             user_data)
11785 {
11786   g_async_initable_new_async (FOO_IGEN_TYPE_BAT_PROXY, G_PRIORITY_DEFAULT, cancellable, callback, user_data, "g-flags", flags, "g-name", name, "g-bus-type", bus_type, "g-object-path", object_path, "g-interface-name", "org.project.Bat", NULL);
11787 }
11788
11789 /**
11790  * foo_igen_bat_proxy_new_for_bus_finish:
11791  * @res: The #GAsyncResult obtained from the #GAsyncReadyCallback passed to foo_igen_bat_proxy_new_for_bus().
11792  * @error: Return location for error or %NULL
11793  *
11794  * Finishes an operation started with foo_igen_bat_proxy_new_for_bus().
11795  *
11796  * Returns: (transfer full) (type FooiGenBatProxy): The constructed proxy object or %NULL if @error is set.
11797  */
11798 FooiGenBat *
11799 foo_igen_bat_proxy_new_for_bus_finish (
11800     GAsyncResult        *res,
11801     GError             **error)
11802 {
11803   GObject *ret;
11804   GObject *source_object;
11805   source_object = g_async_result_get_source_object (res);
11806   ret = g_async_initable_new_finish (G_ASYNC_INITABLE (source_object), res, error);
11807   g_object_unref (source_object);
11808   if (ret != NULL)
11809     return FOO_IGEN_BAT (ret);
11810   else
11811     return NULL;
11812 }
11813
11814 /**
11815  * foo_igen_bat_proxy_new_for_bus_sync:
11816  * @bus_type: A #GBusType.
11817  * @flags: Flags from the #GDBusProxyFlags enumeration.
11818  * @name: A bus name (well-known or unique).
11819  * @object_path: An object path.
11820  * @cancellable: (allow-none): A #GCancellable or %NULL.
11821  * @error: Return location for error or %NULL
11822  *
11823  * Like foo_igen_bat_proxy_new_sync() but takes a #GBusType instead of a #GDBusConnection.
11824  *
11825  * The calling thread is blocked until a reply is received.
11826  *
11827  * See foo_igen_bat_proxy_new_for_bus() for the asynchronous version of this constructor.
11828  *
11829  * Returns: (transfer full) (type FooiGenBatProxy): The constructed proxy object or %NULL if @error is set.
11830  */
11831 FooiGenBat *
11832 foo_igen_bat_proxy_new_for_bus_sync (
11833     GBusType             bus_type,
11834     GDBusProxyFlags      flags,
11835     const gchar         *name,
11836     const gchar         *object_path,
11837     GCancellable        *cancellable,
11838     GError             **error)
11839 {
11840   GInitable *ret;
11841   ret = g_initable_new (FOO_IGEN_TYPE_BAT_PROXY, cancellable, error, "g-flags", flags, "g-name", name, "g-bus-type", bus_type, "g-object-path", object_path, "g-interface-name", "org.project.Bat", NULL);
11842   if (ret != NULL)
11843     return FOO_IGEN_BAT (ret);
11844   else
11845     return NULL;
11846 }
11847
11848
11849 /* ------------------------------------------------------------------------ */
11850
11851 /**
11852  * FooiGenBatSkeleton:
11853  *
11854  * The #FooiGenBatSkeleton structure contains only private data and should only be accessed using the provided API.
11855  */
11856
11857 /**
11858  * FooiGenBatSkeletonClass:
11859  * @parent_class: The parent class.
11860  *
11861  * Class structure for #FooiGenBatSkeleton.
11862  */
11863
11864 struct _FooiGenBatSkeletonPrivate
11865 {
11866   GValue *properties;
11867   GList *changed_properties;
11868   GSource *changed_properties_idle_source;
11869   GMainContext *context;
11870   GMutex lock;
11871 };
11872
11873 static void
11874 _foo_igen_bat_skeleton_handle_method_call (
11875   GDBusConnection *connection,
11876   const gchar *sender,
11877   const gchar *object_path,
11878   const gchar *interface_name,
11879   const gchar *method_name,
11880   GVariant *parameters,
11881   GDBusMethodInvocation *invocation,
11882   gpointer user_data)
11883 {
11884   FooiGenBatSkeleton *skeleton = FOO_IGEN_BAT_SKELETON (user_data);
11885   _ExtendedGDBusMethodInfo *info;
11886   GVariantIter iter;
11887   GVariant *child;
11888   GValue *paramv;
11889   guint num_params;
11890   guint num_extra;
11891   guint n;
11892   guint signal_id;
11893   GValue return_value = G_VALUE_INIT;
11894   info = (_ExtendedGDBusMethodInfo *) g_dbus_method_invocation_get_method_info (invocation);
11895   g_assert (info != NULL);
11896   num_params = g_variant_n_children (parameters);
11897   num_extra = info->pass_fdlist ? 3 : 2;  paramv = g_new0 (GValue, num_params + num_extra);
11898   n = 0;
11899   g_value_init (&paramv[n], FOO_IGEN_TYPE_BAT);
11900   g_value_set_object (&paramv[n++], skeleton);
11901   g_value_init (&paramv[n], G_TYPE_DBUS_METHOD_INVOCATION);
11902   g_value_set_object (&paramv[n++], invocation);
11903   if (info->pass_fdlist)
11904     {
11905 #ifdef G_OS_UNIX
11906       g_value_init (&paramv[n], G_TYPE_UNIX_FD_LIST);
11907       g_value_set_object (&paramv[n++], g_dbus_message_get_unix_fd_list (g_dbus_method_invocation_get_message (invocation)));
11908 #else
11909       g_assert_not_reached ();
11910 #endif
11911     }
11912   g_variant_iter_init (&iter, parameters);
11913   while ((child = g_variant_iter_next_value (&iter)) != NULL)
11914     {
11915       _ExtendedGDBusArgInfo *arg_info = (_ExtendedGDBusArgInfo *) info->parent_struct.in_args[n - num_extra];
11916       if (arg_info->use_gvariant)
11917         {
11918           g_value_init (&paramv[n], G_TYPE_VARIANT);
11919           g_value_set_variant (&paramv[n], child);
11920           n++;
11921         }
11922       else
11923         g_dbus_gvariant_to_gvalue (child, &paramv[n++]);
11924       g_variant_unref (child);
11925     }
11926   signal_id = g_signal_lookup (info->signal_name, FOO_IGEN_TYPE_BAT);
11927   g_value_init (&return_value, G_TYPE_BOOLEAN);
11928   g_signal_emitv (paramv, signal_id, 0, &return_value);
11929   if (!g_value_get_boolean (&return_value))
11930     g_dbus_method_invocation_return_error (invocation, G_DBUS_ERROR, G_DBUS_ERROR_UNKNOWN_METHOD, "Method %s is not implemented on interface %s", method_name, interface_name);
11931   g_value_unset (&return_value);
11932   for (n = 0; n < num_params + num_extra; n++)
11933     g_value_unset (&paramv[n]);
11934   g_free (paramv);
11935 }
11936
11937 static GVariant *
11938 _foo_igen_bat_skeleton_handle_get_property (
11939   GDBusConnection *connection,
11940   const gchar *sender,
11941   const gchar *object_path,
11942   const gchar *interface_name,
11943   const gchar *property_name,
11944   GError **error,
11945   gpointer user_data)
11946 {
11947   FooiGenBatSkeleton *skeleton = FOO_IGEN_BAT_SKELETON (user_data);
11948   GValue value = G_VALUE_INIT;
11949   GParamSpec *pspec;
11950   _ExtendedGDBusPropertyInfo *info;
11951   GVariant *ret;
11952   ret = NULL;
11953   info = (_ExtendedGDBusPropertyInfo *) g_dbus_interface_info_lookup_property ((GDBusInterfaceInfo *) &_foo_igen_bat_interface_info, property_name);
11954   g_assert (info != NULL);
11955   pspec = g_object_class_find_property (G_OBJECT_GET_CLASS (skeleton), info->hyphen_name);
11956   if (pspec == NULL)
11957     {
11958       g_set_error (error, G_DBUS_ERROR, G_DBUS_ERROR_INVALID_ARGS, "No property with name %s", property_name);
11959     }
11960   else
11961     {
11962       g_value_init (&value, pspec->value_type);
11963       g_object_get_property (G_OBJECT (skeleton), info->hyphen_name, &value);
11964       ret = g_dbus_gvalue_to_gvariant (&value, G_VARIANT_TYPE (info->parent_struct.signature));
11965       g_value_unset (&value);
11966     }
11967   return ret;
11968 }
11969
11970 static gboolean
11971 _foo_igen_bat_skeleton_handle_set_property (
11972   GDBusConnection *connection,
11973   const gchar *sender,
11974   const gchar *object_path,
11975   const gchar *interface_name,
11976   const gchar *property_name,
11977   GVariant *variant,
11978   GError **error,
11979   gpointer user_data)
11980 {
11981   FooiGenBatSkeleton *skeleton = FOO_IGEN_BAT_SKELETON (user_data);
11982   GValue value = G_VALUE_INIT;
11983   GParamSpec *pspec;
11984   _ExtendedGDBusPropertyInfo *info;
11985   gboolean ret;
11986   ret = FALSE;
11987   info = (_ExtendedGDBusPropertyInfo *) g_dbus_interface_info_lookup_property ((GDBusInterfaceInfo *) &_foo_igen_bat_interface_info, property_name);
11988   g_assert (info != NULL);
11989   pspec = g_object_class_find_property (G_OBJECT_GET_CLASS (skeleton), info->hyphen_name);
11990   if (pspec == NULL)
11991     {
11992       g_set_error (error, G_DBUS_ERROR, G_DBUS_ERROR_INVALID_ARGS, "No property with name %s", property_name);
11993     }
11994   else
11995     {
11996       if (info->use_gvariant)
11997         g_value_set_variant (&value, variant);
11998       else
11999         g_dbus_gvariant_to_gvalue (variant, &value);
12000       g_object_set_property (G_OBJECT (skeleton), info->hyphen_name, &value);
12001       g_value_unset (&value);
12002       ret = TRUE;
12003     }
12004   return ret;
12005 }
12006
12007 static const GDBusInterfaceVTable _foo_igen_bat_skeleton_vtable =
12008 {
12009   _foo_igen_bat_skeleton_handle_method_call,
12010   _foo_igen_bat_skeleton_handle_get_property,
12011   _foo_igen_bat_skeleton_handle_set_property
12012 };
12013
12014 static GDBusInterfaceInfo *
12015 foo_igen_bat_skeleton_dbus_interface_get_info (GDBusInterfaceSkeleton *skeleton)
12016 {
12017   return foo_igen_bat_interface_info ();
12018 }
12019
12020 static GDBusInterfaceVTable *
12021 foo_igen_bat_skeleton_dbus_interface_get_vtable (GDBusInterfaceSkeleton *skeleton)
12022 {
12023   return (GDBusInterfaceVTable *) &_foo_igen_bat_skeleton_vtable;
12024 }
12025
12026 static GVariant *
12027 foo_igen_bat_skeleton_dbus_interface_get_properties (GDBusInterfaceSkeleton *_skeleton)
12028 {
12029   FooiGenBatSkeleton *skeleton = FOO_IGEN_BAT_SKELETON (_skeleton);
12030
12031   GVariantBuilder builder;
12032   guint n;
12033   g_variant_builder_init (&builder, G_VARIANT_TYPE ("a{sv}"));
12034   if (_foo_igen_bat_interface_info.parent_struct.properties == NULL)
12035     goto out;
12036   for (n = 0; _foo_igen_bat_interface_info.parent_struct.properties[n] != NULL; n++)
12037     {
12038       GDBusPropertyInfo *info = _foo_igen_bat_interface_info.parent_struct.properties[n];
12039       if (info->flags & G_DBUS_PROPERTY_INFO_FLAGS_READABLE)
12040         {
12041           GVariant *value;
12042           value = _foo_igen_bat_skeleton_handle_get_property (g_dbus_interface_skeleton_get_connection (G_DBUS_INTERFACE_SKELETON (skeleton)), NULL, g_dbus_interface_skeleton_get_object_path (G_DBUS_INTERFACE_SKELETON (skeleton)), "org.project.Bat", info->name, NULL, skeleton);
12043           if (value != NULL)
12044             {
12045               g_variant_take_ref (value);
12046               g_variant_builder_add (&builder, "{sv}", info->name, value);
12047               g_variant_unref (value);
12048             }
12049         }
12050     }
12051 out:
12052   return g_variant_builder_end (&builder);
12053 }
12054
12055 static gboolean _foo_igen_bat_emit_changed (gpointer user_data);
12056
12057 static void
12058 foo_igen_bat_skeleton_dbus_interface_flush (GDBusInterfaceSkeleton *_skeleton)
12059 {
12060   FooiGenBatSkeleton *skeleton = FOO_IGEN_BAT_SKELETON (_skeleton);
12061   gboolean emit_changed = FALSE;
12062
12063   g_mutex_lock (&skeleton->priv->lock);
12064   if (skeleton->priv->changed_properties_idle_source != NULL)
12065     {
12066       g_source_destroy (skeleton->priv->changed_properties_idle_source);
12067       skeleton->priv->changed_properties_idle_source = NULL;
12068       emit_changed = TRUE;
12069     }
12070   g_mutex_unlock (&skeleton->priv->lock);
12071
12072   if (emit_changed)
12073     _foo_igen_bat_emit_changed (skeleton);
12074 }
12075
12076 static void
12077 _foo_igen_bat_on_signal_force_signal (
12078     FooiGenBat *object,
12079     GVariant *arg_force_i,
12080     GVariant *arg_force_s,
12081     GVariant *arg_force_ay,
12082     GVariant *arg_force_struct)
12083 {
12084   FooiGenBatSkeleton *skeleton = FOO_IGEN_BAT_SKELETON (object);
12085
12086   GList      *connections, *l;
12087   GVariant   *signal_variant;
12088   connections = g_dbus_interface_skeleton_get_connections (G_DBUS_INTERFACE_SKELETON (skeleton));
12089
12090   signal_variant = g_variant_ref_sink (g_variant_new ("(@i@s@ay@(i))",
12091                    arg_force_i,
12092                    arg_force_s,
12093                    arg_force_ay,
12094                    arg_force_struct));
12095   for (l = connections; l != NULL; l = l->next)
12096     {
12097       GDBusConnection *connection = l->data;
12098       g_dbus_connection_emit_signal (connection,
12099         NULL, g_dbus_interface_skeleton_get_object_path (G_DBUS_INTERFACE_SKELETON (skeleton)), "org.project.Bat", "ForceSignal",
12100         signal_variant, NULL);
12101     }
12102   g_variant_unref (signal_variant);
12103   g_list_free_full (connections, g_object_unref);
12104 }
12105
12106 static void foo_igen_bat_skeleton_iface_init (FooiGenBatIface *iface);
12107 G_DEFINE_TYPE_WITH_CODE (FooiGenBatSkeleton, foo_igen_bat_skeleton, G_TYPE_DBUS_INTERFACE_SKELETON,
12108                          G_IMPLEMENT_INTERFACE (FOO_IGEN_TYPE_BAT, foo_igen_bat_skeleton_iface_init));
12109
12110 static void
12111 foo_igen_bat_skeleton_finalize (GObject *object)
12112 {
12113   FooiGenBatSkeleton *skeleton = FOO_IGEN_BAT_SKELETON (object);
12114   guint n;
12115   for (n = 0; n < 4; n++)
12116     g_value_unset (&skeleton->priv->properties[n]);
12117   g_free (skeleton->priv->properties);
12118   g_list_free_full (skeleton->priv->changed_properties, (GDestroyNotify) _changed_property_free);
12119   if (skeleton->priv->changed_properties_idle_source != NULL)
12120     g_source_destroy (skeleton->priv->changed_properties_idle_source);
12121   g_main_context_unref (skeleton->priv->context);
12122   g_mutex_clear (&skeleton->priv->lock);
12123   G_OBJECT_CLASS (foo_igen_bat_skeleton_parent_class)->finalize (object);
12124 }
12125
12126 static void
12127 foo_igen_bat_skeleton_get_property (GObject      *object,
12128   guint         prop_id,
12129   GValue       *value,
12130   GParamSpec   *pspec)
12131 {
12132   FooiGenBatSkeleton *skeleton = FOO_IGEN_BAT_SKELETON (object);
12133   g_assert (prop_id != 0 && prop_id - 1 < 4);
12134   g_mutex_lock (&skeleton->priv->lock);
12135   g_value_copy (&skeleton->priv->properties[prop_id - 1], value);
12136   g_mutex_unlock (&skeleton->priv->lock);
12137 }
12138
12139 static gboolean
12140 _foo_igen_bat_emit_changed (gpointer user_data)
12141 {
12142   FooiGenBatSkeleton *skeleton = FOO_IGEN_BAT_SKELETON (user_data);
12143   GList *l;
12144   GVariantBuilder builder;
12145   GVariantBuilder invalidated_builder;
12146   guint num_changes;
12147
12148   g_mutex_lock (&skeleton->priv->lock);
12149   g_variant_builder_init (&builder, G_VARIANT_TYPE ("a{sv}"));
12150   g_variant_builder_init (&invalidated_builder, G_VARIANT_TYPE ("as"));
12151   for (l = skeleton->priv->changed_properties, num_changes = 0; l != NULL; l = l->next)
12152     {
12153       ChangedProperty *cp = l->data;
12154       GVariant *variant;
12155       const GValue *cur_value;
12156
12157       cur_value = &skeleton->priv->properties[cp->prop_id - 1];
12158       if (!_g_value_equal (cur_value, &cp->orig_value))
12159         {
12160           variant = g_dbus_gvalue_to_gvariant (cur_value, G_VARIANT_TYPE (cp->info->parent_struct.signature));
12161           g_variant_builder_add (&builder, "{sv}", cp->info->parent_struct.name, variant);
12162           g_variant_unref (variant);
12163           num_changes++;
12164         }
12165     }
12166   if (num_changes > 0)
12167     {
12168       GList *connections, *l;
12169       GVariant *signal_variant;
12170       signal_variant = g_variant_ref_sink (g_variant_new ("(sa{sv}as)", "org.project.Bat",
12171                                            &builder, &invalidated_builder));
12172       connections = g_dbus_interface_skeleton_get_connections (G_DBUS_INTERFACE_SKELETON (skeleton));
12173       for (l = connections; l != NULL; l = l->next)
12174         {
12175           GDBusConnection *connection = l->data;
12176
12177           g_dbus_connection_emit_signal (connection,
12178                                          NULL, g_dbus_interface_skeleton_get_object_path (G_DBUS_INTERFACE_SKELETON (skeleton)),
12179                                          "org.freedesktop.DBus.Properties",
12180                                          "PropertiesChanged",
12181                                          signal_variant,
12182                                          NULL);
12183         }
12184       g_variant_unref (signal_variant);
12185       g_list_free_full (connections, g_object_unref);
12186     }
12187   else
12188     {
12189       g_variant_builder_clear (&builder);
12190       g_variant_builder_clear (&invalidated_builder);
12191     }
12192   g_list_free_full (skeleton->priv->changed_properties, (GDestroyNotify) _changed_property_free);
12193   skeleton->priv->changed_properties = NULL;
12194   skeleton->priv->changed_properties_idle_source = NULL;
12195   g_mutex_unlock (&skeleton->priv->lock);
12196   return FALSE;
12197 }
12198
12199 static void
12200 _foo_igen_bat_schedule_emit_changed (FooiGenBatSkeleton *skeleton, const _ExtendedGDBusPropertyInfo *info, guint prop_id, const GValue *orig_value)
12201 {
12202   ChangedProperty *cp;
12203   GList *l;
12204   cp = NULL;
12205   for (l = skeleton->priv->changed_properties; l != NULL; l = l->next)
12206     {
12207       ChangedProperty *i_cp = l->data;
12208       if (i_cp->info == info)
12209         {
12210           cp = i_cp;
12211           break;
12212         }
12213     }
12214   if (cp == NULL)
12215     {
12216       cp = g_new0 (ChangedProperty, 1);
12217       cp->prop_id = prop_id;
12218       cp->info = info;
12219       skeleton->priv->changed_properties = g_list_prepend (skeleton->priv->changed_properties, cp);
12220       g_value_init (&cp->orig_value, G_VALUE_TYPE (orig_value));
12221       g_value_copy (orig_value, &cp->orig_value);
12222     }
12223 }
12224
12225 static void
12226 foo_igen_bat_skeleton_notify (GObject      *object,
12227   GParamSpec *pspec)
12228 {
12229   FooiGenBatSkeleton *skeleton = FOO_IGEN_BAT_SKELETON (object);
12230   g_mutex_lock (&skeleton->priv->lock);
12231   if (skeleton->priv->changed_properties != NULL &&
12232       skeleton->priv->changed_properties_idle_source == NULL)
12233     {
12234       skeleton->priv->changed_properties_idle_source = g_idle_source_new ();
12235       g_source_set_priority (skeleton->priv->changed_properties_idle_source, G_PRIORITY_DEFAULT);
12236       g_source_set_callback (skeleton->priv->changed_properties_idle_source, _foo_igen_bat_emit_changed, g_object_ref (skeleton), (GDestroyNotify) g_object_unref);
12237       g_source_attach (skeleton->priv->changed_properties_idle_source, skeleton->priv->context);
12238       g_source_unref (skeleton->priv->changed_properties_idle_source);
12239     }
12240   g_mutex_unlock (&skeleton->priv->lock);
12241 }
12242
12243 static void
12244 foo_igen_bat_skeleton_set_property (GObject      *object,
12245   guint         prop_id,
12246   const GValue *value,
12247   GParamSpec   *pspec)
12248 {
12249   FooiGenBatSkeleton *skeleton = FOO_IGEN_BAT_SKELETON (object);
12250   g_assert (prop_id != 0 && prop_id - 1 < 4);
12251   g_mutex_lock (&skeleton->priv->lock);
12252   g_object_freeze_notify (object);
12253   if (!_g_value_equal (value, &skeleton->priv->properties[prop_id - 1]))
12254     {
12255       if (g_dbus_interface_skeleton_get_connection (G_DBUS_INTERFACE_SKELETON (skeleton)) != NULL)
12256         _foo_igen_bat_schedule_emit_changed (skeleton, _foo_igen_bat_property_info_pointers[prop_id - 1], prop_id, &skeleton->priv->properties[prop_id - 1]);
12257       g_value_copy (value, &skeleton->priv->properties[prop_id - 1]);
12258       g_object_notify_by_pspec (object, pspec);
12259     }
12260   g_mutex_unlock (&skeleton->priv->lock);
12261   g_object_thaw_notify (object);
12262 }
12263
12264 static void
12265 foo_igen_bat_skeleton_init (FooiGenBatSkeleton *skeleton)
12266 {
12267   skeleton->priv = G_TYPE_INSTANCE_GET_PRIVATE (skeleton, FOO_IGEN_TYPE_BAT_SKELETON, FooiGenBatSkeletonPrivate);
12268   g_mutex_init (&skeleton->priv->lock);
12269   skeleton->priv->context = g_main_context_ref_thread_default ();
12270   skeleton->priv->properties = g_new0 (GValue, 4);
12271   g_value_init (&skeleton->priv->properties[0], G_TYPE_VARIANT);
12272   g_value_init (&skeleton->priv->properties[1], G_TYPE_VARIANT);
12273   g_value_init (&skeleton->priv->properties[2], G_TYPE_VARIANT);
12274   g_value_init (&skeleton->priv->properties[3], G_TYPE_VARIANT);
12275 }
12276
12277 static GVariant *
12278 foo_igen_bat_skeleton_get_force_i (FooiGenBat *object)
12279 {
12280   FooiGenBatSkeleton *skeleton = FOO_IGEN_BAT_SKELETON (object);
12281   GVariant *value;
12282   g_mutex_lock (&skeleton->priv->lock);
12283   value = g_value_get_variant (&(skeleton->priv->properties[0]));
12284   g_mutex_unlock (&skeleton->priv->lock);
12285   return value;
12286 }
12287
12288 static GVariant *
12289 foo_igen_bat_skeleton_get_force_s (FooiGenBat *object)
12290 {
12291   FooiGenBatSkeleton *skeleton = FOO_IGEN_BAT_SKELETON (object);
12292   GVariant *value;
12293   g_mutex_lock (&skeleton->priv->lock);
12294   value = g_value_get_variant (&(skeleton->priv->properties[1]));
12295   g_mutex_unlock (&skeleton->priv->lock);
12296   return value;
12297 }
12298
12299 static GVariant *
12300 foo_igen_bat_skeleton_get_force_ay (FooiGenBat *object)
12301 {
12302   FooiGenBatSkeleton *skeleton = FOO_IGEN_BAT_SKELETON (object);
12303   GVariant *value;
12304   g_mutex_lock (&skeleton->priv->lock);
12305   value = g_value_get_variant (&(skeleton->priv->properties[2]));
12306   g_mutex_unlock (&skeleton->priv->lock);
12307   return value;
12308 }
12309
12310 static GVariant *
12311 foo_igen_bat_skeleton_get_force_struct (FooiGenBat *object)
12312 {
12313   FooiGenBatSkeleton *skeleton = FOO_IGEN_BAT_SKELETON (object);
12314   GVariant *value;
12315   g_mutex_lock (&skeleton->priv->lock);
12316   value = g_value_get_variant (&(skeleton->priv->properties[3]));
12317   g_mutex_unlock (&skeleton->priv->lock);
12318   return value;
12319 }
12320
12321 static void
12322 foo_igen_bat_skeleton_class_init (FooiGenBatSkeletonClass *klass)
12323 {
12324   GObjectClass *gobject_class;
12325   GDBusInterfaceSkeletonClass *skeleton_class;
12326
12327   g_type_class_add_private (klass, sizeof (FooiGenBatSkeletonPrivate));
12328
12329   gobject_class = G_OBJECT_CLASS (klass);
12330   gobject_class->finalize = foo_igen_bat_skeleton_finalize;
12331   gobject_class->get_property = foo_igen_bat_skeleton_get_property;
12332   gobject_class->set_property = foo_igen_bat_skeleton_set_property;
12333   gobject_class->notify       = foo_igen_bat_skeleton_notify;
12334
12335
12336   foo_igen_bat_override_properties (gobject_class, 1);
12337
12338   skeleton_class = G_DBUS_INTERFACE_SKELETON_CLASS (klass);
12339   skeleton_class->get_info = foo_igen_bat_skeleton_dbus_interface_get_info;
12340   skeleton_class->get_properties = foo_igen_bat_skeleton_dbus_interface_get_properties;
12341   skeleton_class->flush = foo_igen_bat_skeleton_dbus_interface_flush;
12342   skeleton_class->get_vtable = foo_igen_bat_skeleton_dbus_interface_get_vtable;
12343 }
12344
12345 static void
12346 foo_igen_bat_skeleton_iface_init (FooiGenBatIface *iface)
12347 {
12348   iface->force_signal = _foo_igen_bat_on_signal_force_signal;
12349   iface->get_force_i = foo_igen_bat_skeleton_get_force_i;
12350   iface->get_force_s = foo_igen_bat_skeleton_get_force_s;
12351   iface->get_force_ay = foo_igen_bat_skeleton_get_force_ay;
12352   iface->get_force_struct = foo_igen_bat_skeleton_get_force_struct;
12353 }
12354
12355 /**
12356  * foo_igen_bat_skeleton_new:
12357  *
12358  * Creates a skeleton object for the D-Bus interface <link linkend="gdbus-interface-org-project-Bat.top_of_page">org.project.Bat</link>.
12359  *
12360  * Returns: (transfer full) (type FooiGenBatSkeleton): The skeleton object.
12361  */
12362 FooiGenBat *
12363 foo_igen_bat_skeleton_new (void)
12364 {
12365   return FOO_IGEN_BAT (g_object_new (FOO_IGEN_TYPE_BAT_SKELETON, NULL));
12366 }
12367
12368 /* ------------------------------------------------------------------------
12369  * Code for interface org.project.Authorize
12370  * ------------------------------------------------------------------------
12371  */
12372
12373 /**
12374  * SECTION:FooiGenAuthorize
12375  * @title: FooiGenAuthorize
12376  * @short_description: Generated C code for the org.project.Authorize D-Bus interface
12377  *
12378  * This section contains code for working with the <link linkend="gdbus-interface-org-project-Authorize.top_of_page">org.project.Authorize</link> D-Bus interface in C.
12379  */
12380
12381 /* ---- Introspection data for org.project.Authorize ---- */
12382
12383 static const _ExtendedGDBusMethodInfo _foo_igen_authorize_method_info_check_not_authorized =
12384 {
12385   {
12386     -1,
12387     "CheckNotAuthorized",
12388     NULL,
12389     NULL,
12390     NULL
12391   },
12392   "handle-check-not-authorized",
12393   FALSE
12394 };
12395
12396 static const _ExtendedGDBusMethodInfo _foo_igen_authorize_method_info_check_authorized =
12397 {
12398   {
12399     -1,
12400     "CheckAuthorized",
12401     NULL,
12402     NULL,
12403     NULL
12404   },
12405   "handle-check-authorized",
12406   FALSE
12407 };
12408
12409 static const _ExtendedGDBusMethodInfo _foo_igen_authorize_method_info_check_not_authorized_from_object =
12410 {
12411   {
12412     -1,
12413     "CheckNotAuthorizedFromObject",
12414     NULL,
12415     NULL,
12416     NULL
12417   },
12418   "handle-check-not-authorized-from-object",
12419   FALSE
12420 };
12421
12422 static const _ExtendedGDBusMethodInfo * const _foo_igen_authorize_method_info_pointers[] =
12423 {
12424   &_foo_igen_authorize_method_info_check_not_authorized,
12425   &_foo_igen_authorize_method_info_check_authorized,
12426   &_foo_igen_authorize_method_info_check_not_authorized_from_object,
12427   NULL
12428 };
12429
12430 static const _ExtendedGDBusInterfaceInfo _foo_igen_authorize_interface_info =
12431 {
12432   {
12433     -1,
12434     "org.project.Authorize",
12435     (GDBusMethodInfo **) &_foo_igen_authorize_method_info_pointers,
12436     NULL,
12437     NULL,
12438     NULL
12439   },
12440   "authorize",
12441 };
12442
12443
12444 /**
12445  * foo_igen_authorize_interface_info:
12446  *
12447  * Gets a machine-readable description of the <link linkend="gdbus-interface-org-project-Authorize.top_of_page">org.project.Authorize</link> D-Bus interface.
12448  *
12449  * Returns: (transfer none): A #GDBusInterfaceInfo. Do not free.
12450  */
12451 GDBusInterfaceInfo *
12452 foo_igen_authorize_interface_info (void)
12453 {
12454   return (GDBusInterfaceInfo *) &_foo_igen_authorize_interface_info;
12455 }
12456
12457 /**
12458  * foo_igen_authorize_override_properties:
12459  * @klass: The class structure for a #GObject<!-- -->-derived class.
12460  * @property_id_begin: The property id to assign to the first overridden property.
12461  *
12462  * Overrides all #GObject properties in the #FooiGenAuthorize interface for a concrete class.
12463  * The properties are overridden in the order they are defined.
12464  *
12465  * Returns: The last property id.
12466  */
12467 guint
12468 foo_igen_authorize_override_properties (GObjectClass *klass, guint property_id_begin)
12469 {
12470   return property_id_begin - 1;
12471 }
12472
12473
12474
12475 /**
12476  * FooiGenAuthorize:
12477  *
12478  * Abstract interface type for the D-Bus interface <link linkend="gdbus-interface-org-project-Authorize.top_of_page">org.project.Authorize</link>.
12479  */
12480
12481 /**
12482  * FooiGenAuthorizeIface:
12483  * @parent_iface: The parent interface.
12484  * @handle_check_authorized: Handler for the #FooiGenAuthorize::handle-check-authorized signal.
12485  * @handle_check_not_authorized: Handler for the #FooiGenAuthorize::handle-check-not-authorized signal.
12486  * @handle_check_not_authorized_from_object: Handler for the #FooiGenAuthorize::handle-check-not-authorized-from-object signal.
12487  *
12488  * Virtual table for the D-Bus interface <link linkend="gdbus-interface-org-project-Authorize.top_of_page">org.project.Authorize</link>.
12489  */
12490
12491 static void
12492 foo_igen_authorize_default_init (FooiGenAuthorizeIface *iface)
12493 {
12494   /* GObject signals for incoming D-Bus method calls: */
12495   /**
12496    * FooiGenAuthorize::handle-check-not-authorized:
12497    * @object: A #FooiGenAuthorize.
12498    * @invocation: A #GDBusMethodInvocation.
12499    *
12500    * Signal emitted when a remote caller is invoking the <link linkend="gdbus-method-org-project-Authorize.CheckNotAuthorized">CheckNotAuthorized()</link> D-Bus method.
12501    *
12502    * If a signal handler returns %TRUE, it means the signal handler will handle the invocation (e.g. take a reference to @invocation and eventually call foo_igen_authorize_complete_check_not_authorized() or e.g. g_dbus_method_invocation_return_error() on it) and no order signal handlers will run. If no signal handler handles the invocation, the %G_DBUS_ERROR_UNKNOWN_METHOD error is returned.
12503    *
12504    * Returns: %TRUE if the invocation was handled, %FALSE to let other signal handlers run.
12505    */
12506   g_signal_new ("handle-check-not-authorized",
12507     G_TYPE_FROM_INTERFACE (iface),
12508     G_SIGNAL_RUN_LAST,
12509     G_STRUCT_OFFSET (FooiGenAuthorizeIface, handle_check_not_authorized),
12510     g_signal_accumulator_true_handled,
12511     NULL,
12512     g_cclosure_marshal_generic,
12513     G_TYPE_BOOLEAN,
12514     1,
12515     G_TYPE_DBUS_METHOD_INVOCATION);
12516
12517   /**
12518    * FooiGenAuthorize::handle-check-authorized:
12519    * @object: A #FooiGenAuthorize.
12520    * @invocation: A #GDBusMethodInvocation.
12521    *
12522    * Signal emitted when a remote caller is invoking the <link linkend="gdbus-method-org-project-Authorize.CheckAuthorized">CheckAuthorized()</link> D-Bus method.
12523    *
12524    * If a signal handler returns %TRUE, it means the signal handler will handle the invocation (e.g. take a reference to @invocation and eventually call foo_igen_authorize_complete_check_authorized() or e.g. g_dbus_method_invocation_return_error() on it) and no order signal handlers will run. If no signal handler handles the invocation, the %G_DBUS_ERROR_UNKNOWN_METHOD error is returned.
12525    *
12526    * Returns: %TRUE if the invocation was handled, %FALSE to let other signal handlers run.
12527    */
12528   g_signal_new ("handle-check-authorized",
12529     G_TYPE_FROM_INTERFACE (iface),
12530     G_SIGNAL_RUN_LAST,
12531     G_STRUCT_OFFSET (FooiGenAuthorizeIface, handle_check_authorized),
12532     g_signal_accumulator_true_handled,
12533     NULL,
12534     g_cclosure_marshal_generic,
12535     G_TYPE_BOOLEAN,
12536     1,
12537     G_TYPE_DBUS_METHOD_INVOCATION);
12538
12539   /**
12540    * FooiGenAuthorize::handle-check-not-authorized-from-object:
12541    * @object: A #FooiGenAuthorize.
12542    * @invocation: A #GDBusMethodInvocation.
12543    *
12544    * Signal emitted when a remote caller is invoking the <link linkend="gdbus-method-org-project-Authorize.CheckNotAuthorizedFromObject">CheckNotAuthorizedFromObject()</link> D-Bus method.
12545    *
12546    * If a signal handler returns %TRUE, it means the signal handler will handle the invocation (e.g. take a reference to @invocation and eventually call foo_igen_authorize_complete_check_not_authorized_from_object() or e.g. g_dbus_method_invocation_return_error() on it) and no order signal handlers will run. If no signal handler handles the invocation, the %G_DBUS_ERROR_UNKNOWN_METHOD error is returned.
12547    *
12548    * Returns: %TRUE if the invocation was handled, %FALSE to let other signal handlers run.
12549    */
12550   g_signal_new ("handle-check-not-authorized-from-object",
12551     G_TYPE_FROM_INTERFACE (iface),
12552     G_SIGNAL_RUN_LAST,
12553     G_STRUCT_OFFSET (FooiGenAuthorizeIface, handle_check_not_authorized_from_object),
12554     g_signal_accumulator_true_handled,
12555     NULL,
12556     g_cclosure_marshal_generic,
12557     G_TYPE_BOOLEAN,
12558     1,
12559     G_TYPE_DBUS_METHOD_INVOCATION);
12560
12561 }
12562
12563 typedef FooiGenAuthorizeIface FooiGenAuthorizeInterface;
12564 G_DEFINE_INTERFACE (FooiGenAuthorize, foo_igen_authorize, G_TYPE_OBJECT);
12565
12566 /**
12567  * foo_igen_authorize_call_check_not_authorized:
12568  * @proxy: A #FooiGenAuthorizeProxy.
12569  * @cancellable: (allow-none): A #GCancellable or %NULL.
12570  * @callback: A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
12571  * @user_data: User data to pass to @callback.
12572  *
12573  * Asynchronously invokes the <link linkend="gdbus-method-org-project-Authorize.CheckNotAuthorized">CheckNotAuthorized()</link> D-Bus method on @proxy.
12574  * When the operation is finished, @callback will be invoked in the <link linkend="g-main-context-push-thread-default">thread-default main loop</link> of the thread you are calling this method from.
12575  * You can then call foo_igen_authorize_call_check_not_authorized_finish() to get the result of the operation.
12576  *
12577  * See foo_igen_authorize_call_check_not_authorized_sync() for the synchronous, blocking version of this method.
12578  */
12579 void
12580 foo_igen_authorize_call_check_not_authorized (
12581     FooiGenAuthorize *proxy,
12582     GCancellable *cancellable,
12583     GAsyncReadyCallback callback,
12584     gpointer user_data)
12585 {
12586   g_dbus_proxy_call (G_DBUS_PROXY (proxy),
12587     "CheckNotAuthorized",
12588     g_variant_new ("()"),
12589     G_DBUS_CALL_FLAGS_NONE,
12590     -1,
12591     cancellable,
12592     callback,
12593     user_data);
12594 }
12595
12596 /**
12597  * foo_igen_authorize_call_check_not_authorized_finish:
12598  * @proxy: A #FooiGenAuthorizeProxy.
12599  * @res: The #GAsyncResult obtained from the #GAsyncReadyCallback passed to foo_igen_authorize_call_check_not_authorized().
12600  * @error: Return location for error or %NULL.
12601  *
12602  * Finishes an operation started with foo_igen_authorize_call_check_not_authorized().
12603  *
12604  * Returns: (skip): %TRUE if the call succeded, %FALSE if @error is set.
12605  */
12606 gboolean
12607 foo_igen_authorize_call_check_not_authorized_finish (
12608     FooiGenAuthorize *proxy,
12609     GAsyncResult *res,
12610     GError **error)
12611 {
12612   GVariant *_ret;
12613   _ret = g_dbus_proxy_call_finish (G_DBUS_PROXY (proxy), res, error);
12614   if (_ret == NULL)
12615     goto _out;
12616   g_variant_get (_ret,
12617                  "()");
12618   g_variant_unref (_ret);
12619 _out:
12620   return _ret != NULL;
12621 }
12622
12623 /**
12624  * foo_igen_authorize_call_check_not_authorized_sync:
12625  * @proxy: A #FooiGenAuthorizeProxy.
12626  * @cancellable: (allow-none): A #GCancellable or %NULL.
12627  * @error: Return location for error or %NULL.
12628  *
12629  * Synchronously invokes the <link linkend="gdbus-method-org-project-Authorize.CheckNotAuthorized">CheckNotAuthorized()</link> D-Bus method on @proxy. The calling thread is blocked until a reply is received.
12630  *
12631  * See foo_igen_authorize_call_check_not_authorized() for the asynchronous version of this method.
12632  *
12633  * Returns: (skip): %TRUE if the call succeded, %FALSE if @error is set.
12634  */
12635 gboolean
12636 foo_igen_authorize_call_check_not_authorized_sync (
12637     FooiGenAuthorize *proxy,
12638     GCancellable *cancellable,
12639     GError **error)
12640 {
12641   GVariant *_ret;
12642   _ret = g_dbus_proxy_call_sync (G_DBUS_PROXY (proxy),
12643     "CheckNotAuthorized",
12644     g_variant_new ("()"),
12645     G_DBUS_CALL_FLAGS_NONE,
12646     -1,
12647     cancellable,
12648     error);
12649   if (_ret == NULL)
12650     goto _out;
12651   g_variant_get (_ret,
12652                  "()");
12653   g_variant_unref (_ret);
12654 _out:
12655   return _ret != NULL;
12656 }
12657
12658 /**
12659  * foo_igen_authorize_call_check_authorized:
12660  * @proxy: A #FooiGenAuthorizeProxy.
12661  * @cancellable: (allow-none): A #GCancellable or %NULL.
12662  * @callback: A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
12663  * @user_data: User data to pass to @callback.
12664  *
12665  * Asynchronously invokes the <link linkend="gdbus-method-org-project-Authorize.CheckAuthorized">CheckAuthorized()</link> D-Bus method on @proxy.
12666  * When the operation is finished, @callback will be invoked in the <link linkend="g-main-context-push-thread-default">thread-default main loop</link> of the thread you are calling this method from.
12667  * You can then call foo_igen_authorize_call_check_authorized_finish() to get the result of the operation.
12668  *
12669  * See foo_igen_authorize_call_check_authorized_sync() for the synchronous, blocking version of this method.
12670  */
12671 void
12672 foo_igen_authorize_call_check_authorized (
12673     FooiGenAuthorize *proxy,
12674     GCancellable *cancellable,
12675     GAsyncReadyCallback callback,
12676     gpointer user_data)
12677 {
12678   g_dbus_proxy_call (G_DBUS_PROXY (proxy),
12679     "CheckAuthorized",
12680     g_variant_new ("()"),
12681     G_DBUS_CALL_FLAGS_NONE,
12682     -1,
12683     cancellable,
12684     callback,
12685     user_data);
12686 }
12687
12688 /**
12689  * foo_igen_authorize_call_check_authorized_finish:
12690  * @proxy: A #FooiGenAuthorizeProxy.
12691  * @res: The #GAsyncResult obtained from the #GAsyncReadyCallback passed to foo_igen_authorize_call_check_authorized().
12692  * @error: Return location for error or %NULL.
12693  *
12694  * Finishes an operation started with foo_igen_authorize_call_check_authorized().
12695  *
12696  * Returns: (skip): %TRUE if the call succeded, %FALSE if @error is set.
12697  */
12698 gboolean
12699 foo_igen_authorize_call_check_authorized_finish (
12700     FooiGenAuthorize *proxy,
12701     GAsyncResult *res,
12702     GError **error)
12703 {
12704   GVariant *_ret;
12705   _ret = g_dbus_proxy_call_finish (G_DBUS_PROXY (proxy), res, error);
12706   if (_ret == NULL)
12707     goto _out;
12708   g_variant_get (_ret,
12709                  "()");
12710   g_variant_unref (_ret);
12711 _out:
12712   return _ret != NULL;
12713 }
12714
12715 /**
12716  * foo_igen_authorize_call_check_authorized_sync:
12717  * @proxy: A #FooiGenAuthorizeProxy.
12718  * @cancellable: (allow-none): A #GCancellable or %NULL.
12719  * @error: Return location for error or %NULL.
12720  *
12721  * Synchronously invokes the <link linkend="gdbus-method-org-project-Authorize.CheckAuthorized">CheckAuthorized()</link> D-Bus method on @proxy. The calling thread is blocked until a reply is received.
12722  *
12723  * See foo_igen_authorize_call_check_authorized() for the asynchronous version of this method.
12724  *
12725  * Returns: (skip): %TRUE if the call succeded, %FALSE if @error is set.
12726  */
12727 gboolean
12728 foo_igen_authorize_call_check_authorized_sync (
12729     FooiGenAuthorize *proxy,
12730     GCancellable *cancellable,
12731     GError **error)
12732 {
12733   GVariant *_ret;
12734   _ret = g_dbus_proxy_call_sync (G_DBUS_PROXY (proxy),
12735     "CheckAuthorized",
12736     g_variant_new ("()"),
12737     G_DBUS_CALL_FLAGS_NONE,
12738     -1,
12739     cancellable,
12740     error);
12741   if (_ret == NULL)
12742     goto _out;
12743   g_variant_get (_ret,
12744                  "()");
12745   g_variant_unref (_ret);
12746 _out:
12747   return _ret != NULL;
12748 }
12749
12750 /**
12751  * foo_igen_authorize_call_check_not_authorized_from_object:
12752  * @proxy: A #FooiGenAuthorizeProxy.
12753  * @cancellable: (allow-none): A #GCancellable or %NULL.
12754  * @callback: A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
12755  * @user_data: User data to pass to @callback.
12756  *
12757  * Asynchronously invokes the <link linkend="gdbus-method-org-project-Authorize.CheckNotAuthorizedFromObject">CheckNotAuthorizedFromObject()</link> D-Bus method on @proxy.
12758  * When the operation is finished, @callback will be invoked in the <link linkend="g-main-context-push-thread-default">thread-default main loop</link> of the thread you are calling this method from.
12759  * You can then call foo_igen_authorize_call_check_not_authorized_from_object_finish() to get the result of the operation.
12760  *
12761  * See foo_igen_authorize_call_check_not_authorized_from_object_sync() for the synchronous, blocking version of this method.
12762  */
12763 void
12764 foo_igen_authorize_call_check_not_authorized_from_object (
12765     FooiGenAuthorize *proxy,
12766     GCancellable *cancellable,
12767     GAsyncReadyCallback callback,
12768     gpointer user_data)
12769 {
12770   g_dbus_proxy_call (G_DBUS_PROXY (proxy),
12771     "CheckNotAuthorizedFromObject",
12772     g_variant_new ("()"),
12773     G_DBUS_CALL_FLAGS_NONE,
12774     -1,
12775     cancellable,
12776     callback,
12777     user_data);
12778 }
12779
12780 /**
12781  * foo_igen_authorize_call_check_not_authorized_from_object_finish:
12782  * @proxy: A #FooiGenAuthorizeProxy.
12783  * @res: The #GAsyncResult obtained from the #GAsyncReadyCallback passed to foo_igen_authorize_call_check_not_authorized_from_object().
12784  * @error: Return location for error or %NULL.
12785  *
12786  * Finishes an operation started with foo_igen_authorize_call_check_not_authorized_from_object().
12787  *
12788  * Returns: (skip): %TRUE if the call succeded, %FALSE if @error is set.
12789  */
12790 gboolean
12791 foo_igen_authorize_call_check_not_authorized_from_object_finish (
12792     FooiGenAuthorize *proxy,
12793     GAsyncResult *res,
12794     GError **error)
12795 {
12796   GVariant *_ret;
12797   _ret = g_dbus_proxy_call_finish (G_DBUS_PROXY (proxy), res, error);
12798   if (_ret == NULL)
12799     goto _out;
12800   g_variant_get (_ret,
12801                  "()");
12802   g_variant_unref (_ret);
12803 _out:
12804   return _ret != NULL;
12805 }
12806
12807 /**
12808  * foo_igen_authorize_call_check_not_authorized_from_object_sync:
12809  * @proxy: A #FooiGenAuthorizeProxy.
12810  * @cancellable: (allow-none): A #GCancellable or %NULL.
12811  * @error: Return location for error or %NULL.
12812  *
12813  * Synchronously invokes the <link linkend="gdbus-method-org-project-Authorize.CheckNotAuthorizedFromObject">CheckNotAuthorizedFromObject()</link> D-Bus method on @proxy. The calling thread is blocked until a reply is received.
12814  *
12815  * See foo_igen_authorize_call_check_not_authorized_from_object() for the asynchronous version of this method.
12816  *
12817  * Returns: (skip): %TRUE if the call succeded, %FALSE if @error is set.
12818  */
12819 gboolean
12820 foo_igen_authorize_call_check_not_authorized_from_object_sync (
12821     FooiGenAuthorize *proxy,
12822     GCancellable *cancellable,
12823     GError **error)
12824 {
12825   GVariant *_ret;
12826   _ret = g_dbus_proxy_call_sync (G_DBUS_PROXY (proxy),
12827     "CheckNotAuthorizedFromObject",
12828     g_variant_new ("()"),
12829     G_DBUS_CALL_FLAGS_NONE,
12830     -1,
12831     cancellable,
12832     error);
12833   if (_ret == NULL)
12834     goto _out;
12835   g_variant_get (_ret,
12836                  "()");
12837   g_variant_unref (_ret);
12838 _out:
12839   return _ret != NULL;
12840 }
12841
12842 /**
12843  * foo_igen_authorize_complete_check_not_authorized:
12844  * @object: A #FooiGenAuthorize.
12845  * @invocation: (transfer full): A #GDBusMethodInvocation.
12846  *
12847  * Helper function used in service implementations to finish handling invocations of the <link linkend="gdbus-method-org-project-Authorize.CheckNotAuthorized">CheckNotAuthorized()</link> D-Bus method. If you instead want to finish handling an invocation by returning an error, use g_dbus_method_invocation_return_error() or similar.
12848  *
12849  * This method will free @invocation, you cannot use it afterwards.
12850  */
12851 void
12852 foo_igen_authorize_complete_check_not_authorized (
12853     FooiGenAuthorize *object,
12854     GDBusMethodInvocation *invocation)
12855 {
12856   g_dbus_method_invocation_return_value (invocation,
12857     g_variant_new ("()"));
12858 }
12859
12860 /**
12861  * foo_igen_authorize_complete_check_authorized:
12862  * @object: A #FooiGenAuthorize.
12863  * @invocation: (transfer full): A #GDBusMethodInvocation.
12864  *
12865  * Helper function used in service implementations to finish handling invocations of the <link linkend="gdbus-method-org-project-Authorize.CheckAuthorized">CheckAuthorized()</link> D-Bus method. If you instead want to finish handling an invocation by returning an error, use g_dbus_method_invocation_return_error() or similar.
12866  *
12867  * This method will free @invocation, you cannot use it afterwards.
12868  */
12869 void
12870 foo_igen_authorize_complete_check_authorized (
12871     FooiGenAuthorize *object,
12872     GDBusMethodInvocation *invocation)
12873 {
12874   g_dbus_method_invocation_return_value (invocation,
12875     g_variant_new ("()"));
12876 }
12877
12878 /**
12879  * foo_igen_authorize_complete_check_not_authorized_from_object:
12880  * @object: A #FooiGenAuthorize.
12881  * @invocation: (transfer full): A #GDBusMethodInvocation.
12882  *
12883  * Helper function used in service implementations to finish handling invocations of the <link linkend="gdbus-method-org-project-Authorize.CheckNotAuthorizedFromObject">CheckNotAuthorizedFromObject()</link> D-Bus method. If you instead want to finish handling an invocation by returning an error, use g_dbus_method_invocation_return_error() or similar.
12884  *
12885  * This method will free @invocation, you cannot use it afterwards.
12886  */
12887 void
12888 foo_igen_authorize_complete_check_not_authorized_from_object (
12889     FooiGenAuthorize *object,
12890     GDBusMethodInvocation *invocation)
12891 {
12892   g_dbus_method_invocation_return_value (invocation,
12893     g_variant_new ("()"));
12894 }
12895
12896 /* ------------------------------------------------------------------------ */
12897
12898 /**
12899  * FooiGenAuthorizeProxy:
12900  *
12901  * The #FooiGenAuthorizeProxy structure contains only private data and should only be accessed using the provided API.
12902  */
12903
12904 /**
12905  * FooiGenAuthorizeProxyClass:
12906  * @parent_class: The parent class.
12907  *
12908  * Class structure for #FooiGenAuthorizeProxy.
12909  */
12910
12911 struct _FooiGenAuthorizeProxyPrivate
12912 {
12913   GData *qdata;
12914 };
12915
12916 static void foo_igen_authorize_proxy_iface_init (FooiGenAuthorizeIface *iface);
12917
12918 G_DEFINE_TYPE_WITH_CODE (FooiGenAuthorizeProxy, foo_igen_authorize_proxy, G_TYPE_DBUS_PROXY,
12919                          G_IMPLEMENT_INTERFACE (FOO_IGEN_TYPE_AUTHORIZE, foo_igen_authorize_proxy_iface_init));
12920
12921 static void
12922 foo_igen_authorize_proxy_finalize (GObject *object)
12923 {
12924   FooiGenAuthorizeProxy *proxy = FOO_IGEN_AUTHORIZE_PROXY (object);
12925   g_datalist_clear (&proxy->priv->qdata);
12926   G_OBJECT_CLASS (foo_igen_authorize_proxy_parent_class)->finalize (object);
12927 }
12928
12929 static void
12930 foo_igen_authorize_proxy_get_property (GObject      *object,
12931   guint         prop_id,
12932   GValue       *value,
12933   GParamSpec   *pspec)
12934 {
12935 }
12936
12937 static void
12938 foo_igen_authorize_proxy_set_property (GObject      *object,
12939   guint         prop_id,
12940   const GValue *value,
12941   GParamSpec   *pspec)
12942 {
12943 }
12944
12945 static void
12946 foo_igen_authorize_proxy_g_signal (GDBusProxy *proxy,
12947   const gchar *sender_name,
12948   const gchar *signal_name,
12949   GVariant *parameters)
12950 {
12951   _ExtendedGDBusSignalInfo *info;
12952   GVariantIter iter;
12953   GVariant *child;
12954   GValue *paramv;
12955   guint num_params;
12956   guint n;
12957   guint signal_id;
12958   info = (_ExtendedGDBusSignalInfo *) g_dbus_interface_info_lookup_signal ((GDBusInterfaceInfo *) &_foo_igen_authorize_interface_info, signal_name);
12959   if (info == NULL)
12960     return;
12961   num_params = g_variant_n_children (parameters);
12962   paramv = g_new0 (GValue, num_params + 1);
12963   g_value_init (&paramv[0], FOO_IGEN_TYPE_AUTHORIZE);
12964   g_value_set_object (&paramv[0], proxy);
12965   g_variant_iter_init (&iter, parameters);
12966   n = 1;
12967   while ((child = g_variant_iter_next_value (&iter)) != NULL)
12968     {
12969       _ExtendedGDBusArgInfo *arg_info = (_ExtendedGDBusArgInfo *) info->parent_struct.args[n - 1];
12970       if (arg_info->use_gvariant)
12971         {
12972           g_value_init (&paramv[n], G_TYPE_VARIANT);
12973           g_value_set_variant (&paramv[n], child);
12974           n++;
12975         }
12976       else
12977         g_dbus_gvariant_to_gvalue (child, &paramv[n++]);
12978       g_variant_unref (child);
12979     }
12980   signal_id = g_signal_lookup (info->signal_name, FOO_IGEN_TYPE_AUTHORIZE);
12981   g_signal_emitv (paramv, signal_id, 0, NULL);
12982   for (n = 0; n < num_params + 1; n++)
12983     g_value_unset (&paramv[n]);
12984   g_free (paramv);
12985 }
12986
12987 static void
12988 foo_igen_authorize_proxy_g_properties_changed (GDBusProxy *_proxy,
12989   GVariant *changed_properties,
12990   const gchar *const *invalidated_properties)
12991 {
12992   FooiGenAuthorizeProxy *proxy = FOO_IGEN_AUTHORIZE_PROXY (_proxy);
12993   guint n;
12994   const gchar *key;
12995   GVariantIter *iter;
12996   _ExtendedGDBusPropertyInfo *info;
12997   g_variant_get (changed_properties, "a{sv}", &iter);
12998   while (g_variant_iter_next (iter, "{&sv}", &key, NULL))
12999     {
13000       info = (_ExtendedGDBusPropertyInfo *) g_dbus_interface_info_lookup_property ((GDBusInterfaceInfo *) &_foo_igen_authorize_interface_info, key);
13001       g_datalist_remove_data (&proxy->priv->qdata, key);
13002       if (info != NULL)
13003         g_object_notify (G_OBJECT (proxy), info->hyphen_name);
13004     }
13005   g_variant_iter_free (iter);
13006   for (n = 0; invalidated_properties[n] != NULL; n++)
13007     {
13008       info = (_ExtendedGDBusPropertyInfo *) g_dbus_interface_info_lookup_property ((GDBusInterfaceInfo *) &_foo_igen_authorize_interface_info, invalidated_properties[n]);
13009       g_datalist_remove_data (&proxy->priv->qdata, invalidated_properties[n]);
13010       if (info != NULL)
13011         g_object_notify (G_OBJECT (proxy), info->hyphen_name);
13012     }
13013 }
13014
13015 static void
13016 foo_igen_authorize_proxy_init (FooiGenAuthorizeProxy *proxy)
13017 {
13018   proxy->priv = G_TYPE_INSTANCE_GET_PRIVATE (proxy, FOO_IGEN_TYPE_AUTHORIZE_PROXY, FooiGenAuthorizeProxyPrivate);
13019   g_dbus_proxy_set_interface_info (G_DBUS_PROXY (proxy), foo_igen_authorize_interface_info ());
13020 }
13021
13022 static void
13023 foo_igen_authorize_proxy_class_init (FooiGenAuthorizeProxyClass *klass)
13024 {
13025   GObjectClass *gobject_class;
13026   GDBusProxyClass *proxy_class;
13027
13028   g_type_class_add_private (klass, sizeof (FooiGenAuthorizeProxyPrivate));
13029
13030   gobject_class = G_OBJECT_CLASS (klass);
13031   gobject_class->finalize     = foo_igen_authorize_proxy_finalize;
13032   gobject_class->get_property = foo_igen_authorize_proxy_get_property;
13033   gobject_class->set_property = foo_igen_authorize_proxy_set_property;
13034
13035   proxy_class = G_DBUS_PROXY_CLASS (klass);
13036   proxy_class->g_signal = foo_igen_authorize_proxy_g_signal;
13037   proxy_class->g_properties_changed = foo_igen_authorize_proxy_g_properties_changed;
13038
13039 }
13040
13041 static void
13042 foo_igen_authorize_proxy_iface_init (FooiGenAuthorizeIface *iface)
13043 {
13044 }
13045
13046 /**
13047  * foo_igen_authorize_proxy_new:
13048  * @connection: A #GDBusConnection.
13049  * @flags: Flags from the #GDBusProxyFlags enumeration.
13050  * @name: (allow-none): A bus name (well-known or unique) or %NULL if @connection is not a message bus connection.
13051  * @object_path: An object path.
13052  * @cancellable: (allow-none): A #GCancellable or %NULL.
13053  * @callback: A #GAsyncReadyCallback to call when the request is satisfied.
13054  * @user_data: User data to pass to @callback.
13055  *
13056  * Asynchronously creates a proxy for the D-Bus interface <link linkend="gdbus-interface-org-project-Authorize.top_of_page">org.project.Authorize</link>. See g_dbus_proxy_new() for more details.
13057  *
13058  * When the operation is finished, @callback will be invoked in the <link linkend="g-main-context-push-thread-default">thread-default main loop</link> of the thread you are calling this method from.
13059  * You can then call foo_igen_authorize_proxy_new_finish() to get the result of the operation.
13060  *
13061  * See foo_igen_authorize_proxy_new_sync() for the synchronous, blocking version of this constructor.
13062  */
13063 void
13064 foo_igen_authorize_proxy_new (
13065     GDBusConnection     *connection,
13066     GDBusProxyFlags      flags,
13067     const gchar         *name,
13068     const gchar         *object_path,
13069     GCancellable        *cancellable,
13070     GAsyncReadyCallback  callback,
13071     gpointer             user_data)
13072 {
13073   g_async_initable_new_async (FOO_IGEN_TYPE_AUTHORIZE_PROXY, G_PRIORITY_DEFAULT, cancellable, callback, user_data, "g-flags", flags, "g-name", name, "g-connection", connection, "g-object-path", object_path, "g-interface-name", "org.project.Authorize", NULL);
13074 }
13075
13076 /**
13077  * foo_igen_authorize_proxy_new_finish:
13078  * @res: The #GAsyncResult obtained from the #GAsyncReadyCallback passed to foo_igen_authorize_proxy_new().
13079  * @error: Return location for error or %NULL
13080  *
13081  * Finishes an operation started with foo_igen_authorize_proxy_new().
13082  *
13083  * Returns: (transfer full) (type FooiGenAuthorizeProxy): The constructed proxy object or %NULL if @error is set.
13084  */
13085 FooiGenAuthorize *
13086 foo_igen_authorize_proxy_new_finish (
13087     GAsyncResult        *res,
13088     GError             **error)
13089 {
13090   GObject *ret;
13091   GObject *source_object;
13092   source_object = g_async_result_get_source_object (res);
13093   ret = g_async_initable_new_finish (G_ASYNC_INITABLE (source_object), res, error);
13094   g_object_unref (source_object);
13095   if (ret != NULL)
13096     return FOO_IGEN_AUTHORIZE (ret);
13097   else
13098     return NULL;
13099 }
13100
13101 /**
13102  * foo_igen_authorize_proxy_new_sync:
13103  * @connection: A #GDBusConnection.
13104  * @flags: Flags from the #GDBusProxyFlags enumeration.
13105  * @name: (allow-none): A bus name (well-known or unique) or %NULL if @connection is not a message bus connection.
13106  * @object_path: An object path.
13107  * @cancellable: (allow-none): A #GCancellable or %NULL.
13108  * @error: Return location for error or %NULL
13109  *
13110  * Synchronously creates a proxy for the D-Bus interface <link linkend="gdbus-interface-org-project-Authorize.top_of_page">org.project.Authorize</link>. See g_dbus_proxy_new_sync() for more details.
13111  *
13112  * The calling thread is blocked until a reply is received.
13113  *
13114  * See foo_igen_authorize_proxy_new() for the asynchronous version of this constructor.
13115  *
13116  * Returns: (transfer full) (type FooiGenAuthorizeProxy): The constructed proxy object or %NULL if @error is set.
13117  */
13118 FooiGenAuthorize *
13119 foo_igen_authorize_proxy_new_sync (
13120     GDBusConnection     *connection,
13121     GDBusProxyFlags      flags,
13122     const gchar         *name,
13123     const gchar         *object_path,
13124     GCancellable        *cancellable,
13125     GError             **error)
13126 {
13127   GInitable *ret;
13128   ret = g_initable_new (FOO_IGEN_TYPE_AUTHORIZE_PROXY, cancellable, error, "g-flags", flags, "g-name", name, "g-connection", connection, "g-object-path", object_path, "g-interface-name", "org.project.Authorize", NULL);
13129   if (ret != NULL)
13130     return FOO_IGEN_AUTHORIZE (ret);
13131   else
13132     return NULL;
13133 }
13134
13135
13136 /**
13137  * foo_igen_authorize_proxy_new_for_bus:
13138  * @bus_type: A #GBusType.
13139  * @flags: Flags from the #GDBusProxyFlags enumeration.
13140  * @name: A bus name (well-known or unique).
13141  * @object_path: An object path.
13142  * @cancellable: (allow-none): A #GCancellable or %NULL.
13143  * @callback: A #GAsyncReadyCallback to call when the request is satisfied.
13144  * @user_data: User data to pass to @callback.
13145  *
13146  * Like foo_igen_authorize_proxy_new() but takes a #GBusType instead of a #GDBusConnection.
13147  *
13148  * When the operation is finished, @callback will be invoked in the <link linkend="g-main-context-push-thread-default">thread-default main loop</link> of the thread you are calling this method from.
13149  * You can then call foo_igen_authorize_proxy_new_for_bus_finish() to get the result of the operation.
13150  *
13151  * See foo_igen_authorize_proxy_new_for_bus_sync() for the synchronous, blocking version of this constructor.
13152  */
13153 void
13154 foo_igen_authorize_proxy_new_for_bus (
13155     GBusType             bus_type,
13156     GDBusProxyFlags      flags,
13157     const gchar         *name,
13158     const gchar         *object_path,
13159     GCancellable        *cancellable,
13160     GAsyncReadyCallback  callback,
13161     gpointer             user_data)
13162 {
13163   g_async_initable_new_async (FOO_IGEN_TYPE_AUTHORIZE_PROXY, G_PRIORITY_DEFAULT, cancellable, callback, user_data, "g-flags", flags, "g-name", name, "g-bus-type", bus_type, "g-object-path", object_path, "g-interface-name", "org.project.Authorize", NULL);
13164 }
13165
13166 /**
13167  * foo_igen_authorize_proxy_new_for_bus_finish:
13168  * @res: The #GAsyncResult obtained from the #GAsyncReadyCallback passed to foo_igen_authorize_proxy_new_for_bus().
13169  * @error: Return location for error or %NULL
13170  *
13171  * Finishes an operation started with foo_igen_authorize_proxy_new_for_bus().
13172  *
13173  * Returns: (transfer full) (type FooiGenAuthorizeProxy): The constructed proxy object or %NULL if @error is set.
13174  */
13175 FooiGenAuthorize *
13176 foo_igen_authorize_proxy_new_for_bus_finish (
13177     GAsyncResult        *res,
13178     GError             **error)
13179 {
13180   GObject *ret;
13181   GObject *source_object;
13182   source_object = g_async_result_get_source_object (res);
13183   ret = g_async_initable_new_finish (G_ASYNC_INITABLE (source_object), res, error);
13184   g_object_unref (source_object);
13185   if (ret != NULL)
13186     return FOO_IGEN_AUTHORIZE (ret);
13187   else
13188     return NULL;
13189 }
13190
13191 /**
13192  * foo_igen_authorize_proxy_new_for_bus_sync:
13193  * @bus_type: A #GBusType.
13194  * @flags: Flags from the #GDBusProxyFlags enumeration.
13195  * @name: A bus name (well-known or unique).
13196  * @object_path: An object path.
13197  * @cancellable: (allow-none): A #GCancellable or %NULL.
13198  * @error: Return location for error or %NULL
13199  *
13200  * Like foo_igen_authorize_proxy_new_sync() but takes a #GBusType instead of a #GDBusConnection.
13201  *
13202  * The calling thread is blocked until a reply is received.
13203  *
13204  * See foo_igen_authorize_proxy_new_for_bus() for the asynchronous version of this constructor.
13205  *
13206  * Returns: (transfer full) (type FooiGenAuthorizeProxy): The constructed proxy object or %NULL if @error is set.
13207  */
13208 FooiGenAuthorize *
13209 foo_igen_authorize_proxy_new_for_bus_sync (
13210     GBusType             bus_type,
13211     GDBusProxyFlags      flags,
13212     const gchar         *name,
13213     const gchar         *object_path,
13214     GCancellable        *cancellable,
13215     GError             **error)
13216 {
13217   GInitable *ret;
13218   ret = g_initable_new (FOO_IGEN_TYPE_AUTHORIZE_PROXY, cancellable, error, "g-flags", flags, "g-name", name, "g-bus-type", bus_type, "g-object-path", object_path, "g-interface-name", "org.project.Authorize", NULL);
13219   if (ret != NULL)
13220     return FOO_IGEN_AUTHORIZE (ret);
13221   else
13222     return NULL;
13223 }
13224
13225
13226 /* ------------------------------------------------------------------------ */
13227
13228 /**
13229  * FooiGenAuthorizeSkeleton:
13230  *
13231  * The #FooiGenAuthorizeSkeleton structure contains only private data and should only be accessed using the provided API.
13232  */
13233
13234 /**
13235  * FooiGenAuthorizeSkeletonClass:
13236  * @parent_class: The parent class.
13237  *
13238  * Class structure for #FooiGenAuthorizeSkeleton.
13239  */
13240
13241 struct _FooiGenAuthorizeSkeletonPrivate
13242 {
13243   GValue *properties;
13244   GList *changed_properties;
13245   GSource *changed_properties_idle_source;
13246   GMainContext *context;
13247   GMutex lock;
13248 };
13249
13250 static void
13251 _foo_igen_authorize_skeleton_handle_method_call (
13252   GDBusConnection *connection,
13253   const gchar *sender,
13254   const gchar *object_path,
13255   const gchar *interface_name,
13256   const gchar *method_name,
13257   GVariant *parameters,
13258   GDBusMethodInvocation *invocation,
13259   gpointer user_data)
13260 {
13261   FooiGenAuthorizeSkeleton *skeleton = FOO_IGEN_AUTHORIZE_SKELETON (user_data);
13262   _ExtendedGDBusMethodInfo *info;
13263   GVariantIter iter;
13264   GVariant *child;
13265   GValue *paramv;
13266   guint num_params;
13267   guint num_extra;
13268   guint n;
13269   guint signal_id;
13270   GValue return_value = G_VALUE_INIT;
13271   info = (_ExtendedGDBusMethodInfo *) g_dbus_method_invocation_get_method_info (invocation);
13272   g_assert (info != NULL);
13273   num_params = g_variant_n_children (parameters);
13274   num_extra = info->pass_fdlist ? 3 : 2;  paramv = g_new0 (GValue, num_params + num_extra);
13275   n = 0;
13276   g_value_init (&paramv[n], FOO_IGEN_TYPE_AUTHORIZE);
13277   g_value_set_object (&paramv[n++], skeleton);
13278   g_value_init (&paramv[n], G_TYPE_DBUS_METHOD_INVOCATION);
13279   g_value_set_object (&paramv[n++], invocation);
13280   if (info->pass_fdlist)
13281     {
13282 #ifdef G_OS_UNIX
13283       g_value_init (&paramv[n], G_TYPE_UNIX_FD_LIST);
13284       g_value_set_object (&paramv[n++], g_dbus_message_get_unix_fd_list (g_dbus_method_invocation_get_message (invocation)));
13285 #else
13286       g_assert_not_reached ();
13287 #endif
13288     }
13289   g_variant_iter_init (&iter, parameters);
13290   while ((child = g_variant_iter_next_value (&iter)) != NULL)
13291     {
13292       _ExtendedGDBusArgInfo *arg_info = (_ExtendedGDBusArgInfo *) info->parent_struct.in_args[n - num_extra];
13293       if (arg_info->use_gvariant)
13294         {
13295           g_value_init (&paramv[n], G_TYPE_VARIANT);
13296           g_value_set_variant (&paramv[n], child);
13297           n++;
13298         }
13299       else
13300         g_dbus_gvariant_to_gvalue (child, &paramv[n++]);
13301       g_variant_unref (child);
13302     }
13303   signal_id = g_signal_lookup (info->signal_name, FOO_IGEN_TYPE_AUTHORIZE);
13304   g_value_init (&return_value, G_TYPE_BOOLEAN);
13305   g_signal_emitv (paramv, signal_id, 0, &return_value);
13306   if (!g_value_get_boolean (&return_value))
13307     g_dbus_method_invocation_return_error (invocation, G_DBUS_ERROR, G_DBUS_ERROR_UNKNOWN_METHOD, "Method %s is not implemented on interface %s", method_name, interface_name);
13308   g_value_unset (&return_value);
13309   for (n = 0; n < num_params + num_extra; n++)
13310     g_value_unset (&paramv[n]);
13311   g_free (paramv);
13312 }
13313
13314 static GVariant *
13315 _foo_igen_authorize_skeleton_handle_get_property (
13316   GDBusConnection *connection,
13317   const gchar *sender,
13318   const gchar *object_path,
13319   const gchar *interface_name,
13320   const gchar *property_name,
13321   GError **error,
13322   gpointer user_data)
13323 {
13324   FooiGenAuthorizeSkeleton *skeleton = FOO_IGEN_AUTHORIZE_SKELETON (user_data);
13325   GValue value = G_VALUE_INIT;
13326   GParamSpec *pspec;
13327   _ExtendedGDBusPropertyInfo *info;
13328   GVariant *ret;
13329   ret = NULL;
13330   info = (_ExtendedGDBusPropertyInfo *) g_dbus_interface_info_lookup_property ((GDBusInterfaceInfo *) &_foo_igen_authorize_interface_info, property_name);
13331   g_assert (info != NULL);
13332   pspec = g_object_class_find_property (G_OBJECT_GET_CLASS (skeleton), info->hyphen_name);
13333   if (pspec == NULL)
13334     {
13335       g_set_error (error, G_DBUS_ERROR, G_DBUS_ERROR_INVALID_ARGS, "No property with name %s", property_name);
13336     }
13337   else
13338     {
13339       g_value_init (&value, pspec->value_type);
13340       g_object_get_property (G_OBJECT (skeleton), info->hyphen_name, &value);
13341       ret = g_dbus_gvalue_to_gvariant (&value, G_VARIANT_TYPE (info->parent_struct.signature));
13342       g_value_unset (&value);
13343     }
13344   return ret;
13345 }
13346
13347 static gboolean
13348 _foo_igen_authorize_skeleton_handle_set_property (
13349   GDBusConnection *connection,
13350   const gchar *sender,
13351   const gchar *object_path,
13352   const gchar *interface_name,
13353   const gchar *property_name,
13354   GVariant *variant,
13355   GError **error,
13356   gpointer user_data)
13357 {
13358   FooiGenAuthorizeSkeleton *skeleton = FOO_IGEN_AUTHORIZE_SKELETON (user_data);
13359   GValue value = G_VALUE_INIT;
13360   GParamSpec *pspec;
13361   _ExtendedGDBusPropertyInfo *info;
13362   gboolean ret;
13363   ret = FALSE;
13364   info = (_ExtendedGDBusPropertyInfo *) g_dbus_interface_info_lookup_property ((GDBusInterfaceInfo *) &_foo_igen_authorize_interface_info, property_name);
13365   g_assert (info != NULL);
13366   pspec = g_object_class_find_property (G_OBJECT_GET_CLASS (skeleton), info->hyphen_name);
13367   if (pspec == NULL)
13368     {
13369       g_set_error (error, G_DBUS_ERROR, G_DBUS_ERROR_INVALID_ARGS, "No property with name %s", property_name);
13370     }
13371   else
13372     {
13373       if (info->use_gvariant)
13374         g_value_set_variant (&value, variant);
13375       else
13376         g_dbus_gvariant_to_gvalue (variant, &value);
13377       g_object_set_property (G_OBJECT (skeleton), info->hyphen_name, &value);
13378       g_value_unset (&value);
13379       ret = TRUE;
13380     }
13381   return ret;
13382 }
13383
13384 static const GDBusInterfaceVTable _foo_igen_authorize_skeleton_vtable =
13385 {
13386   _foo_igen_authorize_skeleton_handle_method_call,
13387   _foo_igen_authorize_skeleton_handle_get_property,
13388   _foo_igen_authorize_skeleton_handle_set_property
13389 };
13390
13391 static GDBusInterfaceInfo *
13392 foo_igen_authorize_skeleton_dbus_interface_get_info (GDBusInterfaceSkeleton *skeleton)
13393 {
13394   return foo_igen_authorize_interface_info ();
13395 }
13396
13397 static GDBusInterfaceVTable *
13398 foo_igen_authorize_skeleton_dbus_interface_get_vtable (GDBusInterfaceSkeleton *skeleton)
13399 {
13400   return (GDBusInterfaceVTable *) &_foo_igen_authorize_skeleton_vtable;
13401 }
13402
13403 static GVariant *
13404 foo_igen_authorize_skeleton_dbus_interface_get_properties (GDBusInterfaceSkeleton *_skeleton)
13405 {
13406   FooiGenAuthorizeSkeleton *skeleton = FOO_IGEN_AUTHORIZE_SKELETON (_skeleton);
13407
13408   GVariantBuilder builder;
13409   guint n;
13410   g_variant_builder_init (&builder, G_VARIANT_TYPE ("a{sv}"));
13411   if (_foo_igen_authorize_interface_info.parent_struct.properties == NULL)
13412     goto out;
13413   for (n = 0; _foo_igen_authorize_interface_info.parent_struct.properties[n] != NULL; n++)
13414     {
13415       GDBusPropertyInfo *info = _foo_igen_authorize_interface_info.parent_struct.properties[n];
13416       if (info->flags & G_DBUS_PROPERTY_INFO_FLAGS_READABLE)
13417         {
13418           GVariant *value;
13419           value = _foo_igen_authorize_skeleton_handle_get_property (g_dbus_interface_skeleton_get_connection (G_DBUS_INTERFACE_SKELETON (skeleton)), NULL, g_dbus_interface_skeleton_get_object_path (G_DBUS_INTERFACE_SKELETON (skeleton)), "org.project.Authorize", info->name, NULL, skeleton);
13420           if (value != NULL)
13421             {
13422               g_variant_take_ref (value);
13423               g_variant_builder_add (&builder, "{sv}", info->name, value);
13424               g_variant_unref (value);
13425             }
13426         }
13427     }
13428 out:
13429   return g_variant_builder_end (&builder);
13430 }
13431
13432 static void
13433 foo_igen_authorize_skeleton_dbus_interface_flush (GDBusInterfaceSkeleton *_skeleton)
13434 {
13435 }
13436
13437 static void foo_igen_authorize_skeleton_iface_init (FooiGenAuthorizeIface *iface);
13438 G_DEFINE_TYPE_WITH_CODE (FooiGenAuthorizeSkeleton, foo_igen_authorize_skeleton, G_TYPE_DBUS_INTERFACE_SKELETON,
13439                          G_IMPLEMENT_INTERFACE (FOO_IGEN_TYPE_AUTHORIZE, foo_igen_authorize_skeleton_iface_init));
13440
13441 static void
13442 foo_igen_authorize_skeleton_finalize (GObject *object)
13443 {
13444   FooiGenAuthorizeSkeleton *skeleton = FOO_IGEN_AUTHORIZE_SKELETON (object);
13445   g_list_free_full (skeleton->priv->changed_properties, (GDestroyNotify) _changed_property_free);
13446   if (skeleton->priv->changed_properties_idle_source != NULL)
13447     g_source_destroy (skeleton->priv->changed_properties_idle_source);
13448   g_main_context_unref (skeleton->priv->context);
13449   g_mutex_clear (&skeleton->priv->lock);
13450   G_OBJECT_CLASS (foo_igen_authorize_skeleton_parent_class)->finalize (object);
13451 }
13452
13453 static void
13454 foo_igen_authorize_skeleton_init (FooiGenAuthorizeSkeleton *skeleton)
13455 {
13456   skeleton->priv = G_TYPE_INSTANCE_GET_PRIVATE (skeleton, FOO_IGEN_TYPE_AUTHORIZE_SKELETON, FooiGenAuthorizeSkeletonPrivate);
13457   g_mutex_init (&skeleton->priv->lock);
13458   skeleton->priv->context = g_main_context_ref_thread_default ();
13459 }
13460
13461 static void
13462 foo_igen_authorize_skeleton_class_init (FooiGenAuthorizeSkeletonClass *klass)
13463 {
13464   GObjectClass *gobject_class;
13465   GDBusInterfaceSkeletonClass *skeleton_class;
13466
13467   g_type_class_add_private (klass, sizeof (FooiGenAuthorizeSkeletonPrivate));
13468
13469   gobject_class = G_OBJECT_CLASS (klass);
13470   gobject_class->finalize = foo_igen_authorize_skeleton_finalize;
13471
13472   skeleton_class = G_DBUS_INTERFACE_SKELETON_CLASS (klass);
13473   skeleton_class->get_info = foo_igen_authorize_skeleton_dbus_interface_get_info;
13474   skeleton_class->get_properties = foo_igen_authorize_skeleton_dbus_interface_get_properties;
13475   skeleton_class->flush = foo_igen_authorize_skeleton_dbus_interface_flush;
13476   skeleton_class->get_vtable = foo_igen_authorize_skeleton_dbus_interface_get_vtable;
13477 }
13478
13479 static void
13480 foo_igen_authorize_skeleton_iface_init (FooiGenAuthorizeIface *iface)
13481 {
13482 }
13483
13484 /**
13485  * foo_igen_authorize_skeleton_new:
13486  *
13487  * Creates a skeleton object for the D-Bus interface <link linkend="gdbus-interface-org-project-Authorize.top_of_page">org.project.Authorize</link>.
13488  *
13489  * Returns: (transfer full) (type FooiGenAuthorizeSkeleton): The skeleton object.
13490  */
13491 FooiGenAuthorize *
13492 foo_igen_authorize_skeleton_new (void)
13493 {
13494   return FOO_IGEN_AUTHORIZE (g_object_new (FOO_IGEN_TYPE_AUTHORIZE_SKELETON, NULL));
13495 }
13496
13497 /* ------------------------------------------------------------------------
13498  * Code for interface org.project.MethodThreads
13499  * ------------------------------------------------------------------------
13500  */
13501
13502 /**
13503  * SECTION:FooiGenMethodThreads
13504  * @title: FooiGenMethodThreads
13505  * @short_description: Generated C code for the org.project.MethodThreads D-Bus interface
13506  *
13507  * This section contains code for working with the <link linkend="gdbus-interface-org-project-MethodThreads.top_of_page">org.project.MethodThreads</link> D-Bus interface in C.
13508  */
13509
13510 /* ---- Introspection data for org.project.MethodThreads ---- */
13511
13512 static const _ExtendedGDBusArgInfo _foo_igen_method_threads_method_info_get_self_OUT_ARG_self_pointer =
13513 {
13514   {
13515     -1,
13516     "self_pointer",
13517     "s",
13518     NULL
13519   },
13520   FALSE
13521 };
13522
13523 static const _ExtendedGDBusArgInfo * const _foo_igen_method_threads_method_info_get_self_OUT_ARG_pointers[] =
13524 {
13525   &_foo_igen_method_threads_method_info_get_self_OUT_ARG_self_pointer,
13526   NULL
13527 };
13528
13529 static const _ExtendedGDBusMethodInfo _foo_igen_method_threads_method_info_get_self =
13530 {
13531   {
13532     -1,
13533     "GetSelf",
13534     NULL,
13535     (GDBusArgInfo **) &_foo_igen_method_threads_method_info_get_self_OUT_ARG_pointers,
13536     NULL
13537   },
13538   "handle-get-self",
13539   FALSE
13540 };
13541
13542 static const _ExtendedGDBusMethodInfo * const _foo_igen_method_threads_method_info_pointers[] =
13543 {
13544   &_foo_igen_method_threads_method_info_get_self,
13545   NULL
13546 };
13547
13548 static const _ExtendedGDBusInterfaceInfo _foo_igen_method_threads_interface_info =
13549 {
13550   {
13551     -1,
13552     "org.project.MethodThreads",
13553     (GDBusMethodInfo **) &_foo_igen_method_threads_method_info_pointers,
13554     NULL,
13555     NULL,
13556     NULL
13557   },
13558   "method-threads",
13559 };
13560
13561
13562 /**
13563  * foo_igen_method_threads_interface_info:
13564  *
13565  * Gets a machine-readable description of the <link linkend="gdbus-interface-org-project-MethodThreads.top_of_page">org.project.MethodThreads</link> D-Bus interface.
13566  *
13567  * Returns: (transfer none): A #GDBusInterfaceInfo. Do not free.
13568  */
13569 GDBusInterfaceInfo *
13570 foo_igen_method_threads_interface_info (void)
13571 {
13572   return (GDBusInterfaceInfo *) &_foo_igen_method_threads_interface_info;
13573 }
13574
13575 /**
13576  * foo_igen_method_threads_override_properties:
13577  * @klass: The class structure for a #GObject<!-- -->-derived class.
13578  * @property_id_begin: The property id to assign to the first overridden property.
13579  *
13580  * Overrides all #GObject properties in the #FooiGenMethodThreads interface for a concrete class.
13581  * The properties are overridden in the order they are defined.
13582  *
13583  * Returns: The last property id.
13584  */
13585 guint
13586 foo_igen_method_threads_override_properties (GObjectClass *klass, guint property_id_begin)
13587 {
13588   return property_id_begin - 1;
13589 }
13590
13591
13592
13593 /**
13594  * FooiGenMethodThreads:
13595  *
13596  * Abstract interface type for the D-Bus interface <link linkend="gdbus-interface-org-project-MethodThreads.top_of_page">org.project.MethodThreads</link>.
13597  */
13598
13599 /**
13600  * FooiGenMethodThreadsIface:
13601  * @parent_iface: The parent interface.
13602  * @handle_get_self: Handler for the #FooiGenMethodThreads::handle-get-self signal.
13603  *
13604  * Virtual table for the D-Bus interface <link linkend="gdbus-interface-org-project-MethodThreads.top_of_page">org.project.MethodThreads</link>.
13605  */
13606
13607 static void
13608 foo_igen_method_threads_default_init (FooiGenMethodThreadsIface *iface)
13609 {
13610   /* GObject signals for incoming D-Bus method calls: */
13611   /**
13612    * FooiGenMethodThreads::handle-get-self:
13613    * @object: A #FooiGenMethodThreads.
13614    * @invocation: A #GDBusMethodInvocation.
13615    *
13616    * Signal emitted when a remote caller is invoking the <link linkend="gdbus-method-org-project-MethodThreads.GetSelf">GetSelf()</link> D-Bus method.
13617    *
13618    * If a signal handler returns %TRUE, it means the signal handler will handle the invocation (e.g. take a reference to @invocation and eventually call foo_igen_method_threads_complete_get_self() or e.g. g_dbus_method_invocation_return_error() on it) and no order signal handlers will run. If no signal handler handles the invocation, the %G_DBUS_ERROR_UNKNOWN_METHOD error is returned.
13619    *
13620    * Returns: %TRUE if the invocation was handled, %FALSE to let other signal handlers run.
13621    */
13622   g_signal_new ("handle-get-self",
13623     G_TYPE_FROM_INTERFACE (iface),
13624     G_SIGNAL_RUN_LAST,
13625     G_STRUCT_OFFSET (FooiGenMethodThreadsIface, handle_get_self),
13626     g_signal_accumulator_true_handled,
13627     NULL,
13628     g_cclosure_marshal_generic,
13629     G_TYPE_BOOLEAN,
13630     1,
13631     G_TYPE_DBUS_METHOD_INVOCATION);
13632
13633 }
13634
13635 typedef FooiGenMethodThreadsIface FooiGenMethodThreadsInterface;
13636 G_DEFINE_INTERFACE (FooiGenMethodThreads, foo_igen_method_threads, G_TYPE_OBJECT);
13637
13638 /**
13639  * foo_igen_method_threads_call_get_self:
13640  * @proxy: A #FooiGenMethodThreadsProxy.
13641  * @cancellable: (allow-none): A #GCancellable or %NULL.
13642  * @callback: A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
13643  * @user_data: User data to pass to @callback.
13644  *
13645  * Asynchronously invokes the <link linkend="gdbus-method-org-project-MethodThreads.GetSelf">GetSelf()</link> D-Bus method on @proxy.
13646  * When the operation is finished, @callback will be invoked in the <link linkend="g-main-context-push-thread-default">thread-default main loop</link> of the thread you are calling this method from.
13647  * You can then call foo_igen_method_threads_call_get_self_finish() to get the result of the operation.
13648  *
13649  * See foo_igen_method_threads_call_get_self_sync() for the synchronous, blocking version of this method.
13650  */
13651 void
13652 foo_igen_method_threads_call_get_self (
13653     FooiGenMethodThreads *proxy,
13654     GCancellable *cancellable,
13655     GAsyncReadyCallback callback,
13656     gpointer user_data)
13657 {
13658   g_dbus_proxy_call (G_DBUS_PROXY (proxy),
13659     "GetSelf",
13660     g_variant_new ("()"),
13661     G_DBUS_CALL_FLAGS_NONE,
13662     -1,
13663     cancellable,
13664     callback,
13665     user_data);
13666 }
13667
13668 /**
13669  * foo_igen_method_threads_call_get_self_finish:
13670  * @proxy: A #FooiGenMethodThreadsProxy.
13671  * @out_self_pointer: (out): Return location for return parameter or %NULL to ignore.
13672  * @res: The #GAsyncResult obtained from the #GAsyncReadyCallback passed to foo_igen_method_threads_call_get_self().
13673  * @error: Return location for error or %NULL.
13674  *
13675  * Finishes an operation started with foo_igen_method_threads_call_get_self().
13676  *
13677  * Returns: (skip): %TRUE if the call succeded, %FALSE if @error is set.
13678  */
13679 gboolean
13680 foo_igen_method_threads_call_get_self_finish (
13681     FooiGenMethodThreads *proxy,
13682     gchar **out_self_pointer,
13683     GAsyncResult *res,
13684     GError **error)
13685 {
13686   GVariant *_ret;
13687   _ret = g_dbus_proxy_call_finish (G_DBUS_PROXY (proxy), res, error);
13688   if (_ret == NULL)
13689     goto _out;
13690   g_variant_get (_ret,
13691                  "(s)",
13692                  out_self_pointer);
13693   g_variant_unref (_ret);
13694 _out:
13695   return _ret != NULL;
13696 }
13697
13698 /**
13699  * foo_igen_method_threads_call_get_self_sync:
13700  * @proxy: A #FooiGenMethodThreadsProxy.
13701  * @out_self_pointer: (out): Return location for return parameter or %NULL to ignore.
13702  * @cancellable: (allow-none): A #GCancellable or %NULL.
13703  * @error: Return location for error or %NULL.
13704  *
13705  * Synchronously invokes the <link linkend="gdbus-method-org-project-MethodThreads.GetSelf">GetSelf()</link> D-Bus method on @proxy. The calling thread is blocked until a reply is received.
13706  *
13707  * See foo_igen_method_threads_call_get_self() for the asynchronous version of this method.
13708  *
13709  * Returns: (skip): %TRUE if the call succeded, %FALSE if @error is set.
13710  */
13711 gboolean
13712 foo_igen_method_threads_call_get_self_sync (
13713     FooiGenMethodThreads *proxy,
13714     gchar **out_self_pointer,
13715     GCancellable *cancellable,
13716     GError **error)
13717 {
13718   GVariant *_ret;
13719   _ret = g_dbus_proxy_call_sync (G_DBUS_PROXY (proxy),
13720     "GetSelf",
13721     g_variant_new ("()"),
13722     G_DBUS_CALL_FLAGS_NONE,
13723     -1,
13724     cancellable,
13725     error);
13726   if (_ret == NULL)
13727     goto _out;
13728   g_variant_get (_ret,
13729                  "(s)",
13730                  out_self_pointer);
13731   g_variant_unref (_ret);
13732 _out:
13733   return _ret != NULL;
13734 }
13735
13736 /**
13737  * foo_igen_method_threads_complete_get_self:
13738  * @object: A #FooiGenMethodThreads.
13739  * @invocation: (transfer full): A #GDBusMethodInvocation.
13740  * @self_pointer: Parameter to return.
13741  *
13742  * Helper function used in service implementations to finish handling invocations of the <link linkend="gdbus-method-org-project-MethodThreads.GetSelf">GetSelf()</link> D-Bus method. If you instead want to finish handling an invocation by returning an error, use g_dbus_method_invocation_return_error() or similar.
13743  *
13744  * This method will free @invocation, you cannot use it afterwards.
13745  */
13746 void
13747 foo_igen_method_threads_complete_get_self (
13748     FooiGenMethodThreads *object,
13749     GDBusMethodInvocation *invocation,
13750     const gchar *self_pointer)
13751 {
13752   g_dbus_method_invocation_return_value (invocation,
13753     g_variant_new ("(s)",
13754                    self_pointer));
13755 }
13756
13757 /* ------------------------------------------------------------------------ */
13758
13759 /**
13760  * FooiGenMethodThreadsProxy:
13761  *
13762  * The #FooiGenMethodThreadsProxy structure contains only private data and should only be accessed using the provided API.
13763  */
13764
13765 /**
13766  * FooiGenMethodThreadsProxyClass:
13767  * @parent_class: The parent class.
13768  *
13769  * Class structure for #FooiGenMethodThreadsProxy.
13770  */
13771
13772 struct _FooiGenMethodThreadsProxyPrivate
13773 {
13774   GData *qdata;
13775 };
13776
13777 static void foo_igen_method_threads_proxy_iface_init (FooiGenMethodThreadsIface *iface);
13778
13779 G_DEFINE_TYPE_WITH_CODE (FooiGenMethodThreadsProxy, foo_igen_method_threads_proxy, G_TYPE_DBUS_PROXY,
13780                          G_IMPLEMENT_INTERFACE (FOO_IGEN_TYPE_METHOD_THREADS, foo_igen_method_threads_proxy_iface_init));
13781
13782 static void
13783 foo_igen_method_threads_proxy_finalize (GObject *object)
13784 {
13785   FooiGenMethodThreadsProxy *proxy = FOO_IGEN_METHOD_THREADS_PROXY (object);
13786   g_datalist_clear (&proxy->priv->qdata);
13787   G_OBJECT_CLASS (foo_igen_method_threads_proxy_parent_class)->finalize (object);
13788 }
13789
13790 static void
13791 foo_igen_method_threads_proxy_get_property (GObject      *object,
13792   guint         prop_id,
13793   GValue       *value,
13794   GParamSpec   *pspec)
13795 {
13796 }
13797
13798 static void
13799 foo_igen_method_threads_proxy_set_property (GObject      *object,
13800   guint         prop_id,
13801   const GValue *value,
13802   GParamSpec   *pspec)
13803 {
13804 }
13805
13806 static void
13807 foo_igen_method_threads_proxy_g_signal (GDBusProxy *proxy,
13808   const gchar *sender_name,
13809   const gchar *signal_name,
13810   GVariant *parameters)
13811 {
13812   _ExtendedGDBusSignalInfo *info;
13813   GVariantIter iter;
13814   GVariant *child;
13815   GValue *paramv;
13816   guint num_params;
13817   guint n;
13818   guint signal_id;
13819   info = (_ExtendedGDBusSignalInfo *) g_dbus_interface_info_lookup_signal ((GDBusInterfaceInfo *) &_foo_igen_method_threads_interface_info, signal_name);
13820   if (info == NULL)
13821     return;
13822   num_params = g_variant_n_children (parameters);
13823   paramv = g_new0 (GValue, num_params + 1);
13824   g_value_init (&paramv[0], FOO_IGEN_TYPE_METHOD_THREADS);
13825   g_value_set_object (&paramv[0], proxy);
13826   g_variant_iter_init (&iter, parameters);
13827   n = 1;
13828   while ((child = g_variant_iter_next_value (&iter)) != NULL)
13829     {
13830       _ExtendedGDBusArgInfo *arg_info = (_ExtendedGDBusArgInfo *) info->parent_struct.args[n - 1];
13831       if (arg_info->use_gvariant)
13832         {
13833           g_value_init (&paramv[n], G_TYPE_VARIANT);
13834           g_value_set_variant (&paramv[n], child);
13835           n++;
13836         }
13837       else
13838         g_dbus_gvariant_to_gvalue (child, &paramv[n++]);
13839       g_variant_unref (child);
13840     }
13841   signal_id = g_signal_lookup (info->signal_name, FOO_IGEN_TYPE_METHOD_THREADS);
13842   g_signal_emitv (paramv, signal_id, 0, NULL);
13843   for (n = 0; n < num_params + 1; n++)
13844     g_value_unset (&paramv[n]);
13845   g_free (paramv);
13846 }
13847
13848 static void
13849 foo_igen_method_threads_proxy_g_properties_changed (GDBusProxy *_proxy,
13850   GVariant *changed_properties,
13851   const gchar *const *invalidated_properties)
13852 {
13853   FooiGenMethodThreadsProxy *proxy = FOO_IGEN_METHOD_THREADS_PROXY (_proxy);
13854   guint n;
13855   const gchar *key;
13856   GVariantIter *iter;
13857   _ExtendedGDBusPropertyInfo *info;
13858   g_variant_get (changed_properties, "a{sv}", &iter);
13859   while (g_variant_iter_next (iter, "{&sv}", &key, NULL))
13860     {
13861       info = (_ExtendedGDBusPropertyInfo *) g_dbus_interface_info_lookup_property ((GDBusInterfaceInfo *) &_foo_igen_method_threads_interface_info, key);
13862       g_datalist_remove_data (&proxy->priv->qdata, key);
13863       if (info != NULL)
13864         g_object_notify (G_OBJECT (proxy), info->hyphen_name);
13865     }
13866   g_variant_iter_free (iter);
13867   for (n = 0; invalidated_properties[n] != NULL; n++)
13868     {
13869       info = (_ExtendedGDBusPropertyInfo *) g_dbus_interface_info_lookup_property ((GDBusInterfaceInfo *) &_foo_igen_method_threads_interface_info, invalidated_properties[n]);
13870       g_datalist_remove_data (&proxy->priv->qdata, invalidated_properties[n]);
13871       if (info != NULL)
13872         g_object_notify (G_OBJECT (proxy), info->hyphen_name);
13873     }
13874 }
13875
13876 static void
13877 foo_igen_method_threads_proxy_init (FooiGenMethodThreadsProxy *proxy)
13878 {
13879   proxy->priv = G_TYPE_INSTANCE_GET_PRIVATE (proxy, FOO_IGEN_TYPE_METHOD_THREADS_PROXY, FooiGenMethodThreadsProxyPrivate);
13880   g_dbus_proxy_set_interface_info (G_DBUS_PROXY (proxy), foo_igen_method_threads_interface_info ());
13881 }
13882
13883 static void
13884 foo_igen_method_threads_proxy_class_init (FooiGenMethodThreadsProxyClass *klass)
13885 {
13886   GObjectClass *gobject_class;
13887   GDBusProxyClass *proxy_class;
13888
13889   g_type_class_add_private (klass, sizeof (FooiGenMethodThreadsProxyPrivate));
13890
13891   gobject_class = G_OBJECT_CLASS (klass);
13892   gobject_class->finalize     = foo_igen_method_threads_proxy_finalize;
13893   gobject_class->get_property = foo_igen_method_threads_proxy_get_property;
13894   gobject_class->set_property = foo_igen_method_threads_proxy_set_property;
13895
13896   proxy_class = G_DBUS_PROXY_CLASS (klass);
13897   proxy_class->g_signal = foo_igen_method_threads_proxy_g_signal;
13898   proxy_class->g_properties_changed = foo_igen_method_threads_proxy_g_properties_changed;
13899
13900 }
13901
13902 static void
13903 foo_igen_method_threads_proxy_iface_init (FooiGenMethodThreadsIface *iface)
13904 {
13905 }
13906
13907 /**
13908  * foo_igen_method_threads_proxy_new:
13909  * @connection: A #GDBusConnection.
13910  * @flags: Flags from the #GDBusProxyFlags enumeration.
13911  * @name: (allow-none): A bus name (well-known or unique) or %NULL if @connection is not a message bus connection.
13912  * @object_path: An object path.
13913  * @cancellable: (allow-none): A #GCancellable or %NULL.
13914  * @callback: A #GAsyncReadyCallback to call when the request is satisfied.
13915  * @user_data: User data to pass to @callback.
13916  *
13917  * Asynchronously creates a proxy for the D-Bus interface <link linkend="gdbus-interface-org-project-MethodThreads.top_of_page">org.project.MethodThreads</link>. See g_dbus_proxy_new() for more details.
13918  *
13919  * When the operation is finished, @callback will be invoked in the <link linkend="g-main-context-push-thread-default">thread-default main loop</link> of the thread you are calling this method from.
13920  * You can then call foo_igen_method_threads_proxy_new_finish() to get the result of the operation.
13921  *
13922  * See foo_igen_method_threads_proxy_new_sync() for the synchronous, blocking version of this constructor.
13923  */
13924 void
13925 foo_igen_method_threads_proxy_new (
13926     GDBusConnection     *connection,
13927     GDBusProxyFlags      flags,
13928     const gchar         *name,
13929     const gchar         *object_path,
13930     GCancellable        *cancellable,
13931     GAsyncReadyCallback  callback,
13932     gpointer             user_data)
13933 {
13934   g_async_initable_new_async (FOO_IGEN_TYPE_METHOD_THREADS_PROXY, G_PRIORITY_DEFAULT, cancellable, callback, user_data, "g-flags", flags, "g-name", name, "g-connection", connection, "g-object-path", object_path, "g-interface-name", "org.project.MethodThreads", NULL);
13935 }
13936
13937 /**
13938  * foo_igen_method_threads_proxy_new_finish:
13939  * @res: The #GAsyncResult obtained from the #GAsyncReadyCallback passed to foo_igen_method_threads_proxy_new().
13940  * @error: Return location for error or %NULL
13941  *
13942  * Finishes an operation started with foo_igen_method_threads_proxy_new().
13943  *
13944  * Returns: (transfer full) (type FooiGenMethodThreadsProxy): The constructed proxy object or %NULL if @error is set.
13945  */
13946 FooiGenMethodThreads *
13947 foo_igen_method_threads_proxy_new_finish (
13948     GAsyncResult        *res,
13949     GError             **error)
13950 {
13951   GObject *ret;
13952   GObject *source_object;
13953   source_object = g_async_result_get_source_object (res);
13954   ret = g_async_initable_new_finish (G_ASYNC_INITABLE (source_object), res, error);
13955   g_object_unref (source_object);
13956   if (ret != NULL)
13957     return FOO_IGEN_METHOD_THREADS (ret);
13958   else
13959     return NULL;
13960 }
13961
13962 /**
13963  * foo_igen_method_threads_proxy_new_sync:
13964  * @connection: A #GDBusConnection.
13965  * @flags: Flags from the #GDBusProxyFlags enumeration.
13966  * @name: (allow-none): A bus name (well-known or unique) or %NULL if @connection is not a message bus connection.
13967  * @object_path: An object path.
13968  * @cancellable: (allow-none): A #GCancellable or %NULL.
13969  * @error: Return location for error or %NULL
13970  *
13971  * Synchronously creates a proxy for the D-Bus interface <link linkend="gdbus-interface-org-project-MethodThreads.top_of_page">org.project.MethodThreads</link>. See g_dbus_proxy_new_sync() for more details.
13972  *
13973  * The calling thread is blocked until a reply is received.
13974  *
13975  * See foo_igen_method_threads_proxy_new() for the asynchronous version of this constructor.
13976  *
13977  * Returns: (transfer full) (type FooiGenMethodThreadsProxy): The constructed proxy object or %NULL if @error is set.
13978  */
13979 FooiGenMethodThreads *
13980 foo_igen_method_threads_proxy_new_sync (
13981     GDBusConnection     *connection,
13982     GDBusProxyFlags      flags,
13983     const gchar         *name,
13984     const gchar         *object_path,
13985     GCancellable        *cancellable,
13986     GError             **error)
13987 {
13988   GInitable *ret;
13989   ret = g_initable_new (FOO_IGEN_TYPE_METHOD_THREADS_PROXY, cancellable, error, "g-flags", flags, "g-name", name, "g-connection", connection, "g-object-path", object_path, "g-interface-name", "org.project.MethodThreads", NULL);
13990   if (ret != NULL)
13991     return FOO_IGEN_METHOD_THREADS (ret);
13992   else
13993     return NULL;
13994 }
13995
13996
13997 /**
13998  * foo_igen_method_threads_proxy_new_for_bus:
13999  * @bus_type: A #GBusType.
14000  * @flags: Flags from the #GDBusProxyFlags enumeration.
14001  * @name: A bus name (well-known or unique).
14002  * @object_path: An object path.
14003  * @cancellable: (allow-none): A #GCancellable or %NULL.
14004  * @callback: A #GAsyncReadyCallback to call when the request is satisfied.
14005  * @user_data: User data to pass to @callback.
14006  *
14007  * Like foo_igen_method_threads_proxy_new() but takes a #GBusType instead of a #GDBusConnection.
14008  *
14009  * When the operation is finished, @callback will be invoked in the <link linkend="g-main-context-push-thread-default">thread-default main loop</link> of the thread you are calling this method from.
14010  * You can then call foo_igen_method_threads_proxy_new_for_bus_finish() to get the result of the operation.
14011  *
14012  * See foo_igen_method_threads_proxy_new_for_bus_sync() for the synchronous, blocking version of this constructor.
14013  */
14014 void
14015 foo_igen_method_threads_proxy_new_for_bus (
14016     GBusType             bus_type,
14017     GDBusProxyFlags      flags,
14018     const gchar         *name,
14019     const gchar         *object_path,
14020     GCancellable        *cancellable,
14021     GAsyncReadyCallback  callback,
14022     gpointer             user_data)
14023 {
14024   g_async_initable_new_async (FOO_IGEN_TYPE_METHOD_THREADS_PROXY, G_PRIORITY_DEFAULT, cancellable, callback, user_data, "g-flags", flags, "g-name", name, "g-bus-type", bus_type, "g-object-path", object_path, "g-interface-name", "org.project.MethodThreads", NULL);
14025 }
14026
14027 /**
14028  * foo_igen_method_threads_proxy_new_for_bus_finish:
14029  * @res: The #GAsyncResult obtained from the #GAsyncReadyCallback passed to foo_igen_method_threads_proxy_new_for_bus().
14030  * @error: Return location for error or %NULL
14031  *
14032  * Finishes an operation started with foo_igen_method_threads_proxy_new_for_bus().
14033  *
14034  * Returns: (transfer full) (type FooiGenMethodThreadsProxy): The constructed proxy object or %NULL if @error is set.
14035  */
14036 FooiGenMethodThreads *
14037 foo_igen_method_threads_proxy_new_for_bus_finish (
14038     GAsyncResult        *res,
14039     GError             **error)
14040 {
14041   GObject *ret;
14042   GObject *source_object;
14043   source_object = g_async_result_get_source_object (res);
14044   ret = g_async_initable_new_finish (G_ASYNC_INITABLE (source_object), res, error);
14045   g_object_unref (source_object);
14046   if (ret != NULL)
14047     return FOO_IGEN_METHOD_THREADS (ret);
14048   else
14049     return NULL;
14050 }
14051
14052 /**
14053  * foo_igen_method_threads_proxy_new_for_bus_sync:
14054  * @bus_type: A #GBusType.
14055  * @flags: Flags from the #GDBusProxyFlags enumeration.
14056  * @name: A bus name (well-known or unique).
14057  * @object_path: An object path.
14058  * @cancellable: (allow-none): A #GCancellable or %NULL.
14059  * @error: Return location for error or %NULL
14060  *
14061  * Like foo_igen_method_threads_proxy_new_sync() but takes a #GBusType instead of a #GDBusConnection.
14062  *
14063  * The calling thread is blocked until a reply is received.
14064  *
14065  * See foo_igen_method_threads_proxy_new_for_bus() for the asynchronous version of this constructor.
14066  *
14067  * Returns: (transfer full) (type FooiGenMethodThreadsProxy): The constructed proxy object or %NULL if @error is set.
14068  */
14069 FooiGenMethodThreads *
14070 foo_igen_method_threads_proxy_new_for_bus_sync (
14071     GBusType             bus_type,
14072     GDBusProxyFlags      flags,
14073     const gchar         *name,
14074     const gchar         *object_path,
14075     GCancellable        *cancellable,
14076     GError             **error)
14077 {
14078   GInitable *ret;
14079   ret = g_initable_new (FOO_IGEN_TYPE_METHOD_THREADS_PROXY, cancellable, error, "g-flags", flags, "g-name", name, "g-bus-type", bus_type, "g-object-path", object_path, "g-interface-name", "org.project.MethodThreads", NULL);
14080   if (ret != NULL)
14081     return FOO_IGEN_METHOD_THREADS (ret);
14082   else
14083     return NULL;
14084 }
14085
14086
14087 /* ------------------------------------------------------------------------ */
14088
14089 /**
14090  * FooiGenMethodThreadsSkeleton:
14091  *
14092  * The #FooiGenMethodThreadsSkeleton structure contains only private data and should only be accessed using the provided API.
14093  */
14094
14095 /**
14096  * FooiGenMethodThreadsSkeletonClass:
14097  * @parent_class: The parent class.
14098  *
14099  * Class structure for #FooiGenMethodThreadsSkeleton.
14100  */
14101
14102 struct _FooiGenMethodThreadsSkeletonPrivate
14103 {
14104   GValue *properties;
14105   GList *changed_properties;
14106   GSource *changed_properties_idle_source;
14107   GMainContext *context;
14108   GMutex lock;
14109 };
14110
14111 static void
14112 _foo_igen_method_threads_skeleton_handle_method_call (
14113   GDBusConnection *connection,
14114   const gchar *sender,
14115   const gchar *object_path,
14116   const gchar *interface_name,
14117   const gchar *method_name,
14118   GVariant *parameters,
14119   GDBusMethodInvocation *invocation,
14120   gpointer user_data)
14121 {
14122   FooiGenMethodThreadsSkeleton *skeleton = FOO_IGEN_METHOD_THREADS_SKELETON (user_data);
14123   _ExtendedGDBusMethodInfo *info;
14124   GVariantIter iter;
14125   GVariant *child;
14126   GValue *paramv;
14127   guint num_params;
14128   guint num_extra;
14129   guint n;
14130   guint signal_id;
14131   GValue return_value = G_VALUE_INIT;
14132   info = (_ExtendedGDBusMethodInfo *) g_dbus_method_invocation_get_method_info (invocation);
14133   g_assert (info != NULL);
14134   num_params = g_variant_n_children (parameters);
14135   num_extra = info->pass_fdlist ? 3 : 2;  paramv = g_new0 (GValue, num_params + num_extra);
14136   n = 0;
14137   g_value_init (&paramv[n], FOO_IGEN_TYPE_METHOD_THREADS);
14138   g_value_set_object (&paramv[n++], skeleton);
14139   g_value_init (&paramv[n], G_TYPE_DBUS_METHOD_INVOCATION);
14140   g_value_set_object (&paramv[n++], invocation);
14141   if (info->pass_fdlist)
14142     {
14143 #ifdef G_OS_UNIX
14144       g_value_init (&paramv[n], G_TYPE_UNIX_FD_LIST);
14145       g_value_set_object (&paramv[n++], g_dbus_message_get_unix_fd_list (g_dbus_method_invocation_get_message (invocation)));
14146 #else
14147       g_assert_not_reached ();
14148 #endif
14149     }
14150   g_variant_iter_init (&iter, parameters);
14151   while ((child = g_variant_iter_next_value (&iter)) != NULL)
14152     {
14153       _ExtendedGDBusArgInfo *arg_info = (_ExtendedGDBusArgInfo *) info->parent_struct.in_args[n - num_extra];
14154       if (arg_info->use_gvariant)
14155         {
14156           g_value_init (&paramv[n], G_TYPE_VARIANT);
14157           g_value_set_variant (&paramv[n], child);
14158           n++;
14159         }
14160       else
14161         g_dbus_gvariant_to_gvalue (child, &paramv[n++]);
14162       g_variant_unref (child);
14163     }
14164   signal_id = g_signal_lookup (info->signal_name, FOO_IGEN_TYPE_METHOD_THREADS);
14165   g_value_init (&return_value, G_TYPE_BOOLEAN);
14166   g_signal_emitv (paramv, signal_id, 0, &return_value);
14167   if (!g_value_get_boolean (&return_value))
14168     g_dbus_method_invocation_return_error (invocation, G_DBUS_ERROR, G_DBUS_ERROR_UNKNOWN_METHOD, "Method %s is not implemented on interface %s", method_name, interface_name);
14169   g_value_unset (&return_value);
14170   for (n = 0; n < num_params + num_extra; n++)
14171     g_value_unset (&paramv[n]);
14172   g_free (paramv);
14173 }
14174
14175 static GVariant *
14176 _foo_igen_method_threads_skeleton_handle_get_property (
14177   GDBusConnection *connection,
14178   const gchar *sender,
14179   const gchar *object_path,
14180   const gchar *interface_name,
14181   const gchar *property_name,
14182   GError **error,
14183   gpointer user_data)
14184 {
14185   FooiGenMethodThreadsSkeleton *skeleton = FOO_IGEN_METHOD_THREADS_SKELETON (user_data);
14186   GValue value = G_VALUE_INIT;
14187   GParamSpec *pspec;
14188   _ExtendedGDBusPropertyInfo *info;
14189   GVariant *ret;
14190   ret = NULL;
14191   info = (_ExtendedGDBusPropertyInfo *) g_dbus_interface_info_lookup_property ((GDBusInterfaceInfo *) &_foo_igen_method_threads_interface_info, property_name);
14192   g_assert (info != NULL);
14193   pspec = g_object_class_find_property (G_OBJECT_GET_CLASS (skeleton), info->hyphen_name);
14194   if (pspec == NULL)
14195     {
14196       g_set_error (error, G_DBUS_ERROR, G_DBUS_ERROR_INVALID_ARGS, "No property with name %s", property_name);
14197     }
14198   else
14199     {
14200       g_value_init (&value, pspec->value_type);
14201       g_object_get_property (G_OBJECT (skeleton), info->hyphen_name, &value);
14202       ret = g_dbus_gvalue_to_gvariant (&value, G_VARIANT_TYPE (info->parent_struct.signature));
14203       g_value_unset (&value);
14204     }
14205   return ret;
14206 }
14207
14208 static gboolean
14209 _foo_igen_method_threads_skeleton_handle_set_property (
14210   GDBusConnection *connection,
14211   const gchar *sender,
14212   const gchar *object_path,
14213   const gchar *interface_name,
14214   const gchar *property_name,
14215   GVariant *variant,
14216   GError **error,
14217   gpointer user_data)
14218 {
14219   FooiGenMethodThreadsSkeleton *skeleton = FOO_IGEN_METHOD_THREADS_SKELETON (user_data);
14220   GValue value = G_VALUE_INIT;
14221   GParamSpec *pspec;
14222   _ExtendedGDBusPropertyInfo *info;
14223   gboolean ret;
14224   ret = FALSE;
14225   info = (_ExtendedGDBusPropertyInfo *) g_dbus_interface_info_lookup_property ((GDBusInterfaceInfo *) &_foo_igen_method_threads_interface_info, property_name);
14226   g_assert (info != NULL);
14227   pspec = g_object_class_find_property (G_OBJECT_GET_CLASS (skeleton), info->hyphen_name);
14228   if (pspec == NULL)
14229     {
14230       g_set_error (error, G_DBUS_ERROR, G_DBUS_ERROR_INVALID_ARGS, "No property with name %s", property_name);
14231     }
14232   else
14233     {
14234       if (info->use_gvariant)
14235         g_value_set_variant (&value, variant);
14236       else
14237         g_dbus_gvariant_to_gvalue (variant, &value);
14238       g_object_set_property (G_OBJECT (skeleton), info->hyphen_name, &value);
14239       g_value_unset (&value);
14240       ret = TRUE;
14241     }
14242   return ret;
14243 }
14244
14245 static const GDBusInterfaceVTable _foo_igen_method_threads_skeleton_vtable =
14246 {
14247   _foo_igen_method_threads_skeleton_handle_method_call,
14248   _foo_igen_method_threads_skeleton_handle_get_property,
14249   _foo_igen_method_threads_skeleton_handle_set_property
14250 };
14251
14252 static GDBusInterfaceInfo *
14253 foo_igen_method_threads_skeleton_dbus_interface_get_info (GDBusInterfaceSkeleton *skeleton)
14254 {
14255   return foo_igen_method_threads_interface_info ();
14256 }
14257
14258 static GDBusInterfaceVTable *
14259 foo_igen_method_threads_skeleton_dbus_interface_get_vtable (GDBusInterfaceSkeleton *skeleton)
14260 {
14261   return (GDBusInterfaceVTable *) &_foo_igen_method_threads_skeleton_vtable;
14262 }
14263
14264 static GVariant *
14265 foo_igen_method_threads_skeleton_dbus_interface_get_properties (GDBusInterfaceSkeleton *_skeleton)
14266 {
14267   FooiGenMethodThreadsSkeleton *skeleton = FOO_IGEN_METHOD_THREADS_SKELETON (_skeleton);
14268
14269   GVariantBuilder builder;
14270   guint n;
14271   g_variant_builder_init (&builder, G_VARIANT_TYPE ("a{sv}"));
14272   if (_foo_igen_method_threads_interface_info.parent_struct.properties == NULL)
14273     goto out;
14274   for (n = 0; _foo_igen_method_threads_interface_info.parent_struct.properties[n] != NULL; n++)
14275     {
14276       GDBusPropertyInfo *info = _foo_igen_method_threads_interface_info.parent_struct.properties[n];
14277       if (info->flags & G_DBUS_PROPERTY_INFO_FLAGS_READABLE)
14278         {
14279           GVariant *value;
14280           value = _foo_igen_method_threads_skeleton_handle_get_property (g_dbus_interface_skeleton_get_connection (G_DBUS_INTERFACE_SKELETON (skeleton)), NULL, g_dbus_interface_skeleton_get_object_path (G_DBUS_INTERFACE_SKELETON (skeleton)), "org.project.MethodThreads", info->name, NULL, skeleton);
14281           if (value != NULL)
14282             {
14283               g_variant_take_ref (value);
14284               g_variant_builder_add (&builder, "{sv}", info->name, value);
14285               g_variant_unref (value);
14286             }
14287         }
14288     }
14289 out:
14290   return g_variant_builder_end (&builder);
14291 }
14292
14293 static void
14294 foo_igen_method_threads_skeleton_dbus_interface_flush (GDBusInterfaceSkeleton *_skeleton)
14295 {
14296 }
14297
14298 static void foo_igen_method_threads_skeleton_iface_init (FooiGenMethodThreadsIface *iface);
14299 G_DEFINE_TYPE_WITH_CODE (FooiGenMethodThreadsSkeleton, foo_igen_method_threads_skeleton, G_TYPE_DBUS_INTERFACE_SKELETON,
14300                          G_IMPLEMENT_INTERFACE (FOO_IGEN_TYPE_METHOD_THREADS, foo_igen_method_threads_skeleton_iface_init));
14301
14302 static void
14303 foo_igen_method_threads_skeleton_finalize (GObject *object)
14304 {
14305   FooiGenMethodThreadsSkeleton *skeleton = FOO_IGEN_METHOD_THREADS_SKELETON (object);
14306   g_list_free_full (skeleton->priv->changed_properties, (GDestroyNotify) _changed_property_free);
14307   if (skeleton->priv->changed_properties_idle_source != NULL)
14308     g_source_destroy (skeleton->priv->changed_properties_idle_source);
14309   g_main_context_unref (skeleton->priv->context);
14310   g_mutex_clear (&skeleton->priv->lock);
14311   G_OBJECT_CLASS (foo_igen_method_threads_skeleton_parent_class)->finalize (object);
14312 }
14313
14314 static void
14315 foo_igen_method_threads_skeleton_init (FooiGenMethodThreadsSkeleton *skeleton)
14316 {
14317   skeleton->priv = G_TYPE_INSTANCE_GET_PRIVATE (skeleton, FOO_IGEN_TYPE_METHOD_THREADS_SKELETON, FooiGenMethodThreadsSkeletonPrivate);
14318   g_mutex_init (&skeleton->priv->lock);
14319   skeleton->priv->context = g_main_context_ref_thread_default ();
14320 }
14321
14322 static void
14323 foo_igen_method_threads_skeleton_class_init (FooiGenMethodThreadsSkeletonClass *klass)
14324 {
14325   GObjectClass *gobject_class;
14326   GDBusInterfaceSkeletonClass *skeleton_class;
14327
14328   g_type_class_add_private (klass, sizeof (FooiGenMethodThreadsSkeletonPrivate));
14329
14330   gobject_class = G_OBJECT_CLASS (klass);
14331   gobject_class->finalize = foo_igen_method_threads_skeleton_finalize;
14332
14333   skeleton_class = G_DBUS_INTERFACE_SKELETON_CLASS (klass);
14334   skeleton_class->get_info = foo_igen_method_threads_skeleton_dbus_interface_get_info;
14335   skeleton_class->get_properties = foo_igen_method_threads_skeleton_dbus_interface_get_properties;
14336   skeleton_class->flush = foo_igen_method_threads_skeleton_dbus_interface_flush;
14337   skeleton_class->get_vtable = foo_igen_method_threads_skeleton_dbus_interface_get_vtable;
14338 }
14339
14340 static void
14341 foo_igen_method_threads_skeleton_iface_init (FooiGenMethodThreadsIface *iface)
14342 {
14343 }
14344
14345 /**
14346  * foo_igen_method_threads_skeleton_new:
14347  *
14348  * Creates a skeleton object for the D-Bus interface <link linkend="gdbus-interface-org-project-MethodThreads.top_of_page">org.project.MethodThreads</link>.
14349  *
14350  * Returns: (transfer full) (type FooiGenMethodThreadsSkeleton): The skeleton object.
14351  */
14352 FooiGenMethodThreads *
14353 foo_igen_method_threads_skeleton_new (void)
14354 {
14355   return FOO_IGEN_METHOD_THREADS (g_object_new (FOO_IGEN_TYPE_METHOD_THREADS_SKELETON, NULL));
14356 }
14357
14358 /* ------------------------------------------------------------------------
14359  * Code for interface org.project.InlineDocs
14360  * ------------------------------------------------------------------------
14361  */
14362
14363 /**
14364  * SECTION:FooiGenInlineDocs
14365  * @title: FooiGenInlineDocs
14366  * @short_description: Generated C code for the org.project.InlineDocs D-Bus interface
14367  *
14368  * This section contains code for working with the <link linkend="gdbus-interface-org-project-InlineDocs.top_of_page">org.project.InlineDocs</link> D-Bus interface in C.
14369  */
14370
14371 /* ---- Introspection data for org.project.InlineDocs ---- */
14372
14373 static const _ExtendedGDBusArgInfo _foo_igen_inline_docs_method_info_foo_method_IN_ARG_greeting =
14374 {
14375   {
14376     -1,
14377     "greeting",
14378     "s",
14379     NULL
14380   },
14381   FALSE
14382 };
14383
14384 static const _ExtendedGDBusArgInfo * const _foo_igen_inline_docs_method_info_foo_method_IN_ARG_pointers[] =
14385 {
14386   &_foo_igen_inline_docs_method_info_foo_method_IN_ARG_greeting,
14387   NULL
14388 };
14389
14390 static const _ExtendedGDBusArgInfo _foo_igen_inline_docs_method_info_foo_method_OUT_ARG_response =
14391 {
14392   {
14393     -1,
14394     "response",
14395     "s",
14396     NULL
14397   },
14398   FALSE
14399 };
14400
14401 static const _ExtendedGDBusArgInfo * const _foo_igen_inline_docs_method_info_foo_method_OUT_ARG_pointers[] =
14402 {
14403   &_foo_igen_inline_docs_method_info_foo_method_OUT_ARG_response,
14404   NULL
14405 };
14406
14407 static const _ExtendedGDBusMethodInfo _foo_igen_inline_docs_method_info_foo_method =
14408 {
14409   {
14410     -1,
14411     "FooMethod",
14412     (GDBusArgInfo **) &_foo_igen_inline_docs_method_info_foo_method_IN_ARG_pointers,
14413     (GDBusArgInfo **) &_foo_igen_inline_docs_method_info_foo_method_OUT_ARG_pointers,
14414     NULL
14415   },
14416   "handle-foo-method",
14417   FALSE
14418 };
14419
14420 static const _ExtendedGDBusArgInfo _foo_igen_inline_docs_method_info_method2_IN_ARG_greeting =
14421 {
14422   {
14423     -1,
14424     "greeting",
14425     "s",
14426     NULL
14427   },
14428   FALSE
14429 };
14430
14431 static const _ExtendedGDBusArgInfo * const _foo_igen_inline_docs_method_info_method2_IN_ARG_pointers[] =
14432 {
14433   &_foo_igen_inline_docs_method_info_method2_IN_ARG_greeting,
14434   NULL
14435 };
14436
14437 static const _ExtendedGDBusArgInfo _foo_igen_inline_docs_method_info_method2_OUT_ARG_response =
14438 {
14439   {
14440     -1,
14441     "response",
14442     "s",
14443     NULL
14444   },
14445   FALSE
14446 };
14447
14448 static const _ExtendedGDBusArgInfo * const _foo_igen_inline_docs_method_info_method2_OUT_ARG_pointers[] =
14449 {
14450   &_foo_igen_inline_docs_method_info_method2_OUT_ARG_response,
14451   NULL
14452 };
14453
14454 static const _ExtendedGDBusMethodInfo _foo_igen_inline_docs_method_info_method2 =
14455 {
14456   {
14457     -1,
14458     "Method2",
14459     (GDBusArgInfo **) &_foo_igen_inline_docs_method_info_method2_IN_ARG_pointers,
14460     (GDBusArgInfo **) &_foo_igen_inline_docs_method_info_method2_OUT_ARG_pointers,
14461     NULL
14462   },
14463   "handle-method2",
14464   FALSE
14465 };
14466
14467 static const _ExtendedGDBusMethodInfo * const _foo_igen_inline_docs_method_info_pointers[] =
14468 {
14469   &_foo_igen_inline_docs_method_info_foo_method,
14470   &_foo_igen_inline_docs_method_info_method2,
14471   NULL
14472 };
14473
14474 static const _ExtendedGDBusArgInfo _foo_igen_inline_docs_signal_info_bar_signal_ARG_blah =
14475 {
14476   {
14477     -1,
14478     "blah",
14479     "s",
14480     NULL
14481   },
14482   FALSE
14483 };
14484
14485 static const _ExtendedGDBusArgInfo _foo_igen_inline_docs_signal_info_bar_signal_ARG_boo =
14486 {
14487   {
14488     -1,
14489     "boo",
14490     "s",
14491     NULL
14492   },
14493   FALSE
14494 };
14495
14496 static const _ExtendedGDBusArgInfo * const _foo_igen_inline_docs_signal_info_bar_signal_ARG_pointers[] =
14497 {
14498   &_foo_igen_inline_docs_signal_info_bar_signal_ARG_blah,
14499   &_foo_igen_inline_docs_signal_info_bar_signal_ARG_boo,
14500   NULL
14501 };
14502
14503 static const _ExtendedGDBusSignalInfo _foo_igen_inline_docs_signal_info_bar_signal =
14504 {
14505   {
14506     -1,
14507     "BarSignal",
14508     (GDBusArgInfo **) &_foo_igen_inline_docs_signal_info_bar_signal_ARG_pointers,
14509     NULL
14510   },
14511   "bar-signal"
14512 };
14513
14514 static const _ExtendedGDBusSignalInfo * const _foo_igen_inline_docs_signal_info_pointers[] =
14515 {
14516   &_foo_igen_inline_docs_signal_info_bar_signal,
14517   NULL
14518 };
14519
14520 static const _ExtendedGDBusPropertyInfo _foo_igen_inline_docs_property_info_baz_property =
14521 {
14522   {
14523     -1,
14524     "BazProperty",
14525     "s",
14526     G_DBUS_PROPERTY_INFO_FLAGS_READABLE,
14527     NULL
14528   },
14529   "baz-property",
14530   FALSE
14531 };
14532
14533 static const _ExtendedGDBusPropertyInfo _foo_igen_inline_docs_property_info_property2 =
14534 {
14535   {
14536     -1,
14537     "Property2",
14538     "s",
14539     G_DBUS_PROPERTY_INFO_FLAGS_READABLE,
14540     NULL
14541   },
14542   "property2",
14543   FALSE
14544 };
14545
14546 static const _ExtendedGDBusPropertyInfo _foo_igen_inline_docs_property_info_property3 =
14547 {
14548   {
14549     -1,
14550     "Property3",
14551     "s",
14552     G_DBUS_PROPERTY_INFO_FLAGS_READABLE,
14553     NULL
14554   },
14555   "property3",
14556   FALSE
14557 };
14558
14559 static const _ExtendedGDBusPropertyInfo _foo_igen_inline_docs_property_info_property4 =
14560 {
14561   {
14562     -1,
14563     "Property4",
14564     "s",
14565     G_DBUS_PROPERTY_INFO_FLAGS_READABLE,
14566     NULL
14567   },
14568   "property4",
14569   FALSE
14570 };
14571
14572 static const _ExtendedGDBusPropertyInfo _foo_igen_inline_docs_property_info_property5 =
14573 {
14574   {
14575     -1,
14576     "Property5",
14577     "s",
14578     G_DBUS_PROPERTY_INFO_FLAGS_READABLE,
14579     NULL
14580   },
14581   "property5",
14582   FALSE
14583 };
14584
14585 static const _ExtendedGDBusPropertyInfo _foo_igen_inline_docs_property_info_fancy_property =
14586 {
14587   {
14588     -1,
14589     "FancyProperty",
14590     "s",
14591     G_DBUS_PROPERTY_INFO_FLAGS_READABLE,
14592     NULL
14593   },
14594   "fancy-property",
14595   FALSE
14596 };
14597
14598 static const _ExtendedGDBusPropertyInfo * const _foo_igen_inline_docs_property_info_pointers[] =
14599 {
14600   &_foo_igen_inline_docs_property_info_baz_property,
14601   &_foo_igen_inline_docs_property_info_property2,
14602   &_foo_igen_inline_docs_property_info_property3,
14603   &_foo_igen_inline_docs_property_info_property4,
14604   &_foo_igen_inline_docs_property_info_property5,
14605   &_foo_igen_inline_docs_property_info_fancy_property,
14606   NULL
14607 };
14608
14609 static const _ExtendedGDBusInterfaceInfo _foo_igen_inline_docs_interface_info =
14610 {
14611   {
14612     -1,
14613     "org.project.InlineDocs",
14614     (GDBusMethodInfo **) &_foo_igen_inline_docs_method_info_pointers,
14615     (GDBusSignalInfo **) &_foo_igen_inline_docs_signal_info_pointers,
14616     (GDBusPropertyInfo **) &_foo_igen_inline_docs_property_info_pointers,
14617     NULL
14618   },
14619   "inline-docs",
14620 };
14621
14622
14623 /**
14624  * foo_igen_inline_docs_interface_info:
14625  *
14626  * Gets a machine-readable description of the <link linkend="gdbus-interface-org-project-InlineDocs.top_of_page">org.project.InlineDocs</link> D-Bus interface.
14627  *
14628  * Returns: (transfer none): A #GDBusInterfaceInfo. Do not free.
14629  */
14630 GDBusInterfaceInfo *
14631 foo_igen_inline_docs_interface_info (void)
14632 {
14633   return (GDBusInterfaceInfo *) &_foo_igen_inline_docs_interface_info;
14634 }
14635
14636 /**
14637  * foo_igen_inline_docs_override_properties:
14638  * @klass: The class structure for a #GObject<!-- -->-derived class.
14639  * @property_id_begin: The property id to assign to the first overridden property.
14640  *
14641  * Overrides all #GObject properties in the #FooiGenInlineDocs interface for a concrete class.
14642  * The properties are overridden in the order they are defined.
14643  *
14644  * Returns: The last property id.
14645  */
14646 guint
14647 foo_igen_inline_docs_override_properties (GObjectClass *klass, guint property_id_begin)
14648 {
14649   g_object_class_override_property (klass, property_id_begin++, "baz-property");
14650   g_object_class_override_property (klass, property_id_begin++, "property2");
14651   g_object_class_override_property (klass, property_id_begin++, "property3");
14652   g_object_class_override_property (klass, property_id_begin++, "property4");
14653   g_object_class_override_property (klass, property_id_begin++, "property5");
14654   g_object_class_override_property (klass, property_id_begin++, "fancy-property");
14655   return property_id_begin - 1;
14656 }
14657
14658
14659
14660 /**
14661  * FooiGenInlineDocs:
14662  *
14663  * Abstract interface type for the D-Bus interface <link linkend="gdbus-interface-org-project-InlineDocs.top_of_page">org.project.InlineDocs</link>.
14664  */
14665
14666 /**
14667  * FooiGenInlineDocsIface:
14668  * @parent_iface: The parent interface.
14669  * @handle_foo_method: Handler for the #FooiGenInlineDocs::handle-foo-method signal.
14670  * @handle_method2: Handler for the #FooiGenInlineDocs::handle-method2 signal.
14671  * @get_baz_property: Getter for the #FooiGenInlineDocs:baz-property property.
14672  * @get_fancy_property: Getter for the #FooiGenInlineDocs:fancy-property property.
14673  * @get_property2: Getter for the #FooiGenInlineDocs:property2 property.
14674  * @get_property3: Getter for the #FooiGenInlineDocs:property3 property.
14675  * @get_property4: Getter for the #FooiGenInlineDocs:property4 property.
14676  * @get_property5: Getter for the #FooiGenInlineDocs:property5 property.
14677  * @bar_signal: Handler for the #FooiGenInlineDocs::bar-signal signal.
14678  *
14679  * Virtual table for the D-Bus interface <link linkend="gdbus-interface-org-project-InlineDocs.top_of_page">org.project.InlineDocs</link>.
14680  */
14681
14682 static void
14683 foo_igen_inline_docs_default_init (FooiGenInlineDocsIface *iface)
14684 {
14685   /* GObject signals for incoming D-Bus method calls: */
14686   /**
14687    * FooiGenInlineDocs::handle-foo-method:
14688    * @object: A #FooiGenInlineDocs.
14689    * @invocation: A #GDBusMethodInvocation.
14690    * @arg_greeting: Argument passed by remote caller.
14691    *
14692    * Signal emitted when a remote caller is invoking the <link linkend="gdbus-method-org-project-InlineDocs.FooMethod">FooMethod()</link> D-Bus method.
14693    *
14694    * If a signal handler returns %TRUE, it means the signal handler will handle the invocation (e.g. take a reference to @invocation and eventually call foo_igen_inline_docs_complete_foo_method() or e.g. g_dbus_method_invocation_return_error() on it) and no order signal handlers will run. If no signal handler handles the invocation, the %G_DBUS_ERROR_UNKNOWN_METHOD error is returned.
14695    *
14696    * Returns: %TRUE if the invocation was handled, %FALSE to let other signal handlers run.
14697    */
14698   g_signal_new ("handle-foo-method",
14699     G_TYPE_FROM_INTERFACE (iface),
14700     G_SIGNAL_RUN_LAST,
14701     G_STRUCT_OFFSET (FooiGenInlineDocsIface, handle_foo_method),
14702     g_signal_accumulator_true_handled,
14703     NULL,
14704     g_cclosure_marshal_generic,
14705     G_TYPE_BOOLEAN,
14706     2,
14707     G_TYPE_DBUS_METHOD_INVOCATION, G_TYPE_STRING);
14708
14709   /**
14710    * FooiGenInlineDocs::handle-method2:
14711    * @object: A #FooiGenInlineDocs.
14712    * @invocation: A #GDBusMethodInvocation.
14713    * @arg_greeting: Argument passed by remote caller.
14714    *
14715    * Signal emitted when a remote caller is invoking the <link linkend="gdbus-method-org-project-InlineDocs.Method2">Method2()</link> D-Bus method.
14716    *
14717    * If a signal handler returns %TRUE, it means the signal handler will handle the invocation (e.g. take a reference to @invocation and eventually call foo_igen_inline_docs_complete_method2() or e.g. g_dbus_method_invocation_return_error() on it) and no order signal handlers will run. If no signal handler handles the invocation, the %G_DBUS_ERROR_UNKNOWN_METHOD error is returned.
14718    *
14719    * Returns: %TRUE if the invocation was handled, %FALSE to let other signal handlers run.
14720    */
14721   g_signal_new ("handle-method2",
14722     G_TYPE_FROM_INTERFACE (iface),
14723     G_SIGNAL_RUN_LAST,
14724     G_STRUCT_OFFSET (FooiGenInlineDocsIface, handle_method2),
14725     g_signal_accumulator_true_handled,
14726     NULL,
14727     g_cclosure_marshal_generic,
14728     G_TYPE_BOOLEAN,
14729     2,
14730     G_TYPE_DBUS_METHOD_INVOCATION, G_TYPE_STRING);
14731
14732   /* GObject signals for received D-Bus signals: */
14733   /**
14734    * FooiGenInlineDocs::bar-signal:
14735    * @object: A #FooiGenInlineDocs.
14736    * @arg_blah: Argument.
14737    * @arg_boo: Argument.
14738    *
14739    * On the client-side, this signal is emitted whenever the D-Bus signal <link linkend="gdbus-signal-org-project-InlineDocs.BarSignal">"BarSignal"</link> is received.
14740    *
14741    * On the service-side, this signal can be used with e.g. g_signal_emit_by_name() to make the object emit the D-Bus signal.
14742    */
14743   g_signal_new ("bar-signal",
14744     G_TYPE_FROM_INTERFACE (iface),
14745     G_SIGNAL_RUN_LAST,
14746     G_STRUCT_OFFSET (FooiGenInlineDocsIface, bar_signal),
14747     NULL,
14748     NULL,
14749     g_cclosure_marshal_generic,
14750     G_TYPE_NONE,
14751     2, G_TYPE_STRING, G_TYPE_STRING);
14752
14753   /* GObject properties for D-Bus properties: */
14754   /**
14755    * FooiGenInlineDocs:baz-property:
14756    *
14757    * Represents the D-Bus property <link linkend="gdbus-property-org-project-InlineDocs.BazProperty">"BazProperty"</link>.
14758    *
14759    * Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
14760    */
14761   g_object_interface_install_property (iface,
14762     g_param_spec_string ("baz-property", "BazProperty", "BazProperty", NULL, G_PARAM_READWRITE | G_PARAM_STATIC_STRINGS));
14763   /**
14764    * FooiGenInlineDocs:property2:
14765    *
14766    * Represents the D-Bus property <link linkend="gdbus-property-org-project-InlineDocs.Property2">"Property2"</link>.
14767    *
14768    * Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
14769    */
14770   g_object_interface_install_property (iface,
14771     g_param_spec_string ("property2", "Property2", "Property2", NULL, G_PARAM_READWRITE | G_PARAM_STATIC_STRINGS));
14772   /**
14773    * FooiGenInlineDocs:property3:
14774    *
14775    * Represents the D-Bus property <link linkend="gdbus-property-org-project-InlineDocs.Property3">"Property3"</link>.
14776    *
14777    * Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
14778    */
14779   g_object_interface_install_property (iface,
14780     g_param_spec_string ("property3", "Property3", "Property3", NULL, G_PARAM_READWRITE | G_PARAM_STATIC_STRINGS));
14781   /**
14782    * FooiGenInlineDocs:property4:
14783    *
14784    * Represents the D-Bus property <link linkend="gdbus-property-org-project-InlineDocs.Property4">"Property4"</link>.
14785    *
14786    * Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
14787    */
14788   g_object_interface_install_property (iface,
14789     g_param_spec_string ("property4", "Property4", "Property4", NULL, G_PARAM_READWRITE | G_PARAM_STATIC_STRINGS));
14790   /**
14791    * FooiGenInlineDocs:property5:
14792    *
14793    * Represents the D-Bus property <link linkend="gdbus-property-org-project-InlineDocs.Property5">"Property5"</link>.
14794    *
14795    * Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
14796    */
14797   g_object_interface_install_property (iface,
14798     g_param_spec_string ("property5", "Property5", "Property5", NULL, G_PARAM_READWRITE | G_PARAM_STATIC_STRINGS));
14799   /**
14800    * FooiGenInlineDocs:fancy-property:
14801    *
14802    * Represents the D-Bus property <link linkend="gdbus-property-org-project-InlineDocs.FancyProperty">"FancyProperty"</link>.
14803    *
14804    * Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
14805    */
14806   g_object_interface_install_property (iface,
14807     g_param_spec_string ("fancy-property", "FancyProperty", "FancyProperty", NULL, G_PARAM_READWRITE | G_PARAM_STATIC_STRINGS));
14808 }
14809
14810 typedef FooiGenInlineDocsIface FooiGenInlineDocsInterface;
14811 G_DEFINE_INTERFACE (FooiGenInlineDocs, foo_igen_inline_docs, G_TYPE_OBJECT);
14812
14813 /**
14814  * foo_igen_inline_docs_get_baz_property: (skip)
14815  * @object: A #FooiGenInlineDocs.
14816  *
14817  * Gets the value of the <link linkend="gdbus-property-org-project-InlineDocs.BazProperty">"BazProperty"</link> D-Bus property.
14818  *
14819  * Since this D-Bus property is readable, it is meaningful to use this function on both the client- and service-side.
14820  *
14821  * <warning>The returned value is only valid until the property changes so on the client-side it is only safe to use this function on the thread where @object was constructed. Use foo_igen_inline_docs_dup_baz_property() if on another thread.</warning>
14822  *
14823  * Returns: (transfer none): The property value or %NULL if the property is not set. Do not free the returned value, it belongs to @object.
14824  */
14825 const gchar *
14826 foo_igen_inline_docs_get_baz_property (FooiGenInlineDocs *object)
14827 {
14828   return FOO_IGEN_INLINE_DOCS_GET_IFACE (object)->get_baz_property (object);
14829 }
14830
14831 /**
14832  * foo_igen_inline_docs_dup_baz_property: (skip)
14833  * @object: A #FooiGenInlineDocs.
14834  *
14835  * Gets a copy of the <link linkend="gdbus-property-org-project-InlineDocs.BazProperty">"BazProperty"</link> D-Bus property.
14836  *
14837  * Since this D-Bus property is readable, it is meaningful to use this function on both the client- and service-side.
14838  *
14839  * Returns: (transfer full): The property value or %NULL if the property is not set. The returned value should be freed with g_free().
14840  */
14841 gchar *
14842 foo_igen_inline_docs_dup_baz_property (FooiGenInlineDocs *object)
14843 {
14844   gchar *value;
14845   g_object_get (G_OBJECT (object), "baz-property", &value, NULL);
14846   return value;
14847 }
14848
14849 /**
14850  * foo_igen_inline_docs_set_baz_property: (skip)
14851  * @object: A #FooiGenInlineDocs.
14852  * @value: The value to set.
14853  *
14854  * Sets the <link linkend="gdbus-property-org-project-InlineDocs.BazProperty">"BazProperty"</link> D-Bus property to @value.
14855  *
14856  * Since this D-Bus property is not writable, it is only meaningful to use this function on the service-side.
14857  */
14858 void
14859 foo_igen_inline_docs_set_baz_property (FooiGenInlineDocs *object, const gchar *value)
14860 {
14861   g_object_set (G_OBJECT (object), "baz-property", value, NULL);
14862 }
14863
14864 /**
14865  * foo_igen_inline_docs_get_property2: (skip)
14866  * @object: A #FooiGenInlineDocs.
14867  *
14868  * Gets the value of the <link linkend="gdbus-property-org-project-InlineDocs.Property2">"Property2"</link> D-Bus property.
14869  *
14870  * Since this D-Bus property is readable, it is meaningful to use this function on both the client- and service-side.
14871  *
14872  * <warning>The returned value is only valid until the property changes so on the client-side it is only safe to use this function on the thread where @object was constructed. Use foo_igen_inline_docs_dup_property2() if on another thread.</warning>
14873  *
14874  * Returns: (transfer none): The property value or %NULL if the property is not set. Do not free the returned value, it belongs to @object.
14875  */
14876 const gchar *
14877 foo_igen_inline_docs_get_property2 (FooiGenInlineDocs *object)
14878 {
14879   return FOO_IGEN_INLINE_DOCS_GET_IFACE (object)->get_property2 (object);
14880 }
14881
14882 /**
14883  * foo_igen_inline_docs_dup_property2: (skip)
14884  * @object: A #FooiGenInlineDocs.
14885  *
14886  * Gets a copy of the <link linkend="gdbus-property-org-project-InlineDocs.Property2">"Property2"</link> D-Bus property.
14887  *
14888  * Since this D-Bus property is readable, it is meaningful to use this function on both the client- and service-side.
14889  *
14890  * Returns: (transfer full): The property value or %NULL if the property is not set. The returned value should be freed with g_free().
14891  */
14892 gchar *
14893 foo_igen_inline_docs_dup_property2 (FooiGenInlineDocs *object)
14894 {
14895   gchar *value;
14896   g_object_get (G_OBJECT (object), "property2", &value, NULL);
14897   return value;
14898 }
14899
14900 /**
14901  * foo_igen_inline_docs_set_property2: (skip)
14902  * @object: A #FooiGenInlineDocs.
14903  * @value: The value to set.
14904  *
14905  * Sets the <link linkend="gdbus-property-org-project-InlineDocs.Property2">"Property2"</link> D-Bus property to @value.
14906  *
14907  * Since this D-Bus property is not writable, it is only meaningful to use this function on the service-side.
14908  */
14909 void
14910 foo_igen_inline_docs_set_property2 (FooiGenInlineDocs *object, const gchar *value)
14911 {
14912   g_object_set (G_OBJECT (object), "property2", value, NULL);
14913 }
14914
14915 /**
14916  * foo_igen_inline_docs_get_property3: (skip)
14917  * @object: A #FooiGenInlineDocs.
14918  *
14919  * Gets the value of the <link linkend="gdbus-property-org-project-InlineDocs.Property3">"Property3"</link> D-Bus property.
14920  *
14921  * Since this D-Bus property is readable, it is meaningful to use this function on both the client- and service-side.
14922  *
14923  * <warning>The returned value is only valid until the property changes so on the client-side it is only safe to use this function on the thread where @object was constructed. Use foo_igen_inline_docs_dup_property3() if on another thread.</warning>
14924  *
14925  * Returns: (transfer none): The property value or %NULL if the property is not set. Do not free the returned value, it belongs to @object.
14926  */
14927 const gchar *
14928 foo_igen_inline_docs_get_property3 (FooiGenInlineDocs *object)
14929 {
14930   return FOO_IGEN_INLINE_DOCS_GET_IFACE (object)->get_property3 (object);
14931 }
14932
14933 /**
14934  * foo_igen_inline_docs_dup_property3: (skip)
14935  * @object: A #FooiGenInlineDocs.
14936  *
14937  * Gets a copy of the <link linkend="gdbus-property-org-project-InlineDocs.Property3">"Property3"</link> D-Bus property.
14938  *
14939  * Since this D-Bus property is readable, it is meaningful to use this function on both the client- and service-side.
14940  *
14941  * Returns: (transfer full): The property value or %NULL if the property is not set. The returned value should be freed with g_free().
14942  */
14943 gchar *
14944 foo_igen_inline_docs_dup_property3 (FooiGenInlineDocs *object)
14945 {
14946   gchar *value;
14947   g_object_get (G_OBJECT (object), "property3", &value, NULL);
14948   return value;
14949 }
14950
14951 /**
14952  * foo_igen_inline_docs_set_property3: (skip)
14953  * @object: A #FooiGenInlineDocs.
14954  * @value: The value to set.
14955  *
14956  * Sets the <link linkend="gdbus-property-org-project-InlineDocs.Property3">"Property3"</link> D-Bus property to @value.
14957  *
14958  * Since this D-Bus property is not writable, it is only meaningful to use this function on the service-side.
14959  */
14960 void
14961 foo_igen_inline_docs_set_property3 (FooiGenInlineDocs *object, const gchar *value)
14962 {
14963   g_object_set (G_OBJECT (object), "property3", value, NULL);
14964 }
14965
14966 /**
14967  * foo_igen_inline_docs_get_property4: (skip)
14968  * @object: A #FooiGenInlineDocs.
14969  *
14970  * Gets the value of the <link linkend="gdbus-property-org-project-InlineDocs.Property4">"Property4"</link> D-Bus property.
14971  *
14972  * Since this D-Bus property is readable, it is meaningful to use this function on both the client- and service-side.
14973  *
14974  * <warning>The returned value is only valid until the property changes so on the client-side it is only safe to use this function on the thread where @object was constructed. Use foo_igen_inline_docs_dup_property4() if on another thread.</warning>
14975  *
14976  * Returns: (transfer none): The property value or %NULL if the property is not set. Do not free the returned value, it belongs to @object.
14977  */
14978 const gchar *
14979 foo_igen_inline_docs_get_property4 (FooiGenInlineDocs *object)
14980 {
14981   return FOO_IGEN_INLINE_DOCS_GET_IFACE (object)->get_property4 (object);
14982 }
14983
14984 /**
14985  * foo_igen_inline_docs_dup_property4: (skip)
14986  * @object: A #FooiGenInlineDocs.
14987  *
14988  * Gets a copy of the <link linkend="gdbus-property-org-project-InlineDocs.Property4">"Property4"</link> D-Bus property.
14989  *
14990  * Since this D-Bus property is readable, it is meaningful to use this function on both the client- and service-side.
14991  *
14992  * Returns: (transfer full): The property value or %NULL if the property is not set. The returned value should be freed with g_free().
14993  */
14994 gchar *
14995 foo_igen_inline_docs_dup_property4 (FooiGenInlineDocs *object)
14996 {
14997   gchar *value;
14998   g_object_get (G_OBJECT (object), "property4", &value, NULL);
14999   return value;
15000 }
15001
15002 /**
15003  * foo_igen_inline_docs_set_property4: (skip)
15004  * @object: A #FooiGenInlineDocs.
15005  * @value: The value to set.
15006  *
15007  * Sets the <link linkend="gdbus-property-org-project-InlineDocs.Property4">"Property4"</link> D-Bus property to @value.
15008  *
15009  * Since this D-Bus property is not writable, it is only meaningful to use this function on the service-side.
15010  */
15011 void
15012 foo_igen_inline_docs_set_property4 (FooiGenInlineDocs *object, const gchar *value)
15013 {
15014   g_object_set (G_OBJECT (object), "property4", value, NULL);
15015 }
15016
15017 /**
15018  * foo_igen_inline_docs_get_property5: (skip)
15019  * @object: A #FooiGenInlineDocs.
15020  *
15021  * Gets the value of the <link linkend="gdbus-property-org-project-InlineDocs.Property5">"Property5"</link> D-Bus property.
15022  *
15023  * Since this D-Bus property is readable, it is meaningful to use this function on both the client- and service-side.
15024  *
15025  * <warning>The returned value is only valid until the property changes so on the client-side it is only safe to use this function on the thread where @object was constructed. Use foo_igen_inline_docs_dup_property5() if on another thread.</warning>
15026  *
15027  * Returns: (transfer none): The property value or %NULL if the property is not set. Do not free the returned value, it belongs to @object.
15028  */
15029 const gchar *
15030 foo_igen_inline_docs_get_property5 (FooiGenInlineDocs *object)
15031 {
15032   return FOO_IGEN_INLINE_DOCS_GET_IFACE (object)->get_property5 (object);
15033 }
15034
15035 /**
15036  * foo_igen_inline_docs_dup_property5: (skip)
15037  * @object: A #FooiGenInlineDocs.
15038  *
15039  * Gets a copy of the <link linkend="gdbus-property-org-project-InlineDocs.Property5">"Property5"</link> D-Bus property.
15040  *
15041  * Since this D-Bus property is readable, it is meaningful to use this function on both the client- and service-side.
15042  *
15043  * Returns: (transfer full): The property value or %NULL if the property is not set. The returned value should be freed with g_free().
15044  */
15045 gchar *
15046 foo_igen_inline_docs_dup_property5 (FooiGenInlineDocs *object)
15047 {
15048   gchar *value;
15049   g_object_get (G_OBJECT (object), "property5", &value, NULL);
15050   return value;
15051 }
15052
15053 /**
15054  * foo_igen_inline_docs_set_property5: (skip)
15055  * @object: A #FooiGenInlineDocs.
15056  * @value: The value to set.
15057  *
15058  * Sets the <link linkend="gdbus-property-org-project-InlineDocs.Property5">"Property5"</link> D-Bus property to @value.
15059  *
15060  * Since this D-Bus property is not writable, it is only meaningful to use this function on the service-side.
15061  */
15062 void
15063 foo_igen_inline_docs_set_property5 (FooiGenInlineDocs *object, const gchar *value)
15064 {
15065   g_object_set (G_OBJECT (object), "property5", value, NULL);
15066 }
15067
15068 /**
15069  * foo_igen_inline_docs_get_fancy_property: (skip)
15070  * @object: A #FooiGenInlineDocs.
15071  *
15072  * Gets the value of the <link linkend="gdbus-property-org-project-InlineDocs.FancyProperty">"FancyProperty"</link> D-Bus property.
15073  *
15074  * Since this D-Bus property is readable, it is meaningful to use this function on both the client- and service-side.
15075  *
15076  * <warning>The returned value is only valid until the property changes so on the client-side it is only safe to use this function on the thread where @object was constructed. Use foo_igen_inline_docs_dup_fancy_property() if on another thread.</warning>
15077  *
15078  * Returns: (transfer none): The property value or %NULL if the property is not set. Do not free the returned value, it belongs to @object.
15079  */
15080 const gchar *
15081 foo_igen_inline_docs_get_fancy_property (FooiGenInlineDocs *object)
15082 {
15083   return FOO_IGEN_INLINE_DOCS_GET_IFACE (object)->get_fancy_property (object);
15084 }
15085
15086 /**
15087  * foo_igen_inline_docs_dup_fancy_property: (skip)
15088  * @object: A #FooiGenInlineDocs.
15089  *
15090  * Gets a copy of the <link linkend="gdbus-property-org-project-InlineDocs.FancyProperty">"FancyProperty"</link> D-Bus property.
15091  *
15092  * Since this D-Bus property is readable, it is meaningful to use this function on both the client- and service-side.
15093  *
15094  * Returns: (transfer full): The property value or %NULL if the property is not set. The returned value should be freed with g_free().
15095  */
15096 gchar *
15097 foo_igen_inline_docs_dup_fancy_property (FooiGenInlineDocs *object)
15098 {
15099   gchar *value;
15100   g_object_get (G_OBJECT (object), "fancy-property", &value, NULL);
15101   return value;
15102 }
15103
15104 /**
15105  * foo_igen_inline_docs_set_fancy_property: (skip)
15106  * @object: A #FooiGenInlineDocs.
15107  * @value: The value to set.
15108  *
15109  * Sets the <link linkend="gdbus-property-org-project-InlineDocs.FancyProperty">"FancyProperty"</link> D-Bus property to @value.
15110  *
15111  * Since this D-Bus property is not writable, it is only meaningful to use this function on the service-side.
15112  */
15113 void
15114 foo_igen_inline_docs_set_fancy_property (FooiGenInlineDocs *object, const gchar *value)
15115 {
15116   g_object_set (G_OBJECT (object), "fancy-property", value, NULL);
15117 }
15118
15119 /**
15120  * foo_igen_inline_docs_emit_bar_signal:
15121  * @object: A #FooiGenInlineDocs.
15122  * @arg_blah: Argument to pass with the signal.
15123  * @arg_boo: Argument to pass with the signal.
15124  *
15125  * Emits the <link linkend="gdbus-signal-org-project-InlineDocs.BarSignal">"BarSignal"</link> D-Bus signal.
15126  */
15127 void
15128 foo_igen_inline_docs_emit_bar_signal (
15129     FooiGenInlineDocs *object,
15130     const gchar *arg_blah,
15131     const gchar *arg_boo)
15132 {
15133   g_signal_emit_by_name (object, "bar-signal", arg_blah, arg_boo);
15134 }
15135
15136 /**
15137  * foo_igen_inline_docs_call_foo_method:
15138  * @proxy: A #FooiGenInlineDocsProxy.
15139  * @arg_greeting: Argument to pass with the method invocation.
15140  * @cancellable: (allow-none): A #GCancellable or %NULL.
15141  * @callback: A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
15142  * @user_data: User data to pass to @callback.
15143  *
15144  * Asynchronously invokes the <link linkend="gdbus-method-org-project-InlineDocs.FooMethod">FooMethod()</link> D-Bus method on @proxy.
15145  * When the operation is finished, @callback will be invoked in the <link linkend="g-main-context-push-thread-default">thread-default main loop</link> of the thread you are calling this method from.
15146  * You can then call foo_igen_inline_docs_call_foo_method_finish() to get the result of the operation.
15147  *
15148  * See foo_igen_inline_docs_call_foo_method_sync() for the synchronous, blocking version of this method.
15149  */
15150 void
15151 foo_igen_inline_docs_call_foo_method (
15152     FooiGenInlineDocs *proxy,
15153     const gchar *arg_greeting,
15154     GCancellable *cancellable,
15155     GAsyncReadyCallback callback,
15156     gpointer user_data)
15157 {
15158   g_dbus_proxy_call (G_DBUS_PROXY (proxy),
15159     "FooMethod",
15160     g_variant_new ("(s)",
15161                    arg_greeting),
15162     G_DBUS_CALL_FLAGS_NONE,
15163     -1,
15164     cancellable,
15165     callback,
15166     user_data);
15167 }
15168
15169 /**
15170  * foo_igen_inline_docs_call_foo_method_finish:
15171  * @proxy: A #FooiGenInlineDocsProxy.
15172  * @out_response: (out): Return location for return parameter or %NULL to ignore.
15173  * @res: The #GAsyncResult obtained from the #GAsyncReadyCallback passed to foo_igen_inline_docs_call_foo_method().
15174  * @error: Return location for error or %NULL.
15175  *
15176  * Finishes an operation started with foo_igen_inline_docs_call_foo_method().
15177  *
15178  * Returns: (skip): %TRUE if the call succeded, %FALSE if @error is set.
15179  */
15180 gboolean
15181 foo_igen_inline_docs_call_foo_method_finish (
15182     FooiGenInlineDocs *proxy,
15183     gchar **out_response,
15184     GAsyncResult *res,
15185     GError **error)
15186 {
15187   GVariant *_ret;
15188   _ret = g_dbus_proxy_call_finish (G_DBUS_PROXY (proxy), res, error);
15189   if (_ret == NULL)
15190     goto _out;
15191   g_variant_get (_ret,
15192                  "(s)",
15193                  out_response);
15194   g_variant_unref (_ret);
15195 _out:
15196   return _ret != NULL;
15197 }
15198
15199 /**
15200  * foo_igen_inline_docs_call_foo_method_sync:
15201  * @proxy: A #FooiGenInlineDocsProxy.
15202  * @arg_greeting: Argument to pass with the method invocation.
15203  * @out_response: (out): Return location for return parameter or %NULL to ignore.
15204  * @cancellable: (allow-none): A #GCancellable or %NULL.
15205  * @error: Return location for error or %NULL.
15206  *
15207  * Synchronously invokes the <link linkend="gdbus-method-org-project-InlineDocs.FooMethod">FooMethod()</link> D-Bus method on @proxy. The calling thread is blocked until a reply is received.
15208  *
15209  * See foo_igen_inline_docs_call_foo_method() for the asynchronous version of this method.
15210  *
15211  * Returns: (skip): %TRUE if the call succeded, %FALSE if @error is set.
15212  */
15213 gboolean
15214 foo_igen_inline_docs_call_foo_method_sync (
15215     FooiGenInlineDocs *proxy,
15216     const gchar *arg_greeting,
15217     gchar **out_response,
15218     GCancellable *cancellable,
15219     GError **error)
15220 {
15221   GVariant *_ret;
15222   _ret = g_dbus_proxy_call_sync (G_DBUS_PROXY (proxy),
15223     "FooMethod",
15224     g_variant_new ("(s)",
15225                    arg_greeting),
15226     G_DBUS_CALL_FLAGS_NONE,
15227     -1,
15228     cancellable,
15229     error);
15230   if (_ret == NULL)
15231     goto _out;
15232   g_variant_get (_ret,
15233                  "(s)",
15234                  out_response);
15235   g_variant_unref (_ret);
15236 _out:
15237   return _ret != NULL;
15238 }
15239
15240 /**
15241  * foo_igen_inline_docs_call_method2:
15242  * @proxy: A #FooiGenInlineDocsProxy.
15243  * @arg_greeting: Argument to pass with the method invocation.
15244  * @cancellable: (allow-none): A #GCancellable or %NULL.
15245  * @callback: A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
15246  * @user_data: User data to pass to @callback.
15247  *
15248  * Asynchronously invokes the <link linkend="gdbus-method-org-project-InlineDocs.Method2">Method2()</link> D-Bus method on @proxy.
15249  * When the operation is finished, @callback will be invoked in the <link linkend="g-main-context-push-thread-default">thread-default main loop</link> of the thread you are calling this method from.
15250  * You can then call foo_igen_inline_docs_call_method2_finish() to get the result of the operation.
15251  *
15252  * See foo_igen_inline_docs_call_method2_sync() for the synchronous, blocking version of this method.
15253  */
15254 void
15255 foo_igen_inline_docs_call_method2 (
15256     FooiGenInlineDocs *proxy,
15257     const gchar *arg_greeting,
15258     GCancellable *cancellable,
15259     GAsyncReadyCallback callback,
15260     gpointer user_data)
15261 {
15262   g_dbus_proxy_call (G_DBUS_PROXY (proxy),
15263     "Method2",
15264     g_variant_new ("(s)",
15265                    arg_greeting),
15266     G_DBUS_CALL_FLAGS_NONE,
15267     -1,
15268     cancellable,
15269     callback,
15270     user_data);
15271 }
15272
15273 /**
15274  * foo_igen_inline_docs_call_method2_finish:
15275  * @proxy: A #FooiGenInlineDocsProxy.
15276  * @out_response: (out): Return location for return parameter or %NULL to ignore.
15277  * @res: The #GAsyncResult obtained from the #GAsyncReadyCallback passed to foo_igen_inline_docs_call_method2().
15278  * @error: Return location for error or %NULL.
15279  *
15280  * Finishes an operation started with foo_igen_inline_docs_call_method2().
15281  *
15282  * Returns: (skip): %TRUE if the call succeded, %FALSE if @error is set.
15283  */
15284 gboolean
15285 foo_igen_inline_docs_call_method2_finish (
15286     FooiGenInlineDocs *proxy,
15287     gchar **out_response,
15288     GAsyncResult *res,
15289     GError **error)
15290 {
15291   GVariant *_ret;
15292   _ret = g_dbus_proxy_call_finish (G_DBUS_PROXY (proxy), res, error);
15293   if (_ret == NULL)
15294     goto _out;
15295   g_variant_get (_ret,
15296                  "(s)",
15297                  out_response);
15298   g_variant_unref (_ret);
15299 _out:
15300   return _ret != NULL;
15301 }
15302
15303 /**
15304  * foo_igen_inline_docs_call_method2_sync:
15305  * @proxy: A #FooiGenInlineDocsProxy.
15306  * @arg_greeting: Argument to pass with the method invocation.
15307  * @out_response: (out): Return location for return parameter or %NULL to ignore.
15308  * @cancellable: (allow-none): A #GCancellable or %NULL.
15309  * @error: Return location for error or %NULL.
15310  *
15311  * Synchronously invokes the <link linkend="gdbus-method-org-project-InlineDocs.Method2">Method2()</link> D-Bus method on @proxy. The calling thread is blocked until a reply is received.
15312  *
15313  * See foo_igen_inline_docs_call_method2() for the asynchronous version of this method.
15314  *
15315  * Returns: (skip): %TRUE if the call succeded, %FALSE if @error is set.
15316  */
15317 gboolean
15318 foo_igen_inline_docs_call_method2_sync (
15319     FooiGenInlineDocs *proxy,
15320     const gchar *arg_greeting,
15321     gchar **out_response,
15322     GCancellable *cancellable,
15323     GError **error)
15324 {
15325   GVariant *_ret;
15326   _ret = g_dbus_proxy_call_sync (G_DBUS_PROXY (proxy),
15327     "Method2",
15328     g_variant_new ("(s)",
15329                    arg_greeting),
15330     G_DBUS_CALL_FLAGS_NONE,
15331     -1,
15332     cancellable,
15333     error);
15334   if (_ret == NULL)
15335     goto _out;
15336   g_variant_get (_ret,
15337                  "(s)",
15338                  out_response);
15339   g_variant_unref (_ret);
15340 _out:
15341   return _ret != NULL;
15342 }
15343
15344 /**
15345  * foo_igen_inline_docs_complete_foo_method:
15346  * @object: A #FooiGenInlineDocs.
15347  * @invocation: (transfer full): A #GDBusMethodInvocation.
15348  * @response: Parameter to return.
15349  *
15350  * Helper function used in service implementations to finish handling invocations of the <link linkend="gdbus-method-org-project-InlineDocs.FooMethod">FooMethod()</link> D-Bus method. If you instead want to finish handling an invocation by returning an error, use g_dbus_method_invocation_return_error() or similar.
15351  *
15352  * This method will free @invocation, you cannot use it afterwards.
15353  */
15354 void
15355 foo_igen_inline_docs_complete_foo_method (
15356     FooiGenInlineDocs *object,
15357     GDBusMethodInvocation *invocation,
15358     const gchar *response)
15359 {
15360   g_dbus_method_invocation_return_value (invocation,
15361     g_variant_new ("(s)",
15362                    response));
15363 }
15364
15365 /**
15366  * foo_igen_inline_docs_complete_method2:
15367  * @object: A #FooiGenInlineDocs.
15368  * @invocation: (transfer full): A #GDBusMethodInvocation.
15369  * @response: Parameter to return.
15370  *
15371  * Helper function used in service implementations to finish handling invocations of the <link linkend="gdbus-method-org-project-InlineDocs.Method2">Method2()</link> D-Bus method. If you instead want to finish handling an invocation by returning an error, use g_dbus_method_invocation_return_error() or similar.
15372  *
15373  * This method will free @invocation, you cannot use it afterwards.
15374  */
15375 void
15376 foo_igen_inline_docs_complete_method2 (
15377     FooiGenInlineDocs *object,
15378     GDBusMethodInvocation *invocation,
15379     const gchar *response)
15380 {
15381   g_dbus_method_invocation_return_value (invocation,
15382     g_variant_new ("(s)",
15383                    response));
15384 }
15385
15386 /* ------------------------------------------------------------------------ */
15387
15388 /**
15389  * FooiGenInlineDocsProxy:
15390  *
15391  * The #FooiGenInlineDocsProxy structure contains only private data and should only be accessed using the provided API.
15392  */
15393
15394 /**
15395  * FooiGenInlineDocsProxyClass:
15396  * @parent_class: The parent class.
15397  *
15398  * Class structure for #FooiGenInlineDocsProxy.
15399  */
15400
15401 struct _FooiGenInlineDocsProxyPrivate
15402 {
15403   GData *qdata;
15404 };
15405
15406 static void foo_igen_inline_docs_proxy_iface_init (FooiGenInlineDocsIface *iface);
15407
15408 G_DEFINE_TYPE_WITH_CODE (FooiGenInlineDocsProxy, foo_igen_inline_docs_proxy, G_TYPE_DBUS_PROXY,
15409                          G_IMPLEMENT_INTERFACE (FOO_IGEN_TYPE_INLINE_DOCS, foo_igen_inline_docs_proxy_iface_init));
15410
15411 static void
15412 foo_igen_inline_docs_proxy_finalize (GObject *object)
15413 {
15414   FooiGenInlineDocsProxy *proxy = FOO_IGEN_INLINE_DOCS_PROXY (object);
15415   g_datalist_clear (&proxy->priv->qdata);
15416   G_OBJECT_CLASS (foo_igen_inline_docs_proxy_parent_class)->finalize (object);
15417 }
15418
15419 static void
15420 foo_igen_inline_docs_proxy_get_property (GObject      *object,
15421   guint         prop_id,
15422   GValue       *value,
15423   GParamSpec   *pspec)
15424 {
15425   const _ExtendedGDBusPropertyInfo *info;
15426   GVariant *variant;
15427   g_assert (prop_id != 0 && prop_id - 1 < 6);
15428   info = _foo_igen_inline_docs_property_info_pointers[prop_id - 1];
15429   variant = g_dbus_proxy_get_cached_property (G_DBUS_PROXY (object), info->parent_struct.name);
15430   if (info->use_gvariant)
15431     {
15432       g_value_set_variant (value, variant);
15433     }
15434   else
15435     {
15436       if (variant != NULL)
15437         g_dbus_gvariant_to_gvalue (variant, value);
15438     }
15439   if (variant != NULL)
15440     g_variant_unref (variant);
15441 }
15442
15443 static void
15444 foo_igen_inline_docs_proxy_set_property_cb (GDBusProxy *proxy,
15445   GAsyncResult *res,
15446   gpointer      user_data)
15447 {
15448   const _ExtendedGDBusPropertyInfo *info = user_data;
15449   GError *error;
15450   error = NULL;
15451   if (!g_dbus_proxy_call_finish (proxy, res, &error))
15452     {
15453       g_warning ("Error setting property `%s' on interface org.project.InlineDocs: %s (%s, %d)",
15454                  info->parent_struct.name, 
15455                  error->message, g_quark_to_string (error->domain), error->code);
15456       g_error_free (error);
15457     }
15458 }
15459
15460 static void
15461 foo_igen_inline_docs_proxy_set_property (GObject      *object,
15462   guint         prop_id,
15463   const GValue *value,
15464   GParamSpec   *pspec)
15465 {
15466   const _ExtendedGDBusPropertyInfo *info;
15467   GVariant *variant;
15468   g_assert (prop_id != 0 && prop_id - 1 < 6);
15469   info = _foo_igen_inline_docs_property_info_pointers[prop_id - 1];
15470   variant = g_dbus_gvalue_to_gvariant (value, G_VARIANT_TYPE (info->parent_struct.signature));
15471   g_dbus_proxy_call (G_DBUS_PROXY (object),
15472     "org.freedesktop.DBus.Properties.Set",
15473     g_variant_new ("(ssv)", "org.project.InlineDocs", info->parent_struct.name, variant),
15474     G_DBUS_CALL_FLAGS_NONE,
15475     -1,
15476     NULL, (GAsyncReadyCallback) foo_igen_inline_docs_proxy_set_property_cb, (gpointer) info);
15477   g_variant_unref (variant);
15478 }
15479
15480 static void
15481 foo_igen_inline_docs_proxy_g_signal (GDBusProxy *proxy,
15482   const gchar *sender_name,
15483   const gchar *signal_name,
15484   GVariant *parameters)
15485 {
15486   _ExtendedGDBusSignalInfo *info;
15487   GVariantIter iter;
15488   GVariant *child;
15489   GValue *paramv;
15490   guint num_params;
15491   guint n;
15492   guint signal_id;
15493   info = (_ExtendedGDBusSignalInfo *) g_dbus_interface_info_lookup_signal ((GDBusInterfaceInfo *) &_foo_igen_inline_docs_interface_info, signal_name);
15494   if (info == NULL)
15495     return;
15496   num_params = g_variant_n_children (parameters);
15497   paramv = g_new0 (GValue, num_params + 1);
15498   g_value_init (&paramv[0], FOO_IGEN_TYPE_INLINE_DOCS);
15499   g_value_set_object (&paramv[0], proxy);
15500   g_variant_iter_init (&iter, parameters);
15501   n = 1;
15502   while ((child = g_variant_iter_next_value (&iter)) != NULL)
15503     {
15504       _ExtendedGDBusArgInfo *arg_info = (_ExtendedGDBusArgInfo *) info->parent_struct.args[n - 1];
15505       if (arg_info->use_gvariant)
15506         {
15507           g_value_init (&paramv[n], G_TYPE_VARIANT);
15508           g_value_set_variant (&paramv[n], child);
15509           n++;
15510         }
15511       else
15512         g_dbus_gvariant_to_gvalue (child, &paramv[n++]);
15513       g_variant_unref (child);
15514     }
15515   signal_id = g_signal_lookup (info->signal_name, FOO_IGEN_TYPE_INLINE_DOCS);
15516   g_signal_emitv (paramv, signal_id, 0, NULL);
15517   for (n = 0; n < num_params + 1; n++)
15518     g_value_unset (&paramv[n]);
15519   g_free (paramv);
15520 }
15521
15522 static void
15523 foo_igen_inline_docs_proxy_g_properties_changed (GDBusProxy *_proxy,
15524   GVariant *changed_properties,
15525   const gchar *const *invalidated_properties)
15526 {
15527   FooiGenInlineDocsProxy *proxy = FOO_IGEN_INLINE_DOCS_PROXY (_proxy);
15528   guint n;
15529   const gchar *key;
15530   GVariantIter *iter;
15531   _ExtendedGDBusPropertyInfo *info;
15532   g_variant_get (changed_properties, "a{sv}", &iter);
15533   while (g_variant_iter_next (iter, "{&sv}", &key, NULL))
15534     {
15535       info = (_ExtendedGDBusPropertyInfo *) g_dbus_interface_info_lookup_property ((GDBusInterfaceInfo *) &_foo_igen_inline_docs_interface_info, key);
15536       g_datalist_remove_data (&proxy->priv->qdata, key);
15537       if (info != NULL)
15538         g_object_notify (G_OBJECT (proxy), info->hyphen_name);
15539     }
15540   g_variant_iter_free (iter);
15541   for (n = 0; invalidated_properties[n] != NULL; n++)
15542     {
15543       info = (_ExtendedGDBusPropertyInfo *) g_dbus_interface_info_lookup_property ((GDBusInterfaceInfo *) &_foo_igen_inline_docs_interface_info, invalidated_properties[n]);
15544       g_datalist_remove_data (&proxy->priv->qdata, invalidated_properties[n]);
15545       if (info != NULL)
15546         g_object_notify (G_OBJECT (proxy), info->hyphen_name);
15547     }
15548 }
15549
15550 static const gchar *
15551 foo_igen_inline_docs_proxy_get_baz_property (FooiGenInlineDocs *object)
15552 {
15553   FooiGenInlineDocsProxy *proxy = FOO_IGEN_INLINE_DOCS_PROXY (object);
15554   GVariant *variant;
15555   const gchar *value = NULL;
15556   variant = g_dbus_proxy_get_cached_property (G_DBUS_PROXY (proxy), "BazProperty");
15557   if (variant != NULL)
15558     {
15559       value = g_variant_get_string (variant, NULL);
15560       g_variant_unref (variant);
15561     }
15562   return value;
15563 }
15564
15565 static const gchar *
15566 foo_igen_inline_docs_proxy_get_property2 (FooiGenInlineDocs *object)
15567 {
15568   FooiGenInlineDocsProxy *proxy = FOO_IGEN_INLINE_DOCS_PROXY (object);
15569   GVariant *variant;
15570   const gchar *value = NULL;
15571   variant = g_dbus_proxy_get_cached_property (G_DBUS_PROXY (proxy), "Property2");
15572   if (variant != NULL)
15573     {
15574       value = g_variant_get_string (variant, NULL);
15575       g_variant_unref (variant);
15576     }
15577   return value;
15578 }
15579
15580 static const gchar *
15581 foo_igen_inline_docs_proxy_get_property3 (FooiGenInlineDocs *object)
15582 {
15583   FooiGenInlineDocsProxy *proxy = FOO_IGEN_INLINE_DOCS_PROXY (object);
15584   GVariant *variant;
15585   const gchar *value = NULL;
15586   variant = g_dbus_proxy_get_cached_property (G_DBUS_PROXY (proxy), "Property3");
15587   if (variant != NULL)
15588     {
15589       value = g_variant_get_string (variant, NULL);
15590       g_variant_unref (variant);
15591     }
15592   return value;
15593 }
15594
15595 static const gchar *
15596 foo_igen_inline_docs_proxy_get_property4 (FooiGenInlineDocs *object)
15597 {
15598   FooiGenInlineDocsProxy *proxy = FOO_IGEN_INLINE_DOCS_PROXY (object);
15599   GVariant *variant;
15600   const gchar *value = NULL;
15601   variant = g_dbus_proxy_get_cached_property (G_DBUS_PROXY (proxy), "Property4");
15602   if (variant != NULL)
15603     {
15604       value = g_variant_get_string (variant, NULL);
15605       g_variant_unref (variant);
15606     }
15607   return value;
15608 }
15609
15610 static const gchar *
15611 foo_igen_inline_docs_proxy_get_property5 (FooiGenInlineDocs *object)
15612 {
15613   FooiGenInlineDocsProxy *proxy = FOO_IGEN_INLINE_DOCS_PROXY (object);
15614   GVariant *variant;
15615   const gchar *value = NULL;
15616   variant = g_dbus_proxy_get_cached_property (G_DBUS_PROXY (proxy), "Property5");
15617   if (variant != NULL)
15618     {
15619       value = g_variant_get_string (variant, NULL);
15620       g_variant_unref (variant);
15621     }
15622   return value;
15623 }
15624
15625 static const gchar *
15626 foo_igen_inline_docs_proxy_get_fancy_property (FooiGenInlineDocs *object)
15627 {
15628   FooiGenInlineDocsProxy *proxy = FOO_IGEN_INLINE_DOCS_PROXY (object);
15629   GVariant *variant;
15630   const gchar *value = NULL;
15631   variant = g_dbus_proxy_get_cached_property (G_DBUS_PROXY (proxy), "FancyProperty");
15632   if (variant != NULL)
15633     {
15634       value = g_variant_get_string (variant, NULL);
15635       g_variant_unref (variant);
15636     }
15637   return value;
15638 }
15639
15640 static void
15641 foo_igen_inline_docs_proxy_init (FooiGenInlineDocsProxy *proxy)
15642 {
15643   proxy->priv = G_TYPE_INSTANCE_GET_PRIVATE (proxy, FOO_IGEN_TYPE_INLINE_DOCS_PROXY, FooiGenInlineDocsProxyPrivate);
15644   g_dbus_proxy_set_interface_info (G_DBUS_PROXY (proxy), foo_igen_inline_docs_interface_info ());
15645 }
15646
15647 static void
15648 foo_igen_inline_docs_proxy_class_init (FooiGenInlineDocsProxyClass *klass)
15649 {
15650   GObjectClass *gobject_class;
15651   GDBusProxyClass *proxy_class;
15652
15653   g_type_class_add_private (klass, sizeof (FooiGenInlineDocsProxyPrivate));
15654
15655   gobject_class = G_OBJECT_CLASS (klass);
15656   gobject_class->finalize     = foo_igen_inline_docs_proxy_finalize;
15657   gobject_class->get_property = foo_igen_inline_docs_proxy_get_property;
15658   gobject_class->set_property = foo_igen_inline_docs_proxy_set_property;
15659
15660   proxy_class = G_DBUS_PROXY_CLASS (klass);
15661   proxy_class->g_signal = foo_igen_inline_docs_proxy_g_signal;
15662   proxy_class->g_properties_changed = foo_igen_inline_docs_proxy_g_properties_changed;
15663
15664
15665   foo_igen_inline_docs_override_properties (gobject_class, 1);
15666 }
15667
15668 static void
15669 foo_igen_inline_docs_proxy_iface_init (FooiGenInlineDocsIface *iface)
15670 {
15671   iface->get_baz_property = foo_igen_inline_docs_proxy_get_baz_property;
15672   iface->get_property2 = foo_igen_inline_docs_proxy_get_property2;
15673   iface->get_property3 = foo_igen_inline_docs_proxy_get_property3;
15674   iface->get_property4 = foo_igen_inline_docs_proxy_get_property4;
15675   iface->get_property5 = foo_igen_inline_docs_proxy_get_property5;
15676   iface->get_fancy_property = foo_igen_inline_docs_proxy_get_fancy_property;
15677 }
15678
15679 /**
15680  * foo_igen_inline_docs_proxy_new:
15681  * @connection: A #GDBusConnection.
15682  * @flags: Flags from the #GDBusProxyFlags enumeration.
15683  * @name: (allow-none): A bus name (well-known or unique) or %NULL if @connection is not a message bus connection.
15684  * @object_path: An object path.
15685  * @cancellable: (allow-none): A #GCancellable or %NULL.
15686  * @callback: A #GAsyncReadyCallback to call when the request is satisfied.
15687  * @user_data: User data to pass to @callback.
15688  *
15689  * Asynchronously creates a proxy for the D-Bus interface <link linkend="gdbus-interface-org-project-InlineDocs.top_of_page">org.project.InlineDocs</link>. See g_dbus_proxy_new() for more details.
15690  *
15691  * When the operation is finished, @callback will be invoked in the <link linkend="g-main-context-push-thread-default">thread-default main loop</link> of the thread you are calling this method from.
15692  * You can then call foo_igen_inline_docs_proxy_new_finish() to get the result of the operation.
15693  *
15694  * See foo_igen_inline_docs_proxy_new_sync() for the synchronous, blocking version of this constructor.
15695  */
15696 void
15697 foo_igen_inline_docs_proxy_new (
15698     GDBusConnection     *connection,
15699     GDBusProxyFlags      flags,
15700     const gchar         *name,
15701     const gchar         *object_path,
15702     GCancellable        *cancellable,
15703     GAsyncReadyCallback  callback,
15704     gpointer             user_data)
15705 {
15706   g_async_initable_new_async (FOO_IGEN_TYPE_INLINE_DOCS_PROXY, G_PRIORITY_DEFAULT, cancellable, callback, user_data, "g-flags", flags, "g-name", name, "g-connection", connection, "g-object-path", object_path, "g-interface-name", "org.project.InlineDocs", NULL);
15707 }
15708
15709 /**
15710  * foo_igen_inline_docs_proxy_new_finish:
15711  * @res: The #GAsyncResult obtained from the #GAsyncReadyCallback passed to foo_igen_inline_docs_proxy_new().
15712  * @error: Return location for error or %NULL
15713  *
15714  * Finishes an operation started with foo_igen_inline_docs_proxy_new().
15715  *
15716  * Returns: (transfer full) (type FooiGenInlineDocsProxy): The constructed proxy object or %NULL if @error is set.
15717  */
15718 FooiGenInlineDocs *
15719 foo_igen_inline_docs_proxy_new_finish (
15720     GAsyncResult        *res,
15721     GError             **error)
15722 {
15723   GObject *ret;
15724   GObject *source_object;
15725   source_object = g_async_result_get_source_object (res);
15726   ret = g_async_initable_new_finish (G_ASYNC_INITABLE (source_object), res, error);
15727   g_object_unref (source_object);
15728   if (ret != NULL)
15729     return FOO_IGEN_INLINE_DOCS (ret);
15730   else
15731     return NULL;
15732 }
15733
15734 /**
15735  * foo_igen_inline_docs_proxy_new_sync:
15736  * @connection: A #GDBusConnection.
15737  * @flags: Flags from the #GDBusProxyFlags enumeration.
15738  * @name: (allow-none): A bus name (well-known or unique) or %NULL if @connection is not a message bus connection.
15739  * @object_path: An object path.
15740  * @cancellable: (allow-none): A #GCancellable or %NULL.
15741  * @error: Return location for error or %NULL
15742  *
15743  * Synchronously creates a proxy for the D-Bus interface <link linkend="gdbus-interface-org-project-InlineDocs.top_of_page">org.project.InlineDocs</link>. See g_dbus_proxy_new_sync() for more details.
15744  *
15745  * The calling thread is blocked until a reply is received.
15746  *
15747  * See foo_igen_inline_docs_proxy_new() for the asynchronous version of this constructor.
15748  *
15749  * Returns: (transfer full) (type FooiGenInlineDocsProxy): The constructed proxy object or %NULL if @error is set.
15750  */
15751 FooiGenInlineDocs *
15752 foo_igen_inline_docs_proxy_new_sync (
15753     GDBusConnection     *connection,
15754     GDBusProxyFlags      flags,
15755     const gchar         *name,
15756     const gchar         *object_path,
15757     GCancellable        *cancellable,
15758     GError             **error)
15759 {
15760   GInitable *ret;
15761   ret = g_initable_new (FOO_IGEN_TYPE_INLINE_DOCS_PROXY, cancellable, error, "g-flags", flags, "g-name", name, "g-connection", connection, "g-object-path", object_path, "g-interface-name", "org.project.InlineDocs", NULL);
15762   if (ret != NULL)
15763     return FOO_IGEN_INLINE_DOCS (ret);
15764   else
15765     return NULL;
15766 }
15767
15768
15769 /**
15770  * foo_igen_inline_docs_proxy_new_for_bus:
15771  * @bus_type: A #GBusType.
15772  * @flags: Flags from the #GDBusProxyFlags enumeration.
15773  * @name: A bus name (well-known or unique).
15774  * @object_path: An object path.
15775  * @cancellable: (allow-none): A #GCancellable or %NULL.
15776  * @callback: A #GAsyncReadyCallback to call when the request is satisfied.
15777  * @user_data: User data to pass to @callback.
15778  *
15779  * Like foo_igen_inline_docs_proxy_new() but takes a #GBusType instead of a #GDBusConnection.
15780  *
15781  * When the operation is finished, @callback will be invoked in the <link linkend="g-main-context-push-thread-default">thread-default main loop</link> of the thread you are calling this method from.
15782  * You can then call foo_igen_inline_docs_proxy_new_for_bus_finish() to get the result of the operation.
15783  *
15784  * See foo_igen_inline_docs_proxy_new_for_bus_sync() for the synchronous, blocking version of this constructor.
15785  */
15786 void
15787 foo_igen_inline_docs_proxy_new_for_bus (
15788     GBusType             bus_type,
15789     GDBusProxyFlags      flags,
15790     const gchar         *name,
15791     const gchar         *object_path,
15792     GCancellable        *cancellable,
15793     GAsyncReadyCallback  callback,
15794     gpointer             user_data)
15795 {
15796   g_async_initable_new_async (FOO_IGEN_TYPE_INLINE_DOCS_PROXY, G_PRIORITY_DEFAULT, cancellable, callback, user_data, "g-flags", flags, "g-name", name, "g-bus-type", bus_type, "g-object-path", object_path, "g-interface-name", "org.project.InlineDocs", NULL);
15797 }
15798
15799 /**
15800  * foo_igen_inline_docs_proxy_new_for_bus_finish:
15801  * @res: The #GAsyncResult obtained from the #GAsyncReadyCallback passed to foo_igen_inline_docs_proxy_new_for_bus().
15802  * @error: Return location for error or %NULL
15803  *
15804  * Finishes an operation started with foo_igen_inline_docs_proxy_new_for_bus().
15805  *
15806  * Returns: (transfer full) (type FooiGenInlineDocsProxy): The constructed proxy object or %NULL if @error is set.
15807  */
15808 FooiGenInlineDocs *
15809 foo_igen_inline_docs_proxy_new_for_bus_finish (
15810     GAsyncResult        *res,
15811     GError             **error)
15812 {
15813   GObject *ret;
15814   GObject *source_object;
15815   source_object = g_async_result_get_source_object (res);
15816   ret = g_async_initable_new_finish (G_ASYNC_INITABLE (source_object), res, error);
15817   g_object_unref (source_object);
15818   if (ret != NULL)
15819     return FOO_IGEN_INLINE_DOCS (ret);
15820   else
15821     return NULL;
15822 }
15823
15824 /**
15825  * foo_igen_inline_docs_proxy_new_for_bus_sync:
15826  * @bus_type: A #GBusType.
15827  * @flags: Flags from the #GDBusProxyFlags enumeration.
15828  * @name: A bus name (well-known or unique).
15829  * @object_path: An object path.
15830  * @cancellable: (allow-none): A #GCancellable or %NULL.
15831  * @error: Return location for error or %NULL
15832  *
15833  * Like foo_igen_inline_docs_proxy_new_sync() but takes a #GBusType instead of a #GDBusConnection.
15834  *
15835  * The calling thread is blocked until a reply is received.
15836  *
15837  * See foo_igen_inline_docs_proxy_new_for_bus() for the asynchronous version of this constructor.
15838  *
15839  * Returns: (transfer full) (type FooiGenInlineDocsProxy): The constructed proxy object or %NULL if @error is set.
15840  */
15841 FooiGenInlineDocs *
15842 foo_igen_inline_docs_proxy_new_for_bus_sync (
15843     GBusType             bus_type,
15844     GDBusProxyFlags      flags,
15845     const gchar         *name,
15846     const gchar         *object_path,
15847     GCancellable        *cancellable,
15848     GError             **error)
15849 {
15850   GInitable *ret;
15851   ret = g_initable_new (FOO_IGEN_TYPE_INLINE_DOCS_PROXY, cancellable, error, "g-flags", flags, "g-name", name, "g-bus-type", bus_type, "g-object-path", object_path, "g-interface-name", "org.project.InlineDocs", NULL);
15852   if (ret != NULL)
15853     return FOO_IGEN_INLINE_DOCS (ret);
15854   else
15855     return NULL;
15856 }
15857
15858
15859 /* ------------------------------------------------------------------------ */
15860
15861 /**
15862  * FooiGenInlineDocsSkeleton:
15863  *
15864  * The #FooiGenInlineDocsSkeleton structure contains only private data and should only be accessed using the provided API.
15865  */
15866
15867 /**
15868  * FooiGenInlineDocsSkeletonClass:
15869  * @parent_class: The parent class.
15870  *
15871  * Class structure for #FooiGenInlineDocsSkeleton.
15872  */
15873
15874 struct _FooiGenInlineDocsSkeletonPrivate
15875 {
15876   GValue *properties;
15877   GList *changed_properties;
15878   GSource *changed_properties_idle_source;
15879   GMainContext *context;
15880   GMutex lock;
15881 };
15882
15883 static void
15884 _foo_igen_inline_docs_skeleton_handle_method_call (
15885   GDBusConnection *connection,
15886   const gchar *sender,
15887   const gchar *object_path,
15888   const gchar *interface_name,
15889   const gchar *method_name,
15890   GVariant *parameters,
15891   GDBusMethodInvocation *invocation,
15892   gpointer user_data)
15893 {
15894   FooiGenInlineDocsSkeleton *skeleton = FOO_IGEN_INLINE_DOCS_SKELETON (user_data);
15895   _ExtendedGDBusMethodInfo *info;
15896   GVariantIter iter;
15897   GVariant *child;
15898   GValue *paramv;
15899   guint num_params;
15900   guint num_extra;
15901   guint n;
15902   guint signal_id;
15903   GValue return_value = G_VALUE_INIT;
15904   info = (_ExtendedGDBusMethodInfo *) g_dbus_method_invocation_get_method_info (invocation);
15905   g_assert (info != NULL);
15906   num_params = g_variant_n_children (parameters);
15907   num_extra = info->pass_fdlist ? 3 : 2;  paramv = g_new0 (GValue, num_params + num_extra);
15908   n = 0;
15909   g_value_init (&paramv[n], FOO_IGEN_TYPE_INLINE_DOCS);
15910   g_value_set_object (&paramv[n++], skeleton);
15911   g_value_init (&paramv[n], G_TYPE_DBUS_METHOD_INVOCATION);
15912   g_value_set_object (&paramv[n++], invocation);
15913   if (info->pass_fdlist)
15914     {
15915 #ifdef G_OS_UNIX
15916       g_value_init (&paramv[n], G_TYPE_UNIX_FD_LIST);
15917       g_value_set_object (&paramv[n++], g_dbus_message_get_unix_fd_list (g_dbus_method_invocation_get_message (invocation)));
15918 #else
15919       g_assert_not_reached ();
15920 #endif
15921     }
15922   g_variant_iter_init (&iter, parameters);
15923   while ((child = g_variant_iter_next_value (&iter)) != NULL)
15924     {
15925       _ExtendedGDBusArgInfo *arg_info = (_ExtendedGDBusArgInfo *) info->parent_struct.in_args[n - num_extra];
15926       if (arg_info->use_gvariant)
15927         {
15928           g_value_init (&paramv[n], G_TYPE_VARIANT);
15929           g_value_set_variant (&paramv[n], child);
15930           n++;
15931         }
15932       else
15933         g_dbus_gvariant_to_gvalue (child, &paramv[n++]);
15934       g_variant_unref (child);
15935     }
15936   signal_id = g_signal_lookup (info->signal_name, FOO_IGEN_TYPE_INLINE_DOCS);
15937   g_value_init (&return_value, G_TYPE_BOOLEAN);
15938   g_signal_emitv (paramv, signal_id, 0, &return_value);
15939   if (!g_value_get_boolean (&return_value))
15940     g_dbus_method_invocation_return_error (invocation, G_DBUS_ERROR, G_DBUS_ERROR_UNKNOWN_METHOD, "Method %s is not implemented on interface %s", method_name, interface_name);
15941   g_value_unset (&return_value);
15942   for (n = 0; n < num_params + num_extra; n++)
15943     g_value_unset (&paramv[n]);
15944   g_free (paramv);
15945 }
15946
15947 static GVariant *
15948 _foo_igen_inline_docs_skeleton_handle_get_property (
15949   GDBusConnection *connection,
15950   const gchar *sender,
15951   const gchar *object_path,
15952   const gchar *interface_name,
15953   const gchar *property_name,
15954   GError **error,
15955   gpointer user_data)
15956 {
15957   FooiGenInlineDocsSkeleton *skeleton = FOO_IGEN_INLINE_DOCS_SKELETON (user_data);
15958   GValue value = G_VALUE_INIT;
15959   GParamSpec *pspec;
15960   _ExtendedGDBusPropertyInfo *info;
15961   GVariant *ret;
15962   ret = NULL;
15963   info = (_ExtendedGDBusPropertyInfo *) g_dbus_interface_info_lookup_property ((GDBusInterfaceInfo *) &_foo_igen_inline_docs_interface_info, property_name);
15964   g_assert (info != NULL);
15965   pspec = g_object_class_find_property (G_OBJECT_GET_CLASS (skeleton), info->hyphen_name);
15966   if (pspec == NULL)
15967     {
15968       g_set_error (error, G_DBUS_ERROR, G_DBUS_ERROR_INVALID_ARGS, "No property with name %s", property_name);
15969     }
15970   else
15971     {
15972       g_value_init (&value, pspec->value_type);
15973       g_object_get_property (G_OBJECT (skeleton), info->hyphen_name, &value);
15974       ret = g_dbus_gvalue_to_gvariant (&value, G_VARIANT_TYPE (info->parent_struct.signature));
15975       g_value_unset (&value);
15976     }
15977   return ret;
15978 }
15979
15980 static gboolean
15981 _foo_igen_inline_docs_skeleton_handle_set_property (
15982   GDBusConnection *connection,
15983   const gchar *sender,
15984   const gchar *object_path,
15985   const gchar *interface_name,
15986   const gchar *property_name,
15987   GVariant *variant,
15988   GError **error,
15989   gpointer user_data)
15990 {
15991   FooiGenInlineDocsSkeleton *skeleton = FOO_IGEN_INLINE_DOCS_SKELETON (user_data);
15992   GValue value = G_VALUE_INIT;
15993   GParamSpec *pspec;
15994   _ExtendedGDBusPropertyInfo *info;
15995   gboolean ret;
15996   ret = FALSE;
15997   info = (_ExtendedGDBusPropertyInfo *) g_dbus_interface_info_lookup_property ((GDBusInterfaceInfo *) &_foo_igen_inline_docs_interface_info, property_name);
15998   g_assert (info != NULL);
15999   pspec = g_object_class_find_property (G_OBJECT_GET_CLASS (skeleton), info->hyphen_name);
16000   if (pspec == NULL)
16001     {
16002       g_set_error (error, G_DBUS_ERROR, G_DBUS_ERROR_INVALID_ARGS, "No property with name %s", property_name);
16003     }
16004   else
16005     {
16006       if (info->use_gvariant)
16007         g_value_set_variant (&value, variant);
16008       else
16009         g_dbus_gvariant_to_gvalue (variant, &value);
16010       g_object_set_property (G_OBJECT (skeleton), info->hyphen_name, &value);
16011       g_value_unset (&value);
16012       ret = TRUE;
16013     }
16014   return ret;
16015 }
16016
16017 static const GDBusInterfaceVTable _foo_igen_inline_docs_skeleton_vtable =
16018 {
16019   _foo_igen_inline_docs_skeleton_handle_method_call,
16020   _foo_igen_inline_docs_skeleton_handle_get_property,
16021   _foo_igen_inline_docs_skeleton_handle_set_property
16022 };
16023
16024 static GDBusInterfaceInfo *
16025 foo_igen_inline_docs_skeleton_dbus_interface_get_info (GDBusInterfaceSkeleton *skeleton)
16026 {
16027   return foo_igen_inline_docs_interface_info ();
16028 }
16029
16030 static GDBusInterfaceVTable *
16031 foo_igen_inline_docs_skeleton_dbus_interface_get_vtable (GDBusInterfaceSkeleton *skeleton)
16032 {
16033   return (GDBusInterfaceVTable *) &_foo_igen_inline_docs_skeleton_vtable;
16034 }
16035
16036 static GVariant *
16037 foo_igen_inline_docs_skeleton_dbus_interface_get_properties (GDBusInterfaceSkeleton *_skeleton)
16038 {
16039   FooiGenInlineDocsSkeleton *skeleton = FOO_IGEN_INLINE_DOCS_SKELETON (_skeleton);
16040
16041   GVariantBuilder builder;
16042   guint n;
16043   g_variant_builder_init (&builder, G_VARIANT_TYPE ("a{sv}"));
16044   if (_foo_igen_inline_docs_interface_info.parent_struct.properties == NULL)
16045     goto out;
16046   for (n = 0; _foo_igen_inline_docs_interface_info.parent_struct.properties[n] != NULL; n++)
16047     {
16048       GDBusPropertyInfo *info = _foo_igen_inline_docs_interface_info.parent_struct.properties[n];
16049       if (info->flags & G_DBUS_PROPERTY_INFO_FLAGS_READABLE)
16050         {
16051           GVariant *value;
16052           value = _foo_igen_inline_docs_skeleton_handle_get_property (g_dbus_interface_skeleton_get_connection (G_DBUS_INTERFACE_SKELETON (skeleton)), NULL, g_dbus_interface_skeleton_get_object_path (G_DBUS_INTERFACE_SKELETON (skeleton)), "org.project.InlineDocs", info->name, NULL, skeleton);
16053           if (value != NULL)
16054             {
16055               g_variant_take_ref (value);
16056               g_variant_builder_add (&builder, "{sv}", info->name, value);
16057               g_variant_unref (value);
16058             }
16059         }
16060     }
16061 out:
16062   return g_variant_builder_end (&builder);
16063 }
16064
16065 static gboolean _foo_igen_inline_docs_emit_changed (gpointer user_data);
16066
16067 static void
16068 foo_igen_inline_docs_skeleton_dbus_interface_flush (GDBusInterfaceSkeleton *_skeleton)
16069 {
16070   FooiGenInlineDocsSkeleton *skeleton = FOO_IGEN_INLINE_DOCS_SKELETON (_skeleton);
16071   gboolean emit_changed = FALSE;
16072
16073   g_mutex_lock (&skeleton->priv->lock);
16074   if (skeleton->priv->changed_properties_idle_source != NULL)
16075     {
16076       g_source_destroy (skeleton->priv->changed_properties_idle_source);
16077       skeleton->priv->changed_properties_idle_source = NULL;
16078       emit_changed = TRUE;
16079     }
16080   g_mutex_unlock (&skeleton->priv->lock);
16081
16082   if (emit_changed)
16083     _foo_igen_inline_docs_emit_changed (skeleton);
16084 }
16085
16086 static void
16087 _foo_igen_inline_docs_on_signal_bar_signal (
16088     FooiGenInlineDocs *object,
16089     const gchar *arg_blah,
16090     const gchar *arg_boo)
16091 {
16092   FooiGenInlineDocsSkeleton *skeleton = FOO_IGEN_INLINE_DOCS_SKELETON (object);
16093
16094   GList      *connections, *l;
16095   GVariant   *signal_variant;
16096   connections = g_dbus_interface_skeleton_get_connections (G_DBUS_INTERFACE_SKELETON (skeleton));
16097
16098   signal_variant = g_variant_ref_sink (g_variant_new ("(ss)",
16099                    arg_blah,
16100                    arg_boo));
16101   for (l = connections; l != NULL; l = l->next)
16102     {
16103       GDBusConnection *connection = l->data;
16104       g_dbus_connection_emit_signal (connection,
16105         NULL, g_dbus_interface_skeleton_get_object_path (G_DBUS_INTERFACE_SKELETON (skeleton)), "org.project.InlineDocs", "BarSignal",
16106         signal_variant, NULL);
16107     }
16108   g_variant_unref (signal_variant);
16109   g_list_free_full (connections, g_object_unref);
16110 }
16111
16112 static void foo_igen_inline_docs_skeleton_iface_init (FooiGenInlineDocsIface *iface);
16113 G_DEFINE_TYPE_WITH_CODE (FooiGenInlineDocsSkeleton, foo_igen_inline_docs_skeleton, G_TYPE_DBUS_INTERFACE_SKELETON,
16114                          G_IMPLEMENT_INTERFACE (FOO_IGEN_TYPE_INLINE_DOCS, foo_igen_inline_docs_skeleton_iface_init));
16115
16116 static void
16117 foo_igen_inline_docs_skeleton_finalize (GObject *object)
16118 {
16119   FooiGenInlineDocsSkeleton *skeleton = FOO_IGEN_INLINE_DOCS_SKELETON (object);
16120   guint n;
16121   for (n = 0; n < 6; n++)
16122     g_value_unset (&skeleton->priv->properties[n]);
16123   g_free (skeleton->priv->properties);
16124   g_list_free_full (skeleton->priv->changed_properties, (GDestroyNotify) _changed_property_free);
16125   if (skeleton->priv->changed_properties_idle_source != NULL)
16126     g_source_destroy (skeleton->priv->changed_properties_idle_source);
16127   g_main_context_unref (skeleton->priv->context);
16128   g_mutex_clear (&skeleton->priv->lock);
16129   G_OBJECT_CLASS (foo_igen_inline_docs_skeleton_parent_class)->finalize (object);
16130 }
16131
16132 static void
16133 foo_igen_inline_docs_skeleton_get_property (GObject      *object,
16134   guint         prop_id,
16135   GValue       *value,
16136   GParamSpec   *pspec)
16137 {
16138   FooiGenInlineDocsSkeleton *skeleton = FOO_IGEN_INLINE_DOCS_SKELETON (object);
16139   g_assert (prop_id != 0 && prop_id - 1 < 6);
16140   g_mutex_lock (&skeleton->priv->lock);
16141   g_value_copy (&skeleton->priv->properties[prop_id - 1], value);
16142   g_mutex_unlock (&skeleton->priv->lock);
16143 }
16144
16145 static gboolean
16146 _foo_igen_inline_docs_emit_changed (gpointer user_data)
16147 {
16148   FooiGenInlineDocsSkeleton *skeleton = FOO_IGEN_INLINE_DOCS_SKELETON (user_data);
16149   GList *l;
16150   GVariantBuilder builder;
16151   GVariantBuilder invalidated_builder;
16152   guint num_changes;
16153
16154   g_mutex_lock (&skeleton->priv->lock);
16155   g_variant_builder_init (&builder, G_VARIANT_TYPE ("a{sv}"));
16156   g_variant_builder_init (&invalidated_builder, G_VARIANT_TYPE ("as"));
16157   for (l = skeleton->priv->changed_properties, num_changes = 0; l != NULL; l = l->next)
16158     {
16159       ChangedProperty *cp = l->data;
16160       GVariant *variant;
16161       const GValue *cur_value;
16162
16163       cur_value = &skeleton->priv->properties[cp->prop_id - 1];
16164       if (!_g_value_equal (cur_value, &cp->orig_value))
16165         {
16166           variant = g_dbus_gvalue_to_gvariant (cur_value, G_VARIANT_TYPE (cp->info->parent_struct.signature));
16167           g_variant_builder_add (&builder, "{sv}", cp->info->parent_struct.name, variant);
16168           g_variant_unref (variant);
16169           num_changes++;
16170         }
16171     }
16172   if (num_changes > 0)
16173     {
16174       GList *connections, *l;
16175       GVariant *signal_variant;
16176       signal_variant = g_variant_ref_sink (g_variant_new ("(sa{sv}as)", "org.project.InlineDocs",
16177                                            &builder, &invalidated_builder));
16178       connections = g_dbus_interface_skeleton_get_connections (G_DBUS_INTERFACE_SKELETON (skeleton));
16179       for (l = connections; l != NULL; l = l->next)
16180         {
16181           GDBusConnection *connection = l->data;
16182
16183           g_dbus_connection_emit_signal (connection,
16184                                          NULL, g_dbus_interface_skeleton_get_object_path (G_DBUS_INTERFACE_SKELETON (skeleton)),
16185                                          "org.freedesktop.DBus.Properties",
16186                                          "PropertiesChanged",
16187                                          signal_variant,
16188                                          NULL);
16189         }
16190       g_variant_unref (signal_variant);
16191       g_list_free_full (connections, g_object_unref);
16192     }
16193   else
16194     {
16195       g_variant_builder_clear (&builder);
16196       g_variant_builder_clear (&invalidated_builder);
16197     }
16198   g_list_free_full (skeleton->priv->changed_properties, (GDestroyNotify) _changed_property_free);
16199   skeleton->priv->changed_properties = NULL;
16200   skeleton->priv->changed_properties_idle_source = NULL;
16201   g_mutex_unlock (&skeleton->priv->lock);
16202   return FALSE;
16203 }
16204
16205 static void
16206 _foo_igen_inline_docs_schedule_emit_changed (FooiGenInlineDocsSkeleton *skeleton, const _ExtendedGDBusPropertyInfo *info, guint prop_id, const GValue *orig_value)
16207 {
16208   ChangedProperty *cp;
16209   GList *l;
16210   cp = NULL;
16211   for (l = skeleton->priv->changed_properties; l != NULL; l = l->next)
16212     {
16213       ChangedProperty *i_cp = l->data;
16214       if (i_cp->info == info)
16215         {
16216           cp = i_cp;
16217           break;
16218         }
16219     }
16220   if (cp == NULL)
16221     {
16222       cp = g_new0 (ChangedProperty, 1);
16223       cp->prop_id = prop_id;
16224       cp->info = info;
16225       skeleton->priv->changed_properties = g_list_prepend (skeleton->priv->changed_properties, cp);
16226       g_value_init (&cp->orig_value, G_VALUE_TYPE (orig_value));
16227       g_value_copy (orig_value, &cp->orig_value);
16228     }
16229 }
16230
16231 static void
16232 foo_igen_inline_docs_skeleton_notify (GObject      *object,
16233   GParamSpec *pspec)
16234 {
16235   FooiGenInlineDocsSkeleton *skeleton = FOO_IGEN_INLINE_DOCS_SKELETON (object);
16236   g_mutex_lock (&skeleton->priv->lock);
16237   if (skeleton->priv->changed_properties != NULL &&
16238       skeleton->priv->changed_properties_idle_source == NULL)
16239     {
16240       skeleton->priv->changed_properties_idle_source = g_idle_source_new ();
16241       g_source_set_priority (skeleton->priv->changed_properties_idle_source, G_PRIORITY_DEFAULT);
16242       g_source_set_callback (skeleton->priv->changed_properties_idle_source, _foo_igen_inline_docs_emit_changed, g_object_ref (skeleton), (GDestroyNotify) g_object_unref);
16243       g_source_attach (skeleton->priv->changed_properties_idle_source, skeleton->priv->context);
16244       g_source_unref (skeleton->priv->changed_properties_idle_source);
16245     }
16246   g_mutex_unlock (&skeleton->priv->lock);
16247 }
16248
16249 static void
16250 foo_igen_inline_docs_skeleton_set_property (GObject      *object,
16251   guint         prop_id,
16252   const GValue *value,
16253   GParamSpec   *pspec)
16254 {
16255   FooiGenInlineDocsSkeleton *skeleton = FOO_IGEN_INLINE_DOCS_SKELETON (object);
16256   g_assert (prop_id != 0 && prop_id - 1 < 6);
16257   g_mutex_lock (&skeleton->priv->lock);
16258   g_object_freeze_notify (object);
16259   if (!_g_value_equal (value, &skeleton->priv->properties[prop_id - 1]))
16260     {
16261       if (g_dbus_interface_skeleton_get_connection (G_DBUS_INTERFACE_SKELETON (skeleton)) != NULL)
16262         _foo_igen_inline_docs_schedule_emit_changed (skeleton, _foo_igen_inline_docs_property_info_pointers[prop_id - 1], prop_id, &skeleton->priv->properties[prop_id - 1]);
16263       g_value_copy (value, &skeleton->priv->properties[prop_id - 1]);
16264       g_object_notify_by_pspec (object, pspec);
16265     }
16266   g_mutex_unlock (&skeleton->priv->lock);
16267   g_object_thaw_notify (object);
16268 }
16269
16270 static void
16271 foo_igen_inline_docs_skeleton_init (FooiGenInlineDocsSkeleton *skeleton)
16272 {
16273   skeleton->priv = G_TYPE_INSTANCE_GET_PRIVATE (skeleton, FOO_IGEN_TYPE_INLINE_DOCS_SKELETON, FooiGenInlineDocsSkeletonPrivate);
16274   g_mutex_init (&skeleton->priv->lock);
16275   skeleton->priv->context = g_main_context_ref_thread_default ();
16276   skeleton->priv->properties = g_new0 (GValue, 6);
16277   g_value_init (&skeleton->priv->properties[0], G_TYPE_STRING);
16278   g_value_init (&skeleton->priv->properties[1], G_TYPE_STRING);
16279   g_value_init (&skeleton->priv->properties[2], G_TYPE_STRING);
16280   g_value_init (&skeleton->priv->properties[3], G_TYPE_STRING);
16281   g_value_init (&skeleton->priv->properties[4], G_TYPE_STRING);
16282   g_value_init (&skeleton->priv->properties[5], G_TYPE_STRING);
16283 }
16284
16285 static const gchar *
16286 foo_igen_inline_docs_skeleton_get_baz_property (FooiGenInlineDocs *object)
16287 {
16288   FooiGenInlineDocsSkeleton *skeleton = FOO_IGEN_INLINE_DOCS_SKELETON (object);
16289   const gchar *value;
16290   g_mutex_lock (&skeleton->priv->lock);
16291   value = g_value_get_string (&(skeleton->priv->properties[0]));
16292   g_mutex_unlock (&skeleton->priv->lock);
16293   return value;
16294 }
16295
16296 static const gchar *
16297 foo_igen_inline_docs_skeleton_get_property2 (FooiGenInlineDocs *object)
16298 {
16299   FooiGenInlineDocsSkeleton *skeleton = FOO_IGEN_INLINE_DOCS_SKELETON (object);
16300   const gchar *value;
16301   g_mutex_lock (&skeleton->priv->lock);
16302   value = g_value_get_string (&(skeleton->priv->properties[1]));
16303   g_mutex_unlock (&skeleton->priv->lock);
16304   return value;
16305 }
16306
16307 static const gchar *
16308 foo_igen_inline_docs_skeleton_get_property3 (FooiGenInlineDocs *object)
16309 {
16310   FooiGenInlineDocsSkeleton *skeleton = FOO_IGEN_INLINE_DOCS_SKELETON (object);
16311   const gchar *value;
16312   g_mutex_lock (&skeleton->priv->lock);
16313   value = g_value_get_string (&(skeleton->priv->properties[2]));
16314   g_mutex_unlock (&skeleton->priv->lock);
16315   return value;
16316 }
16317
16318 static const gchar *
16319 foo_igen_inline_docs_skeleton_get_property4 (FooiGenInlineDocs *object)
16320 {
16321   FooiGenInlineDocsSkeleton *skeleton = FOO_IGEN_INLINE_DOCS_SKELETON (object);
16322   const gchar *value;
16323   g_mutex_lock (&skeleton->priv->lock);
16324   value = g_value_get_string (&(skeleton->priv->properties[3]));
16325   g_mutex_unlock (&skeleton->priv->lock);
16326   return value;
16327 }
16328
16329 static const gchar *
16330 foo_igen_inline_docs_skeleton_get_property5 (FooiGenInlineDocs *object)
16331 {
16332   FooiGenInlineDocsSkeleton *skeleton = FOO_IGEN_INLINE_DOCS_SKELETON (object);
16333   const gchar *value;
16334   g_mutex_lock (&skeleton->priv->lock);
16335   value = g_value_get_string (&(skeleton->priv->properties[4]));
16336   g_mutex_unlock (&skeleton->priv->lock);
16337   return value;
16338 }
16339
16340 static const gchar *
16341 foo_igen_inline_docs_skeleton_get_fancy_property (FooiGenInlineDocs *object)
16342 {
16343   FooiGenInlineDocsSkeleton *skeleton = FOO_IGEN_INLINE_DOCS_SKELETON (object);
16344   const gchar *value;
16345   g_mutex_lock (&skeleton->priv->lock);
16346   value = g_value_get_string (&(skeleton->priv->properties[5]));
16347   g_mutex_unlock (&skeleton->priv->lock);
16348   return value;
16349 }
16350
16351 static void
16352 foo_igen_inline_docs_skeleton_class_init (FooiGenInlineDocsSkeletonClass *klass)
16353 {
16354   GObjectClass *gobject_class;
16355   GDBusInterfaceSkeletonClass *skeleton_class;
16356
16357   g_type_class_add_private (klass, sizeof (FooiGenInlineDocsSkeletonPrivate));
16358
16359   gobject_class = G_OBJECT_CLASS (klass);
16360   gobject_class->finalize = foo_igen_inline_docs_skeleton_finalize;
16361   gobject_class->get_property = foo_igen_inline_docs_skeleton_get_property;
16362   gobject_class->set_property = foo_igen_inline_docs_skeleton_set_property;
16363   gobject_class->notify       = foo_igen_inline_docs_skeleton_notify;
16364
16365
16366   foo_igen_inline_docs_override_properties (gobject_class, 1);
16367
16368   skeleton_class = G_DBUS_INTERFACE_SKELETON_CLASS (klass);
16369   skeleton_class->get_info = foo_igen_inline_docs_skeleton_dbus_interface_get_info;
16370   skeleton_class->get_properties = foo_igen_inline_docs_skeleton_dbus_interface_get_properties;
16371   skeleton_class->flush = foo_igen_inline_docs_skeleton_dbus_interface_flush;
16372   skeleton_class->get_vtable = foo_igen_inline_docs_skeleton_dbus_interface_get_vtable;
16373 }
16374
16375 static void
16376 foo_igen_inline_docs_skeleton_iface_init (FooiGenInlineDocsIface *iface)
16377 {
16378   iface->bar_signal = _foo_igen_inline_docs_on_signal_bar_signal;
16379   iface->get_baz_property = foo_igen_inline_docs_skeleton_get_baz_property;
16380   iface->get_property2 = foo_igen_inline_docs_skeleton_get_property2;
16381   iface->get_property3 = foo_igen_inline_docs_skeleton_get_property3;
16382   iface->get_property4 = foo_igen_inline_docs_skeleton_get_property4;
16383   iface->get_property5 = foo_igen_inline_docs_skeleton_get_property5;
16384   iface->get_fancy_property = foo_igen_inline_docs_skeleton_get_fancy_property;
16385 }
16386
16387 /**
16388  * foo_igen_inline_docs_skeleton_new:
16389  *
16390  * Creates a skeleton object for the D-Bus interface <link linkend="gdbus-interface-org-project-InlineDocs.top_of_page">org.project.InlineDocs</link>.
16391  *
16392  * Returns: (transfer full) (type FooiGenInlineDocsSkeleton): The skeleton object.
16393  */
16394 FooiGenInlineDocs *
16395 foo_igen_inline_docs_skeleton_new (void)
16396 {
16397   return FOO_IGEN_INLINE_DOCS (g_object_new (FOO_IGEN_TYPE_INLINE_DOCS_SKELETON, NULL));
16398 }
16399
16400 /* ------------------------------------------------------------------------
16401  * Code for interface ChangingInterfaceV1
16402  * ------------------------------------------------------------------------
16403  */
16404
16405 /**
16406  * SECTION:FooiGenChangingInterfaceV1
16407  * @title: FooiGenChangingInterfaceV1
16408  * @short_description: Generated C code for the ChangingInterfaceV1 D-Bus interface
16409  *
16410  * This section contains code for working with the <link linkend="gdbus-interface-ChangingInterfaceV1.top_of_page">ChangingInterfaceV1</link> D-Bus interface in C.
16411  */
16412
16413 /* ---- Introspection data for ChangingInterfaceV1 ---- */
16414
16415 static const _ExtendedGDBusMethodInfo _foo_igen_changing_interface_v1_method_info_foo_method =
16416 {
16417   {
16418     -1,
16419     "FooMethod",
16420     NULL,
16421     NULL,
16422     NULL
16423   },
16424   "handle-foo-method",
16425   FALSE
16426 };
16427
16428 static const _ExtendedGDBusMethodInfo _foo_igen_changing_interface_v1_method_info_bar_method =
16429 {
16430   {
16431     -1,
16432     "BarMethod",
16433     NULL,
16434     NULL,
16435     NULL
16436   },
16437   "handle-bar-method",
16438   FALSE
16439 };
16440
16441 static const _ExtendedGDBusMethodInfo _foo_igen_changing_interface_v1_method_info_baz_method =
16442 {
16443   {
16444     -1,
16445     "BazMethod",
16446     NULL,
16447     NULL,
16448     NULL
16449   },
16450   "handle-baz-method",
16451   FALSE
16452 };
16453
16454 static const _ExtendedGDBusMethodInfo * const _foo_igen_changing_interface_v1_method_info_pointers[] =
16455 {
16456   &_foo_igen_changing_interface_v1_method_info_foo_method,
16457   &_foo_igen_changing_interface_v1_method_info_bar_method,
16458   &_foo_igen_changing_interface_v1_method_info_baz_method,
16459   NULL
16460 };
16461
16462 static const _ExtendedGDBusSignalInfo _foo_igen_changing_interface_v1_signal_info_foo_signal =
16463 {
16464   {
16465     -1,
16466     "FooSignal",
16467     NULL,
16468     NULL
16469   },
16470   "foo-signal"
16471 };
16472
16473 static const _ExtendedGDBusSignalInfo _foo_igen_changing_interface_v1_signal_info_bar_signal =
16474 {
16475   {
16476     -1,
16477     "BarSignal",
16478     NULL,
16479     NULL
16480   },
16481   "bar-signal"
16482 };
16483
16484 static const _ExtendedGDBusSignalInfo _foo_igen_changing_interface_v1_signal_info_baz_signal =
16485 {
16486   {
16487     -1,
16488     "BazSignal",
16489     NULL,
16490     NULL
16491   },
16492   "baz-signal"
16493 };
16494
16495 static const _ExtendedGDBusSignalInfo * const _foo_igen_changing_interface_v1_signal_info_pointers[] =
16496 {
16497   &_foo_igen_changing_interface_v1_signal_info_foo_signal,
16498   &_foo_igen_changing_interface_v1_signal_info_bar_signal,
16499   &_foo_igen_changing_interface_v1_signal_info_baz_signal,
16500   NULL
16501 };
16502
16503 static const _ExtendedGDBusInterfaceInfo _foo_igen_changing_interface_v1_interface_info =
16504 {
16505   {
16506     -1,
16507     "ChangingInterfaceV1",
16508     (GDBusMethodInfo **) &_foo_igen_changing_interface_v1_method_info_pointers,
16509     (GDBusSignalInfo **) &_foo_igen_changing_interface_v1_signal_info_pointers,
16510     NULL,
16511     NULL
16512   },
16513   "changing-interface-v1",
16514 };
16515
16516
16517 /**
16518  * foo_igen_changing_interface_v1_interface_info:
16519  *
16520  * Gets a machine-readable description of the <link linkend="gdbus-interface-ChangingInterfaceV1.top_of_page">ChangingInterfaceV1</link> D-Bus interface.
16521  *
16522  * Returns: (transfer none): A #GDBusInterfaceInfo. Do not free.
16523  */
16524 GDBusInterfaceInfo *
16525 foo_igen_changing_interface_v1_interface_info (void)
16526 {
16527   return (GDBusInterfaceInfo *) &_foo_igen_changing_interface_v1_interface_info;
16528 }
16529
16530 /**
16531  * foo_igen_changing_interface_v1_override_properties:
16532  * @klass: The class structure for a #GObject<!-- -->-derived class.
16533  * @property_id_begin: The property id to assign to the first overridden property.
16534  *
16535  * Overrides all #GObject properties in the #FooiGenChangingInterfaceV1 interface for a concrete class.
16536  * The properties are overridden in the order they are defined.
16537  *
16538  * Returns: The last property id.
16539  */
16540 guint
16541 foo_igen_changing_interface_v1_override_properties (GObjectClass *klass, guint property_id_begin)
16542 {
16543   return property_id_begin - 1;
16544 }
16545
16546
16547
16548 /**
16549  * FooiGenChangingInterfaceV1:
16550  *
16551  * Abstract interface type for the D-Bus interface <link linkend="gdbus-interface-ChangingInterfaceV1.top_of_page">ChangingInterfaceV1</link>.
16552  */
16553
16554 /**
16555  * FooiGenChangingInterfaceV1Iface:
16556  * @parent_iface: The parent interface.
16557  * @handle_bar_method: Handler for the #FooiGenChangingInterfaceV1::handle-bar-method signal.
16558  * @handle_baz_method: Handler for the #FooiGenChangingInterfaceV1::handle-baz-method signal.
16559  * @handle_foo_method: Handler for the #FooiGenChangingInterfaceV1::handle-foo-method signal.
16560  * @bar_signal: Handler for the #FooiGenChangingInterfaceV1::bar-signal signal.
16561  * @baz_signal: Handler for the #FooiGenChangingInterfaceV1::baz-signal signal.
16562  * @foo_signal: Handler for the #FooiGenChangingInterfaceV1::foo-signal signal.
16563  *
16564  * Virtual table for the D-Bus interface <link linkend="gdbus-interface-ChangingInterfaceV1.top_of_page">ChangingInterfaceV1</link>.
16565  */
16566
16567 static void
16568 foo_igen_changing_interface_v1_default_init (FooiGenChangingInterfaceV1Iface *iface)
16569 {
16570   /* GObject signals for incoming D-Bus method calls: */
16571   /**
16572    * FooiGenChangingInterfaceV1::handle-foo-method:
16573    * @object: A #FooiGenChangingInterfaceV1.
16574    * @invocation: A #GDBusMethodInvocation.
16575    *
16576    * Signal emitted when a remote caller is invoking the <link linkend="gdbus-method-ChangingInterfaceV1.FooMethod">FooMethod()</link> D-Bus method.
16577    *
16578    * If a signal handler returns %TRUE, it means the signal handler will handle the invocation (e.g. take a reference to @invocation and eventually call foo_igen_changing_interface_v1_complete_foo_method() or e.g. g_dbus_method_invocation_return_error() on it) and no order signal handlers will run. If no signal handler handles the invocation, the %G_DBUS_ERROR_UNKNOWN_METHOD error is returned.
16579    *
16580    * Returns: %TRUE if the invocation was handled, %FALSE to let other signal handlers run.
16581    */
16582   g_signal_new ("handle-foo-method",
16583     G_TYPE_FROM_INTERFACE (iface),
16584     G_SIGNAL_RUN_LAST,
16585     G_STRUCT_OFFSET (FooiGenChangingInterfaceV1Iface, handle_foo_method),
16586     g_signal_accumulator_true_handled,
16587     NULL,
16588     g_cclosure_marshal_generic,
16589     G_TYPE_BOOLEAN,
16590     1,
16591     G_TYPE_DBUS_METHOD_INVOCATION);
16592
16593   /**
16594    * FooiGenChangingInterfaceV1::handle-bar-method:
16595    * @object: A #FooiGenChangingInterfaceV1.
16596    * @invocation: A #GDBusMethodInvocation.
16597    *
16598    * Signal emitted when a remote caller is invoking the <link linkend="gdbus-method-ChangingInterfaceV1.BarMethod">BarMethod()</link> D-Bus method.
16599    *
16600    * If a signal handler returns %TRUE, it means the signal handler will handle the invocation (e.g. take a reference to @invocation and eventually call foo_igen_changing_interface_v1_complete_bar_method() or e.g. g_dbus_method_invocation_return_error() on it) and no order signal handlers will run. If no signal handler handles the invocation, the %G_DBUS_ERROR_UNKNOWN_METHOD error is returned.
16601    *
16602    * Returns: %TRUE if the invocation was handled, %FALSE to let other signal handlers run.
16603    */
16604   g_signal_new ("handle-bar-method",
16605     G_TYPE_FROM_INTERFACE (iface),
16606     G_SIGNAL_RUN_LAST,
16607     G_STRUCT_OFFSET (FooiGenChangingInterfaceV1Iface, handle_bar_method),
16608     g_signal_accumulator_true_handled,
16609     NULL,
16610     g_cclosure_marshal_generic,
16611     G_TYPE_BOOLEAN,
16612     1,
16613     G_TYPE_DBUS_METHOD_INVOCATION);
16614
16615   /**
16616    * FooiGenChangingInterfaceV1::handle-baz-method:
16617    * @object: A #FooiGenChangingInterfaceV1.
16618    * @invocation: A #GDBusMethodInvocation.
16619    *
16620    * Signal emitted when a remote caller is invoking the <link linkend="gdbus-method-ChangingInterfaceV1.BazMethod">BazMethod()</link> D-Bus method.
16621    *
16622    * If a signal handler returns %TRUE, it means the signal handler will handle the invocation (e.g. take a reference to @invocation and eventually call foo_igen_changing_interface_v1_complete_baz_method() or e.g. g_dbus_method_invocation_return_error() on it) and no order signal handlers will run. If no signal handler handles the invocation, the %G_DBUS_ERROR_UNKNOWN_METHOD error is returned.
16623    *
16624    * Returns: %TRUE if the invocation was handled, %FALSE to let other signal handlers run.
16625    */
16626   g_signal_new ("handle-baz-method",
16627     G_TYPE_FROM_INTERFACE (iface),
16628     G_SIGNAL_RUN_LAST,
16629     G_STRUCT_OFFSET (FooiGenChangingInterfaceV1Iface, handle_baz_method),
16630     g_signal_accumulator_true_handled,
16631     NULL,
16632     g_cclosure_marshal_generic,
16633     G_TYPE_BOOLEAN,
16634     1,
16635     G_TYPE_DBUS_METHOD_INVOCATION);
16636
16637   /* GObject signals for received D-Bus signals: */
16638   /**
16639    * FooiGenChangingInterfaceV1::foo-signal:
16640    * @object: A #FooiGenChangingInterfaceV1.
16641    *
16642    * On the client-side, this signal is emitted whenever the D-Bus signal <link linkend="gdbus-signal-ChangingInterfaceV1.FooSignal">"FooSignal"</link> is received.
16643    *
16644    * On the service-side, this signal can be used with e.g. g_signal_emit_by_name() to make the object emit the D-Bus signal.
16645    */
16646   g_signal_new ("foo-signal",
16647     G_TYPE_FROM_INTERFACE (iface),
16648     G_SIGNAL_RUN_LAST,
16649     G_STRUCT_OFFSET (FooiGenChangingInterfaceV1Iface, foo_signal),
16650     NULL,
16651     NULL,
16652     g_cclosure_marshal_generic,
16653     G_TYPE_NONE,
16654     0);
16655
16656   /**
16657    * FooiGenChangingInterfaceV1::bar-signal:
16658    * @object: A #FooiGenChangingInterfaceV1.
16659    *
16660    * On the client-side, this signal is emitted whenever the D-Bus signal <link linkend="gdbus-signal-ChangingInterfaceV1.BarSignal">"BarSignal"</link> is received.
16661    *
16662    * On the service-side, this signal can be used with e.g. g_signal_emit_by_name() to make the object emit the D-Bus signal.
16663    */
16664   g_signal_new ("bar-signal",
16665     G_TYPE_FROM_INTERFACE (iface),
16666     G_SIGNAL_RUN_LAST,
16667     G_STRUCT_OFFSET (FooiGenChangingInterfaceV1Iface, bar_signal),
16668     NULL,
16669     NULL,
16670     g_cclosure_marshal_generic,
16671     G_TYPE_NONE,
16672     0);
16673
16674   /**
16675    * FooiGenChangingInterfaceV1::baz-signal:
16676    * @object: A #FooiGenChangingInterfaceV1.
16677    *
16678    * On the client-side, this signal is emitted whenever the D-Bus signal <link linkend="gdbus-signal-ChangingInterfaceV1.BazSignal">"BazSignal"</link> is received.
16679    *
16680    * On the service-side, this signal can be used with e.g. g_signal_emit_by_name() to make the object emit the D-Bus signal.
16681    */
16682   g_signal_new ("baz-signal",
16683     G_TYPE_FROM_INTERFACE (iface),
16684     G_SIGNAL_RUN_LAST,
16685     G_STRUCT_OFFSET (FooiGenChangingInterfaceV1Iface, baz_signal),
16686     NULL,
16687     NULL,
16688     g_cclosure_marshal_generic,
16689     G_TYPE_NONE,
16690     0);
16691
16692 }
16693
16694 typedef FooiGenChangingInterfaceV1Iface FooiGenChangingInterfaceV1Interface;
16695 G_DEFINE_INTERFACE (FooiGenChangingInterfaceV1, foo_igen_changing_interface_v1, G_TYPE_OBJECT);
16696
16697 /**
16698  * foo_igen_changing_interface_v1_emit_foo_signal:
16699  * @object: A #FooiGenChangingInterfaceV1.
16700  *
16701  * Emits the <link linkend="gdbus-signal-ChangingInterfaceV1.FooSignal">"FooSignal"</link> D-Bus signal.
16702  */
16703 void
16704 foo_igen_changing_interface_v1_emit_foo_signal (
16705     FooiGenChangingInterfaceV1 *object)
16706 {
16707   g_signal_emit_by_name (object, "foo-signal");
16708 }
16709
16710 /**
16711  * foo_igen_changing_interface_v1_emit_bar_signal:
16712  * @object: A #FooiGenChangingInterfaceV1.
16713  *
16714  * Emits the <link linkend="gdbus-signal-ChangingInterfaceV1.BarSignal">"BarSignal"</link> D-Bus signal.
16715  */
16716 void
16717 foo_igen_changing_interface_v1_emit_bar_signal (
16718     FooiGenChangingInterfaceV1 *object)
16719 {
16720   g_signal_emit_by_name (object, "bar-signal");
16721 }
16722
16723 /**
16724  * foo_igen_changing_interface_v1_emit_baz_signal:
16725  * @object: A #FooiGenChangingInterfaceV1.
16726  *
16727  * Emits the <link linkend="gdbus-signal-ChangingInterfaceV1.BazSignal">"BazSignal"</link> D-Bus signal.
16728  */
16729 void
16730 foo_igen_changing_interface_v1_emit_baz_signal (
16731     FooiGenChangingInterfaceV1 *object)
16732 {
16733   g_signal_emit_by_name (object, "baz-signal");
16734 }
16735
16736 /**
16737  * foo_igen_changing_interface_v1_call_foo_method:
16738  * @proxy: A #FooiGenChangingInterfaceV1Proxy.
16739  * @cancellable: (allow-none): A #GCancellable or %NULL.
16740  * @callback: A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
16741  * @user_data: User data to pass to @callback.
16742  *
16743  * Asynchronously invokes the <link linkend="gdbus-method-ChangingInterfaceV1.FooMethod">FooMethod()</link> D-Bus method on @proxy.
16744  * When the operation is finished, @callback will be invoked in the <link linkend="g-main-context-push-thread-default">thread-default main loop</link> of the thread you are calling this method from.
16745  * You can then call foo_igen_changing_interface_v1_call_foo_method_finish() to get the result of the operation.
16746  *
16747  * See foo_igen_changing_interface_v1_call_foo_method_sync() for the synchronous, blocking version of this method.
16748  */
16749 void
16750 foo_igen_changing_interface_v1_call_foo_method (
16751     FooiGenChangingInterfaceV1 *proxy,
16752     GCancellable *cancellable,
16753     GAsyncReadyCallback callback,
16754     gpointer user_data)
16755 {
16756   g_dbus_proxy_call (G_DBUS_PROXY (proxy),
16757     "FooMethod",
16758     g_variant_new ("()"),
16759     G_DBUS_CALL_FLAGS_NONE,
16760     -1,
16761     cancellable,
16762     callback,
16763     user_data);
16764 }
16765
16766 /**
16767  * foo_igen_changing_interface_v1_call_foo_method_finish:
16768  * @proxy: A #FooiGenChangingInterfaceV1Proxy.
16769  * @res: The #GAsyncResult obtained from the #GAsyncReadyCallback passed to foo_igen_changing_interface_v1_call_foo_method().
16770  * @error: Return location for error or %NULL.
16771  *
16772  * Finishes an operation started with foo_igen_changing_interface_v1_call_foo_method().
16773  *
16774  * Returns: (skip): %TRUE if the call succeded, %FALSE if @error is set.
16775  */
16776 gboolean
16777 foo_igen_changing_interface_v1_call_foo_method_finish (
16778     FooiGenChangingInterfaceV1 *proxy,
16779     GAsyncResult *res,
16780     GError **error)
16781 {
16782   GVariant *_ret;
16783   _ret = g_dbus_proxy_call_finish (G_DBUS_PROXY (proxy), res, error);
16784   if (_ret == NULL)
16785     goto _out;
16786   g_variant_get (_ret,
16787                  "()");
16788   g_variant_unref (_ret);
16789 _out:
16790   return _ret != NULL;
16791 }
16792
16793 /**
16794  * foo_igen_changing_interface_v1_call_foo_method_sync:
16795  * @proxy: A #FooiGenChangingInterfaceV1Proxy.
16796  * @cancellable: (allow-none): A #GCancellable or %NULL.
16797  * @error: Return location for error or %NULL.
16798  *
16799  * Synchronously invokes the <link linkend="gdbus-method-ChangingInterfaceV1.FooMethod">FooMethod()</link> D-Bus method on @proxy. The calling thread is blocked until a reply is received.
16800  *
16801  * See foo_igen_changing_interface_v1_call_foo_method() for the asynchronous version of this method.
16802  *
16803  * Returns: (skip): %TRUE if the call succeded, %FALSE if @error is set.
16804  */
16805 gboolean
16806 foo_igen_changing_interface_v1_call_foo_method_sync (
16807     FooiGenChangingInterfaceV1 *proxy,
16808     GCancellable *cancellable,
16809     GError **error)
16810 {
16811   GVariant *_ret;
16812   _ret = g_dbus_proxy_call_sync (G_DBUS_PROXY (proxy),
16813     "FooMethod",
16814     g_variant_new ("()"),
16815     G_DBUS_CALL_FLAGS_NONE,
16816     -1,
16817     cancellable,
16818     error);
16819   if (_ret == NULL)
16820     goto _out;
16821   g_variant_get (_ret,
16822                  "()");
16823   g_variant_unref (_ret);
16824 _out:
16825   return _ret != NULL;
16826 }
16827
16828 /**
16829  * foo_igen_changing_interface_v1_call_bar_method:
16830  * @proxy: A #FooiGenChangingInterfaceV1Proxy.
16831  * @cancellable: (allow-none): A #GCancellable or %NULL.
16832  * @callback: A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
16833  * @user_data: User data to pass to @callback.
16834  *
16835  * Asynchronously invokes the <link linkend="gdbus-method-ChangingInterfaceV1.BarMethod">BarMethod()</link> D-Bus method on @proxy.
16836  * When the operation is finished, @callback will be invoked in the <link linkend="g-main-context-push-thread-default">thread-default main loop</link> of the thread you are calling this method from.
16837  * You can then call foo_igen_changing_interface_v1_call_bar_method_finish() to get the result of the operation.
16838  *
16839  * See foo_igen_changing_interface_v1_call_bar_method_sync() for the synchronous, blocking version of this method.
16840  */
16841 void
16842 foo_igen_changing_interface_v1_call_bar_method (
16843     FooiGenChangingInterfaceV1 *proxy,
16844     GCancellable *cancellable,
16845     GAsyncReadyCallback callback,
16846     gpointer user_data)
16847 {
16848   g_dbus_proxy_call (G_DBUS_PROXY (proxy),
16849     "BarMethod",
16850     g_variant_new ("()"),
16851     G_DBUS_CALL_FLAGS_NONE,
16852     -1,
16853     cancellable,
16854     callback,
16855     user_data);
16856 }
16857
16858 /**
16859  * foo_igen_changing_interface_v1_call_bar_method_finish:
16860  * @proxy: A #FooiGenChangingInterfaceV1Proxy.
16861  * @res: The #GAsyncResult obtained from the #GAsyncReadyCallback passed to foo_igen_changing_interface_v1_call_bar_method().
16862  * @error: Return location for error or %NULL.
16863  *
16864  * Finishes an operation started with foo_igen_changing_interface_v1_call_bar_method().
16865  *
16866  * Returns: (skip): %TRUE if the call succeded, %FALSE if @error is set.
16867  */
16868 gboolean
16869 foo_igen_changing_interface_v1_call_bar_method_finish (
16870     FooiGenChangingInterfaceV1 *proxy,
16871     GAsyncResult *res,
16872     GError **error)
16873 {
16874   GVariant *_ret;
16875   _ret = g_dbus_proxy_call_finish (G_DBUS_PROXY (proxy), res, error);
16876   if (_ret == NULL)
16877     goto _out;
16878   g_variant_get (_ret,
16879                  "()");
16880   g_variant_unref (_ret);
16881 _out:
16882   return _ret != NULL;
16883 }
16884
16885 /**
16886  * foo_igen_changing_interface_v1_call_bar_method_sync:
16887  * @proxy: A #FooiGenChangingInterfaceV1Proxy.
16888  * @cancellable: (allow-none): A #GCancellable or %NULL.
16889  * @error: Return location for error or %NULL.
16890  *
16891  * Synchronously invokes the <link linkend="gdbus-method-ChangingInterfaceV1.BarMethod">BarMethod()</link> D-Bus method on @proxy. The calling thread is blocked until a reply is received.
16892  *
16893  * See foo_igen_changing_interface_v1_call_bar_method() for the asynchronous version of this method.
16894  *
16895  * Returns: (skip): %TRUE if the call succeded, %FALSE if @error is set.
16896  */
16897 gboolean
16898 foo_igen_changing_interface_v1_call_bar_method_sync (
16899     FooiGenChangingInterfaceV1 *proxy,
16900     GCancellable *cancellable,
16901     GError **error)
16902 {
16903   GVariant *_ret;
16904   _ret = g_dbus_proxy_call_sync (G_DBUS_PROXY (proxy),
16905     "BarMethod",
16906     g_variant_new ("()"),
16907     G_DBUS_CALL_FLAGS_NONE,
16908     -1,
16909     cancellable,
16910     error);
16911   if (_ret == NULL)
16912     goto _out;
16913   g_variant_get (_ret,
16914                  "()");
16915   g_variant_unref (_ret);
16916 _out:
16917   return _ret != NULL;
16918 }
16919
16920 /**
16921  * foo_igen_changing_interface_v1_call_baz_method:
16922  * @proxy: A #FooiGenChangingInterfaceV1Proxy.
16923  * @cancellable: (allow-none): A #GCancellable or %NULL.
16924  * @callback: A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
16925  * @user_data: User data to pass to @callback.
16926  *
16927  * Asynchronously invokes the <link linkend="gdbus-method-ChangingInterfaceV1.BazMethod">BazMethod()</link> D-Bus method on @proxy.
16928  * When the operation is finished, @callback will be invoked in the <link linkend="g-main-context-push-thread-default">thread-default main loop</link> of the thread you are calling this method from.
16929  * You can then call foo_igen_changing_interface_v1_call_baz_method_finish() to get the result of the operation.
16930  *
16931  * See foo_igen_changing_interface_v1_call_baz_method_sync() for the synchronous, blocking version of this method.
16932  */
16933 void
16934 foo_igen_changing_interface_v1_call_baz_method (
16935     FooiGenChangingInterfaceV1 *proxy,
16936     GCancellable *cancellable,
16937     GAsyncReadyCallback callback,
16938     gpointer user_data)
16939 {
16940   g_dbus_proxy_call (G_DBUS_PROXY (proxy),
16941     "BazMethod",
16942     g_variant_new ("()"),
16943     G_DBUS_CALL_FLAGS_NONE,
16944     -1,
16945     cancellable,
16946     callback,
16947     user_data);
16948 }
16949
16950 /**
16951  * foo_igen_changing_interface_v1_call_baz_method_finish:
16952  * @proxy: A #FooiGenChangingInterfaceV1Proxy.
16953  * @res: The #GAsyncResult obtained from the #GAsyncReadyCallback passed to foo_igen_changing_interface_v1_call_baz_method().
16954  * @error: Return location for error or %NULL.
16955  *
16956  * Finishes an operation started with foo_igen_changing_interface_v1_call_baz_method().
16957  *
16958  * Returns: (skip): %TRUE if the call succeded, %FALSE if @error is set.
16959  */
16960 gboolean
16961 foo_igen_changing_interface_v1_call_baz_method_finish (
16962     FooiGenChangingInterfaceV1 *proxy,
16963     GAsyncResult *res,
16964     GError **error)
16965 {
16966   GVariant *_ret;
16967   _ret = g_dbus_proxy_call_finish (G_DBUS_PROXY (proxy), res, error);
16968   if (_ret == NULL)
16969     goto _out;
16970   g_variant_get (_ret,
16971                  "()");
16972   g_variant_unref (_ret);
16973 _out:
16974   return _ret != NULL;
16975 }
16976
16977 /**
16978  * foo_igen_changing_interface_v1_call_baz_method_sync:
16979  * @proxy: A #FooiGenChangingInterfaceV1Proxy.
16980  * @cancellable: (allow-none): A #GCancellable or %NULL.
16981  * @error: Return location for error or %NULL.
16982  *
16983  * Synchronously invokes the <link linkend="gdbus-method-ChangingInterfaceV1.BazMethod">BazMethod()</link> D-Bus method on @proxy. The calling thread is blocked until a reply is received.
16984  *
16985  * See foo_igen_changing_interface_v1_call_baz_method() for the asynchronous version of this method.
16986  *
16987  * Returns: (skip): %TRUE if the call succeded, %FALSE if @error is set.
16988  */
16989 gboolean
16990 foo_igen_changing_interface_v1_call_baz_method_sync (
16991     FooiGenChangingInterfaceV1 *proxy,
16992     GCancellable *cancellable,
16993     GError **error)
16994 {
16995   GVariant *_ret;
16996   _ret = g_dbus_proxy_call_sync (G_DBUS_PROXY (proxy),
16997     "BazMethod",
16998     g_variant_new ("()"),
16999     G_DBUS_CALL_FLAGS_NONE,
17000     -1,
17001     cancellable,
17002     error);
17003   if (_ret == NULL)
17004     goto _out;
17005   g_variant_get (_ret,
17006                  "()");
17007   g_variant_unref (_ret);
17008 _out:
17009   return _ret != NULL;
17010 }
17011
17012 /**
17013  * foo_igen_changing_interface_v1_complete_foo_method:
17014  * @object: A #FooiGenChangingInterfaceV1.
17015  * @invocation: (transfer full): A #GDBusMethodInvocation.
17016  *
17017  * Helper function used in service implementations to finish handling invocations of the <link linkend="gdbus-method-ChangingInterfaceV1.FooMethod">FooMethod()</link> D-Bus method. If you instead want to finish handling an invocation by returning an error, use g_dbus_method_invocation_return_error() or similar.
17018  *
17019  * This method will free @invocation, you cannot use it afterwards.
17020  */
17021 void
17022 foo_igen_changing_interface_v1_complete_foo_method (
17023     FooiGenChangingInterfaceV1 *object,
17024     GDBusMethodInvocation *invocation)
17025 {
17026   g_dbus_method_invocation_return_value (invocation,
17027     g_variant_new ("()"));
17028 }
17029
17030 /**
17031  * foo_igen_changing_interface_v1_complete_bar_method:
17032  * @object: A #FooiGenChangingInterfaceV1.
17033  * @invocation: (transfer full): A #GDBusMethodInvocation.
17034  *
17035  * Helper function used in service implementations to finish handling invocations of the <link linkend="gdbus-method-ChangingInterfaceV1.BarMethod">BarMethod()</link> D-Bus method. If you instead want to finish handling an invocation by returning an error, use g_dbus_method_invocation_return_error() or similar.
17036  *
17037  * This method will free @invocation, you cannot use it afterwards.
17038  */
17039 void
17040 foo_igen_changing_interface_v1_complete_bar_method (
17041     FooiGenChangingInterfaceV1 *object,
17042     GDBusMethodInvocation *invocation)
17043 {
17044   g_dbus_method_invocation_return_value (invocation,
17045     g_variant_new ("()"));
17046 }
17047
17048 /**
17049  * foo_igen_changing_interface_v1_complete_baz_method:
17050  * @object: A #FooiGenChangingInterfaceV1.
17051  * @invocation: (transfer full): A #GDBusMethodInvocation.
17052  *
17053  * Helper function used in service implementations to finish handling invocations of the <link linkend="gdbus-method-ChangingInterfaceV1.BazMethod">BazMethod()</link> D-Bus method. If you instead want to finish handling an invocation by returning an error, use g_dbus_method_invocation_return_error() or similar.
17054  *
17055  * This method will free @invocation, you cannot use it afterwards.
17056  */
17057 void
17058 foo_igen_changing_interface_v1_complete_baz_method (
17059     FooiGenChangingInterfaceV1 *object,
17060     GDBusMethodInvocation *invocation)
17061 {
17062   g_dbus_method_invocation_return_value (invocation,
17063     g_variant_new ("()"));
17064 }
17065
17066 /* ------------------------------------------------------------------------ */
17067
17068 /**
17069  * FooiGenChangingInterfaceV1Proxy:
17070  *
17071  * The #FooiGenChangingInterfaceV1Proxy structure contains only private data and should only be accessed using the provided API.
17072  */
17073
17074 /**
17075  * FooiGenChangingInterfaceV1ProxyClass:
17076  * @parent_class: The parent class.
17077  *
17078  * Class structure for #FooiGenChangingInterfaceV1Proxy.
17079  */
17080
17081 struct _FooiGenChangingInterfaceV1ProxyPrivate
17082 {
17083   GData *qdata;
17084 };
17085
17086 static void foo_igen_changing_interface_v1_proxy_iface_init (FooiGenChangingInterfaceV1Iface *iface);
17087
17088 G_DEFINE_TYPE_WITH_CODE (FooiGenChangingInterfaceV1Proxy, foo_igen_changing_interface_v1_proxy, G_TYPE_DBUS_PROXY,
17089                          G_IMPLEMENT_INTERFACE (FOO_IGEN_TYPE_CHANGING_INTERFACE_V1, foo_igen_changing_interface_v1_proxy_iface_init));
17090
17091 static void
17092 foo_igen_changing_interface_v1_proxy_finalize (GObject *object)
17093 {
17094   FooiGenChangingInterfaceV1Proxy *proxy = FOO_IGEN_CHANGING_INTERFACE_V1_PROXY (object);
17095   g_datalist_clear (&proxy->priv->qdata);
17096   G_OBJECT_CLASS (foo_igen_changing_interface_v1_proxy_parent_class)->finalize (object);
17097 }
17098
17099 static void
17100 foo_igen_changing_interface_v1_proxy_get_property (GObject      *object,
17101   guint         prop_id,
17102   GValue       *value,
17103   GParamSpec   *pspec)
17104 {
17105 }
17106
17107 static void
17108 foo_igen_changing_interface_v1_proxy_set_property (GObject      *object,
17109   guint         prop_id,
17110   const GValue *value,
17111   GParamSpec   *pspec)
17112 {
17113 }
17114
17115 static void
17116 foo_igen_changing_interface_v1_proxy_g_signal (GDBusProxy *proxy,
17117   const gchar *sender_name,
17118   const gchar *signal_name,
17119   GVariant *parameters)
17120 {
17121   _ExtendedGDBusSignalInfo *info;
17122   GVariantIter iter;
17123   GVariant *child;
17124   GValue *paramv;
17125   guint num_params;
17126   guint n;
17127   guint signal_id;
17128   info = (_ExtendedGDBusSignalInfo *) g_dbus_interface_info_lookup_signal ((GDBusInterfaceInfo *) &_foo_igen_changing_interface_v1_interface_info, signal_name);
17129   if (info == NULL)
17130     return;
17131   num_params = g_variant_n_children (parameters);
17132   paramv = g_new0 (GValue, num_params + 1);
17133   g_value_init (&paramv[0], FOO_IGEN_TYPE_CHANGING_INTERFACE_V1);
17134   g_value_set_object (&paramv[0], proxy);
17135   g_variant_iter_init (&iter, parameters);
17136   n = 1;
17137   while ((child = g_variant_iter_next_value (&iter)) != NULL)
17138     {
17139       _ExtendedGDBusArgInfo *arg_info = (_ExtendedGDBusArgInfo *) info->parent_struct.args[n - 1];
17140       if (arg_info->use_gvariant)
17141         {
17142           g_value_init (&paramv[n], G_TYPE_VARIANT);
17143           g_value_set_variant (&paramv[n], child);
17144           n++;
17145         }
17146       else
17147         g_dbus_gvariant_to_gvalue (child, &paramv[n++]);
17148       g_variant_unref (child);
17149     }
17150   signal_id = g_signal_lookup (info->signal_name, FOO_IGEN_TYPE_CHANGING_INTERFACE_V1);
17151   g_signal_emitv (paramv, signal_id, 0, NULL);
17152   for (n = 0; n < num_params + 1; n++)
17153     g_value_unset (&paramv[n]);
17154   g_free (paramv);
17155 }
17156
17157 static void
17158 foo_igen_changing_interface_v1_proxy_g_properties_changed (GDBusProxy *_proxy,
17159   GVariant *changed_properties,
17160   const gchar *const *invalidated_properties)
17161 {
17162   FooiGenChangingInterfaceV1Proxy *proxy = FOO_IGEN_CHANGING_INTERFACE_V1_PROXY (_proxy);
17163   guint n;
17164   const gchar *key;
17165   GVariantIter *iter;
17166   _ExtendedGDBusPropertyInfo *info;
17167   g_variant_get (changed_properties, "a{sv}", &iter);
17168   while (g_variant_iter_next (iter, "{&sv}", &key, NULL))
17169     {
17170       info = (_ExtendedGDBusPropertyInfo *) g_dbus_interface_info_lookup_property ((GDBusInterfaceInfo *) &_foo_igen_changing_interface_v1_interface_info, key);
17171       g_datalist_remove_data (&proxy->priv->qdata, key);
17172       if (info != NULL)
17173         g_object_notify (G_OBJECT (proxy), info->hyphen_name);
17174     }
17175   g_variant_iter_free (iter);
17176   for (n = 0; invalidated_properties[n] != NULL; n++)
17177     {
17178       info = (_ExtendedGDBusPropertyInfo *) g_dbus_interface_info_lookup_property ((GDBusInterfaceInfo *) &_foo_igen_changing_interface_v1_interface_info, invalidated_properties[n]);
17179       g_datalist_remove_data (&proxy->priv->qdata, invalidated_properties[n]);
17180       if (info != NULL)
17181         g_object_notify (G_OBJECT (proxy), info->hyphen_name);
17182     }
17183 }
17184
17185 static void
17186 foo_igen_changing_interface_v1_proxy_init (FooiGenChangingInterfaceV1Proxy *proxy)
17187 {
17188   proxy->priv = G_TYPE_INSTANCE_GET_PRIVATE (proxy, FOO_IGEN_TYPE_CHANGING_INTERFACE_V1_PROXY, FooiGenChangingInterfaceV1ProxyPrivate);
17189   g_dbus_proxy_set_interface_info (G_DBUS_PROXY (proxy), foo_igen_changing_interface_v1_interface_info ());
17190 }
17191
17192 static void
17193 foo_igen_changing_interface_v1_proxy_class_init (FooiGenChangingInterfaceV1ProxyClass *klass)
17194 {
17195   GObjectClass *gobject_class;
17196   GDBusProxyClass *proxy_class;
17197
17198   g_type_class_add_private (klass, sizeof (FooiGenChangingInterfaceV1ProxyPrivate));
17199
17200   gobject_class = G_OBJECT_CLASS (klass);
17201   gobject_class->finalize     = foo_igen_changing_interface_v1_proxy_finalize;
17202   gobject_class->get_property = foo_igen_changing_interface_v1_proxy_get_property;
17203   gobject_class->set_property = foo_igen_changing_interface_v1_proxy_set_property;
17204
17205   proxy_class = G_DBUS_PROXY_CLASS (klass);
17206   proxy_class->g_signal = foo_igen_changing_interface_v1_proxy_g_signal;
17207   proxy_class->g_properties_changed = foo_igen_changing_interface_v1_proxy_g_properties_changed;
17208
17209 }
17210
17211 static void
17212 foo_igen_changing_interface_v1_proxy_iface_init (FooiGenChangingInterfaceV1Iface *iface)
17213 {
17214 }
17215
17216 /**
17217  * foo_igen_changing_interface_v1_proxy_new:
17218  * @connection: A #GDBusConnection.
17219  * @flags: Flags from the #GDBusProxyFlags enumeration.
17220  * @name: (allow-none): A bus name (well-known or unique) or %NULL if @connection is not a message bus connection.
17221  * @object_path: An object path.
17222  * @cancellable: (allow-none): A #GCancellable or %NULL.
17223  * @callback: A #GAsyncReadyCallback to call when the request is satisfied.
17224  * @user_data: User data to pass to @callback.
17225  *
17226  * Asynchronously creates a proxy for the D-Bus interface <link linkend="gdbus-interface-ChangingInterfaceV1.top_of_page">ChangingInterfaceV1</link>. See g_dbus_proxy_new() for more details.
17227  *
17228  * When the operation is finished, @callback will be invoked in the <link linkend="g-main-context-push-thread-default">thread-default main loop</link> of the thread you are calling this method from.
17229  * You can then call foo_igen_changing_interface_v1_proxy_new_finish() to get the result of the operation.
17230  *
17231  * See foo_igen_changing_interface_v1_proxy_new_sync() for the synchronous, blocking version of this constructor.
17232  */
17233 void
17234 foo_igen_changing_interface_v1_proxy_new (
17235     GDBusConnection     *connection,
17236     GDBusProxyFlags      flags,
17237     const gchar         *name,
17238     const gchar         *object_path,
17239     GCancellable        *cancellable,
17240     GAsyncReadyCallback  callback,
17241     gpointer             user_data)
17242 {
17243   g_async_initable_new_async (FOO_IGEN_TYPE_CHANGING_INTERFACE_V1_PROXY, G_PRIORITY_DEFAULT, cancellable, callback, user_data, "g-flags", flags, "g-name", name, "g-connection", connection, "g-object-path", object_path, "g-interface-name", "ChangingInterfaceV1", NULL);
17244 }
17245
17246 /**
17247  * foo_igen_changing_interface_v1_proxy_new_finish:
17248  * @res: The #GAsyncResult obtained from the #GAsyncReadyCallback passed to foo_igen_changing_interface_v1_proxy_new().
17249  * @error: Return location for error or %NULL
17250  *
17251  * Finishes an operation started with foo_igen_changing_interface_v1_proxy_new().
17252  *
17253  * Returns: (transfer full) (type FooiGenChangingInterfaceV1Proxy): The constructed proxy object or %NULL if @error is set.
17254  */
17255 FooiGenChangingInterfaceV1 *
17256 foo_igen_changing_interface_v1_proxy_new_finish (
17257     GAsyncResult        *res,
17258     GError             **error)
17259 {
17260   GObject *ret;
17261   GObject *source_object;
17262   source_object = g_async_result_get_source_object (res);
17263   ret = g_async_initable_new_finish (G_ASYNC_INITABLE (source_object), res, error);
17264   g_object_unref (source_object);
17265   if (ret != NULL)
17266     return FOO_IGEN_CHANGING_INTERFACE_V1 (ret);
17267   else
17268     return NULL;
17269 }
17270
17271 /**
17272  * foo_igen_changing_interface_v1_proxy_new_sync:
17273  * @connection: A #GDBusConnection.
17274  * @flags: Flags from the #GDBusProxyFlags enumeration.
17275  * @name: (allow-none): A bus name (well-known or unique) or %NULL if @connection is not a message bus connection.
17276  * @object_path: An object path.
17277  * @cancellable: (allow-none): A #GCancellable or %NULL.
17278  * @error: Return location for error or %NULL
17279  *
17280  * Synchronously creates a proxy for the D-Bus interface <link linkend="gdbus-interface-ChangingInterfaceV1.top_of_page">ChangingInterfaceV1</link>. See g_dbus_proxy_new_sync() for more details.
17281  *
17282  * The calling thread is blocked until a reply is received.
17283  *
17284  * See foo_igen_changing_interface_v1_proxy_new() for the asynchronous version of this constructor.
17285  *
17286  * Returns: (transfer full) (type FooiGenChangingInterfaceV1Proxy): The constructed proxy object or %NULL if @error is set.
17287  */
17288 FooiGenChangingInterfaceV1 *
17289 foo_igen_changing_interface_v1_proxy_new_sync (
17290     GDBusConnection     *connection,
17291     GDBusProxyFlags      flags,
17292     const gchar         *name,
17293     const gchar         *object_path,
17294     GCancellable        *cancellable,
17295     GError             **error)
17296 {
17297   GInitable *ret;
17298   ret = g_initable_new (FOO_IGEN_TYPE_CHANGING_INTERFACE_V1_PROXY, cancellable, error, "g-flags", flags, "g-name", name, "g-connection", connection, "g-object-path", object_path, "g-interface-name", "ChangingInterfaceV1", NULL);
17299   if (ret != NULL)
17300     return FOO_IGEN_CHANGING_INTERFACE_V1 (ret);
17301   else
17302     return NULL;
17303 }
17304
17305
17306 /**
17307  * foo_igen_changing_interface_v1_proxy_new_for_bus:
17308  * @bus_type: A #GBusType.
17309  * @flags: Flags from the #GDBusProxyFlags enumeration.
17310  * @name: A bus name (well-known or unique).
17311  * @object_path: An object path.
17312  * @cancellable: (allow-none): A #GCancellable or %NULL.
17313  * @callback: A #GAsyncReadyCallback to call when the request is satisfied.
17314  * @user_data: User data to pass to @callback.
17315  *
17316  * Like foo_igen_changing_interface_v1_proxy_new() but takes a #GBusType instead of a #GDBusConnection.
17317  *
17318  * When the operation is finished, @callback will be invoked in the <link linkend="g-main-context-push-thread-default">thread-default main loop</link> of the thread you are calling this method from.
17319  * You can then call foo_igen_changing_interface_v1_proxy_new_for_bus_finish() to get the result of the operation.
17320  *
17321  * See foo_igen_changing_interface_v1_proxy_new_for_bus_sync() for the synchronous, blocking version of this constructor.
17322  */
17323 void
17324 foo_igen_changing_interface_v1_proxy_new_for_bus (
17325     GBusType             bus_type,
17326     GDBusProxyFlags      flags,
17327     const gchar         *name,
17328     const gchar         *object_path,
17329     GCancellable        *cancellable,
17330     GAsyncReadyCallback  callback,
17331     gpointer             user_data)
17332 {
17333   g_async_initable_new_async (FOO_IGEN_TYPE_CHANGING_INTERFACE_V1_PROXY, G_PRIORITY_DEFAULT, cancellable, callback, user_data, "g-flags", flags, "g-name", name, "g-bus-type", bus_type, "g-object-path", object_path, "g-interface-name", "ChangingInterfaceV1", NULL);
17334 }
17335
17336 /**
17337  * foo_igen_changing_interface_v1_proxy_new_for_bus_finish:
17338  * @res: The #GAsyncResult obtained from the #GAsyncReadyCallback passed to foo_igen_changing_interface_v1_proxy_new_for_bus().
17339  * @error: Return location for error or %NULL
17340  *
17341  * Finishes an operation started with foo_igen_changing_interface_v1_proxy_new_for_bus().
17342  *
17343  * Returns: (transfer full) (type FooiGenChangingInterfaceV1Proxy): The constructed proxy object or %NULL if @error is set.
17344  */
17345 FooiGenChangingInterfaceV1 *
17346 foo_igen_changing_interface_v1_proxy_new_for_bus_finish (
17347     GAsyncResult        *res,
17348     GError             **error)
17349 {
17350   GObject *ret;
17351   GObject *source_object;
17352   source_object = g_async_result_get_source_object (res);
17353   ret = g_async_initable_new_finish (G_ASYNC_INITABLE (source_object), res, error);
17354   g_object_unref (source_object);
17355   if (ret != NULL)
17356     return FOO_IGEN_CHANGING_INTERFACE_V1 (ret);
17357   else
17358     return NULL;
17359 }
17360
17361 /**
17362  * foo_igen_changing_interface_v1_proxy_new_for_bus_sync:
17363  * @bus_type: A #GBusType.
17364  * @flags: Flags from the #GDBusProxyFlags enumeration.
17365  * @name: A bus name (well-known or unique).
17366  * @object_path: An object path.
17367  * @cancellable: (allow-none): A #GCancellable or %NULL.
17368  * @error: Return location for error or %NULL
17369  *
17370  * Like foo_igen_changing_interface_v1_proxy_new_sync() but takes a #GBusType instead of a #GDBusConnection.
17371  *
17372  * The calling thread is blocked until a reply is received.
17373  *
17374  * See foo_igen_changing_interface_v1_proxy_new_for_bus() for the asynchronous version of this constructor.
17375  *
17376  * Returns: (transfer full) (type FooiGenChangingInterfaceV1Proxy): The constructed proxy object or %NULL if @error is set.
17377  */
17378 FooiGenChangingInterfaceV1 *
17379 foo_igen_changing_interface_v1_proxy_new_for_bus_sync (
17380     GBusType             bus_type,
17381     GDBusProxyFlags      flags,
17382     const gchar         *name,
17383     const gchar         *object_path,
17384     GCancellable        *cancellable,
17385     GError             **error)
17386 {
17387   GInitable *ret;
17388   ret = g_initable_new (FOO_IGEN_TYPE_CHANGING_INTERFACE_V1_PROXY, cancellable, error, "g-flags", flags, "g-name", name, "g-bus-type", bus_type, "g-object-path", object_path, "g-interface-name", "ChangingInterfaceV1", NULL);
17389   if (ret != NULL)
17390     return FOO_IGEN_CHANGING_INTERFACE_V1 (ret);
17391   else
17392     return NULL;
17393 }
17394
17395
17396 /* ------------------------------------------------------------------------ */
17397
17398 /**
17399  * FooiGenChangingInterfaceV1Skeleton:
17400  *
17401  * The #FooiGenChangingInterfaceV1Skeleton structure contains only private data and should only be accessed using the provided API.
17402  */
17403
17404 /**
17405  * FooiGenChangingInterfaceV1SkeletonClass:
17406  * @parent_class: The parent class.
17407  *
17408  * Class structure for #FooiGenChangingInterfaceV1Skeleton.
17409  */
17410
17411 struct _FooiGenChangingInterfaceV1SkeletonPrivate
17412 {
17413   GValue *properties;
17414   GList *changed_properties;
17415   GSource *changed_properties_idle_source;
17416   GMainContext *context;
17417   GMutex lock;
17418 };
17419
17420 static void
17421 _foo_igen_changing_interface_v1_skeleton_handle_method_call (
17422   GDBusConnection *connection,
17423   const gchar *sender,
17424   const gchar *object_path,
17425   const gchar *interface_name,
17426   const gchar *method_name,
17427   GVariant *parameters,
17428   GDBusMethodInvocation *invocation,
17429   gpointer user_data)
17430 {
17431   FooiGenChangingInterfaceV1Skeleton *skeleton = FOO_IGEN_CHANGING_INTERFACE_V1_SKELETON (user_data);
17432   _ExtendedGDBusMethodInfo *info;
17433   GVariantIter iter;
17434   GVariant *child;
17435   GValue *paramv;
17436   guint num_params;
17437   guint num_extra;
17438   guint n;
17439   guint signal_id;
17440   GValue return_value = G_VALUE_INIT;
17441   info = (_ExtendedGDBusMethodInfo *) g_dbus_method_invocation_get_method_info (invocation);
17442   g_assert (info != NULL);
17443   num_params = g_variant_n_children (parameters);
17444   num_extra = info->pass_fdlist ? 3 : 2;  paramv = g_new0 (GValue, num_params + num_extra);
17445   n = 0;
17446   g_value_init (&paramv[n], FOO_IGEN_TYPE_CHANGING_INTERFACE_V1);
17447   g_value_set_object (&paramv[n++], skeleton);
17448   g_value_init (&paramv[n], G_TYPE_DBUS_METHOD_INVOCATION);
17449   g_value_set_object (&paramv[n++], invocation);
17450   if (info->pass_fdlist)
17451     {
17452 #ifdef G_OS_UNIX
17453       g_value_init (&paramv[n], G_TYPE_UNIX_FD_LIST);
17454       g_value_set_object (&paramv[n++], g_dbus_message_get_unix_fd_list (g_dbus_method_invocation_get_message (invocation)));
17455 #else
17456       g_assert_not_reached ();
17457 #endif
17458     }
17459   g_variant_iter_init (&iter, parameters);
17460   while ((child = g_variant_iter_next_value (&iter)) != NULL)
17461     {
17462       _ExtendedGDBusArgInfo *arg_info = (_ExtendedGDBusArgInfo *) info->parent_struct.in_args[n - num_extra];
17463       if (arg_info->use_gvariant)
17464         {
17465           g_value_init (&paramv[n], G_TYPE_VARIANT);
17466           g_value_set_variant (&paramv[n], child);
17467           n++;
17468         }
17469       else
17470         g_dbus_gvariant_to_gvalue (child, &paramv[n++]);
17471       g_variant_unref (child);
17472     }
17473   signal_id = g_signal_lookup (info->signal_name, FOO_IGEN_TYPE_CHANGING_INTERFACE_V1);
17474   g_value_init (&return_value, G_TYPE_BOOLEAN);
17475   g_signal_emitv (paramv, signal_id, 0, &return_value);
17476   if (!g_value_get_boolean (&return_value))
17477     g_dbus_method_invocation_return_error (invocation, G_DBUS_ERROR, G_DBUS_ERROR_UNKNOWN_METHOD, "Method %s is not implemented on interface %s", method_name, interface_name);
17478   g_value_unset (&return_value);
17479   for (n = 0; n < num_params + num_extra; n++)
17480     g_value_unset (&paramv[n]);
17481   g_free (paramv);
17482 }
17483
17484 static GVariant *
17485 _foo_igen_changing_interface_v1_skeleton_handle_get_property (
17486   GDBusConnection *connection,
17487   const gchar *sender,
17488   const gchar *object_path,
17489   const gchar *interface_name,
17490   const gchar *property_name,
17491   GError **error,
17492   gpointer user_data)
17493 {
17494   FooiGenChangingInterfaceV1Skeleton *skeleton = FOO_IGEN_CHANGING_INTERFACE_V1_SKELETON (user_data);
17495   GValue value = G_VALUE_INIT;
17496   GParamSpec *pspec;
17497   _ExtendedGDBusPropertyInfo *info;
17498   GVariant *ret;
17499   ret = NULL;
17500   info = (_ExtendedGDBusPropertyInfo *) g_dbus_interface_info_lookup_property ((GDBusInterfaceInfo *) &_foo_igen_changing_interface_v1_interface_info, property_name);
17501   g_assert (info != NULL);
17502   pspec = g_object_class_find_property (G_OBJECT_GET_CLASS (skeleton), info->hyphen_name);
17503   if (pspec == NULL)
17504     {
17505       g_set_error (error, G_DBUS_ERROR, G_DBUS_ERROR_INVALID_ARGS, "No property with name %s", property_name);
17506     }
17507   else
17508     {
17509       g_value_init (&value, pspec->value_type);
17510       g_object_get_property (G_OBJECT (skeleton), info->hyphen_name, &value);
17511       ret = g_dbus_gvalue_to_gvariant (&value, G_VARIANT_TYPE (info->parent_struct.signature));
17512       g_value_unset (&value);
17513     }
17514   return ret;
17515 }
17516
17517 static gboolean
17518 _foo_igen_changing_interface_v1_skeleton_handle_set_property (
17519   GDBusConnection *connection,
17520   const gchar *sender,
17521   const gchar *object_path,
17522   const gchar *interface_name,
17523   const gchar *property_name,
17524   GVariant *variant,
17525   GError **error,
17526   gpointer user_data)
17527 {
17528   FooiGenChangingInterfaceV1Skeleton *skeleton = FOO_IGEN_CHANGING_INTERFACE_V1_SKELETON (user_data);
17529   GValue value = G_VALUE_INIT;
17530   GParamSpec *pspec;
17531   _ExtendedGDBusPropertyInfo *info;
17532   gboolean ret;
17533   ret = FALSE;
17534   info = (_ExtendedGDBusPropertyInfo *) g_dbus_interface_info_lookup_property ((GDBusInterfaceInfo *) &_foo_igen_changing_interface_v1_interface_info, property_name);
17535   g_assert (info != NULL);
17536   pspec = g_object_class_find_property (G_OBJECT_GET_CLASS (skeleton), info->hyphen_name);
17537   if (pspec == NULL)
17538     {
17539       g_set_error (error, G_DBUS_ERROR, G_DBUS_ERROR_INVALID_ARGS, "No property with name %s", property_name);
17540     }
17541   else
17542     {
17543       if (info->use_gvariant)
17544         g_value_set_variant (&value, variant);
17545       else
17546         g_dbus_gvariant_to_gvalue (variant, &value);
17547       g_object_set_property (G_OBJECT (skeleton), info->hyphen_name, &value);
17548       g_value_unset (&value);
17549       ret = TRUE;
17550     }
17551   return ret;
17552 }
17553
17554 static const GDBusInterfaceVTable _foo_igen_changing_interface_v1_skeleton_vtable =
17555 {
17556   _foo_igen_changing_interface_v1_skeleton_handle_method_call,
17557   _foo_igen_changing_interface_v1_skeleton_handle_get_property,
17558   _foo_igen_changing_interface_v1_skeleton_handle_set_property
17559 };
17560
17561 static GDBusInterfaceInfo *
17562 foo_igen_changing_interface_v1_skeleton_dbus_interface_get_info (GDBusInterfaceSkeleton *skeleton)
17563 {
17564   return foo_igen_changing_interface_v1_interface_info ();
17565 }
17566
17567 static GDBusInterfaceVTable *
17568 foo_igen_changing_interface_v1_skeleton_dbus_interface_get_vtable (GDBusInterfaceSkeleton *skeleton)
17569 {
17570   return (GDBusInterfaceVTable *) &_foo_igen_changing_interface_v1_skeleton_vtable;
17571 }
17572
17573 static GVariant *
17574 foo_igen_changing_interface_v1_skeleton_dbus_interface_get_properties (GDBusInterfaceSkeleton *_skeleton)
17575 {
17576   FooiGenChangingInterfaceV1Skeleton *skeleton = FOO_IGEN_CHANGING_INTERFACE_V1_SKELETON (_skeleton);
17577
17578   GVariantBuilder builder;
17579   guint n;
17580   g_variant_builder_init (&builder, G_VARIANT_TYPE ("a{sv}"));
17581   if (_foo_igen_changing_interface_v1_interface_info.parent_struct.properties == NULL)
17582     goto out;
17583   for (n = 0; _foo_igen_changing_interface_v1_interface_info.parent_struct.properties[n] != NULL; n++)
17584     {
17585       GDBusPropertyInfo *info = _foo_igen_changing_interface_v1_interface_info.parent_struct.properties[n];
17586       if (info->flags & G_DBUS_PROPERTY_INFO_FLAGS_READABLE)
17587         {
17588           GVariant *value;
17589           value = _foo_igen_changing_interface_v1_skeleton_handle_get_property (g_dbus_interface_skeleton_get_connection (G_DBUS_INTERFACE_SKELETON (skeleton)), NULL, g_dbus_interface_skeleton_get_object_path (G_DBUS_INTERFACE_SKELETON (skeleton)), "ChangingInterfaceV1", info->name, NULL, skeleton);
17590           if (value != NULL)
17591             {
17592               g_variant_take_ref (value);
17593               g_variant_builder_add (&builder, "{sv}", info->name, value);
17594               g_variant_unref (value);
17595             }
17596         }
17597     }
17598 out:
17599   return g_variant_builder_end (&builder);
17600 }
17601
17602 static void
17603 foo_igen_changing_interface_v1_skeleton_dbus_interface_flush (GDBusInterfaceSkeleton *_skeleton)
17604 {
17605 }
17606
17607 static void
17608 _foo_igen_changing_interface_v1_on_signal_foo_signal (
17609     FooiGenChangingInterfaceV1 *object)
17610 {
17611   FooiGenChangingInterfaceV1Skeleton *skeleton = FOO_IGEN_CHANGING_INTERFACE_V1_SKELETON (object);
17612
17613   GList      *connections, *l;
17614   GVariant   *signal_variant;
17615   connections = g_dbus_interface_skeleton_get_connections (G_DBUS_INTERFACE_SKELETON (skeleton));
17616
17617   signal_variant = g_variant_ref_sink (g_variant_new ("()"));
17618   for (l = connections; l != NULL; l = l->next)
17619     {
17620       GDBusConnection *connection = l->data;
17621       g_dbus_connection_emit_signal (connection,
17622         NULL, g_dbus_interface_skeleton_get_object_path (G_DBUS_INTERFACE_SKELETON (skeleton)), "ChangingInterfaceV1", "FooSignal",
17623         signal_variant, NULL);
17624     }
17625   g_variant_unref (signal_variant);
17626   g_list_free_full (connections, g_object_unref);
17627 }
17628
17629 static void
17630 _foo_igen_changing_interface_v1_on_signal_bar_signal (
17631     FooiGenChangingInterfaceV1 *object)
17632 {
17633   FooiGenChangingInterfaceV1Skeleton *skeleton = FOO_IGEN_CHANGING_INTERFACE_V1_SKELETON (object);
17634
17635   GList      *connections, *l;
17636   GVariant   *signal_variant;
17637   connections = g_dbus_interface_skeleton_get_connections (G_DBUS_INTERFACE_SKELETON (skeleton));
17638
17639   signal_variant = g_variant_ref_sink (g_variant_new ("()"));
17640   for (l = connections; l != NULL; l = l->next)
17641     {
17642       GDBusConnection *connection = l->data;
17643       g_dbus_connection_emit_signal (connection,
17644         NULL, g_dbus_interface_skeleton_get_object_path (G_DBUS_INTERFACE_SKELETON (skeleton)), "ChangingInterfaceV1", "BarSignal",
17645         signal_variant, NULL);
17646     }
17647   g_variant_unref (signal_variant);
17648   g_list_free_full (connections, g_object_unref);
17649 }
17650
17651 static void
17652 _foo_igen_changing_interface_v1_on_signal_baz_signal (
17653     FooiGenChangingInterfaceV1 *object)
17654 {
17655   FooiGenChangingInterfaceV1Skeleton *skeleton = FOO_IGEN_CHANGING_INTERFACE_V1_SKELETON (object);
17656
17657   GList      *connections, *l;
17658   GVariant   *signal_variant;
17659   connections = g_dbus_interface_skeleton_get_connections (G_DBUS_INTERFACE_SKELETON (skeleton));
17660
17661   signal_variant = g_variant_ref_sink (g_variant_new ("()"));
17662   for (l = connections; l != NULL; l = l->next)
17663     {
17664       GDBusConnection *connection = l->data;
17665       g_dbus_connection_emit_signal (connection,
17666         NULL, g_dbus_interface_skeleton_get_object_path (G_DBUS_INTERFACE_SKELETON (skeleton)), "ChangingInterfaceV1", "BazSignal",
17667         signal_variant, NULL);
17668     }
17669   g_variant_unref (signal_variant);
17670   g_list_free_full (connections, g_object_unref);
17671 }
17672
17673 static void foo_igen_changing_interface_v1_skeleton_iface_init (FooiGenChangingInterfaceV1Iface *iface);
17674 G_DEFINE_TYPE_WITH_CODE (FooiGenChangingInterfaceV1Skeleton, foo_igen_changing_interface_v1_skeleton, G_TYPE_DBUS_INTERFACE_SKELETON,
17675                          G_IMPLEMENT_INTERFACE (FOO_IGEN_TYPE_CHANGING_INTERFACE_V1, foo_igen_changing_interface_v1_skeleton_iface_init));
17676
17677 static void
17678 foo_igen_changing_interface_v1_skeleton_finalize (GObject *object)
17679 {
17680   FooiGenChangingInterfaceV1Skeleton *skeleton = FOO_IGEN_CHANGING_INTERFACE_V1_SKELETON (object);
17681   g_list_free_full (skeleton->priv->changed_properties, (GDestroyNotify) _changed_property_free);
17682   if (skeleton->priv->changed_properties_idle_source != NULL)
17683     g_source_destroy (skeleton->priv->changed_properties_idle_source);
17684   g_main_context_unref (skeleton->priv->context);
17685   g_mutex_clear (&skeleton->priv->lock);
17686   G_OBJECT_CLASS (foo_igen_changing_interface_v1_skeleton_parent_class)->finalize (object);
17687 }
17688
17689 static void
17690 foo_igen_changing_interface_v1_skeleton_init (FooiGenChangingInterfaceV1Skeleton *skeleton)
17691 {
17692   skeleton->priv = G_TYPE_INSTANCE_GET_PRIVATE (skeleton, FOO_IGEN_TYPE_CHANGING_INTERFACE_V1_SKELETON, FooiGenChangingInterfaceV1SkeletonPrivate);
17693   g_mutex_init (&skeleton->priv->lock);
17694   skeleton->priv->context = g_main_context_ref_thread_default ();
17695 }
17696
17697 static void
17698 foo_igen_changing_interface_v1_skeleton_class_init (FooiGenChangingInterfaceV1SkeletonClass *klass)
17699 {
17700   GObjectClass *gobject_class;
17701   GDBusInterfaceSkeletonClass *skeleton_class;
17702
17703   g_type_class_add_private (klass, sizeof (FooiGenChangingInterfaceV1SkeletonPrivate));
17704
17705   gobject_class = G_OBJECT_CLASS (klass);
17706   gobject_class->finalize = foo_igen_changing_interface_v1_skeleton_finalize;
17707
17708   skeleton_class = G_DBUS_INTERFACE_SKELETON_CLASS (klass);
17709   skeleton_class->get_info = foo_igen_changing_interface_v1_skeleton_dbus_interface_get_info;
17710   skeleton_class->get_properties = foo_igen_changing_interface_v1_skeleton_dbus_interface_get_properties;
17711   skeleton_class->flush = foo_igen_changing_interface_v1_skeleton_dbus_interface_flush;
17712   skeleton_class->get_vtable = foo_igen_changing_interface_v1_skeleton_dbus_interface_get_vtable;
17713 }
17714
17715 static void
17716 foo_igen_changing_interface_v1_skeleton_iface_init (FooiGenChangingInterfaceV1Iface *iface)
17717 {
17718   iface->foo_signal = _foo_igen_changing_interface_v1_on_signal_foo_signal;
17719   iface->bar_signal = _foo_igen_changing_interface_v1_on_signal_bar_signal;
17720   iface->baz_signal = _foo_igen_changing_interface_v1_on_signal_baz_signal;
17721 }
17722
17723 /**
17724  * foo_igen_changing_interface_v1_skeleton_new:
17725  *
17726  * Creates a skeleton object for the D-Bus interface <link linkend="gdbus-interface-ChangingInterfaceV1.top_of_page">ChangingInterfaceV1</link>.
17727  *
17728  * Returns: (transfer full) (type FooiGenChangingInterfaceV1Skeleton): The skeleton object.
17729  */
17730 FooiGenChangingInterfaceV1 *
17731 foo_igen_changing_interface_v1_skeleton_new (void)
17732 {
17733   return FOO_IGEN_CHANGING_INTERFACE_V1 (g_object_new (FOO_IGEN_TYPE_CHANGING_INTERFACE_V1_SKELETON, NULL));
17734 }
17735
17736 /* ------------------------------------------------------------------------
17737  * Code for interface ChangingInterfaceV2
17738  * ------------------------------------------------------------------------
17739  */
17740
17741 /**
17742  * SECTION:FooiGenChangingInterfaceV2
17743  * @title: FooiGenChangingInterfaceV2
17744  * @short_description: Generated C code for the ChangingInterfaceV2 D-Bus interface
17745  *
17746  * This section contains code for working with the <link linkend="gdbus-interface-ChangingInterfaceV2.top_of_page">ChangingInterfaceV2</link> D-Bus interface in C.
17747  */
17748
17749 /* ---- Introspection data for ChangingInterfaceV2 ---- */
17750
17751 static const _ExtendedGDBusMethodInfo _foo_igen_changing_interface_v2_method_info_new_method_in2 =
17752 {
17753   {
17754     -1,
17755     "NewMethodIn2",
17756     NULL,
17757     NULL,
17758     NULL
17759   },
17760   "handle-new-method-in2",
17761   FALSE
17762 };
17763
17764 static const _ExtendedGDBusMethodInfo _foo_igen_changing_interface_v2_method_info_baz_method =
17765 {
17766   {
17767     -1,
17768     "BazMethod",
17769     NULL,
17770     NULL,
17771     NULL
17772   },
17773   "handle-baz-method",
17774   FALSE
17775 };
17776
17777 static const _ExtendedGDBusMethodInfo _foo_igen_changing_interface_v2_method_info_bar_method =
17778 {
17779   {
17780     -1,
17781     "BarMethod",
17782     NULL,
17783     NULL,
17784     NULL
17785   },
17786   "handle-bar-method",
17787   FALSE
17788 };
17789
17790 static const _ExtendedGDBusMethodInfo _foo_igen_changing_interface_v2_method_info_foo_method =
17791 {
17792   {
17793     -1,
17794     "FooMethod",
17795     NULL,
17796     NULL,
17797     NULL
17798   },
17799   "handle-foo-method",
17800   FALSE
17801 };
17802
17803 static const _ExtendedGDBusMethodInfo * const _foo_igen_changing_interface_v2_method_info_pointers[] =
17804 {
17805   &_foo_igen_changing_interface_v2_method_info_new_method_in2,
17806   &_foo_igen_changing_interface_v2_method_info_baz_method,
17807   &_foo_igen_changing_interface_v2_method_info_bar_method,
17808   &_foo_igen_changing_interface_v2_method_info_foo_method,
17809   NULL
17810 };
17811
17812 static const _ExtendedGDBusSignalInfo _foo_igen_changing_interface_v2_signal_info_new_signal_in2 =
17813 {
17814   {
17815     -1,
17816     "NewSignalIn2",
17817     NULL,
17818     NULL
17819   },
17820   "new-signal-in2"
17821 };
17822
17823 static const _ExtendedGDBusSignalInfo _foo_igen_changing_interface_v2_signal_info_baz_signal =
17824 {
17825   {
17826     -1,
17827     "BazSignal",
17828     NULL,
17829     NULL
17830   },
17831   "baz-signal"
17832 };
17833
17834 static const _ExtendedGDBusSignalInfo _foo_igen_changing_interface_v2_signal_info_bar_signal =
17835 {
17836   {
17837     -1,
17838     "BarSignal",
17839     NULL,
17840     NULL
17841   },
17842   "bar-signal"
17843 };
17844
17845 static const _ExtendedGDBusSignalInfo _foo_igen_changing_interface_v2_signal_info_foo_signal =
17846 {
17847   {
17848     -1,
17849     "FooSignal",
17850     NULL,
17851     NULL
17852   },
17853   "foo-signal"
17854 };
17855
17856 static const _ExtendedGDBusSignalInfo * const _foo_igen_changing_interface_v2_signal_info_pointers[] =
17857 {
17858   &_foo_igen_changing_interface_v2_signal_info_new_signal_in2,
17859   &_foo_igen_changing_interface_v2_signal_info_baz_signal,
17860   &_foo_igen_changing_interface_v2_signal_info_bar_signal,
17861   &_foo_igen_changing_interface_v2_signal_info_foo_signal,
17862   NULL
17863 };
17864
17865 static const _ExtendedGDBusInterfaceInfo _foo_igen_changing_interface_v2_interface_info =
17866 {
17867   {
17868     -1,
17869     "ChangingInterfaceV2",
17870     (GDBusMethodInfo **) &_foo_igen_changing_interface_v2_method_info_pointers,
17871     (GDBusSignalInfo **) &_foo_igen_changing_interface_v2_signal_info_pointers,
17872     NULL,
17873     NULL
17874   },
17875   "changing-interface-v2",
17876 };
17877
17878
17879 /**
17880  * foo_igen_changing_interface_v2_interface_info:
17881  *
17882  * Gets a machine-readable description of the <link linkend="gdbus-interface-ChangingInterfaceV2.top_of_page">ChangingInterfaceV2</link> D-Bus interface.
17883  *
17884  * Returns: (transfer none): A #GDBusInterfaceInfo. Do not free.
17885  *
17886  * Since: 2.0
17887  */
17888 GDBusInterfaceInfo *
17889 foo_igen_changing_interface_v2_interface_info (void)
17890 {
17891   return (GDBusInterfaceInfo *) &_foo_igen_changing_interface_v2_interface_info;
17892 }
17893
17894 /**
17895  * foo_igen_changing_interface_v2_override_properties:
17896  * @klass: The class structure for a #GObject<!-- -->-derived class.
17897  * @property_id_begin: The property id to assign to the first overridden property.
17898  *
17899  * Overrides all #GObject properties in the #FooiGenChangingInterfaceV2 interface for a concrete class.
17900  * The properties are overridden in the order they are defined.
17901  *
17902  * Returns: The last property id.
17903  *
17904  * Since: 2.0
17905  */
17906 guint
17907 foo_igen_changing_interface_v2_override_properties (GObjectClass *klass, guint property_id_begin)
17908 {
17909   return property_id_begin - 1;
17910 }
17911
17912
17913
17914 /**
17915  * FooiGenChangingInterfaceV2:
17916  *
17917  * Abstract interface type for the D-Bus interface <link linkend="gdbus-interface-ChangingInterfaceV2.top_of_page">ChangingInterfaceV2</link>.
17918  *
17919  * Since: 2.0
17920  */
17921
17922 /**
17923  * FooiGenChangingInterfaceV2Iface:
17924  * @parent_iface: The parent interface.
17925  * @handle_bar_method: Handler for the #FooiGenChangingInterfaceV2::handle-bar-method signal.
17926  * @handle_baz_method: Handler for the #FooiGenChangingInterfaceV2::handle-baz-method signal.
17927  * @handle_foo_method: Handler for the #FooiGenChangingInterfaceV2::handle-foo-method signal.
17928  * @bar_signal: Handler for the #FooiGenChangingInterfaceV2::bar-signal signal.
17929  * @baz_signal: Handler for the #FooiGenChangingInterfaceV2::baz-signal signal.
17930  * @foo_signal: Handler for the #FooiGenChangingInterfaceV2::foo-signal signal.
17931  * @handle_new_method_in2: Handler for the #FooiGenChangingInterfaceV2::handle-new-method-in2 signal.
17932  * @new_signal_in2: Handler for the #FooiGenChangingInterfaceV2::new-signal-in2 signal.
17933  *
17934  * Virtual table for the D-Bus interface <link linkend="gdbus-interface-ChangingInterfaceV2.top_of_page">ChangingInterfaceV2</link>.
17935  *
17936  * Since: 2.0
17937  */
17938
17939 static void
17940 foo_igen_changing_interface_v2_default_init (FooiGenChangingInterfaceV2Iface *iface)
17941 {
17942   /* GObject signals for incoming D-Bus method calls: */
17943   /**
17944    * FooiGenChangingInterfaceV2::handle-new-method-in2:
17945    * @object: A #FooiGenChangingInterfaceV2.
17946    * @invocation: A #GDBusMethodInvocation.
17947    *
17948    * Signal emitted when a remote caller is invoking the <link linkend="gdbus-method-ChangingInterfaceV2.NewMethodIn2">NewMethodIn2()</link> D-Bus method.
17949    *
17950    * If a signal handler returns %TRUE, it means the signal handler will handle the invocation (e.g. take a reference to @invocation and eventually call foo_igen_changing_interface_v2_complete_new_method_in2() or e.g. g_dbus_method_invocation_return_error() on it) and no order signal handlers will run. If no signal handler handles the invocation, the %G_DBUS_ERROR_UNKNOWN_METHOD error is returned.
17951    *
17952    * Returns: %TRUE if the invocation was handled, %FALSE to let other signal handlers run.
17953    *
17954    * Since: 2.0
17955    */
17956   g_signal_new ("handle-new-method-in2",
17957     G_TYPE_FROM_INTERFACE (iface),
17958     G_SIGNAL_RUN_LAST,
17959     G_STRUCT_OFFSET (FooiGenChangingInterfaceV2Iface, handle_new_method_in2),
17960     g_signal_accumulator_true_handled,
17961     NULL,
17962     g_cclosure_marshal_generic,
17963     G_TYPE_BOOLEAN,
17964     1,
17965     G_TYPE_DBUS_METHOD_INVOCATION);
17966
17967   /**
17968    * FooiGenChangingInterfaceV2::handle-baz-method:
17969    * @object: A #FooiGenChangingInterfaceV2.
17970    * @invocation: A #GDBusMethodInvocation.
17971    *
17972    * Signal emitted when a remote caller is invoking the <link linkend="gdbus-method-ChangingInterfaceV2.BazMethod">BazMethod()</link> D-Bus method.
17973    *
17974    * If a signal handler returns %TRUE, it means the signal handler will handle the invocation (e.g. take a reference to @invocation and eventually call foo_igen_changing_interface_v2_complete_baz_method() or e.g. g_dbus_method_invocation_return_error() on it) and no order signal handlers will run. If no signal handler handles the invocation, the %G_DBUS_ERROR_UNKNOWN_METHOD error is returned.
17975    *
17976    * Returns: %TRUE if the invocation was handled, %FALSE to let other signal handlers run.
17977    */
17978   g_signal_new ("handle-baz-method",
17979     G_TYPE_FROM_INTERFACE (iface),
17980     G_SIGNAL_RUN_LAST,
17981     G_STRUCT_OFFSET (FooiGenChangingInterfaceV2Iface, handle_baz_method),
17982     g_signal_accumulator_true_handled,
17983     NULL,
17984     g_cclosure_marshal_generic,
17985     G_TYPE_BOOLEAN,
17986     1,
17987     G_TYPE_DBUS_METHOD_INVOCATION);
17988
17989   /**
17990    * FooiGenChangingInterfaceV2::handle-bar-method:
17991    * @object: A #FooiGenChangingInterfaceV2.
17992    * @invocation: A #GDBusMethodInvocation.
17993    *
17994    * Signal emitted when a remote caller is invoking the <link linkend="gdbus-method-ChangingInterfaceV2.BarMethod">BarMethod()</link> D-Bus method.
17995    *
17996    * If a signal handler returns %TRUE, it means the signal handler will handle the invocation (e.g. take a reference to @invocation and eventually call foo_igen_changing_interface_v2_complete_bar_method() or e.g. g_dbus_method_invocation_return_error() on it) and no order signal handlers will run. If no signal handler handles the invocation, the %G_DBUS_ERROR_UNKNOWN_METHOD error is returned.
17997    *
17998    * Returns: %TRUE if the invocation was handled, %FALSE to let other signal handlers run.
17999    */
18000   g_signal_new ("handle-bar-method",
18001     G_TYPE_FROM_INTERFACE (iface),
18002     G_SIGNAL_RUN_LAST,
18003     G_STRUCT_OFFSET (FooiGenChangingInterfaceV2Iface, handle_bar_method),
18004     g_signal_accumulator_true_handled,
18005     NULL,
18006     g_cclosure_marshal_generic,
18007     G_TYPE_BOOLEAN,
18008     1,
18009     G_TYPE_DBUS_METHOD_INVOCATION);
18010
18011   /**
18012    * FooiGenChangingInterfaceV2::handle-foo-method:
18013    * @object: A #FooiGenChangingInterfaceV2.
18014    * @invocation: A #GDBusMethodInvocation.
18015    *
18016    * Signal emitted when a remote caller is invoking the <link linkend="gdbus-method-ChangingInterfaceV2.FooMethod">FooMethod()</link> D-Bus method.
18017    *
18018    * If a signal handler returns %TRUE, it means the signal handler will handle the invocation (e.g. take a reference to @invocation and eventually call foo_igen_changing_interface_v2_complete_foo_method() or e.g. g_dbus_method_invocation_return_error() on it) and no order signal handlers will run. If no signal handler handles the invocation, the %G_DBUS_ERROR_UNKNOWN_METHOD error is returned.
18019    *
18020    * Returns: %TRUE if the invocation was handled, %FALSE to let other signal handlers run.
18021    */
18022   g_signal_new ("handle-foo-method",
18023     G_TYPE_FROM_INTERFACE (iface),
18024     G_SIGNAL_RUN_LAST,
18025     G_STRUCT_OFFSET (FooiGenChangingInterfaceV2Iface, handle_foo_method),
18026     g_signal_accumulator_true_handled,
18027     NULL,
18028     g_cclosure_marshal_generic,
18029     G_TYPE_BOOLEAN,
18030     1,
18031     G_TYPE_DBUS_METHOD_INVOCATION);
18032
18033   /* GObject signals for received D-Bus signals: */
18034   /**
18035    * FooiGenChangingInterfaceV2::new-signal-in2:
18036    * @object: A #FooiGenChangingInterfaceV2.
18037    *
18038    * On the client-side, this signal is emitted whenever the D-Bus signal <link linkend="gdbus-signal-ChangingInterfaceV2.NewSignalIn2">"NewSignalIn2"</link> is received.
18039    *
18040    * On the service-side, this signal can be used with e.g. g_signal_emit_by_name() to make the object emit the D-Bus signal.
18041    *
18042    * Since: 2.0
18043    */
18044   g_signal_new ("new-signal-in2",
18045     G_TYPE_FROM_INTERFACE (iface),
18046     G_SIGNAL_RUN_LAST,
18047     G_STRUCT_OFFSET (FooiGenChangingInterfaceV2Iface, new_signal_in2),
18048     NULL,
18049     NULL,
18050     g_cclosure_marshal_generic,
18051     G_TYPE_NONE,
18052     0);
18053
18054   /**
18055    * FooiGenChangingInterfaceV2::baz-signal:
18056    * @object: A #FooiGenChangingInterfaceV2.
18057    *
18058    * On the client-side, this signal is emitted whenever the D-Bus signal <link linkend="gdbus-signal-ChangingInterfaceV2.BazSignal">"BazSignal"</link> is received.
18059    *
18060    * On the service-side, this signal can be used with e.g. g_signal_emit_by_name() to make the object emit the D-Bus signal.
18061    */
18062   g_signal_new ("baz-signal",
18063     G_TYPE_FROM_INTERFACE (iface),
18064     G_SIGNAL_RUN_LAST,
18065     G_STRUCT_OFFSET (FooiGenChangingInterfaceV2Iface, baz_signal),
18066     NULL,
18067     NULL,
18068     g_cclosure_marshal_generic,
18069     G_TYPE_NONE,
18070     0);
18071
18072   /**
18073    * FooiGenChangingInterfaceV2::bar-signal:
18074    * @object: A #FooiGenChangingInterfaceV2.
18075    *
18076    * On the client-side, this signal is emitted whenever the D-Bus signal <link linkend="gdbus-signal-ChangingInterfaceV2.BarSignal">"BarSignal"</link> is received.
18077    *
18078    * On the service-side, this signal can be used with e.g. g_signal_emit_by_name() to make the object emit the D-Bus signal.
18079    */
18080   g_signal_new ("bar-signal",
18081     G_TYPE_FROM_INTERFACE (iface),
18082     G_SIGNAL_RUN_LAST,
18083     G_STRUCT_OFFSET (FooiGenChangingInterfaceV2Iface, bar_signal),
18084     NULL,
18085     NULL,
18086     g_cclosure_marshal_generic,
18087     G_TYPE_NONE,
18088     0);
18089
18090   /**
18091    * FooiGenChangingInterfaceV2::foo-signal:
18092    * @object: A #FooiGenChangingInterfaceV2.
18093    *
18094    * On the client-side, this signal is emitted whenever the D-Bus signal <link linkend="gdbus-signal-ChangingInterfaceV2.FooSignal">"FooSignal"</link> is received.
18095    *
18096    * On the service-side, this signal can be used with e.g. g_signal_emit_by_name() to make the object emit the D-Bus signal.
18097    */
18098   g_signal_new ("foo-signal",
18099     G_TYPE_FROM_INTERFACE (iface),
18100     G_SIGNAL_RUN_LAST,
18101     G_STRUCT_OFFSET (FooiGenChangingInterfaceV2Iface, foo_signal),
18102     NULL,
18103     NULL,
18104     g_cclosure_marshal_generic,
18105     G_TYPE_NONE,
18106     0);
18107
18108 }
18109
18110 typedef FooiGenChangingInterfaceV2Iface FooiGenChangingInterfaceV2Interface;
18111 G_DEFINE_INTERFACE (FooiGenChangingInterfaceV2, foo_igen_changing_interface_v2, G_TYPE_OBJECT);
18112
18113 /**
18114  * foo_igen_changing_interface_v2_emit_new_signal_in2:
18115  * @object: A #FooiGenChangingInterfaceV2.
18116  *
18117  * Emits the <link linkend="gdbus-signal-ChangingInterfaceV2.NewSignalIn2">"NewSignalIn2"</link> D-Bus signal.
18118  *
18119  * Since: 2.0
18120  */
18121 void
18122 foo_igen_changing_interface_v2_emit_new_signal_in2 (
18123     FooiGenChangingInterfaceV2 *object)
18124 {
18125   g_signal_emit_by_name (object, "new-signal-in2");
18126 }
18127
18128 /**
18129  * foo_igen_changing_interface_v2_emit_baz_signal:
18130  * @object: A #FooiGenChangingInterfaceV2.
18131  *
18132  * Emits the <link linkend="gdbus-signal-ChangingInterfaceV2.BazSignal">"BazSignal"</link> D-Bus signal.
18133  */
18134 void
18135 foo_igen_changing_interface_v2_emit_baz_signal (
18136     FooiGenChangingInterfaceV2 *object)
18137 {
18138   g_signal_emit_by_name (object, "baz-signal");
18139 }
18140
18141 /**
18142  * foo_igen_changing_interface_v2_emit_bar_signal:
18143  * @object: A #FooiGenChangingInterfaceV2.
18144  *
18145  * Emits the <link linkend="gdbus-signal-ChangingInterfaceV2.BarSignal">"BarSignal"</link> D-Bus signal.
18146  */
18147 void
18148 foo_igen_changing_interface_v2_emit_bar_signal (
18149     FooiGenChangingInterfaceV2 *object)
18150 {
18151   g_signal_emit_by_name (object, "bar-signal");
18152 }
18153
18154 /**
18155  * foo_igen_changing_interface_v2_emit_foo_signal:
18156  * @object: A #FooiGenChangingInterfaceV2.
18157  *
18158  * Emits the <link linkend="gdbus-signal-ChangingInterfaceV2.FooSignal">"FooSignal"</link> D-Bus signal.
18159  */
18160 void
18161 foo_igen_changing_interface_v2_emit_foo_signal (
18162     FooiGenChangingInterfaceV2 *object)
18163 {
18164   g_signal_emit_by_name (object, "foo-signal");
18165 }
18166
18167 /**
18168  * foo_igen_changing_interface_v2_call_new_method_in2:
18169  * @proxy: A #FooiGenChangingInterfaceV2Proxy.
18170  * @cancellable: (allow-none): A #GCancellable or %NULL.
18171  * @callback: A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
18172  * @user_data: User data to pass to @callback.
18173  *
18174  * Asynchronously invokes the <link linkend="gdbus-method-ChangingInterfaceV2.NewMethodIn2">NewMethodIn2()</link> D-Bus method on @proxy.
18175  * When the operation is finished, @callback will be invoked in the <link linkend="g-main-context-push-thread-default">thread-default main loop</link> of the thread you are calling this method from.
18176  * You can then call foo_igen_changing_interface_v2_call_new_method_in2_finish() to get the result of the operation.
18177  *
18178  * See foo_igen_changing_interface_v2_call_new_method_in2_sync() for the synchronous, blocking version of this method.
18179  *
18180  * Since: 2.0
18181  */
18182 void
18183 foo_igen_changing_interface_v2_call_new_method_in2 (
18184     FooiGenChangingInterfaceV2 *proxy,
18185     GCancellable *cancellable,
18186     GAsyncReadyCallback callback,
18187     gpointer user_data)
18188 {
18189   g_dbus_proxy_call (G_DBUS_PROXY (proxy),
18190     "NewMethodIn2",
18191     g_variant_new ("()"),
18192     G_DBUS_CALL_FLAGS_NONE,
18193     -1,
18194     cancellable,
18195     callback,
18196     user_data);
18197 }
18198
18199 /**
18200  * foo_igen_changing_interface_v2_call_new_method_in2_finish:
18201  * @proxy: A #FooiGenChangingInterfaceV2Proxy.
18202  * @res: The #GAsyncResult obtained from the #GAsyncReadyCallback passed to foo_igen_changing_interface_v2_call_new_method_in2().
18203  * @error: Return location for error or %NULL.
18204  *
18205  * Finishes an operation started with foo_igen_changing_interface_v2_call_new_method_in2().
18206  *
18207  * Returns: (skip): %TRUE if the call succeded, %FALSE if @error is set.
18208  *
18209  * Since: 2.0
18210  */
18211 gboolean
18212 foo_igen_changing_interface_v2_call_new_method_in2_finish (
18213     FooiGenChangingInterfaceV2 *proxy,
18214     GAsyncResult *res,
18215     GError **error)
18216 {
18217   GVariant *_ret;
18218   _ret = g_dbus_proxy_call_finish (G_DBUS_PROXY (proxy), res, error);
18219   if (_ret == NULL)
18220     goto _out;
18221   g_variant_get (_ret,
18222                  "()");
18223   g_variant_unref (_ret);
18224 _out:
18225   return _ret != NULL;
18226 }
18227
18228 /**
18229  * foo_igen_changing_interface_v2_call_new_method_in2_sync:
18230  * @proxy: A #FooiGenChangingInterfaceV2Proxy.
18231  * @cancellable: (allow-none): A #GCancellable or %NULL.
18232  * @error: Return location for error or %NULL.
18233  *
18234  * Synchronously invokes the <link linkend="gdbus-method-ChangingInterfaceV2.NewMethodIn2">NewMethodIn2()</link> D-Bus method on @proxy. The calling thread is blocked until a reply is received.
18235  *
18236  * See foo_igen_changing_interface_v2_call_new_method_in2() for the asynchronous version of this method.
18237  *
18238  * Returns: (skip): %TRUE if the call succeded, %FALSE if @error is set.
18239  *
18240  * Since: 2.0
18241  */
18242 gboolean
18243 foo_igen_changing_interface_v2_call_new_method_in2_sync (
18244     FooiGenChangingInterfaceV2 *proxy,
18245     GCancellable *cancellable,
18246     GError **error)
18247 {
18248   GVariant *_ret;
18249   _ret = g_dbus_proxy_call_sync (G_DBUS_PROXY (proxy),
18250     "NewMethodIn2",
18251     g_variant_new ("()"),
18252     G_DBUS_CALL_FLAGS_NONE,
18253     -1,
18254     cancellable,
18255     error);
18256   if (_ret == NULL)
18257     goto _out;
18258   g_variant_get (_ret,
18259                  "()");
18260   g_variant_unref (_ret);
18261 _out:
18262   return _ret != NULL;
18263 }
18264
18265 /**
18266  * foo_igen_changing_interface_v2_call_baz_method:
18267  * @proxy: A #FooiGenChangingInterfaceV2Proxy.
18268  * @cancellable: (allow-none): A #GCancellable or %NULL.
18269  * @callback: A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
18270  * @user_data: User data to pass to @callback.
18271  *
18272  * Asynchronously invokes the <link linkend="gdbus-method-ChangingInterfaceV2.BazMethod">BazMethod()</link> D-Bus method on @proxy.
18273  * When the operation is finished, @callback will be invoked in the <link linkend="g-main-context-push-thread-default">thread-default main loop</link> of the thread you are calling this method from.
18274  * You can then call foo_igen_changing_interface_v2_call_baz_method_finish() to get the result of the operation.
18275  *
18276  * See foo_igen_changing_interface_v2_call_baz_method_sync() for the synchronous, blocking version of this method.
18277  */
18278 void
18279 foo_igen_changing_interface_v2_call_baz_method (
18280     FooiGenChangingInterfaceV2 *proxy,
18281     GCancellable *cancellable,
18282     GAsyncReadyCallback callback,
18283     gpointer user_data)
18284 {
18285   g_dbus_proxy_call (G_DBUS_PROXY (proxy),
18286     "BazMethod",
18287     g_variant_new ("()"),
18288     G_DBUS_CALL_FLAGS_NONE,
18289     -1,
18290     cancellable,
18291     callback,
18292     user_data);
18293 }
18294
18295 /**
18296  * foo_igen_changing_interface_v2_call_baz_method_finish:
18297  * @proxy: A #FooiGenChangingInterfaceV2Proxy.
18298  * @res: The #GAsyncResult obtained from the #GAsyncReadyCallback passed to foo_igen_changing_interface_v2_call_baz_method().
18299  * @error: Return location for error or %NULL.
18300  *
18301  * Finishes an operation started with foo_igen_changing_interface_v2_call_baz_method().
18302  *
18303  * Returns: (skip): %TRUE if the call succeded, %FALSE if @error is set.
18304  */
18305 gboolean
18306 foo_igen_changing_interface_v2_call_baz_method_finish (
18307     FooiGenChangingInterfaceV2 *proxy,
18308     GAsyncResult *res,
18309     GError **error)
18310 {
18311   GVariant *_ret;
18312   _ret = g_dbus_proxy_call_finish (G_DBUS_PROXY (proxy), res, error);
18313   if (_ret == NULL)
18314     goto _out;
18315   g_variant_get (_ret,
18316                  "()");
18317   g_variant_unref (_ret);
18318 _out:
18319   return _ret != NULL;
18320 }
18321
18322 /**
18323  * foo_igen_changing_interface_v2_call_baz_method_sync:
18324  * @proxy: A #FooiGenChangingInterfaceV2Proxy.
18325  * @cancellable: (allow-none): A #GCancellable or %NULL.
18326  * @error: Return location for error or %NULL.
18327  *
18328  * Synchronously invokes the <link linkend="gdbus-method-ChangingInterfaceV2.BazMethod">BazMethod()</link> D-Bus method on @proxy. The calling thread is blocked until a reply is received.
18329  *
18330  * See foo_igen_changing_interface_v2_call_baz_method() for the asynchronous version of this method.
18331  *
18332  * Returns: (skip): %TRUE if the call succeded, %FALSE if @error is set.
18333  */
18334 gboolean
18335 foo_igen_changing_interface_v2_call_baz_method_sync (
18336     FooiGenChangingInterfaceV2 *proxy,
18337     GCancellable *cancellable,
18338     GError **error)
18339 {
18340   GVariant *_ret;
18341   _ret = g_dbus_proxy_call_sync (G_DBUS_PROXY (proxy),
18342     "BazMethod",
18343     g_variant_new ("()"),
18344     G_DBUS_CALL_FLAGS_NONE,
18345     -1,
18346     cancellable,
18347     error);
18348   if (_ret == NULL)
18349     goto _out;
18350   g_variant_get (_ret,
18351                  "()");
18352   g_variant_unref (_ret);
18353 _out:
18354   return _ret != NULL;
18355 }
18356
18357 /**
18358  * foo_igen_changing_interface_v2_call_bar_method:
18359  * @proxy: A #FooiGenChangingInterfaceV2Proxy.
18360  * @cancellable: (allow-none): A #GCancellable or %NULL.
18361  * @callback: A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
18362  * @user_data: User data to pass to @callback.
18363  *
18364  * Asynchronously invokes the <link linkend="gdbus-method-ChangingInterfaceV2.BarMethod">BarMethod()</link> D-Bus method on @proxy.
18365  * When the operation is finished, @callback will be invoked in the <link linkend="g-main-context-push-thread-default">thread-default main loop</link> of the thread you are calling this method from.
18366  * You can then call foo_igen_changing_interface_v2_call_bar_method_finish() to get the result of the operation.
18367  *
18368  * See foo_igen_changing_interface_v2_call_bar_method_sync() for the synchronous, blocking version of this method.
18369  */
18370 void
18371 foo_igen_changing_interface_v2_call_bar_method (
18372     FooiGenChangingInterfaceV2 *proxy,
18373     GCancellable *cancellable,
18374     GAsyncReadyCallback callback,
18375     gpointer user_data)
18376 {
18377   g_dbus_proxy_call (G_DBUS_PROXY (proxy),
18378     "BarMethod",
18379     g_variant_new ("()"),
18380     G_DBUS_CALL_FLAGS_NONE,
18381     -1,
18382     cancellable,
18383     callback,
18384     user_data);
18385 }
18386
18387 /**
18388  * foo_igen_changing_interface_v2_call_bar_method_finish:
18389  * @proxy: A #FooiGenChangingInterfaceV2Proxy.
18390  * @res: The #GAsyncResult obtained from the #GAsyncReadyCallback passed to foo_igen_changing_interface_v2_call_bar_method().
18391  * @error: Return location for error or %NULL.
18392  *
18393  * Finishes an operation started with foo_igen_changing_interface_v2_call_bar_method().
18394  *
18395  * Returns: (skip): %TRUE if the call succeded, %FALSE if @error is set.
18396  */
18397 gboolean
18398 foo_igen_changing_interface_v2_call_bar_method_finish (
18399     FooiGenChangingInterfaceV2 *proxy,
18400     GAsyncResult *res,
18401     GError **error)
18402 {
18403   GVariant *_ret;
18404   _ret = g_dbus_proxy_call_finish (G_DBUS_PROXY (proxy), res, error);
18405   if (_ret == NULL)
18406     goto _out;
18407   g_variant_get (_ret,
18408                  "()");
18409   g_variant_unref (_ret);
18410 _out:
18411   return _ret != NULL;
18412 }
18413
18414 /**
18415  * foo_igen_changing_interface_v2_call_bar_method_sync:
18416  * @proxy: A #FooiGenChangingInterfaceV2Proxy.
18417  * @cancellable: (allow-none): A #GCancellable or %NULL.
18418  * @error: Return location for error or %NULL.
18419  *
18420  * Synchronously invokes the <link linkend="gdbus-method-ChangingInterfaceV2.BarMethod">BarMethod()</link> D-Bus method on @proxy. The calling thread is blocked until a reply is received.
18421  *
18422  * See foo_igen_changing_interface_v2_call_bar_method() for the asynchronous version of this method.
18423  *
18424  * Returns: (skip): %TRUE if the call succeded, %FALSE if @error is set.
18425  */
18426 gboolean
18427 foo_igen_changing_interface_v2_call_bar_method_sync (
18428     FooiGenChangingInterfaceV2 *proxy,
18429     GCancellable *cancellable,
18430     GError **error)
18431 {
18432   GVariant *_ret;
18433   _ret = g_dbus_proxy_call_sync (G_DBUS_PROXY (proxy),
18434     "BarMethod",
18435     g_variant_new ("()"),
18436     G_DBUS_CALL_FLAGS_NONE,
18437     -1,
18438     cancellable,
18439     error);
18440   if (_ret == NULL)
18441     goto _out;
18442   g_variant_get (_ret,
18443                  "()");
18444   g_variant_unref (_ret);
18445 _out:
18446   return _ret != NULL;
18447 }
18448
18449 /**
18450  * foo_igen_changing_interface_v2_call_foo_method:
18451  * @proxy: A #FooiGenChangingInterfaceV2Proxy.
18452  * @cancellable: (allow-none): A #GCancellable or %NULL.
18453  * @callback: A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
18454  * @user_data: User data to pass to @callback.
18455  *
18456  * Asynchronously invokes the <link linkend="gdbus-method-ChangingInterfaceV2.FooMethod">FooMethod()</link> D-Bus method on @proxy.
18457  * When the operation is finished, @callback will be invoked in the <link linkend="g-main-context-push-thread-default">thread-default main loop</link> of the thread you are calling this method from.
18458  * You can then call foo_igen_changing_interface_v2_call_foo_method_finish() to get the result of the operation.
18459  *
18460  * See foo_igen_changing_interface_v2_call_foo_method_sync() for the synchronous, blocking version of this method.
18461  */
18462 void
18463 foo_igen_changing_interface_v2_call_foo_method (
18464     FooiGenChangingInterfaceV2 *proxy,
18465     GCancellable *cancellable,
18466     GAsyncReadyCallback callback,
18467     gpointer user_data)
18468 {
18469   g_dbus_proxy_call (G_DBUS_PROXY (proxy),
18470     "FooMethod",
18471     g_variant_new ("()"),
18472     G_DBUS_CALL_FLAGS_NONE,
18473     -1,
18474     cancellable,
18475     callback,
18476     user_data);
18477 }
18478
18479 /**
18480  * foo_igen_changing_interface_v2_call_foo_method_finish:
18481  * @proxy: A #FooiGenChangingInterfaceV2Proxy.
18482  * @res: The #GAsyncResult obtained from the #GAsyncReadyCallback passed to foo_igen_changing_interface_v2_call_foo_method().
18483  * @error: Return location for error or %NULL.
18484  *
18485  * Finishes an operation started with foo_igen_changing_interface_v2_call_foo_method().
18486  *
18487  * Returns: (skip): %TRUE if the call succeded, %FALSE if @error is set.
18488  */
18489 gboolean
18490 foo_igen_changing_interface_v2_call_foo_method_finish (
18491     FooiGenChangingInterfaceV2 *proxy,
18492     GAsyncResult *res,
18493     GError **error)
18494 {
18495   GVariant *_ret;
18496   _ret = g_dbus_proxy_call_finish (G_DBUS_PROXY (proxy), res, error);
18497   if (_ret == NULL)
18498     goto _out;
18499   g_variant_get (_ret,
18500                  "()");
18501   g_variant_unref (_ret);
18502 _out:
18503   return _ret != NULL;
18504 }
18505
18506 /**
18507  * foo_igen_changing_interface_v2_call_foo_method_sync:
18508  * @proxy: A #FooiGenChangingInterfaceV2Proxy.
18509  * @cancellable: (allow-none): A #GCancellable or %NULL.
18510  * @error: Return location for error or %NULL.
18511  *
18512  * Synchronously invokes the <link linkend="gdbus-method-ChangingInterfaceV2.FooMethod">FooMethod()</link> D-Bus method on @proxy. The calling thread is blocked until a reply is received.
18513  *
18514  * See foo_igen_changing_interface_v2_call_foo_method() for the asynchronous version of this method.
18515  *
18516  * Returns: (skip): %TRUE if the call succeded, %FALSE if @error is set.
18517  */
18518 gboolean
18519 foo_igen_changing_interface_v2_call_foo_method_sync (
18520     FooiGenChangingInterfaceV2 *proxy,
18521     GCancellable *cancellable,
18522     GError **error)
18523 {
18524   GVariant *_ret;
18525   _ret = g_dbus_proxy_call_sync (G_DBUS_PROXY (proxy),
18526     "FooMethod",
18527     g_variant_new ("()"),
18528     G_DBUS_CALL_FLAGS_NONE,
18529     -1,
18530     cancellable,
18531     error);
18532   if (_ret == NULL)
18533     goto _out;
18534   g_variant_get (_ret,
18535                  "()");
18536   g_variant_unref (_ret);
18537 _out:
18538   return _ret != NULL;
18539 }
18540
18541 /**
18542  * foo_igen_changing_interface_v2_complete_new_method_in2:
18543  * @object: A #FooiGenChangingInterfaceV2.
18544  * @invocation: (transfer full): A #GDBusMethodInvocation.
18545  *
18546  * Helper function used in service implementations to finish handling invocations of the <link linkend="gdbus-method-ChangingInterfaceV2.NewMethodIn2">NewMethodIn2()</link> D-Bus method. If you instead want to finish handling an invocation by returning an error, use g_dbus_method_invocation_return_error() or similar.
18547  *
18548  * This method will free @invocation, you cannot use it afterwards.
18549  *
18550  * Since: 2.0
18551  */
18552 void
18553 foo_igen_changing_interface_v2_complete_new_method_in2 (
18554     FooiGenChangingInterfaceV2 *object,
18555     GDBusMethodInvocation *invocation)
18556 {
18557   g_dbus_method_invocation_return_value (invocation,
18558     g_variant_new ("()"));
18559 }
18560
18561 /**
18562  * foo_igen_changing_interface_v2_complete_baz_method:
18563  * @object: A #FooiGenChangingInterfaceV2.
18564  * @invocation: (transfer full): A #GDBusMethodInvocation.
18565  *
18566  * Helper function used in service implementations to finish handling invocations of the <link linkend="gdbus-method-ChangingInterfaceV2.BazMethod">BazMethod()</link> D-Bus method. If you instead want to finish handling an invocation by returning an error, use g_dbus_method_invocation_return_error() or similar.
18567  *
18568  * This method will free @invocation, you cannot use it afterwards.
18569  */
18570 void
18571 foo_igen_changing_interface_v2_complete_baz_method (
18572     FooiGenChangingInterfaceV2 *object,
18573     GDBusMethodInvocation *invocation)
18574 {
18575   g_dbus_method_invocation_return_value (invocation,
18576     g_variant_new ("()"));
18577 }
18578
18579 /**
18580  * foo_igen_changing_interface_v2_complete_bar_method:
18581  * @object: A #FooiGenChangingInterfaceV2.
18582  * @invocation: (transfer full): A #GDBusMethodInvocation.
18583  *
18584  * Helper function used in service implementations to finish handling invocations of the <link linkend="gdbus-method-ChangingInterfaceV2.BarMethod">BarMethod()</link> D-Bus method. If you instead want to finish handling an invocation by returning an error, use g_dbus_method_invocation_return_error() or similar.
18585  *
18586  * This method will free @invocation, you cannot use it afterwards.
18587  */
18588 void
18589 foo_igen_changing_interface_v2_complete_bar_method (
18590     FooiGenChangingInterfaceV2 *object,
18591     GDBusMethodInvocation *invocation)
18592 {
18593   g_dbus_method_invocation_return_value (invocation,
18594     g_variant_new ("()"));
18595 }
18596
18597 /**
18598  * foo_igen_changing_interface_v2_complete_foo_method:
18599  * @object: A #FooiGenChangingInterfaceV2.
18600  * @invocation: (transfer full): A #GDBusMethodInvocation.
18601  *
18602  * Helper function used in service implementations to finish handling invocations of the <link linkend="gdbus-method-ChangingInterfaceV2.FooMethod">FooMethod()</link> D-Bus method. If you instead want to finish handling an invocation by returning an error, use g_dbus_method_invocation_return_error() or similar.
18603  *
18604  * This method will free @invocation, you cannot use it afterwards.
18605  */
18606 void
18607 foo_igen_changing_interface_v2_complete_foo_method (
18608     FooiGenChangingInterfaceV2 *object,
18609     GDBusMethodInvocation *invocation)
18610 {
18611   g_dbus_method_invocation_return_value (invocation,
18612     g_variant_new ("()"));
18613 }
18614
18615 /* ------------------------------------------------------------------------ */
18616
18617 /**
18618  * FooiGenChangingInterfaceV2Proxy:
18619  *
18620  * The #FooiGenChangingInterfaceV2Proxy structure contains only private data and should only be accessed using the provided API.
18621  *
18622  * Since: 2.0
18623  */
18624
18625 /**
18626  * FooiGenChangingInterfaceV2ProxyClass:
18627  * @parent_class: The parent class.
18628  *
18629  * Class structure for #FooiGenChangingInterfaceV2Proxy.
18630  *
18631  * Since: 2.0
18632  */
18633
18634 struct _FooiGenChangingInterfaceV2ProxyPrivate
18635 {
18636   GData *qdata;
18637 };
18638
18639 static void foo_igen_changing_interface_v2_proxy_iface_init (FooiGenChangingInterfaceV2Iface *iface);
18640
18641 G_DEFINE_TYPE_WITH_CODE (FooiGenChangingInterfaceV2Proxy, foo_igen_changing_interface_v2_proxy, G_TYPE_DBUS_PROXY,
18642                          G_IMPLEMENT_INTERFACE (FOO_IGEN_TYPE_CHANGING_INTERFACE_V2, foo_igen_changing_interface_v2_proxy_iface_init));
18643
18644 static void
18645 foo_igen_changing_interface_v2_proxy_finalize (GObject *object)
18646 {
18647   FooiGenChangingInterfaceV2Proxy *proxy = FOO_IGEN_CHANGING_INTERFACE_V2_PROXY (object);
18648   g_datalist_clear (&proxy->priv->qdata);
18649   G_OBJECT_CLASS (foo_igen_changing_interface_v2_proxy_parent_class)->finalize (object);
18650 }
18651
18652 static void
18653 foo_igen_changing_interface_v2_proxy_get_property (GObject      *object,
18654   guint         prop_id,
18655   GValue       *value,
18656   GParamSpec   *pspec)
18657 {
18658 }
18659
18660 static void
18661 foo_igen_changing_interface_v2_proxy_set_property (GObject      *object,
18662   guint         prop_id,
18663   const GValue *value,
18664   GParamSpec   *pspec)
18665 {
18666 }
18667
18668 static void
18669 foo_igen_changing_interface_v2_proxy_g_signal (GDBusProxy *proxy,
18670   const gchar *sender_name,
18671   const gchar *signal_name,
18672   GVariant *parameters)
18673 {
18674   _ExtendedGDBusSignalInfo *info;
18675   GVariantIter iter;
18676   GVariant *child;
18677   GValue *paramv;
18678   guint num_params;
18679   guint n;
18680   guint signal_id;
18681   info = (_ExtendedGDBusSignalInfo *) g_dbus_interface_info_lookup_signal ((GDBusInterfaceInfo *) &_foo_igen_changing_interface_v2_interface_info, signal_name);
18682   if (info == NULL)
18683     return;
18684   num_params = g_variant_n_children (parameters);
18685   paramv = g_new0 (GValue, num_params + 1);
18686   g_value_init (&paramv[0], FOO_IGEN_TYPE_CHANGING_INTERFACE_V2);
18687   g_value_set_object (&paramv[0], proxy);
18688   g_variant_iter_init (&iter, parameters);
18689   n = 1;
18690   while ((child = g_variant_iter_next_value (&iter)) != NULL)
18691     {
18692       _ExtendedGDBusArgInfo *arg_info = (_ExtendedGDBusArgInfo *) info->parent_struct.args[n - 1];
18693       if (arg_info->use_gvariant)
18694         {
18695           g_value_init (&paramv[n], G_TYPE_VARIANT);
18696           g_value_set_variant (&paramv[n], child);
18697           n++;
18698         }
18699       else
18700         g_dbus_gvariant_to_gvalue (child, &paramv[n++]);
18701       g_variant_unref (child);
18702     }
18703   signal_id = g_signal_lookup (info->signal_name, FOO_IGEN_TYPE_CHANGING_INTERFACE_V2);
18704   g_signal_emitv (paramv, signal_id, 0, NULL);
18705   for (n = 0; n < num_params + 1; n++)
18706     g_value_unset (&paramv[n]);
18707   g_free (paramv);
18708 }
18709
18710 static void
18711 foo_igen_changing_interface_v2_proxy_g_properties_changed (GDBusProxy *_proxy,
18712   GVariant *changed_properties,
18713   const gchar *const *invalidated_properties)
18714 {
18715   FooiGenChangingInterfaceV2Proxy *proxy = FOO_IGEN_CHANGING_INTERFACE_V2_PROXY (_proxy);
18716   guint n;
18717   const gchar *key;
18718   GVariantIter *iter;
18719   _ExtendedGDBusPropertyInfo *info;
18720   g_variant_get (changed_properties, "a{sv}", &iter);
18721   while (g_variant_iter_next (iter, "{&sv}", &key, NULL))
18722     {
18723       info = (_ExtendedGDBusPropertyInfo *) g_dbus_interface_info_lookup_property ((GDBusInterfaceInfo *) &_foo_igen_changing_interface_v2_interface_info, key);
18724       g_datalist_remove_data (&proxy->priv->qdata, key);
18725       if (info != NULL)
18726         g_object_notify (G_OBJECT (proxy), info->hyphen_name);
18727     }
18728   g_variant_iter_free (iter);
18729   for (n = 0; invalidated_properties[n] != NULL; n++)
18730     {
18731       info = (_ExtendedGDBusPropertyInfo *) g_dbus_interface_info_lookup_property ((GDBusInterfaceInfo *) &_foo_igen_changing_interface_v2_interface_info, invalidated_properties[n]);
18732       g_datalist_remove_data (&proxy->priv->qdata, invalidated_properties[n]);
18733       if (info != NULL)
18734         g_object_notify (G_OBJECT (proxy), info->hyphen_name);
18735     }
18736 }
18737
18738 static void
18739 foo_igen_changing_interface_v2_proxy_init (FooiGenChangingInterfaceV2Proxy *proxy)
18740 {
18741   proxy->priv = G_TYPE_INSTANCE_GET_PRIVATE (proxy, FOO_IGEN_TYPE_CHANGING_INTERFACE_V2_PROXY, FooiGenChangingInterfaceV2ProxyPrivate);
18742   g_dbus_proxy_set_interface_info (G_DBUS_PROXY (proxy), foo_igen_changing_interface_v2_interface_info ());
18743 }
18744
18745 static void
18746 foo_igen_changing_interface_v2_proxy_class_init (FooiGenChangingInterfaceV2ProxyClass *klass)
18747 {
18748   GObjectClass *gobject_class;
18749   GDBusProxyClass *proxy_class;
18750
18751   g_type_class_add_private (klass, sizeof (FooiGenChangingInterfaceV2ProxyPrivate));
18752
18753   gobject_class = G_OBJECT_CLASS (klass);
18754   gobject_class->finalize     = foo_igen_changing_interface_v2_proxy_finalize;
18755   gobject_class->get_property = foo_igen_changing_interface_v2_proxy_get_property;
18756   gobject_class->set_property = foo_igen_changing_interface_v2_proxy_set_property;
18757
18758   proxy_class = G_DBUS_PROXY_CLASS (klass);
18759   proxy_class->g_signal = foo_igen_changing_interface_v2_proxy_g_signal;
18760   proxy_class->g_properties_changed = foo_igen_changing_interface_v2_proxy_g_properties_changed;
18761
18762 }
18763
18764 static void
18765 foo_igen_changing_interface_v2_proxy_iface_init (FooiGenChangingInterfaceV2Iface *iface)
18766 {
18767 }
18768
18769 /**
18770  * foo_igen_changing_interface_v2_proxy_new:
18771  * @connection: A #GDBusConnection.
18772  * @flags: Flags from the #GDBusProxyFlags enumeration.
18773  * @name: (allow-none): A bus name (well-known or unique) or %NULL if @connection is not a message bus connection.
18774  * @object_path: An object path.
18775  * @cancellable: (allow-none): A #GCancellable or %NULL.
18776  * @callback: A #GAsyncReadyCallback to call when the request is satisfied.
18777  * @user_data: User data to pass to @callback.
18778  *
18779  * Asynchronously creates a proxy for the D-Bus interface <link linkend="gdbus-interface-ChangingInterfaceV2.top_of_page">ChangingInterfaceV2</link>. See g_dbus_proxy_new() for more details.
18780  *
18781  * When the operation is finished, @callback will be invoked in the <link linkend="g-main-context-push-thread-default">thread-default main loop</link> of the thread you are calling this method from.
18782  * You can then call foo_igen_changing_interface_v2_proxy_new_finish() to get the result of the operation.
18783  *
18784  * See foo_igen_changing_interface_v2_proxy_new_sync() for the synchronous, blocking version of this constructor.
18785  *
18786  * Since: 2.0
18787  */
18788 void
18789 foo_igen_changing_interface_v2_proxy_new (
18790     GDBusConnection     *connection,
18791     GDBusProxyFlags      flags,
18792     const gchar         *name,
18793     const gchar         *object_path,
18794     GCancellable        *cancellable,
18795     GAsyncReadyCallback  callback,
18796     gpointer             user_data)
18797 {
18798   g_async_initable_new_async (FOO_IGEN_TYPE_CHANGING_INTERFACE_V2_PROXY, G_PRIORITY_DEFAULT, cancellable, callback, user_data, "g-flags", flags, "g-name", name, "g-connection", connection, "g-object-path", object_path, "g-interface-name", "ChangingInterfaceV2", NULL);
18799 }
18800
18801 /**
18802  * foo_igen_changing_interface_v2_proxy_new_finish:
18803  * @res: The #GAsyncResult obtained from the #GAsyncReadyCallback passed to foo_igen_changing_interface_v2_proxy_new().
18804  * @error: Return location for error or %NULL
18805  *
18806  * Finishes an operation started with foo_igen_changing_interface_v2_proxy_new().
18807  *
18808  * Returns: (transfer full) (type FooiGenChangingInterfaceV2Proxy): The constructed proxy object or %NULL if @error is set.
18809  *
18810  * Since: 2.0
18811  */
18812 FooiGenChangingInterfaceV2 *
18813 foo_igen_changing_interface_v2_proxy_new_finish (
18814     GAsyncResult        *res,
18815     GError             **error)
18816 {
18817   GObject *ret;
18818   GObject *source_object;
18819   source_object = g_async_result_get_source_object (res);
18820   ret = g_async_initable_new_finish (G_ASYNC_INITABLE (source_object), res, error);
18821   g_object_unref (source_object);
18822   if (ret != NULL)
18823     return FOO_IGEN_CHANGING_INTERFACE_V2 (ret);
18824   else
18825     return NULL;
18826 }
18827
18828 /**
18829  * foo_igen_changing_interface_v2_proxy_new_sync:
18830  * @connection: A #GDBusConnection.
18831  * @flags: Flags from the #GDBusProxyFlags enumeration.
18832  * @name: (allow-none): A bus name (well-known or unique) or %NULL if @connection is not a message bus connection.
18833  * @object_path: An object path.
18834  * @cancellable: (allow-none): A #GCancellable or %NULL.
18835  * @error: Return location for error or %NULL
18836  *
18837  * Synchronously creates a proxy for the D-Bus interface <link linkend="gdbus-interface-ChangingInterfaceV2.top_of_page">ChangingInterfaceV2</link>. See g_dbus_proxy_new_sync() for more details.
18838  *
18839  * The calling thread is blocked until a reply is received.
18840  *
18841  * See foo_igen_changing_interface_v2_proxy_new() for the asynchronous version of this constructor.
18842  *
18843  * Returns: (transfer full) (type FooiGenChangingInterfaceV2Proxy): The constructed proxy object or %NULL if @error is set.
18844  *
18845  * Since: 2.0
18846  */
18847 FooiGenChangingInterfaceV2 *
18848 foo_igen_changing_interface_v2_proxy_new_sync (
18849     GDBusConnection     *connection,
18850     GDBusProxyFlags      flags,
18851     const gchar         *name,
18852     const gchar         *object_path,
18853     GCancellable        *cancellable,
18854     GError             **error)
18855 {
18856   GInitable *ret;
18857   ret = g_initable_new (FOO_IGEN_TYPE_CHANGING_INTERFACE_V2_PROXY, cancellable, error, "g-flags", flags, "g-name", name, "g-connection", connection, "g-object-path", object_path, "g-interface-name", "ChangingInterfaceV2", NULL);
18858   if (ret != NULL)
18859     return FOO_IGEN_CHANGING_INTERFACE_V2 (ret);
18860   else
18861     return NULL;
18862 }
18863
18864
18865 /**
18866  * foo_igen_changing_interface_v2_proxy_new_for_bus:
18867  * @bus_type: A #GBusType.
18868  * @flags: Flags from the #GDBusProxyFlags enumeration.
18869  * @name: A bus name (well-known or unique).
18870  * @object_path: An object path.
18871  * @cancellable: (allow-none): A #GCancellable or %NULL.
18872  * @callback: A #GAsyncReadyCallback to call when the request is satisfied.
18873  * @user_data: User data to pass to @callback.
18874  *
18875  * Like foo_igen_changing_interface_v2_proxy_new() but takes a #GBusType instead of a #GDBusConnection.
18876  *
18877  * When the operation is finished, @callback will be invoked in the <link linkend="g-main-context-push-thread-default">thread-default main loop</link> of the thread you are calling this method from.
18878  * You can then call foo_igen_changing_interface_v2_proxy_new_for_bus_finish() to get the result of the operation.
18879  *
18880  * See foo_igen_changing_interface_v2_proxy_new_for_bus_sync() for the synchronous, blocking version of this constructor.
18881  *
18882  * Since: 2.0
18883  */
18884 void
18885 foo_igen_changing_interface_v2_proxy_new_for_bus (
18886     GBusType             bus_type,
18887     GDBusProxyFlags      flags,
18888     const gchar         *name,
18889     const gchar         *object_path,
18890     GCancellable        *cancellable,
18891     GAsyncReadyCallback  callback,
18892     gpointer             user_data)
18893 {
18894   g_async_initable_new_async (FOO_IGEN_TYPE_CHANGING_INTERFACE_V2_PROXY, G_PRIORITY_DEFAULT, cancellable, callback, user_data, "g-flags", flags, "g-name", name, "g-bus-type", bus_type, "g-object-path", object_path, "g-interface-name", "ChangingInterfaceV2", NULL);
18895 }
18896
18897 /**
18898  * foo_igen_changing_interface_v2_proxy_new_for_bus_finish:
18899  * @res: The #GAsyncResult obtained from the #GAsyncReadyCallback passed to foo_igen_changing_interface_v2_proxy_new_for_bus().
18900  * @error: Return location for error or %NULL
18901  *
18902  * Finishes an operation started with foo_igen_changing_interface_v2_proxy_new_for_bus().
18903  *
18904  * Returns: (transfer full) (type FooiGenChangingInterfaceV2Proxy): The constructed proxy object or %NULL if @error is set.
18905  *
18906  * Since: 2.0
18907  */
18908 FooiGenChangingInterfaceV2 *
18909 foo_igen_changing_interface_v2_proxy_new_for_bus_finish (
18910     GAsyncResult        *res,
18911     GError             **error)
18912 {
18913   GObject *ret;
18914   GObject *source_object;
18915   source_object = g_async_result_get_source_object (res);
18916   ret = g_async_initable_new_finish (G_ASYNC_INITABLE (source_object), res, error);
18917   g_object_unref (source_object);
18918   if (ret != NULL)
18919     return FOO_IGEN_CHANGING_INTERFACE_V2 (ret);
18920   else
18921     return NULL;
18922 }
18923
18924 /**
18925  * foo_igen_changing_interface_v2_proxy_new_for_bus_sync:
18926  * @bus_type: A #GBusType.
18927  * @flags: Flags from the #GDBusProxyFlags enumeration.
18928  * @name: A bus name (well-known or unique).
18929  * @object_path: An object path.
18930  * @cancellable: (allow-none): A #GCancellable or %NULL.
18931  * @error: Return location for error or %NULL
18932  *
18933  * Like foo_igen_changing_interface_v2_proxy_new_sync() but takes a #GBusType instead of a #GDBusConnection.
18934  *
18935  * The calling thread is blocked until a reply is received.
18936  *
18937  * See foo_igen_changing_interface_v2_proxy_new_for_bus() for the asynchronous version of this constructor.
18938  *
18939  * Returns: (transfer full) (type FooiGenChangingInterfaceV2Proxy): The constructed proxy object or %NULL if @error is set.
18940  *
18941  * Since: 2.0
18942  */
18943 FooiGenChangingInterfaceV2 *
18944 foo_igen_changing_interface_v2_proxy_new_for_bus_sync (
18945     GBusType             bus_type,
18946     GDBusProxyFlags      flags,
18947     const gchar         *name,
18948     const gchar         *object_path,
18949     GCancellable        *cancellable,
18950     GError             **error)
18951 {
18952   GInitable *ret;
18953   ret = g_initable_new (FOO_IGEN_TYPE_CHANGING_INTERFACE_V2_PROXY, cancellable, error, "g-flags", flags, "g-name", name, "g-bus-type", bus_type, "g-object-path", object_path, "g-interface-name", "ChangingInterfaceV2", NULL);
18954   if (ret != NULL)
18955     return FOO_IGEN_CHANGING_INTERFACE_V2 (ret);
18956   else
18957     return NULL;
18958 }
18959
18960
18961 /* ------------------------------------------------------------------------ */
18962
18963 /**
18964  * FooiGenChangingInterfaceV2Skeleton:
18965  *
18966  * The #FooiGenChangingInterfaceV2Skeleton structure contains only private data and should only be accessed using the provided API.
18967  *
18968  * Since: 2.0
18969  */
18970
18971 /**
18972  * FooiGenChangingInterfaceV2SkeletonClass:
18973  * @parent_class: The parent class.
18974  *
18975  * Class structure for #FooiGenChangingInterfaceV2Skeleton.
18976  *
18977  * Since: 2.0
18978  */
18979
18980 struct _FooiGenChangingInterfaceV2SkeletonPrivate
18981 {
18982   GValue *properties;
18983   GList *changed_properties;
18984   GSource *changed_properties_idle_source;
18985   GMainContext *context;
18986   GMutex lock;
18987 };
18988
18989 static void
18990 _foo_igen_changing_interface_v2_skeleton_handle_method_call (
18991   GDBusConnection *connection,
18992   const gchar *sender,
18993   const gchar *object_path,
18994   const gchar *interface_name,
18995   const gchar *method_name,
18996   GVariant *parameters,
18997   GDBusMethodInvocation *invocation,
18998   gpointer user_data)
18999 {
19000   FooiGenChangingInterfaceV2Skeleton *skeleton = FOO_IGEN_CHANGING_INTERFACE_V2_SKELETON (user_data);
19001   _ExtendedGDBusMethodInfo *info;
19002   GVariantIter iter;
19003   GVariant *child;
19004   GValue *paramv;
19005   guint num_params;
19006   guint num_extra;
19007   guint n;
19008   guint signal_id;
19009   GValue return_value = G_VALUE_INIT;
19010   info = (_ExtendedGDBusMethodInfo *) g_dbus_method_invocation_get_method_info (invocation);
19011   g_assert (info != NULL);
19012   num_params = g_variant_n_children (parameters);
19013   num_extra = info->pass_fdlist ? 3 : 2;  paramv = g_new0 (GValue, num_params + num_extra);
19014   n = 0;
19015   g_value_init (&paramv[n], FOO_IGEN_TYPE_CHANGING_INTERFACE_V2);
19016   g_value_set_object (&paramv[n++], skeleton);
19017   g_value_init (&paramv[n], G_TYPE_DBUS_METHOD_INVOCATION);
19018   g_value_set_object (&paramv[n++], invocation);
19019   if (info->pass_fdlist)
19020     {
19021 #ifdef G_OS_UNIX
19022       g_value_init (&paramv[n], G_TYPE_UNIX_FD_LIST);
19023       g_value_set_object (&paramv[n++], g_dbus_message_get_unix_fd_list (g_dbus_method_invocation_get_message (invocation)));
19024 #else
19025       g_assert_not_reached ();
19026 #endif
19027     }
19028   g_variant_iter_init (&iter, parameters);
19029   while ((child = g_variant_iter_next_value (&iter)) != NULL)
19030     {
19031       _ExtendedGDBusArgInfo *arg_info = (_ExtendedGDBusArgInfo *) info->parent_struct.in_args[n - num_extra];
19032       if (arg_info->use_gvariant)
19033         {
19034           g_value_init (&paramv[n], G_TYPE_VARIANT);
19035           g_value_set_variant (&paramv[n], child);
19036           n++;
19037         }
19038       else
19039         g_dbus_gvariant_to_gvalue (child, &paramv[n++]);
19040       g_variant_unref (child);
19041     }
19042   signal_id = g_signal_lookup (info->signal_name, FOO_IGEN_TYPE_CHANGING_INTERFACE_V2);
19043   g_value_init (&return_value, G_TYPE_BOOLEAN);
19044   g_signal_emitv (paramv, signal_id, 0, &return_value);
19045   if (!g_value_get_boolean (&return_value))
19046     g_dbus_method_invocation_return_error (invocation, G_DBUS_ERROR, G_DBUS_ERROR_UNKNOWN_METHOD, "Method %s is not implemented on interface %s", method_name, interface_name);
19047   g_value_unset (&return_value);
19048   for (n = 0; n < num_params + num_extra; n++)
19049     g_value_unset (&paramv[n]);
19050   g_free (paramv);
19051 }
19052
19053 static GVariant *
19054 _foo_igen_changing_interface_v2_skeleton_handle_get_property (
19055   GDBusConnection *connection,
19056   const gchar *sender,
19057   const gchar *object_path,
19058   const gchar *interface_name,
19059   const gchar *property_name,
19060   GError **error,
19061   gpointer user_data)
19062 {
19063   FooiGenChangingInterfaceV2Skeleton *skeleton = FOO_IGEN_CHANGING_INTERFACE_V2_SKELETON (user_data);
19064   GValue value = G_VALUE_INIT;
19065   GParamSpec *pspec;
19066   _ExtendedGDBusPropertyInfo *info;
19067   GVariant *ret;
19068   ret = NULL;
19069   info = (_ExtendedGDBusPropertyInfo *) g_dbus_interface_info_lookup_property ((GDBusInterfaceInfo *) &_foo_igen_changing_interface_v2_interface_info, property_name);
19070   g_assert (info != NULL);
19071   pspec = g_object_class_find_property (G_OBJECT_GET_CLASS (skeleton), info->hyphen_name);
19072   if (pspec == NULL)
19073     {
19074       g_set_error (error, G_DBUS_ERROR, G_DBUS_ERROR_INVALID_ARGS, "No property with name %s", property_name);
19075     }
19076   else
19077     {
19078       g_value_init (&value, pspec->value_type);
19079       g_object_get_property (G_OBJECT (skeleton), info->hyphen_name, &value);
19080       ret = g_dbus_gvalue_to_gvariant (&value, G_VARIANT_TYPE (info->parent_struct.signature));
19081       g_value_unset (&value);
19082     }
19083   return ret;
19084 }
19085
19086 static gboolean
19087 _foo_igen_changing_interface_v2_skeleton_handle_set_property (
19088   GDBusConnection *connection,
19089   const gchar *sender,
19090   const gchar *object_path,
19091   const gchar *interface_name,
19092   const gchar *property_name,
19093   GVariant *variant,
19094   GError **error,
19095   gpointer user_data)
19096 {
19097   FooiGenChangingInterfaceV2Skeleton *skeleton = FOO_IGEN_CHANGING_INTERFACE_V2_SKELETON (user_data);
19098   GValue value = G_VALUE_INIT;
19099   GParamSpec *pspec;
19100   _ExtendedGDBusPropertyInfo *info;
19101   gboolean ret;
19102   ret = FALSE;
19103   info = (_ExtendedGDBusPropertyInfo *) g_dbus_interface_info_lookup_property ((GDBusInterfaceInfo *) &_foo_igen_changing_interface_v2_interface_info, property_name);
19104   g_assert (info != NULL);
19105   pspec = g_object_class_find_property (G_OBJECT_GET_CLASS (skeleton), info->hyphen_name);
19106   if (pspec == NULL)
19107     {
19108       g_set_error (error, G_DBUS_ERROR, G_DBUS_ERROR_INVALID_ARGS, "No property with name %s", property_name);
19109     }
19110   else
19111     {
19112       if (info->use_gvariant)
19113         g_value_set_variant (&value, variant);
19114       else
19115         g_dbus_gvariant_to_gvalue (variant, &value);
19116       g_object_set_property (G_OBJECT (skeleton), info->hyphen_name, &value);
19117       g_value_unset (&value);
19118       ret = TRUE;
19119     }
19120   return ret;
19121 }
19122
19123 static const GDBusInterfaceVTable _foo_igen_changing_interface_v2_skeleton_vtable =
19124 {
19125   _foo_igen_changing_interface_v2_skeleton_handle_method_call,
19126   _foo_igen_changing_interface_v2_skeleton_handle_get_property,
19127   _foo_igen_changing_interface_v2_skeleton_handle_set_property
19128 };
19129
19130 static GDBusInterfaceInfo *
19131 foo_igen_changing_interface_v2_skeleton_dbus_interface_get_info (GDBusInterfaceSkeleton *skeleton)
19132 {
19133   return foo_igen_changing_interface_v2_interface_info ();
19134 }
19135
19136 static GDBusInterfaceVTable *
19137 foo_igen_changing_interface_v2_skeleton_dbus_interface_get_vtable (GDBusInterfaceSkeleton *skeleton)
19138 {
19139   return (GDBusInterfaceVTable *) &_foo_igen_changing_interface_v2_skeleton_vtable;
19140 }
19141
19142 static GVariant *
19143 foo_igen_changing_interface_v2_skeleton_dbus_interface_get_properties (GDBusInterfaceSkeleton *_skeleton)
19144 {
19145   FooiGenChangingInterfaceV2Skeleton *skeleton = FOO_IGEN_CHANGING_INTERFACE_V2_SKELETON (_skeleton);
19146
19147   GVariantBuilder builder;
19148   guint n;
19149   g_variant_builder_init (&builder, G_VARIANT_TYPE ("a{sv}"));
19150   if (_foo_igen_changing_interface_v2_interface_info.parent_struct.properties == NULL)
19151     goto out;
19152   for (n = 0; _foo_igen_changing_interface_v2_interface_info.parent_struct.properties[n] != NULL; n++)
19153     {
19154       GDBusPropertyInfo *info = _foo_igen_changing_interface_v2_interface_info.parent_struct.properties[n];
19155       if (info->flags & G_DBUS_PROPERTY_INFO_FLAGS_READABLE)
19156         {
19157           GVariant *value;
19158           value = _foo_igen_changing_interface_v2_skeleton_handle_get_property (g_dbus_interface_skeleton_get_connection (G_DBUS_INTERFACE_SKELETON (skeleton)), NULL, g_dbus_interface_skeleton_get_object_path (G_DBUS_INTERFACE_SKELETON (skeleton)), "ChangingInterfaceV2", info->name, NULL, skeleton);
19159           if (value != NULL)
19160             {
19161               g_variant_take_ref (value);
19162               g_variant_builder_add (&builder, "{sv}", info->name, value);
19163               g_variant_unref (value);
19164             }
19165         }
19166     }
19167 out:
19168   return g_variant_builder_end (&builder);
19169 }
19170
19171 static void
19172 foo_igen_changing_interface_v2_skeleton_dbus_interface_flush (GDBusInterfaceSkeleton *_skeleton)
19173 {
19174 }
19175
19176 static void
19177 _foo_igen_changing_interface_v2_on_signal_new_signal_in2 (
19178     FooiGenChangingInterfaceV2 *object)
19179 {
19180   FooiGenChangingInterfaceV2Skeleton *skeleton = FOO_IGEN_CHANGING_INTERFACE_V2_SKELETON (object);
19181
19182   GList      *connections, *l;
19183   GVariant   *signal_variant;
19184   connections = g_dbus_interface_skeleton_get_connections (G_DBUS_INTERFACE_SKELETON (skeleton));
19185
19186   signal_variant = g_variant_ref_sink (g_variant_new ("()"));
19187   for (l = connections; l != NULL; l = l->next)
19188     {
19189       GDBusConnection *connection = l->data;
19190       g_dbus_connection_emit_signal (connection,
19191         NULL, g_dbus_interface_skeleton_get_object_path (G_DBUS_INTERFACE_SKELETON (skeleton)), "ChangingInterfaceV2", "NewSignalIn2",
19192         signal_variant, NULL);
19193     }
19194   g_variant_unref (signal_variant);
19195   g_list_free_full (connections, g_object_unref);
19196 }
19197
19198 static void
19199 _foo_igen_changing_interface_v2_on_signal_baz_signal (
19200     FooiGenChangingInterfaceV2 *object)
19201 {
19202   FooiGenChangingInterfaceV2Skeleton *skeleton = FOO_IGEN_CHANGING_INTERFACE_V2_SKELETON (object);
19203
19204   GList      *connections, *l;
19205   GVariant   *signal_variant;
19206   connections = g_dbus_interface_skeleton_get_connections (G_DBUS_INTERFACE_SKELETON (skeleton));
19207
19208   signal_variant = g_variant_ref_sink (g_variant_new ("()"));
19209   for (l = connections; l != NULL; l = l->next)
19210     {
19211       GDBusConnection *connection = l->data;
19212       g_dbus_connection_emit_signal (connection,
19213         NULL, g_dbus_interface_skeleton_get_object_path (G_DBUS_INTERFACE_SKELETON (skeleton)), "ChangingInterfaceV2", "BazSignal",
19214         signal_variant, NULL);
19215     }
19216   g_variant_unref (signal_variant);
19217   g_list_free_full (connections, g_object_unref);
19218 }
19219
19220 static void
19221 _foo_igen_changing_interface_v2_on_signal_bar_signal (
19222     FooiGenChangingInterfaceV2 *object)
19223 {
19224   FooiGenChangingInterfaceV2Skeleton *skeleton = FOO_IGEN_CHANGING_INTERFACE_V2_SKELETON (object);
19225
19226   GList      *connections, *l;
19227   GVariant   *signal_variant;
19228   connections = g_dbus_interface_skeleton_get_connections (G_DBUS_INTERFACE_SKELETON (skeleton));
19229
19230   signal_variant = g_variant_ref_sink (g_variant_new ("()"));
19231   for (l = connections; l != NULL; l = l->next)
19232     {
19233       GDBusConnection *connection = l->data;
19234       g_dbus_connection_emit_signal (connection,
19235         NULL, g_dbus_interface_skeleton_get_object_path (G_DBUS_INTERFACE_SKELETON (skeleton)), "ChangingInterfaceV2", "BarSignal",
19236         signal_variant, NULL);
19237     }
19238   g_variant_unref (signal_variant);
19239   g_list_free_full (connections, g_object_unref);
19240 }
19241
19242 static void
19243 _foo_igen_changing_interface_v2_on_signal_foo_signal (
19244     FooiGenChangingInterfaceV2 *object)
19245 {
19246   FooiGenChangingInterfaceV2Skeleton *skeleton = FOO_IGEN_CHANGING_INTERFACE_V2_SKELETON (object);
19247
19248   GList      *connections, *l;
19249   GVariant   *signal_variant;
19250   connections = g_dbus_interface_skeleton_get_connections (G_DBUS_INTERFACE_SKELETON (skeleton));
19251
19252   signal_variant = g_variant_ref_sink (g_variant_new ("()"));
19253   for (l = connections; l != NULL; l = l->next)
19254     {
19255       GDBusConnection *connection = l->data;
19256       g_dbus_connection_emit_signal (connection,
19257         NULL, g_dbus_interface_skeleton_get_object_path (G_DBUS_INTERFACE_SKELETON (skeleton)), "ChangingInterfaceV2", "FooSignal",
19258         signal_variant, NULL);
19259     }
19260   g_variant_unref (signal_variant);
19261   g_list_free_full (connections, g_object_unref);
19262 }
19263
19264 static void foo_igen_changing_interface_v2_skeleton_iface_init (FooiGenChangingInterfaceV2Iface *iface);
19265 G_DEFINE_TYPE_WITH_CODE (FooiGenChangingInterfaceV2Skeleton, foo_igen_changing_interface_v2_skeleton, G_TYPE_DBUS_INTERFACE_SKELETON,
19266                          G_IMPLEMENT_INTERFACE (FOO_IGEN_TYPE_CHANGING_INTERFACE_V2, foo_igen_changing_interface_v2_skeleton_iface_init));
19267
19268 static void
19269 foo_igen_changing_interface_v2_skeleton_finalize (GObject *object)
19270 {
19271   FooiGenChangingInterfaceV2Skeleton *skeleton = FOO_IGEN_CHANGING_INTERFACE_V2_SKELETON (object);
19272   g_list_free_full (skeleton->priv->changed_properties, (GDestroyNotify) _changed_property_free);
19273   if (skeleton->priv->changed_properties_idle_source != NULL)
19274     g_source_destroy (skeleton->priv->changed_properties_idle_source);
19275   g_main_context_unref (skeleton->priv->context);
19276   g_mutex_clear (&skeleton->priv->lock);
19277   G_OBJECT_CLASS (foo_igen_changing_interface_v2_skeleton_parent_class)->finalize (object);
19278 }
19279
19280 static void
19281 foo_igen_changing_interface_v2_skeleton_init (FooiGenChangingInterfaceV2Skeleton *skeleton)
19282 {
19283   skeleton->priv = G_TYPE_INSTANCE_GET_PRIVATE (skeleton, FOO_IGEN_TYPE_CHANGING_INTERFACE_V2_SKELETON, FooiGenChangingInterfaceV2SkeletonPrivate);
19284   g_mutex_init (&skeleton->priv->lock);
19285   skeleton->priv->context = g_main_context_ref_thread_default ();
19286 }
19287
19288 static void
19289 foo_igen_changing_interface_v2_skeleton_class_init (FooiGenChangingInterfaceV2SkeletonClass *klass)
19290 {
19291   GObjectClass *gobject_class;
19292   GDBusInterfaceSkeletonClass *skeleton_class;
19293
19294   g_type_class_add_private (klass, sizeof (FooiGenChangingInterfaceV2SkeletonPrivate));
19295
19296   gobject_class = G_OBJECT_CLASS (klass);
19297   gobject_class->finalize = foo_igen_changing_interface_v2_skeleton_finalize;
19298
19299   skeleton_class = G_DBUS_INTERFACE_SKELETON_CLASS (klass);
19300   skeleton_class->get_info = foo_igen_changing_interface_v2_skeleton_dbus_interface_get_info;
19301   skeleton_class->get_properties = foo_igen_changing_interface_v2_skeleton_dbus_interface_get_properties;
19302   skeleton_class->flush = foo_igen_changing_interface_v2_skeleton_dbus_interface_flush;
19303   skeleton_class->get_vtable = foo_igen_changing_interface_v2_skeleton_dbus_interface_get_vtable;
19304 }
19305
19306 static void
19307 foo_igen_changing_interface_v2_skeleton_iface_init (FooiGenChangingInterfaceV2Iface *iface)
19308 {
19309   iface->new_signal_in2 = _foo_igen_changing_interface_v2_on_signal_new_signal_in2;
19310   iface->baz_signal = _foo_igen_changing_interface_v2_on_signal_baz_signal;
19311   iface->bar_signal = _foo_igen_changing_interface_v2_on_signal_bar_signal;
19312   iface->foo_signal = _foo_igen_changing_interface_v2_on_signal_foo_signal;
19313 }
19314
19315 /**
19316  * foo_igen_changing_interface_v2_skeleton_new:
19317  *
19318  * Creates a skeleton object for the D-Bus interface <link linkend="gdbus-interface-ChangingInterfaceV2.top_of_page">ChangingInterfaceV2</link>.
19319  *
19320  * Returns: (transfer full) (type FooiGenChangingInterfaceV2Skeleton): The skeleton object.
19321  *
19322  * Since: 2.0
19323  */
19324 FooiGenChangingInterfaceV2 *
19325 foo_igen_changing_interface_v2_skeleton_new (void)
19326 {
19327   return FOO_IGEN_CHANGING_INTERFACE_V2 (g_object_new (FOO_IGEN_TYPE_CHANGING_INTERFACE_V2_SKELETON, NULL));
19328 }
19329
19330 /* ------------------------------------------------------------------------
19331  * Code for interface ChangingInterfaceV10
19332  * ------------------------------------------------------------------------
19333  */
19334
19335 /**
19336  * SECTION:FooiGenChangingInterfaceV10
19337  * @title: FooiGenChangingInterfaceV10
19338  * @short_description: Generated C code for the ChangingInterfaceV10 D-Bus interface
19339  *
19340  * This section contains code for working with the <link linkend="gdbus-interface-ChangingInterfaceV10.top_of_page">ChangingInterfaceV10</link> D-Bus interface in C.
19341  */
19342
19343 /* ---- Introspection data for ChangingInterfaceV10 ---- */
19344
19345 static const _ExtendedGDBusMethodInfo _foo_igen_changing_interface_v10_method_info_added_method_in10 =
19346 {
19347   {
19348     -1,
19349     "AddedMethodIn10",
19350     NULL,
19351     NULL,
19352     NULL
19353   },
19354   "handle-added-method-in10",
19355   FALSE
19356 };
19357
19358 static const _ExtendedGDBusMethodInfo _foo_igen_changing_interface_v10_method_info_new_method_in2 =
19359 {
19360   {
19361     -1,
19362     "NewMethodIn2",
19363     NULL,
19364     NULL,
19365     NULL
19366   },
19367   "handle-new-method-in2",
19368   FALSE
19369 };
19370
19371 static const _ExtendedGDBusMethodInfo _foo_igen_changing_interface_v10_method_info_baz_method =
19372 {
19373   {
19374     -1,
19375     "BazMethod",
19376     NULL,
19377     NULL,
19378     NULL
19379   },
19380   "handle-baz-method",
19381   FALSE
19382 };
19383
19384 static const _ExtendedGDBusMethodInfo _foo_igen_changing_interface_v10_method_info_bar_method =
19385 {
19386   {
19387     -1,
19388     "BarMethod",
19389     NULL,
19390     NULL,
19391     NULL
19392   },
19393   "handle-bar-method",
19394   FALSE
19395 };
19396
19397 static const _ExtendedGDBusMethodInfo _foo_igen_changing_interface_v10_method_info_foo_method =
19398 {
19399   {
19400     -1,
19401     "FooMethod",
19402     NULL,
19403     NULL,
19404     NULL
19405   },
19406   "handle-foo-method",
19407   FALSE
19408 };
19409
19410 static const _ExtendedGDBusMethodInfo * const _foo_igen_changing_interface_v10_method_info_pointers[] =
19411 {
19412   &_foo_igen_changing_interface_v10_method_info_added_method_in10,
19413   &_foo_igen_changing_interface_v10_method_info_new_method_in2,
19414   &_foo_igen_changing_interface_v10_method_info_baz_method,
19415   &_foo_igen_changing_interface_v10_method_info_bar_method,
19416   &_foo_igen_changing_interface_v10_method_info_foo_method,
19417   NULL
19418 };
19419
19420 static const _ExtendedGDBusSignalInfo _foo_igen_changing_interface_v10_signal_info_added_signal_in10 =
19421 {
19422   {
19423     -1,
19424     "AddedSignalIn10",
19425     NULL,
19426     NULL
19427   },
19428   "added-signal-in10"
19429 };
19430
19431 static const _ExtendedGDBusSignalInfo _foo_igen_changing_interface_v10_signal_info_new_signal_in2 =
19432 {
19433   {
19434     -1,
19435     "NewSignalIn2",
19436     NULL,
19437     NULL
19438   },
19439   "new-signal-in2"
19440 };
19441
19442 static const _ExtendedGDBusSignalInfo _foo_igen_changing_interface_v10_signal_info_baz_signal =
19443 {
19444   {
19445     -1,
19446     "BazSignal",
19447     NULL,
19448     NULL
19449   },
19450   "baz-signal"
19451 };
19452
19453 static const _ExtendedGDBusSignalInfo _foo_igen_changing_interface_v10_signal_info_bar_signal =
19454 {
19455   {
19456     -1,
19457     "BarSignal",
19458     NULL,
19459     NULL
19460   },
19461   "bar-signal"
19462 };
19463
19464 static const _ExtendedGDBusSignalInfo _foo_igen_changing_interface_v10_signal_info_foo_signal =
19465 {
19466   {
19467     -1,
19468     "FooSignal",
19469     NULL,
19470     NULL
19471   },
19472   "foo-signal"
19473 };
19474
19475 static const _ExtendedGDBusSignalInfo * const _foo_igen_changing_interface_v10_signal_info_pointers[] =
19476 {
19477   &_foo_igen_changing_interface_v10_signal_info_added_signal_in10,
19478   &_foo_igen_changing_interface_v10_signal_info_new_signal_in2,
19479   &_foo_igen_changing_interface_v10_signal_info_baz_signal,
19480   &_foo_igen_changing_interface_v10_signal_info_bar_signal,
19481   &_foo_igen_changing_interface_v10_signal_info_foo_signal,
19482   NULL
19483 };
19484
19485 static const _ExtendedGDBusInterfaceInfo _foo_igen_changing_interface_v10_interface_info =
19486 {
19487   {
19488     -1,
19489     "ChangingInterfaceV10",
19490     (GDBusMethodInfo **) &_foo_igen_changing_interface_v10_method_info_pointers,
19491     (GDBusSignalInfo **) &_foo_igen_changing_interface_v10_signal_info_pointers,
19492     NULL,
19493     NULL
19494   },
19495   "changing-interface-v10",
19496 };
19497
19498
19499 /**
19500  * foo_igen_changing_interface_v10_interface_info:
19501  *
19502  * Gets a machine-readable description of the <link linkend="gdbus-interface-ChangingInterfaceV10.top_of_page">ChangingInterfaceV10</link> D-Bus interface.
19503  *
19504  * Returns: (transfer none): A #GDBusInterfaceInfo. Do not free.
19505  *
19506  * Since: 10.0
19507  */
19508 GDBusInterfaceInfo *
19509 foo_igen_changing_interface_v10_interface_info (void)
19510 {
19511   return (GDBusInterfaceInfo *) &_foo_igen_changing_interface_v10_interface_info;
19512 }
19513
19514 /**
19515  * foo_igen_changing_interface_v10_override_properties:
19516  * @klass: The class structure for a #GObject<!-- -->-derived class.
19517  * @property_id_begin: The property id to assign to the first overridden property.
19518  *
19519  * Overrides all #GObject properties in the #FooiGenChangingInterfaceV10 interface for a concrete class.
19520  * The properties are overridden in the order they are defined.
19521  *
19522  * Returns: The last property id.
19523  *
19524  * Since: 10.0
19525  */
19526 guint
19527 foo_igen_changing_interface_v10_override_properties (GObjectClass *klass, guint property_id_begin)
19528 {
19529   return property_id_begin - 1;
19530 }
19531
19532
19533
19534 /**
19535  * FooiGenChangingInterfaceV10:
19536  *
19537  * Abstract interface type for the D-Bus interface <link linkend="gdbus-interface-ChangingInterfaceV10.top_of_page">ChangingInterfaceV10</link>.
19538  *
19539  * Since: 10.0
19540  */
19541
19542 /**
19543  * FooiGenChangingInterfaceV10Iface:
19544  * @parent_iface: The parent interface.
19545  * @handle_bar_method: Handler for the #FooiGenChangingInterfaceV10::handle-bar-method signal.
19546  * @handle_baz_method: Handler for the #FooiGenChangingInterfaceV10::handle-baz-method signal.
19547  * @handle_foo_method: Handler for the #FooiGenChangingInterfaceV10::handle-foo-method signal.
19548  * @bar_signal: Handler for the #FooiGenChangingInterfaceV10::bar-signal signal.
19549  * @baz_signal: Handler for the #FooiGenChangingInterfaceV10::baz-signal signal.
19550  * @foo_signal: Handler for the #FooiGenChangingInterfaceV10::foo-signal signal.
19551  * @handle_new_method_in2: Handler for the #FooiGenChangingInterfaceV10::handle-new-method-in2 signal.
19552  * @new_signal_in2: Handler for the #FooiGenChangingInterfaceV10::new-signal-in2 signal.
19553  * @handle_added_method_in10: Handler for the #FooiGenChangingInterfaceV10::handle-added-method-in10 signal.
19554  * @added_signal_in10: Handler for the #FooiGenChangingInterfaceV10::added-signal-in10 signal.
19555  *
19556  * Virtual table for the D-Bus interface <link linkend="gdbus-interface-ChangingInterfaceV10.top_of_page">ChangingInterfaceV10</link>.
19557  *
19558  * Since: 10.0
19559  */
19560
19561 static void
19562 foo_igen_changing_interface_v10_default_init (FooiGenChangingInterfaceV10Iface *iface)
19563 {
19564   /* GObject signals for incoming D-Bus method calls: */
19565   /**
19566    * FooiGenChangingInterfaceV10::handle-added-method-in10:
19567    * @object: A #FooiGenChangingInterfaceV10.
19568    * @invocation: A #GDBusMethodInvocation.
19569    *
19570    * Signal emitted when a remote caller is invoking the <link linkend="gdbus-method-ChangingInterfaceV10.AddedMethodIn10">AddedMethodIn10()</link> D-Bus method.
19571    *
19572    * If a signal handler returns %TRUE, it means the signal handler will handle the invocation (e.g. take a reference to @invocation and eventually call foo_igen_changing_interface_v10_complete_added_method_in10() or e.g. g_dbus_method_invocation_return_error() on it) and no order signal handlers will run. If no signal handler handles the invocation, the %G_DBUS_ERROR_UNKNOWN_METHOD error is returned.
19573    *
19574    * Returns: %TRUE if the invocation was handled, %FALSE to let other signal handlers run.
19575    *
19576    * Since: 10.0
19577    */
19578   g_signal_new ("handle-added-method-in10",
19579     G_TYPE_FROM_INTERFACE (iface),
19580     G_SIGNAL_RUN_LAST,
19581     G_STRUCT_OFFSET (FooiGenChangingInterfaceV10Iface, handle_added_method_in10),
19582     g_signal_accumulator_true_handled,
19583     NULL,
19584     g_cclosure_marshal_generic,
19585     G_TYPE_BOOLEAN,
19586     1,
19587     G_TYPE_DBUS_METHOD_INVOCATION);
19588
19589   /**
19590    * FooiGenChangingInterfaceV10::handle-new-method-in2:
19591    * @object: A #FooiGenChangingInterfaceV10.
19592    * @invocation: A #GDBusMethodInvocation.
19593    *
19594    * Signal emitted when a remote caller is invoking the <link linkend="gdbus-method-ChangingInterfaceV10.NewMethodIn2">NewMethodIn2()</link> D-Bus method.
19595    *
19596    * If a signal handler returns %TRUE, it means the signal handler will handle the invocation (e.g. take a reference to @invocation and eventually call foo_igen_changing_interface_v10_complete_new_method_in2() or e.g. g_dbus_method_invocation_return_error() on it) and no order signal handlers will run. If no signal handler handles the invocation, the %G_DBUS_ERROR_UNKNOWN_METHOD error is returned.
19597    *
19598    * Returns: %TRUE if the invocation was handled, %FALSE to let other signal handlers run.
19599    *
19600    * Since: 2.0
19601    */
19602   g_signal_new ("handle-new-method-in2",
19603     G_TYPE_FROM_INTERFACE (iface),
19604     G_SIGNAL_RUN_LAST,
19605     G_STRUCT_OFFSET (FooiGenChangingInterfaceV10Iface, handle_new_method_in2),
19606     g_signal_accumulator_true_handled,
19607     NULL,
19608     g_cclosure_marshal_generic,
19609     G_TYPE_BOOLEAN,
19610     1,
19611     G_TYPE_DBUS_METHOD_INVOCATION);
19612
19613   /**
19614    * FooiGenChangingInterfaceV10::handle-baz-method:
19615    * @object: A #FooiGenChangingInterfaceV10.
19616    * @invocation: A #GDBusMethodInvocation.
19617    *
19618    * Signal emitted when a remote caller is invoking the <link linkend="gdbus-method-ChangingInterfaceV10.BazMethod">BazMethod()</link> D-Bus method.
19619    *
19620    * If a signal handler returns %TRUE, it means the signal handler will handle the invocation (e.g. take a reference to @invocation and eventually call foo_igen_changing_interface_v10_complete_baz_method() or e.g. g_dbus_method_invocation_return_error() on it) and no order signal handlers will run. If no signal handler handles the invocation, the %G_DBUS_ERROR_UNKNOWN_METHOD error is returned.
19621    *
19622    * Returns: %TRUE if the invocation was handled, %FALSE to let other signal handlers run.
19623    */
19624   g_signal_new ("handle-baz-method",
19625     G_TYPE_FROM_INTERFACE (iface),
19626     G_SIGNAL_RUN_LAST,
19627     G_STRUCT_OFFSET (FooiGenChangingInterfaceV10Iface, handle_baz_method),
19628     g_signal_accumulator_true_handled,
19629     NULL,
19630     g_cclosure_marshal_generic,
19631     G_TYPE_BOOLEAN,
19632     1,
19633     G_TYPE_DBUS_METHOD_INVOCATION);
19634
19635   /**
19636    * FooiGenChangingInterfaceV10::handle-bar-method:
19637    * @object: A #FooiGenChangingInterfaceV10.
19638    * @invocation: A #GDBusMethodInvocation.
19639    *
19640    * Signal emitted when a remote caller is invoking the <link linkend="gdbus-method-ChangingInterfaceV10.BarMethod">BarMethod()</link> D-Bus method.
19641    *
19642    * If a signal handler returns %TRUE, it means the signal handler will handle the invocation (e.g. take a reference to @invocation and eventually call foo_igen_changing_interface_v10_complete_bar_method() or e.g. g_dbus_method_invocation_return_error() on it) and no order signal handlers will run. If no signal handler handles the invocation, the %G_DBUS_ERROR_UNKNOWN_METHOD error is returned.
19643    *
19644    * Returns: %TRUE if the invocation was handled, %FALSE to let other signal handlers run.
19645    */
19646   g_signal_new ("handle-bar-method",
19647     G_TYPE_FROM_INTERFACE (iface),
19648     G_SIGNAL_RUN_LAST,
19649     G_STRUCT_OFFSET (FooiGenChangingInterfaceV10Iface, handle_bar_method),
19650     g_signal_accumulator_true_handled,
19651     NULL,
19652     g_cclosure_marshal_generic,
19653     G_TYPE_BOOLEAN,
19654     1,
19655     G_TYPE_DBUS_METHOD_INVOCATION);
19656
19657   /**
19658    * FooiGenChangingInterfaceV10::handle-foo-method:
19659    * @object: A #FooiGenChangingInterfaceV10.
19660    * @invocation: A #GDBusMethodInvocation.
19661    *
19662    * Signal emitted when a remote caller is invoking the <link linkend="gdbus-method-ChangingInterfaceV10.FooMethod">FooMethod()</link> D-Bus method.
19663    *
19664    * If a signal handler returns %TRUE, it means the signal handler will handle the invocation (e.g. take a reference to @invocation and eventually call foo_igen_changing_interface_v10_complete_foo_method() or e.g. g_dbus_method_invocation_return_error() on it) and no order signal handlers will run. If no signal handler handles the invocation, the %G_DBUS_ERROR_UNKNOWN_METHOD error is returned.
19665    *
19666    * Returns: %TRUE if the invocation was handled, %FALSE to let other signal handlers run.
19667    */
19668   g_signal_new ("handle-foo-method",
19669     G_TYPE_FROM_INTERFACE (iface),
19670     G_SIGNAL_RUN_LAST,
19671     G_STRUCT_OFFSET (FooiGenChangingInterfaceV10Iface, handle_foo_method),
19672     g_signal_accumulator_true_handled,
19673     NULL,
19674     g_cclosure_marshal_generic,
19675     G_TYPE_BOOLEAN,
19676     1,
19677     G_TYPE_DBUS_METHOD_INVOCATION);
19678
19679   /* GObject signals for received D-Bus signals: */
19680   /**
19681    * FooiGenChangingInterfaceV10::added-signal-in10:
19682    * @object: A #FooiGenChangingInterfaceV10.
19683    *
19684    * On the client-side, this signal is emitted whenever the D-Bus signal <link linkend="gdbus-signal-ChangingInterfaceV10.AddedSignalIn10">"AddedSignalIn10"</link> is received.
19685    *
19686    * On the service-side, this signal can be used with e.g. g_signal_emit_by_name() to make the object emit the D-Bus signal.
19687    *
19688    * Since: 10.0
19689    */
19690   g_signal_new ("added-signal-in10",
19691     G_TYPE_FROM_INTERFACE (iface),
19692     G_SIGNAL_RUN_LAST,
19693     G_STRUCT_OFFSET (FooiGenChangingInterfaceV10Iface, added_signal_in10),
19694     NULL,
19695     NULL,
19696     g_cclosure_marshal_generic,
19697     G_TYPE_NONE,
19698     0);
19699
19700   /**
19701    * FooiGenChangingInterfaceV10::new-signal-in2:
19702    * @object: A #FooiGenChangingInterfaceV10.
19703    *
19704    * On the client-side, this signal is emitted whenever the D-Bus signal <link linkend="gdbus-signal-ChangingInterfaceV10.NewSignalIn2">"NewSignalIn2"</link> is received.
19705    *
19706    * On the service-side, this signal can be used with e.g. g_signal_emit_by_name() to make the object emit the D-Bus signal.
19707    *
19708    * Since: 2.0
19709    */
19710   g_signal_new ("new-signal-in2",
19711     G_TYPE_FROM_INTERFACE (iface),
19712     G_SIGNAL_RUN_LAST,
19713     G_STRUCT_OFFSET (FooiGenChangingInterfaceV10Iface, new_signal_in2),
19714     NULL,
19715     NULL,
19716     g_cclosure_marshal_generic,
19717     G_TYPE_NONE,
19718     0);
19719
19720   /**
19721    * FooiGenChangingInterfaceV10::baz-signal:
19722    * @object: A #FooiGenChangingInterfaceV10.
19723    *
19724    * On the client-side, this signal is emitted whenever the D-Bus signal <link linkend="gdbus-signal-ChangingInterfaceV10.BazSignal">"BazSignal"</link> is received.
19725    *
19726    * On the service-side, this signal can be used with e.g. g_signal_emit_by_name() to make the object emit the D-Bus signal.
19727    */
19728   g_signal_new ("baz-signal",
19729     G_TYPE_FROM_INTERFACE (iface),
19730     G_SIGNAL_RUN_LAST,
19731     G_STRUCT_OFFSET (FooiGenChangingInterfaceV10Iface, baz_signal),
19732     NULL,
19733     NULL,
19734     g_cclosure_marshal_generic,
19735     G_TYPE_NONE,
19736     0);
19737
19738   /**
19739    * FooiGenChangingInterfaceV10::bar-signal:
19740    * @object: A #FooiGenChangingInterfaceV10.
19741    *
19742    * On the client-side, this signal is emitted whenever the D-Bus signal <link linkend="gdbus-signal-ChangingInterfaceV10.BarSignal">"BarSignal"</link> is received.
19743    *
19744    * On the service-side, this signal can be used with e.g. g_signal_emit_by_name() to make the object emit the D-Bus signal.
19745    */
19746   g_signal_new ("bar-signal",
19747     G_TYPE_FROM_INTERFACE (iface),
19748     G_SIGNAL_RUN_LAST,
19749     G_STRUCT_OFFSET (FooiGenChangingInterfaceV10Iface, bar_signal),
19750     NULL,
19751     NULL,
19752     g_cclosure_marshal_generic,
19753     G_TYPE_NONE,
19754     0);
19755
19756   /**
19757    * FooiGenChangingInterfaceV10::foo-signal:
19758    * @object: A #FooiGenChangingInterfaceV10.
19759    *
19760    * On the client-side, this signal is emitted whenever the D-Bus signal <link linkend="gdbus-signal-ChangingInterfaceV10.FooSignal">"FooSignal"</link> is received.
19761    *
19762    * On the service-side, this signal can be used with e.g. g_signal_emit_by_name() to make the object emit the D-Bus signal.
19763    */
19764   g_signal_new ("foo-signal",
19765     G_TYPE_FROM_INTERFACE (iface),
19766     G_SIGNAL_RUN_LAST,
19767     G_STRUCT_OFFSET (FooiGenChangingInterfaceV10Iface, foo_signal),
19768     NULL,
19769     NULL,
19770     g_cclosure_marshal_generic,
19771     G_TYPE_NONE,
19772     0);
19773
19774 }
19775
19776 typedef FooiGenChangingInterfaceV10Iface FooiGenChangingInterfaceV10Interface;
19777 G_DEFINE_INTERFACE (FooiGenChangingInterfaceV10, foo_igen_changing_interface_v10, G_TYPE_OBJECT);
19778
19779 /**
19780  * foo_igen_changing_interface_v10_emit_added_signal_in10:
19781  * @object: A #FooiGenChangingInterfaceV10.
19782  *
19783  * Emits the <link linkend="gdbus-signal-ChangingInterfaceV10.AddedSignalIn10">"AddedSignalIn10"</link> D-Bus signal.
19784  *
19785  * Since: 10.0
19786  */
19787 void
19788 foo_igen_changing_interface_v10_emit_added_signal_in10 (
19789     FooiGenChangingInterfaceV10 *object)
19790 {
19791   g_signal_emit_by_name (object, "added-signal-in10");
19792 }
19793
19794 /**
19795  * foo_igen_changing_interface_v10_emit_new_signal_in2:
19796  * @object: A #FooiGenChangingInterfaceV10.
19797  *
19798  * Emits the <link linkend="gdbus-signal-ChangingInterfaceV10.NewSignalIn2">"NewSignalIn2"</link> D-Bus signal.
19799  *
19800  * Since: 2.0
19801  */
19802 void
19803 foo_igen_changing_interface_v10_emit_new_signal_in2 (
19804     FooiGenChangingInterfaceV10 *object)
19805 {
19806   g_signal_emit_by_name (object, "new-signal-in2");
19807 }
19808
19809 /**
19810  * foo_igen_changing_interface_v10_emit_baz_signal:
19811  * @object: A #FooiGenChangingInterfaceV10.
19812  *
19813  * Emits the <link linkend="gdbus-signal-ChangingInterfaceV10.BazSignal">"BazSignal"</link> D-Bus signal.
19814  */
19815 void
19816 foo_igen_changing_interface_v10_emit_baz_signal (
19817     FooiGenChangingInterfaceV10 *object)
19818 {
19819   g_signal_emit_by_name (object, "baz-signal");
19820 }
19821
19822 /**
19823  * foo_igen_changing_interface_v10_emit_bar_signal:
19824  * @object: A #FooiGenChangingInterfaceV10.
19825  *
19826  * Emits the <link linkend="gdbus-signal-ChangingInterfaceV10.BarSignal">"BarSignal"</link> D-Bus signal.
19827  */
19828 void
19829 foo_igen_changing_interface_v10_emit_bar_signal (
19830     FooiGenChangingInterfaceV10 *object)
19831 {
19832   g_signal_emit_by_name (object, "bar-signal");
19833 }
19834
19835 /**
19836  * foo_igen_changing_interface_v10_emit_foo_signal:
19837  * @object: A #FooiGenChangingInterfaceV10.
19838  *
19839  * Emits the <link linkend="gdbus-signal-ChangingInterfaceV10.FooSignal">"FooSignal"</link> D-Bus signal.
19840  */
19841 void
19842 foo_igen_changing_interface_v10_emit_foo_signal (
19843     FooiGenChangingInterfaceV10 *object)
19844 {
19845   g_signal_emit_by_name (object, "foo-signal");
19846 }
19847
19848 /**
19849  * foo_igen_changing_interface_v10_call_added_method_in10:
19850  * @proxy: A #FooiGenChangingInterfaceV10Proxy.
19851  * @cancellable: (allow-none): A #GCancellable or %NULL.
19852  * @callback: A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
19853  * @user_data: User data to pass to @callback.
19854  *
19855  * Asynchronously invokes the <link linkend="gdbus-method-ChangingInterfaceV10.AddedMethodIn10">AddedMethodIn10()</link> D-Bus method on @proxy.
19856  * When the operation is finished, @callback will be invoked in the <link linkend="g-main-context-push-thread-default">thread-default main loop</link> of the thread you are calling this method from.
19857  * You can then call foo_igen_changing_interface_v10_call_added_method_in10_finish() to get the result of the operation.
19858  *
19859  * See foo_igen_changing_interface_v10_call_added_method_in10_sync() for the synchronous, blocking version of this method.
19860  *
19861  * Since: 10.0
19862  */
19863 void
19864 foo_igen_changing_interface_v10_call_added_method_in10 (
19865     FooiGenChangingInterfaceV10 *proxy,
19866     GCancellable *cancellable,
19867     GAsyncReadyCallback callback,
19868     gpointer user_data)
19869 {
19870   g_dbus_proxy_call (G_DBUS_PROXY (proxy),
19871     "AddedMethodIn10",
19872     g_variant_new ("()"),
19873     G_DBUS_CALL_FLAGS_NONE,
19874     -1,
19875     cancellable,
19876     callback,
19877     user_data);
19878 }
19879
19880 /**
19881  * foo_igen_changing_interface_v10_call_added_method_in10_finish:
19882  * @proxy: A #FooiGenChangingInterfaceV10Proxy.
19883  * @res: The #GAsyncResult obtained from the #GAsyncReadyCallback passed to foo_igen_changing_interface_v10_call_added_method_in10().
19884  * @error: Return location for error or %NULL.
19885  *
19886  * Finishes an operation started with foo_igen_changing_interface_v10_call_added_method_in10().
19887  *
19888  * Returns: (skip): %TRUE if the call succeded, %FALSE if @error is set.
19889  *
19890  * Since: 10.0
19891  */
19892 gboolean
19893 foo_igen_changing_interface_v10_call_added_method_in10_finish (
19894     FooiGenChangingInterfaceV10 *proxy,
19895     GAsyncResult *res,
19896     GError **error)
19897 {
19898   GVariant *_ret;
19899   _ret = g_dbus_proxy_call_finish (G_DBUS_PROXY (proxy), res, error);
19900   if (_ret == NULL)
19901     goto _out;
19902   g_variant_get (_ret,
19903                  "()");
19904   g_variant_unref (_ret);
19905 _out:
19906   return _ret != NULL;
19907 }
19908
19909 /**
19910  * foo_igen_changing_interface_v10_call_added_method_in10_sync:
19911  * @proxy: A #FooiGenChangingInterfaceV10Proxy.
19912  * @cancellable: (allow-none): A #GCancellable or %NULL.
19913  * @error: Return location for error or %NULL.
19914  *
19915  * Synchronously invokes the <link linkend="gdbus-method-ChangingInterfaceV10.AddedMethodIn10">AddedMethodIn10()</link> D-Bus method on @proxy. The calling thread is blocked until a reply is received.
19916  *
19917  * See foo_igen_changing_interface_v10_call_added_method_in10() for the asynchronous version of this method.
19918  *
19919  * Returns: (skip): %TRUE if the call succeded, %FALSE if @error is set.
19920  *
19921  * Since: 10.0
19922  */
19923 gboolean
19924 foo_igen_changing_interface_v10_call_added_method_in10_sync (
19925     FooiGenChangingInterfaceV10 *proxy,
19926     GCancellable *cancellable,
19927     GError **error)
19928 {
19929   GVariant *_ret;
19930   _ret = g_dbus_proxy_call_sync (G_DBUS_PROXY (proxy),
19931     "AddedMethodIn10",
19932     g_variant_new ("()"),
19933     G_DBUS_CALL_FLAGS_NONE,
19934     -1,
19935     cancellable,
19936     error);
19937   if (_ret == NULL)
19938     goto _out;
19939   g_variant_get (_ret,
19940                  "()");
19941   g_variant_unref (_ret);
19942 _out:
19943   return _ret != NULL;
19944 }
19945
19946 /**
19947  * foo_igen_changing_interface_v10_call_new_method_in2:
19948  * @proxy: A #FooiGenChangingInterfaceV10Proxy.
19949  * @cancellable: (allow-none): A #GCancellable or %NULL.
19950  * @callback: A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
19951  * @user_data: User data to pass to @callback.
19952  *
19953  * Asynchronously invokes the <link linkend="gdbus-method-ChangingInterfaceV10.NewMethodIn2">NewMethodIn2()</link> D-Bus method on @proxy.
19954  * When the operation is finished, @callback will be invoked in the <link linkend="g-main-context-push-thread-default">thread-default main loop</link> of the thread you are calling this method from.
19955  * You can then call foo_igen_changing_interface_v10_call_new_method_in2_finish() to get the result of the operation.
19956  *
19957  * See foo_igen_changing_interface_v10_call_new_method_in2_sync() for the synchronous, blocking version of this method.
19958  *
19959  * Since: 2.0
19960  */
19961 void
19962 foo_igen_changing_interface_v10_call_new_method_in2 (
19963     FooiGenChangingInterfaceV10 *proxy,
19964     GCancellable *cancellable,
19965     GAsyncReadyCallback callback,
19966     gpointer user_data)
19967 {
19968   g_dbus_proxy_call (G_DBUS_PROXY (proxy),
19969     "NewMethodIn2",
19970     g_variant_new ("()"),
19971     G_DBUS_CALL_FLAGS_NONE,
19972     -1,
19973     cancellable,
19974     callback,
19975     user_data);
19976 }
19977
19978 /**
19979  * foo_igen_changing_interface_v10_call_new_method_in2_finish:
19980  * @proxy: A #FooiGenChangingInterfaceV10Proxy.
19981  * @res: The #GAsyncResult obtained from the #GAsyncReadyCallback passed to foo_igen_changing_interface_v10_call_new_method_in2().
19982  * @error: Return location for error or %NULL.
19983  *
19984  * Finishes an operation started with foo_igen_changing_interface_v10_call_new_method_in2().
19985  *
19986  * Returns: (skip): %TRUE if the call succeded, %FALSE if @error is set.
19987  *
19988  * Since: 2.0
19989  */
19990 gboolean
19991 foo_igen_changing_interface_v10_call_new_method_in2_finish (
19992     FooiGenChangingInterfaceV10 *proxy,
19993     GAsyncResult *res,
19994     GError **error)
19995 {
19996   GVariant *_ret;
19997   _ret = g_dbus_proxy_call_finish (G_DBUS_PROXY (proxy), res, error);
19998   if (_ret == NULL)
19999     goto _out;
20000   g_variant_get (_ret,
20001                  "()");
20002   g_variant_unref (_ret);
20003 _out:
20004   return _ret != NULL;
20005 }
20006
20007 /**
20008  * foo_igen_changing_interface_v10_call_new_method_in2_sync:
20009  * @proxy: A #FooiGenChangingInterfaceV10Proxy.
20010  * @cancellable: (allow-none): A #GCancellable or %NULL.
20011  * @error: Return location for error or %NULL.
20012  *
20013  * Synchronously invokes the <link linkend="gdbus-method-ChangingInterfaceV10.NewMethodIn2">NewMethodIn2()</link> D-Bus method on @proxy. The calling thread is blocked until a reply is received.
20014  *
20015  * See foo_igen_changing_interface_v10_call_new_method_in2() for the asynchronous version of this method.
20016  *
20017  * Returns: (skip): %TRUE if the call succeded, %FALSE if @error is set.
20018  *
20019  * Since: 2.0
20020  */
20021 gboolean
20022 foo_igen_changing_interface_v10_call_new_method_in2_sync (
20023     FooiGenChangingInterfaceV10 *proxy,
20024     GCancellable *cancellable,
20025     GError **error)
20026 {
20027   GVariant *_ret;
20028   _ret = g_dbus_proxy_call_sync (G_DBUS_PROXY (proxy),
20029     "NewMethodIn2",
20030     g_variant_new ("()"),
20031     G_DBUS_CALL_FLAGS_NONE,
20032     -1,
20033     cancellable,
20034     error);
20035   if (_ret == NULL)
20036     goto _out;
20037   g_variant_get (_ret,
20038                  "()");
20039   g_variant_unref (_ret);
20040 _out:
20041   return _ret != NULL;
20042 }
20043
20044 /**
20045  * foo_igen_changing_interface_v10_call_baz_method:
20046  * @proxy: A #FooiGenChangingInterfaceV10Proxy.
20047  * @cancellable: (allow-none): A #GCancellable or %NULL.
20048  * @callback: A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
20049  * @user_data: User data to pass to @callback.
20050  *
20051  * Asynchronously invokes the <link linkend="gdbus-method-ChangingInterfaceV10.BazMethod">BazMethod()</link> D-Bus method on @proxy.
20052  * When the operation is finished, @callback will be invoked in the <link linkend="g-main-context-push-thread-default">thread-default main loop</link> of the thread you are calling this method from.
20053  * You can then call foo_igen_changing_interface_v10_call_baz_method_finish() to get the result of the operation.
20054  *
20055  * See foo_igen_changing_interface_v10_call_baz_method_sync() for the synchronous, blocking version of this method.
20056  */
20057 void
20058 foo_igen_changing_interface_v10_call_baz_method (
20059     FooiGenChangingInterfaceV10 *proxy,
20060     GCancellable *cancellable,
20061     GAsyncReadyCallback callback,
20062     gpointer user_data)
20063 {
20064   g_dbus_proxy_call (G_DBUS_PROXY (proxy),
20065     "BazMethod",
20066     g_variant_new ("()"),
20067     G_DBUS_CALL_FLAGS_NONE,
20068     -1,
20069     cancellable,
20070     callback,
20071     user_data);
20072 }
20073
20074 /**
20075  * foo_igen_changing_interface_v10_call_baz_method_finish:
20076  * @proxy: A #FooiGenChangingInterfaceV10Proxy.
20077  * @res: The #GAsyncResult obtained from the #GAsyncReadyCallback passed to foo_igen_changing_interface_v10_call_baz_method().
20078  * @error: Return location for error or %NULL.
20079  *
20080  * Finishes an operation started with foo_igen_changing_interface_v10_call_baz_method().
20081  *
20082  * Returns: (skip): %TRUE if the call succeded, %FALSE if @error is set.
20083  */
20084 gboolean
20085 foo_igen_changing_interface_v10_call_baz_method_finish (
20086     FooiGenChangingInterfaceV10 *proxy,
20087     GAsyncResult *res,
20088     GError **error)
20089 {
20090   GVariant *_ret;
20091   _ret = g_dbus_proxy_call_finish (G_DBUS_PROXY (proxy), res, error);
20092   if (_ret == NULL)
20093     goto _out;
20094   g_variant_get (_ret,
20095                  "()");
20096   g_variant_unref (_ret);
20097 _out:
20098   return _ret != NULL;
20099 }
20100
20101 /**
20102  * foo_igen_changing_interface_v10_call_baz_method_sync:
20103  * @proxy: A #FooiGenChangingInterfaceV10Proxy.
20104  * @cancellable: (allow-none): A #GCancellable or %NULL.
20105  * @error: Return location for error or %NULL.
20106  *
20107  * Synchronously invokes the <link linkend="gdbus-method-ChangingInterfaceV10.BazMethod">BazMethod()</link> D-Bus method on @proxy. The calling thread is blocked until a reply is received.
20108  *
20109  * See foo_igen_changing_interface_v10_call_baz_method() for the asynchronous version of this method.
20110  *
20111  * Returns: (skip): %TRUE if the call succeded, %FALSE if @error is set.
20112  */
20113 gboolean
20114 foo_igen_changing_interface_v10_call_baz_method_sync (
20115     FooiGenChangingInterfaceV10 *proxy,
20116     GCancellable *cancellable,
20117     GError **error)
20118 {
20119   GVariant *_ret;
20120   _ret = g_dbus_proxy_call_sync (G_DBUS_PROXY (proxy),
20121     "BazMethod",
20122     g_variant_new ("()"),
20123     G_DBUS_CALL_FLAGS_NONE,
20124     -1,
20125     cancellable,
20126     error);
20127   if (_ret == NULL)
20128     goto _out;
20129   g_variant_get (_ret,
20130                  "()");
20131   g_variant_unref (_ret);
20132 _out:
20133   return _ret != NULL;
20134 }
20135
20136 /**
20137  * foo_igen_changing_interface_v10_call_bar_method:
20138  * @proxy: A #FooiGenChangingInterfaceV10Proxy.
20139  * @cancellable: (allow-none): A #GCancellable or %NULL.
20140  * @callback: A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
20141  * @user_data: User data to pass to @callback.
20142  *
20143  * Asynchronously invokes the <link linkend="gdbus-method-ChangingInterfaceV10.BarMethod">BarMethod()</link> D-Bus method on @proxy.
20144  * When the operation is finished, @callback will be invoked in the <link linkend="g-main-context-push-thread-default">thread-default main loop</link> of the thread you are calling this method from.
20145  * You can then call foo_igen_changing_interface_v10_call_bar_method_finish() to get the result of the operation.
20146  *
20147  * See foo_igen_changing_interface_v10_call_bar_method_sync() for the synchronous, blocking version of this method.
20148  */
20149 void
20150 foo_igen_changing_interface_v10_call_bar_method (
20151     FooiGenChangingInterfaceV10 *proxy,
20152     GCancellable *cancellable,
20153     GAsyncReadyCallback callback,
20154     gpointer user_data)
20155 {
20156   g_dbus_proxy_call (G_DBUS_PROXY (proxy),
20157     "BarMethod",
20158     g_variant_new ("()"),
20159     G_DBUS_CALL_FLAGS_NONE,
20160     -1,
20161     cancellable,
20162     callback,
20163     user_data);
20164 }
20165
20166 /**
20167  * foo_igen_changing_interface_v10_call_bar_method_finish:
20168  * @proxy: A #FooiGenChangingInterfaceV10Proxy.
20169  * @res: The #GAsyncResult obtained from the #GAsyncReadyCallback passed to foo_igen_changing_interface_v10_call_bar_method().
20170  * @error: Return location for error or %NULL.
20171  *
20172  * Finishes an operation started with foo_igen_changing_interface_v10_call_bar_method().
20173  *
20174  * Returns: (skip): %TRUE if the call succeded, %FALSE if @error is set.
20175  */
20176 gboolean
20177 foo_igen_changing_interface_v10_call_bar_method_finish (
20178     FooiGenChangingInterfaceV10 *proxy,
20179     GAsyncResult *res,
20180     GError **error)
20181 {
20182   GVariant *_ret;
20183   _ret = g_dbus_proxy_call_finish (G_DBUS_PROXY (proxy), res, error);
20184   if (_ret == NULL)
20185     goto _out;
20186   g_variant_get (_ret,
20187                  "()");
20188   g_variant_unref (_ret);
20189 _out:
20190   return _ret != NULL;
20191 }
20192
20193 /**
20194  * foo_igen_changing_interface_v10_call_bar_method_sync:
20195  * @proxy: A #FooiGenChangingInterfaceV10Proxy.
20196  * @cancellable: (allow-none): A #GCancellable or %NULL.
20197  * @error: Return location for error or %NULL.
20198  *
20199  * Synchronously invokes the <link linkend="gdbus-method-ChangingInterfaceV10.BarMethod">BarMethod()</link> D-Bus method on @proxy. The calling thread is blocked until a reply is received.
20200  *
20201  * See foo_igen_changing_interface_v10_call_bar_method() for the asynchronous version of this method.
20202  *
20203  * Returns: (skip): %TRUE if the call succeded, %FALSE if @error is set.
20204  */
20205 gboolean
20206 foo_igen_changing_interface_v10_call_bar_method_sync (
20207     FooiGenChangingInterfaceV10 *proxy,
20208     GCancellable *cancellable,
20209     GError **error)
20210 {
20211   GVariant *_ret;
20212   _ret = g_dbus_proxy_call_sync (G_DBUS_PROXY (proxy),
20213     "BarMethod",
20214     g_variant_new ("()"),
20215     G_DBUS_CALL_FLAGS_NONE,
20216     -1,
20217     cancellable,
20218     error);
20219   if (_ret == NULL)
20220     goto _out;
20221   g_variant_get (_ret,
20222                  "()");
20223   g_variant_unref (_ret);
20224 _out:
20225   return _ret != NULL;
20226 }
20227
20228 /**
20229  * foo_igen_changing_interface_v10_call_foo_method:
20230  * @proxy: A #FooiGenChangingInterfaceV10Proxy.
20231  * @cancellable: (allow-none): A #GCancellable or %NULL.
20232  * @callback: A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
20233  * @user_data: User data to pass to @callback.
20234  *
20235  * Asynchronously invokes the <link linkend="gdbus-method-ChangingInterfaceV10.FooMethod">FooMethod()</link> D-Bus method on @proxy.
20236  * When the operation is finished, @callback will be invoked in the <link linkend="g-main-context-push-thread-default">thread-default main loop</link> of the thread you are calling this method from.
20237  * You can then call foo_igen_changing_interface_v10_call_foo_method_finish() to get the result of the operation.
20238  *
20239  * See foo_igen_changing_interface_v10_call_foo_method_sync() for the synchronous, blocking version of this method.
20240  */
20241 void
20242 foo_igen_changing_interface_v10_call_foo_method (
20243     FooiGenChangingInterfaceV10 *proxy,
20244     GCancellable *cancellable,
20245     GAsyncReadyCallback callback,
20246     gpointer user_data)
20247 {
20248   g_dbus_proxy_call (G_DBUS_PROXY (proxy),
20249     "FooMethod",
20250     g_variant_new ("()"),
20251     G_DBUS_CALL_FLAGS_NONE,
20252     -1,
20253     cancellable,
20254     callback,
20255     user_data);
20256 }
20257
20258 /**
20259  * foo_igen_changing_interface_v10_call_foo_method_finish:
20260  * @proxy: A #FooiGenChangingInterfaceV10Proxy.
20261  * @res: The #GAsyncResult obtained from the #GAsyncReadyCallback passed to foo_igen_changing_interface_v10_call_foo_method().
20262  * @error: Return location for error or %NULL.
20263  *
20264  * Finishes an operation started with foo_igen_changing_interface_v10_call_foo_method().
20265  *
20266  * Returns: (skip): %TRUE if the call succeded, %FALSE if @error is set.
20267  */
20268 gboolean
20269 foo_igen_changing_interface_v10_call_foo_method_finish (
20270     FooiGenChangingInterfaceV10 *proxy,
20271     GAsyncResult *res,
20272     GError **error)
20273 {
20274   GVariant *_ret;
20275   _ret = g_dbus_proxy_call_finish (G_DBUS_PROXY (proxy), res, error);
20276   if (_ret == NULL)
20277     goto _out;
20278   g_variant_get (_ret,
20279                  "()");
20280   g_variant_unref (_ret);
20281 _out:
20282   return _ret != NULL;
20283 }
20284
20285 /**
20286  * foo_igen_changing_interface_v10_call_foo_method_sync:
20287  * @proxy: A #FooiGenChangingInterfaceV10Proxy.
20288  * @cancellable: (allow-none): A #GCancellable or %NULL.
20289  * @error: Return location for error or %NULL.
20290  *
20291  * Synchronously invokes the <link linkend="gdbus-method-ChangingInterfaceV10.FooMethod">FooMethod()</link> D-Bus method on @proxy. The calling thread is blocked until a reply is received.
20292  *
20293  * See foo_igen_changing_interface_v10_call_foo_method() for the asynchronous version of this method.
20294  *
20295  * Returns: (skip): %TRUE if the call succeded, %FALSE if @error is set.
20296  */
20297 gboolean
20298 foo_igen_changing_interface_v10_call_foo_method_sync (
20299     FooiGenChangingInterfaceV10 *proxy,
20300     GCancellable *cancellable,
20301     GError **error)
20302 {
20303   GVariant *_ret;
20304   _ret = g_dbus_proxy_call_sync (G_DBUS_PROXY (proxy),
20305     "FooMethod",
20306     g_variant_new ("()"),
20307     G_DBUS_CALL_FLAGS_NONE,
20308     -1,
20309     cancellable,
20310     error);
20311   if (_ret == NULL)
20312     goto _out;
20313   g_variant_get (_ret,
20314                  "()");
20315   g_variant_unref (_ret);
20316 _out:
20317   return _ret != NULL;
20318 }
20319
20320 /**
20321  * foo_igen_changing_interface_v10_complete_added_method_in10:
20322  * @object: A #FooiGenChangingInterfaceV10.
20323  * @invocation: (transfer full): A #GDBusMethodInvocation.
20324  *
20325  * Helper function used in service implementations to finish handling invocations of the <link linkend="gdbus-method-ChangingInterfaceV10.AddedMethodIn10">AddedMethodIn10()</link> D-Bus method. If you instead want to finish handling an invocation by returning an error, use g_dbus_method_invocation_return_error() or similar.
20326  *
20327  * This method will free @invocation, you cannot use it afterwards.
20328  *
20329  * Since: 10.0
20330  */
20331 void
20332 foo_igen_changing_interface_v10_complete_added_method_in10 (
20333     FooiGenChangingInterfaceV10 *object,
20334     GDBusMethodInvocation *invocation)
20335 {
20336   g_dbus_method_invocation_return_value (invocation,
20337     g_variant_new ("()"));
20338 }
20339
20340 /**
20341  * foo_igen_changing_interface_v10_complete_new_method_in2:
20342  * @object: A #FooiGenChangingInterfaceV10.
20343  * @invocation: (transfer full): A #GDBusMethodInvocation.
20344  *
20345  * Helper function used in service implementations to finish handling invocations of the <link linkend="gdbus-method-ChangingInterfaceV10.NewMethodIn2">NewMethodIn2()</link> D-Bus method. If you instead want to finish handling an invocation by returning an error, use g_dbus_method_invocation_return_error() or similar.
20346  *
20347  * This method will free @invocation, you cannot use it afterwards.
20348  *
20349  * Since: 2.0
20350  */
20351 void
20352 foo_igen_changing_interface_v10_complete_new_method_in2 (
20353     FooiGenChangingInterfaceV10 *object,
20354     GDBusMethodInvocation *invocation)
20355 {
20356   g_dbus_method_invocation_return_value (invocation,
20357     g_variant_new ("()"));
20358 }
20359
20360 /**
20361  * foo_igen_changing_interface_v10_complete_baz_method:
20362  * @object: A #FooiGenChangingInterfaceV10.
20363  * @invocation: (transfer full): A #GDBusMethodInvocation.
20364  *
20365  * Helper function used in service implementations to finish handling invocations of the <link linkend="gdbus-method-ChangingInterfaceV10.BazMethod">BazMethod()</link> D-Bus method. If you instead want to finish handling an invocation by returning an error, use g_dbus_method_invocation_return_error() or similar.
20366  *
20367  * This method will free @invocation, you cannot use it afterwards.
20368  */
20369 void
20370 foo_igen_changing_interface_v10_complete_baz_method (
20371     FooiGenChangingInterfaceV10 *object,
20372     GDBusMethodInvocation *invocation)
20373 {
20374   g_dbus_method_invocation_return_value (invocation,
20375     g_variant_new ("()"));
20376 }
20377
20378 /**
20379  * foo_igen_changing_interface_v10_complete_bar_method:
20380  * @object: A #FooiGenChangingInterfaceV10.
20381  * @invocation: (transfer full): A #GDBusMethodInvocation.
20382  *
20383  * Helper function used in service implementations to finish handling invocations of the <link linkend="gdbus-method-ChangingInterfaceV10.BarMethod">BarMethod()</link> D-Bus method. If you instead want to finish handling an invocation by returning an error, use g_dbus_method_invocation_return_error() or similar.
20384  *
20385  * This method will free @invocation, you cannot use it afterwards.
20386  */
20387 void
20388 foo_igen_changing_interface_v10_complete_bar_method (
20389     FooiGenChangingInterfaceV10 *object,
20390     GDBusMethodInvocation *invocation)
20391 {
20392   g_dbus_method_invocation_return_value (invocation,
20393     g_variant_new ("()"));
20394 }
20395
20396 /**
20397  * foo_igen_changing_interface_v10_complete_foo_method:
20398  * @object: A #FooiGenChangingInterfaceV10.
20399  * @invocation: (transfer full): A #GDBusMethodInvocation.
20400  *
20401  * Helper function used in service implementations to finish handling invocations of the <link linkend="gdbus-method-ChangingInterfaceV10.FooMethod">FooMethod()</link> D-Bus method. If you instead want to finish handling an invocation by returning an error, use g_dbus_method_invocation_return_error() or similar.
20402  *
20403  * This method will free @invocation, you cannot use it afterwards.
20404  */
20405 void
20406 foo_igen_changing_interface_v10_complete_foo_method (
20407     FooiGenChangingInterfaceV10 *object,
20408     GDBusMethodInvocation *invocation)
20409 {
20410   g_dbus_method_invocation_return_value (invocation,
20411     g_variant_new ("()"));
20412 }
20413
20414 /* ------------------------------------------------------------------------ */
20415
20416 /**
20417  * FooiGenChangingInterfaceV10Proxy:
20418  *
20419  * The #FooiGenChangingInterfaceV10Proxy structure contains only private data and should only be accessed using the provided API.
20420  *
20421  * Since: 10.0
20422  */
20423
20424 /**
20425  * FooiGenChangingInterfaceV10ProxyClass:
20426  * @parent_class: The parent class.
20427  *
20428  * Class structure for #FooiGenChangingInterfaceV10Proxy.
20429  *
20430  * Since: 10.0
20431  */
20432
20433 struct _FooiGenChangingInterfaceV10ProxyPrivate
20434 {
20435   GData *qdata;
20436 };
20437
20438 static void foo_igen_changing_interface_v10_proxy_iface_init (FooiGenChangingInterfaceV10Iface *iface);
20439
20440 G_DEFINE_TYPE_WITH_CODE (FooiGenChangingInterfaceV10Proxy, foo_igen_changing_interface_v10_proxy, G_TYPE_DBUS_PROXY,
20441                          G_IMPLEMENT_INTERFACE (FOO_IGEN_TYPE_CHANGING_INTERFACE_V10, foo_igen_changing_interface_v10_proxy_iface_init));
20442
20443 static void
20444 foo_igen_changing_interface_v10_proxy_finalize (GObject *object)
20445 {
20446   FooiGenChangingInterfaceV10Proxy *proxy = FOO_IGEN_CHANGING_INTERFACE_V10_PROXY (object);
20447   g_datalist_clear (&proxy->priv->qdata);
20448   G_OBJECT_CLASS (foo_igen_changing_interface_v10_proxy_parent_class)->finalize (object);
20449 }
20450
20451 static void
20452 foo_igen_changing_interface_v10_proxy_get_property (GObject      *object,
20453   guint         prop_id,
20454   GValue       *value,
20455   GParamSpec   *pspec)
20456 {
20457 }
20458
20459 static void
20460 foo_igen_changing_interface_v10_proxy_set_property (GObject      *object,
20461   guint         prop_id,
20462   const GValue *value,
20463   GParamSpec   *pspec)
20464 {
20465 }
20466
20467 static void
20468 foo_igen_changing_interface_v10_proxy_g_signal (GDBusProxy *proxy,
20469   const gchar *sender_name,
20470   const gchar *signal_name,
20471   GVariant *parameters)
20472 {
20473   _ExtendedGDBusSignalInfo *info;
20474   GVariantIter iter;
20475   GVariant *child;
20476   GValue *paramv;
20477   guint num_params;
20478   guint n;
20479   guint signal_id;
20480   info = (_ExtendedGDBusSignalInfo *) g_dbus_interface_info_lookup_signal ((GDBusInterfaceInfo *) &_foo_igen_changing_interface_v10_interface_info, signal_name);
20481   if (info == NULL)
20482     return;
20483   num_params = g_variant_n_children (parameters);
20484   paramv = g_new0 (GValue, num_params + 1);
20485   g_value_init (&paramv[0], FOO_IGEN_TYPE_CHANGING_INTERFACE_V10);
20486   g_value_set_object (&paramv[0], proxy);
20487   g_variant_iter_init (&iter, parameters);
20488   n = 1;
20489   while ((child = g_variant_iter_next_value (&iter)) != NULL)
20490     {
20491       _ExtendedGDBusArgInfo *arg_info = (_ExtendedGDBusArgInfo *) info->parent_struct.args[n - 1];
20492       if (arg_info->use_gvariant)
20493         {
20494           g_value_init (&paramv[n], G_TYPE_VARIANT);
20495           g_value_set_variant (&paramv[n], child);
20496           n++;
20497         }
20498       else
20499         g_dbus_gvariant_to_gvalue (child, &paramv[n++]);
20500       g_variant_unref (child);
20501     }
20502   signal_id = g_signal_lookup (info->signal_name, FOO_IGEN_TYPE_CHANGING_INTERFACE_V10);
20503   g_signal_emitv (paramv, signal_id, 0, NULL);
20504   for (n = 0; n < num_params + 1; n++)
20505     g_value_unset (&paramv[n]);
20506   g_free (paramv);
20507 }
20508
20509 static void
20510 foo_igen_changing_interface_v10_proxy_g_properties_changed (GDBusProxy *_proxy,
20511   GVariant *changed_properties,
20512   const gchar *const *invalidated_properties)
20513 {
20514   FooiGenChangingInterfaceV10Proxy *proxy = FOO_IGEN_CHANGING_INTERFACE_V10_PROXY (_proxy);
20515   guint n;
20516   const gchar *key;
20517   GVariantIter *iter;
20518   _ExtendedGDBusPropertyInfo *info;
20519   g_variant_get (changed_properties, "a{sv}", &iter);
20520   while (g_variant_iter_next (iter, "{&sv}", &key, NULL))
20521     {
20522       info = (_ExtendedGDBusPropertyInfo *) g_dbus_interface_info_lookup_property ((GDBusInterfaceInfo *) &_foo_igen_changing_interface_v10_interface_info, key);
20523       g_datalist_remove_data (&proxy->priv->qdata, key);
20524       if (info != NULL)
20525         g_object_notify (G_OBJECT (proxy), info->hyphen_name);
20526     }
20527   g_variant_iter_free (iter);
20528   for (n = 0; invalidated_properties[n] != NULL; n++)
20529     {
20530       info = (_ExtendedGDBusPropertyInfo *) g_dbus_interface_info_lookup_property ((GDBusInterfaceInfo *) &_foo_igen_changing_interface_v10_interface_info, invalidated_properties[n]);
20531       g_datalist_remove_data (&proxy->priv->qdata, invalidated_properties[n]);
20532       if (info != NULL)
20533         g_object_notify (G_OBJECT (proxy), info->hyphen_name);
20534     }
20535 }
20536
20537 static void
20538 foo_igen_changing_interface_v10_proxy_init (FooiGenChangingInterfaceV10Proxy *proxy)
20539 {
20540   proxy->priv = G_TYPE_INSTANCE_GET_PRIVATE (proxy, FOO_IGEN_TYPE_CHANGING_INTERFACE_V10_PROXY, FooiGenChangingInterfaceV10ProxyPrivate);
20541   g_dbus_proxy_set_interface_info (G_DBUS_PROXY (proxy), foo_igen_changing_interface_v10_interface_info ());
20542 }
20543
20544 static void
20545 foo_igen_changing_interface_v10_proxy_class_init (FooiGenChangingInterfaceV10ProxyClass *klass)
20546 {
20547   GObjectClass *gobject_class;
20548   GDBusProxyClass *proxy_class;
20549
20550   g_type_class_add_private (klass, sizeof (FooiGenChangingInterfaceV10ProxyPrivate));
20551
20552   gobject_class = G_OBJECT_CLASS (klass);
20553   gobject_class->finalize     = foo_igen_changing_interface_v10_proxy_finalize;
20554   gobject_class->get_property = foo_igen_changing_interface_v10_proxy_get_property;
20555   gobject_class->set_property = foo_igen_changing_interface_v10_proxy_set_property;
20556
20557   proxy_class = G_DBUS_PROXY_CLASS (klass);
20558   proxy_class->g_signal = foo_igen_changing_interface_v10_proxy_g_signal;
20559   proxy_class->g_properties_changed = foo_igen_changing_interface_v10_proxy_g_properties_changed;
20560
20561 }
20562
20563 static void
20564 foo_igen_changing_interface_v10_proxy_iface_init (FooiGenChangingInterfaceV10Iface *iface)
20565 {
20566 }
20567
20568 /**
20569  * foo_igen_changing_interface_v10_proxy_new:
20570  * @connection: A #GDBusConnection.
20571  * @flags: Flags from the #GDBusProxyFlags enumeration.
20572  * @name: (allow-none): A bus name (well-known or unique) or %NULL if @connection is not a message bus connection.
20573  * @object_path: An object path.
20574  * @cancellable: (allow-none): A #GCancellable or %NULL.
20575  * @callback: A #GAsyncReadyCallback to call when the request is satisfied.
20576  * @user_data: User data to pass to @callback.
20577  *
20578  * Asynchronously creates a proxy for the D-Bus interface <link linkend="gdbus-interface-ChangingInterfaceV10.top_of_page">ChangingInterfaceV10</link>. See g_dbus_proxy_new() for more details.
20579  *
20580  * When the operation is finished, @callback will be invoked in the <link linkend="g-main-context-push-thread-default">thread-default main loop</link> of the thread you are calling this method from.
20581  * You can then call foo_igen_changing_interface_v10_proxy_new_finish() to get the result of the operation.
20582  *
20583  * See foo_igen_changing_interface_v10_proxy_new_sync() for the synchronous, blocking version of this constructor.
20584  *
20585  * Since: 10.0
20586  */
20587 void
20588 foo_igen_changing_interface_v10_proxy_new (
20589     GDBusConnection     *connection,
20590     GDBusProxyFlags      flags,
20591     const gchar         *name,
20592     const gchar         *object_path,
20593     GCancellable        *cancellable,
20594     GAsyncReadyCallback  callback,
20595     gpointer             user_data)
20596 {
20597   g_async_initable_new_async (FOO_IGEN_TYPE_CHANGING_INTERFACE_V10_PROXY, G_PRIORITY_DEFAULT, cancellable, callback, user_data, "g-flags", flags, "g-name", name, "g-connection", connection, "g-object-path", object_path, "g-interface-name", "ChangingInterfaceV10", NULL);
20598 }
20599
20600 /**
20601  * foo_igen_changing_interface_v10_proxy_new_finish:
20602  * @res: The #GAsyncResult obtained from the #GAsyncReadyCallback passed to foo_igen_changing_interface_v10_proxy_new().
20603  * @error: Return location for error or %NULL
20604  *
20605  * Finishes an operation started with foo_igen_changing_interface_v10_proxy_new().
20606  *
20607  * Returns: (transfer full) (type FooiGenChangingInterfaceV10Proxy): The constructed proxy object or %NULL if @error is set.
20608  *
20609  * Since: 10.0
20610  */
20611 FooiGenChangingInterfaceV10 *
20612 foo_igen_changing_interface_v10_proxy_new_finish (
20613     GAsyncResult        *res,
20614     GError             **error)
20615 {
20616   GObject *ret;
20617   GObject *source_object;
20618   source_object = g_async_result_get_source_object (res);
20619   ret = g_async_initable_new_finish (G_ASYNC_INITABLE (source_object), res, error);
20620   g_object_unref (source_object);
20621   if (ret != NULL)
20622     return FOO_IGEN_CHANGING_INTERFACE_V10 (ret);
20623   else
20624     return NULL;
20625 }
20626
20627 /**
20628  * foo_igen_changing_interface_v10_proxy_new_sync:
20629  * @connection: A #GDBusConnection.
20630  * @flags: Flags from the #GDBusProxyFlags enumeration.
20631  * @name: (allow-none): A bus name (well-known or unique) or %NULL if @connection is not a message bus connection.
20632  * @object_path: An object path.
20633  * @cancellable: (allow-none): A #GCancellable or %NULL.
20634  * @error: Return location for error or %NULL
20635  *
20636  * Synchronously creates a proxy for the D-Bus interface <link linkend="gdbus-interface-ChangingInterfaceV10.top_of_page">ChangingInterfaceV10</link>. See g_dbus_proxy_new_sync() for more details.
20637  *
20638  * The calling thread is blocked until a reply is received.
20639  *
20640  * See foo_igen_changing_interface_v10_proxy_new() for the asynchronous version of this constructor.
20641  *
20642  * Returns: (transfer full) (type FooiGenChangingInterfaceV10Proxy): The constructed proxy object or %NULL if @error is set.
20643  *
20644  * Since: 10.0
20645  */
20646 FooiGenChangingInterfaceV10 *
20647 foo_igen_changing_interface_v10_proxy_new_sync (
20648     GDBusConnection     *connection,
20649     GDBusProxyFlags      flags,
20650     const gchar         *name,
20651     const gchar         *object_path,
20652     GCancellable        *cancellable,
20653     GError             **error)
20654 {
20655   GInitable *ret;
20656   ret = g_initable_new (FOO_IGEN_TYPE_CHANGING_INTERFACE_V10_PROXY, cancellable, error, "g-flags", flags, "g-name", name, "g-connection", connection, "g-object-path", object_path, "g-interface-name", "ChangingInterfaceV10", NULL);
20657   if (ret != NULL)
20658     return FOO_IGEN_CHANGING_INTERFACE_V10 (ret);
20659   else
20660     return NULL;
20661 }
20662
20663
20664 /**
20665  * foo_igen_changing_interface_v10_proxy_new_for_bus:
20666  * @bus_type: A #GBusType.
20667  * @flags: Flags from the #GDBusProxyFlags enumeration.
20668  * @name: A bus name (well-known or unique).
20669  * @object_path: An object path.
20670  * @cancellable: (allow-none): A #GCancellable or %NULL.
20671  * @callback: A #GAsyncReadyCallback to call when the request is satisfied.
20672  * @user_data: User data to pass to @callback.
20673  *
20674  * Like foo_igen_changing_interface_v10_proxy_new() but takes a #GBusType instead of a #GDBusConnection.
20675  *
20676  * When the operation is finished, @callback will be invoked in the <link linkend="g-main-context-push-thread-default">thread-default main loop</link> of the thread you are calling this method from.
20677  * You can then call foo_igen_changing_interface_v10_proxy_new_for_bus_finish() to get the result of the operation.
20678  *
20679  * See foo_igen_changing_interface_v10_proxy_new_for_bus_sync() for the synchronous, blocking version of this constructor.
20680  *
20681  * Since: 10.0
20682  */
20683 void
20684 foo_igen_changing_interface_v10_proxy_new_for_bus (
20685     GBusType             bus_type,
20686     GDBusProxyFlags      flags,
20687     const gchar         *name,
20688     const gchar         *object_path,
20689     GCancellable        *cancellable,
20690     GAsyncReadyCallback  callback,
20691     gpointer             user_data)
20692 {
20693   g_async_initable_new_async (FOO_IGEN_TYPE_CHANGING_INTERFACE_V10_PROXY, G_PRIORITY_DEFAULT, cancellable, callback, user_data, "g-flags", flags, "g-name", name, "g-bus-type", bus_type, "g-object-path", object_path, "g-interface-name", "ChangingInterfaceV10", NULL);
20694 }
20695
20696 /**
20697  * foo_igen_changing_interface_v10_proxy_new_for_bus_finish:
20698  * @res: The #GAsyncResult obtained from the #GAsyncReadyCallback passed to foo_igen_changing_interface_v10_proxy_new_for_bus().
20699  * @error: Return location for error or %NULL
20700  *
20701  * Finishes an operation started with foo_igen_changing_interface_v10_proxy_new_for_bus().
20702  *
20703  * Returns: (transfer full) (type FooiGenChangingInterfaceV10Proxy): The constructed proxy object or %NULL if @error is set.
20704  *
20705  * Since: 10.0
20706  */
20707 FooiGenChangingInterfaceV10 *
20708 foo_igen_changing_interface_v10_proxy_new_for_bus_finish (
20709     GAsyncResult        *res,
20710     GError             **error)
20711 {
20712   GObject *ret;
20713   GObject *source_object;
20714   source_object = g_async_result_get_source_object (res);
20715   ret = g_async_initable_new_finish (G_ASYNC_INITABLE (source_object), res, error);
20716   g_object_unref (source_object);
20717   if (ret != NULL)
20718     return FOO_IGEN_CHANGING_INTERFACE_V10 (ret);
20719   else
20720     return NULL;
20721 }
20722
20723 /**
20724  * foo_igen_changing_interface_v10_proxy_new_for_bus_sync:
20725  * @bus_type: A #GBusType.
20726  * @flags: Flags from the #GDBusProxyFlags enumeration.
20727  * @name: A bus name (well-known or unique).
20728  * @object_path: An object path.
20729  * @cancellable: (allow-none): A #GCancellable or %NULL.
20730  * @error: Return location for error or %NULL
20731  *
20732  * Like foo_igen_changing_interface_v10_proxy_new_sync() but takes a #GBusType instead of a #GDBusConnection.
20733  *
20734  * The calling thread is blocked until a reply is received.
20735  *
20736  * See foo_igen_changing_interface_v10_proxy_new_for_bus() for the asynchronous version of this constructor.
20737  *
20738  * Returns: (transfer full) (type FooiGenChangingInterfaceV10Proxy): The constructed proxy object or %NULL if @error is set.
20739  *
20740  * Since: 10.0
20741  */
20742 FooiGenChangingInterfaceV10 *
20743 foo_igen_changing_interface_v10_proxy_new_for_bus_sync (
20744     GBusType             bus_type,
20745     GDBusProxyFlags      flags,
20746     const gchar         *name,
20747     const gchar         *object_path,
20748     GCancellable        *cancellable,
20749     GError             **error)
20750 {
20751   GInitable *ret;
20752   ret = g_initable_new (FOO_IGEN_TYPE_CHANGING_INTERFACE_V10_PROXY, cancellable, error, "g-flags", flags, "g-name", name, "g-bus-type", bus_type, "g-object-path", object_path, "g-interface-name", "ChangingInterfaceV10", NULL);
20753   if (ret != NULL)
20754     return FOO_IGEN_CHANGING_INTERFACE_V10 (ret);
20755   else
20756     return NULL;
20757 }
20758
20759
20760 /* ------------------------------------------------------------------------ */
20761
20762 /**
20763  * FooiGenChangingInterfaceV10Skeleton:
20764  *
20765  * The #FooiGenChangingInterfaceV10Skeleton structure contains only private data and should only be accessed using the provided API.
20766  *
20767  * Since: 10.0
20768  */
20769
20770 /**
20771  * FooiGenChangingInterfaceV10SkeletonClass:
20772  * @parent_class: The parent class.
20773  *
20774  * Class structure for #FooiGenChangingInterfaceV10Skeleton.
20775  *
20776  * Since: 10.0
20777  */
20778
20779 struct _FooiGenChangingInterfaceV10SkeletonPrivate
20780 {
20781   GValue *properties;
20782   GList *changed_properties;
20783   GSource *changed_properties_idle_source;
20784   GMainContext *context;
20785   GMutex lock;
20786 };
20787
20788 static void
20789 _foo_igen_changing_interface_v10_skeleton_handle_method_call (
20790   GDBusConnection *connection,
20791   const gchar *sender,
20792   const gchar *object_path,
20793   const gchar *interface_name,
20794   const gchar *method_name,
20795   GVariant *parameters,
20796   GDBusMethodInvocation *invocation,
20797   gpointer user_data)
20798 {
20799   FooiGenChangingInterfaceV10Skeleton *skeleton = FOO_IGEN_CHANGING_INTERFACE_V10_SKELETON (user_data);
20800   _ExtendedGDBusMethodInfo *info;
20801   GVariantIter iter;
20802   GVariant *child;
20803   GValue *paramv;
20804   guint num_params;
20805   guint num_extra;
20806   guint n;
20807   guint signal_id;
20808   GValue return_value = G_VALUE_INIT;
20809   info = (_ExtendedGDBusMethodInfo *) g_dbus_method_invocation_get_method_info (invocation);
20810   g_assert (info != NULL);
20811   num_params = g_variant_n_children (parameters);
20812   num_extra = info->pass_fdlist ? 3 : 2;  paramv = g_new0 (GValue, num_params + num_extra);
20813   n = 0;
20814   g_value_init (&paramv[n], FOO_IGEN_TYPE_CHANGING_INTERFACE_V10);
20815   g_value_set_object (&paramv[n++], skeleton);
20816   g_value_init (&paramv[n], G_TYPE_DBUS_METHOD_INVOCATION);
20817   g_value_set_object (&paramv[n++], invocation);
20818   if (info->pass_fdlist)
20819     {
20820 #ifdef G_OS_UNIX
20821       g_value_init (&paramv[n], G_TYPE_UNIX_FD_LIST);
20822       g_value_set_object (&paramv[n++], g_dbus_message_get_unix_fd_list (g_dbus_method_invocation_get_message (invocation)));
20823 #else
20824       g_assert_not_reached ();
20825 #endif
20826     }
20827   g_variant_iter_init (&iter, parameters);
20828   while ((child = g_variant_iter_next_value (&iter)) != NULL)
20829     {
20830       _ExtendedGDBusArgInfo *arg_info = (_ExtendedGDBusArgInfo *) info->parent_struct.in_args[n - num_extra];
20831       if (arg_info->use_gvariant)
20832         {
20833           g_value_init (&paramv[n], G_TYPE_VARIANT);
20834           g_value_set_variant (&paramv[n], child);
20835           n++;
20836         }
20837       else
20838         g_dbus_gvariant_to_gvalue (child, &paramv[n++]);
20839       g_variant_unref (child);
20840     }
20841   signal_id = g_signal_lookup (info->signal_name, FOO_IGEN_TYPE_CHANGING_INTERFACE_V10);
20842   g_value_init (&return_value, G_TYPE_BOOLEAN);
20843   g_signal_emitv (paramv, signal_id, 0, &return_value);
20844   if (!g_value_get_boolean (&return_value))
20845     g_dbus_method_invocation_return_error (invocation, G_DBUS_ERROR, G_DBUS_ERROR_UNKNOWN_METHOD, "Method %s is not implemented on interface %s", method_name, interface_name);
20846   g_value_unset (&return_value);
20847   for (n = 0; n < num_params + num_extra; n++)
20848     g_value_unset (&paramv[n]);
20849   g_free (paramv);
20850 }
20851
20852 static GVariant *
20853 _foo_igen_changing_interface_v10_skeleton_handle_get_property (
20854   GDBusConnection *connection,
20855   const gchar *sender,
20856   const gchar *object_path,
20857   const gchar *interface_name,
20858   const gchar *property_name,
20859   GError **error,
20860   gpointer user_data)
20861 {
20862   FooiGenChangingInterfaceV10Skeleton *skeleton = FOO_IGEN_CHANGING_INTERFACE_V10_SKELETON (user_data);
20863   GValue value = G_VALUE_INIT;
20864   GParamSpec *pspec;
20865   _ExtendedGDBusPropertyInfo *info;
20866   GVariant *ret;
20867   ret = NULL;
20868   info = (_ExtendedGDBusPropertyInfo *) g_dbus_interface_info_lookup_property ((GDBusInterfaceInfo *) &_foo_igen_changing_interface_v10_interface_info, property_name);
20869   g_assert (info != NULL);
20870   pspec = g_object_class_find_property (G_OBJECT_GET_CLASS (skeleton), info->hyphen_name);
20871   if (pspec == NULL)
20872     {
20873       g_set_error (error, G_DBUS_ERROR, G_DBUS_ERROR_INVALID_ARGS, "No property with name %s", property_name);
20874     }
20875   else
20876     {
20877       g_value_init (&value, pspec->value_type);
20878       g_object_get_property (G_OBJECT (skeleton), info->hyphen_name, &value);
20879       ret = g_dbus_gvalue_to_gvariant (&value, G_VARIANT_TYPE (info->parent_struct.signature));
20880       g_value_unset (&value);
20881     }
20882   return ret;
20883 }
20884
20885 static gboolean
20886 _foo_igen_changing_interface_v10_skeleton_handle_set_property (
20887   GDBusConnection *connection,
20888   const gchar *sender,
20889   const gchar *object_path,
20890   const gchar *interface_name,
20891   const gchar *property_name,
20892   GVariant *variant,
20893   GError **error,
20894   gpointer user_data)
20895 {
20896   FooiGenChangingInterfaceV10Skeleton *skeleton = FOO_IGEN_CHANGING_INTERFACE_V10_SKELETON (user_data);
20897   GValue value = G_VALUE_INIT;
20898   GParamSpec *pspec;
20899   _ExtendedGDBusPropertyInfo *info;
20900   gboolean ret;
20901   ret = FALSE;
20902   info = (_ExtendedGDBusPropertyInfo *) g_dbus_interface_info_lookup_property ((GDBusInterfaceInfo *) &_foo_igen_changing_interface_v10_interface_info, property_name);
20903   g_assert (info != NULL);
20904   pspec = g_object_class_find_property (G_OBJECT_GET_CLASS (skeleton), info->hyphen_name);
20905   if (pspec == NULL)
20906     {
20907       g_set_error (error, G_DBUS_ERROR, G_DBUS_ERROR_INVALID_ARGS, "No property with name %s", property_name);
20908     }
20909   else
20910     {
20911       if (info->use_gvariant)
20912         g_value_set_variant (&value, variant);
20913       else
20914         g_dbus_gvariant_to_gvalue (variant, &value);
20915       g_object_set_property (G_OBJECT (skeleton), info->hyphen_name, &value);
20916       g_value_unset (&value);
20917       ret = TRUE;
20918     }
20919   return ret;
20920 }
20921
20922 static const GDBusInterfaceVTable _foo_igen_changing_interface_v10_skeleton_vtable =
20923 {
20924   _foo_igen_changing_interface_v10_skeleton_handle_method_call,
20925   _foo_igen_changing_interface_v10_skeleton_handle_get_property,
20926   _foo_igen_changing_interface_v10_skeleton_handle_set_property
20927 };
20928
20929 static GDBusInterfaceInfo *
20930 foo_igen_changing_interface_v10_skeleton_dbus_interface_get_info (GDBusInterfaceSkeleton *skeleton)
20931 {
20932   return foo_igen_changing_interface_v10_interface_info ();
20933 }
20934
20935 static GDBusInterfaceVTable *
20936 foo_igen_changing_interface_v10_skeleton_dbus_interface_get_vtable (GDBusInterfaceSkeleton *skeleton)
20937 {
20938   return (GDBusInterfaceVTable *) &_foo_igen_changing_interface_v10_skeleton_vtable;
20939 }
20940
20941 static GVariant *
20942 foo_igen_changing_interface_v10_skeleton_dbus_interface_get_properties (GDBusInterfaceSkeleton *_skeleton)
20943 {
20944   FooiGenChangingInterfaceV10Skeleton *skeleton = FOO_IGEN_CHANGING_INTERFACE_V10_SKELETON (_skeleton);
20945
20946   GVariantBuilder builder;
20947   guint n;
20948   g_variant_builder_init (&builder, G_VARIANT_TYPE ("a{sv}"));
20949   if (_foo_igen_changing_interface_v10_interface_info.parent_struct.properties == NULL)
20950     goto out;
20951   for (n = 0; _foo_igen_changing_interface_v10_interface_info.parent_struct.properties[n] != NULL; n++)
20952     {
20953       GDBusPropertyInfo *info = _foo_igen_changing_interface_v10_interface_info.parent_struct.properties[n];
20954       if (info->flags & G_DBUS_PROPERTY_INFO_FLAGS_READABLE)
20955         {
20956           GVariant *value;
20957           value = _foo_igen_changing_interface_v10_skeleton_handle_get_property (g_dbus_interface_skeleton_get_connection (G_DBUS_INTERFACE_SKELETON (skeleton)), NULL, g_dbus_interface_skeleton_get_object_path (G_DBUS_INTERFACE_SKELETON (skeleton)), "ChangingInterfaceV10", info->name, NULL, skeleton);
20958           if (value != NULL)
20959             {
20960               g_variant_take_ref (value);
20961               g_variant_builder_add (&builder, "{sv}", info->name, value);
20962               g_variant_unref (value);
20963             }
20964         }
20965     }
20966 out:
20967   return g_variant_builder_end (&builder);
20968 }
20969
20970 static void
20971 foo_igen_changing_interface_v10_skeleton_dbus_interface_flush (GDBusInterfaceSkeleton *_skeleton)
20972 {
20973 }
20974
20975 static void
20976 _foo_igen_changing_interface_v10_on_signal_added_signal_in10 (
20977     FooiGenChangingInterfaceV10 *object)
20978 {
20979   FooiGenChangingInterfaceV10Skeleton *skeleton = FOO_IGEN_CHANGING_INTERFACE_V10_SKELETON (object);
20980
20981   GList      *connections, *l;
20982   GVariant   *signal_variant;
20983   connections = g_dbus_interface_skeleton_get_connections (G_DBUS_INTERFACE_SKELETON (skeleton));
20984
20985   signal_variant = g_variant_ref_sink (g_variant_new ("()"));
20986   for (l = connections; l != NULL; l = l->next)
20987     {
20988       GDBusConnection *connection = l->data;
20989       g_dbus_connection_emit_signal (connection,
20990         NULL, g_dbus_interface_skeleton_get_object_path (G_DBUS_INTERFACE_SKELETON (skeleton)), "ChangingInterfaceV10", "AddedSignalIn10",
20991         signal_variant, NULL);
20992     }
20993   g_variant_unref (signal_variant);
20994   g_list_free_full (connections, g_object_unref);
20995 }
20996
20997 static void
20998 _foo_igen_changing_interface_v10_on_signal_new_signal_in2 (
20999     FooiGenChangingInterfaceV10 *object)
21000 {
21001   FooiGenChangingInterfaceV10Skeleton *skeleton = FOO_IGEN_CHANGING_INTERFACE_V10_SKELETON (object);
21002
21003   GList      *connections, *l;
21004   GVariant   *signal_variant;
21005   connections = g_dbus_interface_skeleton_get_connections (G_DBUS_INTERFACE_SKELETON (skeleton));
21006
21007   signal_variant = g_variant_ref_sink (g_variant_new ("()"));
21008   for (l = connections; l != NULL; l = l->next)
21009     {
21010       GDBusConnection *connection = l->data;
21011       g_dbus_connection_emit_signal (connection,
21012         NULL, g_dbus_interface_skeleton_get_object_path (G_DBUS_INTERFACE_SKELETON (skeleton)), "ChangingInterfaceV10", "NewSignalIn2",
21013         signal_variant, NULL);
21014     }
21015   g_variant_unref (signal_variant);
21016   g_list_free_full (connections, g_object_unref);
21017 }
21018
21019 static void
21020 _foo_igen_changing_interface_v10_on_signal_baz_signal (
21021     FooiGenChangingInterfaceV10 *object)
21022 {
21023   FooiGenChangingInterfaceV10Skeleton *skeleton = FOO_IGEN_CHANGING_INTERFACE_V10_SKELETON (object);
21024
21025   GList      *connections, *l;
21026   GVariant   *signal_variant;
21027   connections = g_dbus_interface_skeleton_get_connections (G_DBUS_INTERFACE_SKELETON (skeleton));
21028
21029   signal_variant = g_variant_ref_sink (g_variant_new ("()"));
21030   for (l = connections; l != NULL; l = l->next)
21031     {
21032       GDBusConnection *connection = l->data;
21033       g_dbus_connection_emit_signal (connection,
21034         NULL, g_dbus_interface_skeleton_get_object_path (G_DBUS_INTERFACE_SKELETON (skeleton)), "ChangingInterfaceV10", "BazSignal",
21035         signal_variant, NULL);
21036     }
21037   g_variant_unref (signal_variant);
21038   g_list_free_full (connections, g_object_unref);
21039 }
21040
21041 static void
21042 _foo_igen_changing_interface_v10_on_signal_bar_signal (
21043     FooiGenChangingInterfaceV10 *object)
21044 {
21045   FooiGenChangingInterfaceV10Skeleton *skeleton = FOO_IGEN_CHANGING_INTERFACE_V10_SKELETON (object);
21046
21047   GList      *connections, *l;
21048   GVariant   *signal_variant;
21049   connections = g_dbus_interface_skeleton_get_connections (G_DBUS_INTERFACE_SKELETON (skeleton));
21050
21051   signal_variant = g_variant_ref_sink (g_variant_new ("()"));
21052   for (l = connections; l != NULL; l = l->next)
21053     {
21054       GDBusConnection *connection = l->data;
21055       g_dbus_connection_emit_signal (connection,
21056         NULL, g_dbus_interface_skeleton_get_object_path (G_DBUS_INTERFACE_SKELETON (skeleton)), "ChangingInterfaceV10", "BarSignal",
21057         signal_variant, NULL);
21058     }
21059   g_variant_unref (signal_variant);
21060   g_list_free_full (connections, g_object_unref);
21061 }
21062
21063 static void
21064 _foo_igen_changing_interface_v10_on_signal_foo_signal (
21065     FooiGenChangingInterfaceV10 *object)
21066 {
21067   FooiGenChangingInterfaceV10Skeleton *skeleton = FOO_IGEN_CHANGING_INTERFACE_V10_SKELETON (object);
21068
21069   GList      *connections, *l;
21070   GVariant   *signal_variant;
21071   connections = g_dbus_interface_skeleton_get_connections (G_DBUS_INTERFACE_SKELETON (skeleton));
21072
21073   signal_variant = g_variant_ref_sink (g_variant_new ("()"));
21074   for (l = connections; l != NULL; l = l->next)
21075     {
21076       GDBusConnection *connection = l->data;
21077       g_dbus_connection_emit_signal (connection,
21078         NULL, g_dbus_interface_skeleton_get_object_path (G_DBUS_INTERFACE_SKELETON (skeleton)), "ChangingInterfaceV10", "FooSignal",
21079         signal_variant, NULL);
21080     }
21081   g_variant_unref (signal_variant);
21082   g_list_free_full (connections, g_object_unref);
21083 }
21084
21085 static void foo_igen_changing_interface_v10_skeleton_iface_init (FooiGenChangingInterfaceV10Iface *iface);
21086 G_DEFINE_TYPE_WITH_CODE (FooiGenChangingInterfaceV10Skeleton, foo_igen_changing_interface_v10_skeleton, G_TYPE_DBUS_INTERFACE_SKELETON,
21087                          G_IMPLEMENT_INTERFACE (FOO_IGEN_TYPE_CHANGING_INTERFACE_V10, foo_igen_changing_interface_v10_skeleton_iface_init));
21088
21089 static void
21090 foo_igen_changing_interface_v10_skeleton_finalize (GObject *object)
21091 {
21092   FooiGenChangingInterfaceV10Skeleton *skeleton = FOO_IGEN_CHANGING_INTERFACE_V10_SKELETON (object);
21093   g_list_free_full (skeleton->priv->changed_properties, (GDestroyNotify) _changed_property_free);
21094   if (skeleton->priv->changed_properties_idle_source != NULL)
21095     g_source_destroy (skeleton->priv->changed_properties_idle_source);
21096   g_main_context_unref (skeleton->priv->context);
21097   g_mutex_clear (&skeleton->priv->lock);
21098   G_OBJECT_CLASS (foo_igen_changing_interface_v10_skeleton_parent_class)->finalize (object);
21099 }
21100
21101 static void
21102 foo_igen_changing_interface_v10_skeleton_init (FooiGenChangingInterfaceV10Skeleton *skeleton)
21103 {
21104   skeleton->priv = G_TYPE_INSTANCE_GET_PRIVATE (skeleton, FOO_IGEN_TYPE_CHANGING_INTERFACE_V10_SKELETON, FooiGenChangingInterfaceV10SkeletonPrivate);
21105   g_mutex_init (&skeleton->priv->lock);
21106   skeleton->priv->context = g_main_context_ref_thread_default ();
21107 }
21108
21109 static void
21110 foo_igen_changing_interface_v10_skeleton_class_init (FooiGenChangingInterfaceV10SkeletonClass *klass)
21111 {
21112   GObjectClass *gobject_class;
21113   GDBusInterfaceSkeletonClass *skeleton_class;
21114
21115   g_type_class_add_private (klass, sizeof (FooiGenChangingInterfaceV10SkeletonPrivate));
21116
21117   gobject_class = G_OBJECT_CLASS (klass);
21118   gobject_class->finalize = foo_igen_changing_interface_v10_skeleton_finalize;
21119
21120   skeleton_class = G_DBUS_INTERFACE_SKELETON_CLASS (klass);
21121   skeleton_class->get_info = foo_igen_changing_interface_v10_skeleton_dbus_interface_get_info;
21122   skeleton_class->get_properties = foo_igen_changing_interface_v10_skeleton_dbus_interface_get_properties;
21123   skeleton_class->flush = foo_igen_changing_interface_v10_skeleton_dbus_interface_flush;
21124   skeleton_class->get_vtable = foo_igen_changing_interface_v10_skeleton_dbus_interface_get_vtable;
21125 }
21126
21127 static void
21128 foo_igen_changing_interface_v10_skeleton_iface_init (FooiGenChangingInterfaceV10Iface *iface)
21129 {
21130   iface->added_signal_in10 = _foo_igen_changing_interface_v10_on_signal_added_signal_in10;
21131   iface->new_signal_in2 = _foo_igen_changing_interface_v10_on_signal_new_signal_in2;
21132   iface->baz_signal = _foo_igen_changing_interface_v10_on_signal_baz_signal;
21133   iface->bar_signal = _foo_igen_changing_interface_v10_on_signal_bar_signal;
21134   iface->foo_signal = _foo_igen_changing_interface_v10_on_signal_foo_signal;
21135 }
21136
21137 /**
21138  * foo_igen_changing_interface_v10_skeleton_new:
21139  *
21140  * Creates a skeleton object for the D-Bus interface <link linkend="gdbus-interface-ChangingInterfaceV10.top_of_page">ChangingInterfaceV10</link>.
21141  *
21142  * Returns: (transfer full) (type FooiGenChangingInterfaceV10Skeleton): The skeleton object.
21143  *
21144  * Since: 10.0
21145  */
21146 FooiGenChangingInterfaceV10 *
21147 foo_igen_changing_interface_v10_skeleton_new (void)
21148 {
21149   return FOO_IGEN_CHANGING_INTERFACE_V10 (g_object_new (FOO_IGEN_TYPE_CHANGING_INTERFACE_V10_SKELETON, NULL));
21150 }
21151
21152 /* ------------------------------------------------------------------------
21153  * Code for interface TestUglyCaseInterface
21154  * ------------------------------------------------------------------------
21155  */
21156
21157 /**
21158  * SECTION:FooiGenTesTuglyCASEInterface
21159  * @title: FooiGenTesTuglyCASEInterface
21160  * @short_description: Generated C code for the TestUglyCaseInterface D-Bus interface
21161  *
21162  * This section contains code for working with the <link linkend="gdbus-interface-TestUglyCaseInterface.top_of_page">TestUglyCaseInterface</link> D-Bus interface in C.
21163  */
21164
21165 /* ---- Introspection data for TestUglyCaseInterface ---- */
21166
21167 static const _ExtendedGDBusMethodInfo _foo_igen_test_ugly_case_interface_method_info_get_iscsi_servers =
21168 {
21169   {
21170     -1,
21171     "GetiSCSIServers",
21172     NULL,
21173     NULL,
21174     NULL
21175   },
21176   "handle-get-iscsi-servers",
21177   FALSE
21178 };
21179
21180 static const _ExtendedGDBusMethodInfo * const _foo_igen_test_ugly_case_interface_method_info_pointers[] =
21181 {
21182   &_foo_igen_test_ugly_case_interface_method_info_get_iscsi_servers,
21183   NULL
21184 };
21185
21186 static const _ExtendedGDBusSignalInfo _foo_igen_test_ugly_case_interface_signal_info_servers_updated_now =
21187 {
21188   {
21189     -1,
21190     "serversUPDATEDNOW",
21191     NULL,
21192     NULL
21193   },
21194   "servers-updated-now"
21195 };
21196
21197 static const _ExtendedGDBusSignalInfo * const _foo_igen_test_ugly_case_interface_signal_info_pointers[] =
21198 {
21199   &_foo_igen_test_ugly_case_interface_signal_info_servers_updated_now,
21200   NULL
21201 };
21202
21203 static const _ExtendedGDBusPropertyInfo _foo_igen_test_ugly_case_interface_property_info_ugly_name =
21204 {
21205   {
21206     -1,
21207     "UGLYNAME",
21208     "i",
21209     G_DBUS_PROPERTY_INFO_FLAGS_READABLE | G_DBUS_PROPERTY_INFO_FLAGS_WRITABLE,
21210     NULL
21211   },
21212   "ugly-name",
21213   FALSE
21214 };
21215
21216 static const _ExtendedGDBusPropertyInfo * const _foo_igen_test_ugly_case_interface_property_info_pointers[] =
21217 {
21218   &_foo_igen_test_ugly_case_interface_property_info_ugly_name,
21219   NULL
21220 };
21221
21222 static const _ExtendedGDBusInterfaceInfo _foo_igen_test_ugly_case_interface_interface_info =
21223 {
21224   {
21225     -1,
21226     "TestUglyCaseInterface",
21227     (GDBusMethodInfo **) &_foo_igen_test_ugly_case_interface_method_info_pointers,
21228     (GDBusSignalInfo **) &_foo_igen_test_ugly_case_interface_signal_info_pointers,
21229     (GDBusPropertyInfo **) &_foo_igen_test_ugly_case_interface_property_info_pointers,
21230     NULL
21231   },
21232   "test-ugly-case-interface",
21233 };
21234
21235
21236 /**
21237  * foo_igen_test_ugly_case_interface_interface_info:
21238  *
21239  * Gets a machine-readable description of the <link linkend="gdbus-interface-TestUglyCaseInterface.top_of_page">TestUglyCaseInterface</link> D-Bus interface.
21240  *
21241  * Returns: (transfer none): A #GDBusInterfaceInfo. Do not free.
21242  */
21243 GDBusInterfaceInfo *
21244 foo_igen_test_ugly_case_interface_interface_info (void)
21245 {
21246   return (GDBusInterfaceInfo *) &_foo_igen_test_ugly_case_interface_interface_info;
21247 }
21248
21249 /**
21250  * foo_igen_test_ugly_case_interface_override_properties:
21251  * @klass: The class structure for a #GObject<!-- -->-derived class.
21252  * @property_id_begin: The property id to assign to the first overridden property.
21253  *
21254  * Overrides all #GObject properties in the #FooiGenTesTuglyCASEInterface interface for a concrete class.
21255  * The properties are overridden in the order they are defined.
21256  *
21257  * Returns: The last property id.
21258  */
21259 guint
21260 foo_igen_test_ugly_case_interface_override_properties (GObjectClass *klass, guint property_id_begin)
21261 {
21262   g_object_class_override_property (klass, property_id_begin++, "ugly-name");
21263   return property_id_begin - 1;
21264 }
21265
21266
21267
21268 /**
21269  * FooiGenTesTuglyCASEInterface:
21270  *
21271  * Abstract interface type for the D-Bus interface <link linkend="gdbus-interface-TestUglyCaseInterface.top_of_page">TestUglyCaseInterface</link>.
21272  */
21273
21274 /**
21275  * FooiGenTesTuglyCASEInterfaceIface:
21276  * @parent_iface: The parent interface.
21277  * @handle_get_iscsi_servers: Handler for the #FooiGenTesTuglyCASEInterface::handle-get-iscsi-servers signal.
21278  * @get_ugly_name: Getter for the #FooiGenTesTuglyCASEInterface:ugly-name property.
21279  * @servers_updated_now: Handler for the #FooiGenTesTuglyCASEInterface::servers-updated-now signal.
21280  *
21281  * Virtual table for the D-Bus interface <link linkend="gdbus-interface-TestUglyCaseInterface.top_of_page">TestUglyCaseInterface</link>.
21282  */
21283
21284 static void
21285 foo_igen_test_ugly_case_interface_default_init (FooiGenTesTuglyCASEInterfaceIface *iface)
21286 {
21287   /* GObject signals for incoming D-Bus method calls: */
21288   /**
21289    * FooiGenTesTuglyCASEInterface::handle-get-iscsi-servers:
21290    * @object: A #FooiGenTesTuglyCASEInterface.
21291    * @invocation: A #GDBusMethodInvocation.
21292    *
21293    * Signal emitted when a remote caller is invoking the <link linkend="gdbus-method-TestUglyCaseInterface.GetiSCSIServers">GetiSCSIServers()</link> D-Bus method.
21294    *
21295    * If a signal handler returns %TRUE, it means the signal handler will handle the invocation (e.g. take a reference to @invocation and eventually call foo_igen_test_ugly_case_interface_complete_get_iscsi_servers() or e.g. g_dbus_method_invocation_return_error() on it) and no order signal handlers will run. If no signal handler handles the invocation, the %G_DBUS_ERROR_UNKNOWN_METHOD error is returned.
21296    *
21297    * Returns: %TRUE if the invocation was handled, %FALSE to let other signal handlers run.
21298    */
21299   g_signal_new ("handle-get-iscsi-servers",
21300     G_TYPE_FROM_INTERFACE (iface),
21301     G_SIGNAL_RUN_LAST,
21302     G_STRUCT_OFFSET (FooiGenTesTuglyCASEInterfaceIface, handle_get_iscsi_servers),
21303     g_signal_accumulator_true_handled,
21304     NULL,
21305     g_cclosure_marshal_generic,
21306     G_TYPE_BOOLEAN,
21307     1,
21308     G_TYPE_DBUS_METHOD_INVOCATION);
21309
21310   /* GObject signals for received D-Bus signals: */
21311   /**
21312    * FooiGenTesTuglyCASEInterface::servers-updated-now:
21313    * @object: A #FooiGenTesTuglyCASEInterface.
21314    *
21315    * On the client-side, this signal is emitted whenever the D-Bus signal <link linkend="gdbus-signal-TestUglyCaseInterface.serversUPDATEDNOW">"serversUPDATEDNOW"</link> is received.
21316    *
21317    * On the service-side, this signal can be used with e.g. g_signal_emit_by_name() to make the object emit the D-Bus signal.
21318    */
21319   g_signal_new ("servers-updated-now",
21320     G_TYPE_FROM_INTERFACE (iface),
21321     G_SIGNAL_RUN_LAST,
21322     G_STRUCT_OFFSET (FooiGenTesTuglyCASEInterfaceIface, servers_updated_now),
21323     NULL,
21324     NULL,
21325     g_cclosure_marshal_generic,
21326     G_TYPE_NONE,
21327     0);
21328
21329   /* GObject properties for D-Bus properties: */
21330   /**
21331    * FooiGenTesTuglyCASEInterface:ugly-name:
21332    *
21333    * Represents the D-Bus property <link linkend="gdbus-property-TestUglyCaseInterface.UGLYNAME">"UGLYNAME"</link>.
21334    *
21335    * Since the D-Bus property for this #GObject property is both readable and writable, it is meaningful to both read from it and write to it on both the service- and client-side.
21336    */
21337   g_object_interface_install_property (iface,
21338     g_param_spec_int ("ugly-name", "UGLYNAME", "UGLYNAME", G_MININT32, G_MAXINT32, 0, G_PARAM_READWRITE | G_PARAM_STATIC_STRINGS));
21339 }
21340
21341 typedef FooiGenTesTuglyCASEInterfaceIface FooiGenTesTuglyCASEInterfaceInterface;
21342 G_DEFINE_INTERFACE (FooiGenTesTuglyCASEInterface, foo_igen_test_ugly_case_interface, G_TYPE_OBJECT);
21343
21344 /**
21345  * foo_igen_test_ugly_case_interface_get_ugly_name: (skip)
21346  * @object: A #FooiGenTesTuglyCASEInterface.
21347  *
21348  * Gets the value of the <link linkend="gdbus-property-TestUglyCaseInterface.UGLYNAME">"UGLYNAME"</link> D-Bus property.
21349  *
21350  * Since this D-Bus property is both readable and writable, it is meaningful to use this function on both the client- and service-side.
21351  *
21352  * Returns: The property value.
21353  */
21354 gint 
21355 foo_igen_test_ugly_case_interface_get_ugly_name (FooiGenTesTuglyCASEInterface *object)
21356 {
21357   return FOO_IGEN_TEST_UGLY_CASE_INTERFACE_GET_IFACE (object)->get_ugly_name (object);
21358 }
21359
21360 /**
21361  * foo_igen_test_ugly_case_interface_set_ugly_name: (skip)
21362  * @object: A #FooiGenTesTuglyCASEInterface.
21363  * @value: The value to set.
21364  *
21365  * Sets the <link linkend="gdbus-property-TestUglyCaseInterface.UGLYNAME">"UGLYNAME"</link> D-Bus property to @value.
21366  *
21367  * Since this D-Bus property is both readable and writable, it is meaningful to use this function on both the client- and service-side.
21368  */
21369 void
21370 foo_igen_test_ugly_case_interface_set_ugly_name (FooiGenTesTuglyCASEInterface *object, gint value)
21371 {
21372   g_object_set (G_OBJECT (object), "ugly-name", value, NULL);
21373 }
21374
21375 /**
21376  * foo_igen_test_ugly_case_interface_emit_servers_updated_now:
21377  * @object: A #FooiGenTesTuglyCASEInterface.
21378  *
21379  * Emits the <link linkend="gdbus-signal-TestUglyCaseInterface.serversUPDATEDNOW">"serversUPDATEDNOW"</link> D-Bus signal.
21380  */
21381 void
21382 foo_igen_test_ugly_case_interface_emit_servers_updated_now (
21383     FooiGenTesTuglyCASEInterface *object)
21384 {
21385   g_signal_emit_by_name (object, "servers-updated-now");
21386 }
21387
21388 /**
21389  * foo_igen_test_ugly_case_interface_call_get_iscsi_servers:
21390  * @proxy: A #FooiGenTesTuglyCASEInterfaceProxy.
21391  * @cancellable: (allow-none): A #GCancellable or %NULL.
21392  * @callback: A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
21393  * @user_data: User data to pass to @callback.
21394  *
21395  * Asynchronously invokes the <link linkend="gdbus-method-TestUglyCaseInterface.GetiSCSIServers">GetiSCSIServers()</link> D-Bus method on @proxy.
21396  * When the operation is finished, @callback will be invoked in the <link linkend="g-main-context-push-thread-default">thread-default main loop</link> of the thread you are calling this method from.
21397  * You can then call foo_igen_test_ugly_case_interface_call_get_iscsi_servers_finish() to get the result of the operation.
21398  *
21399  * See foo_igen_test_ugly_case_interface_call_get_iscsi_servers_sync() for the synchronous, blocking version of this method.
21400  */
21401 void
21402 foo_igen_test_ugly_case_interface_call_get_iscsi_servers (
21403     FooiGenTesTuglyCASEInterface *proxy,
21404     GCancellable *cancellable,
21405     GAsyncReadyCallback callback,
21406     gpointer user_data)
21407 {
21408   g_dbus_proxy_call (G_DBUS_PROXY (proxy),
21409     "GetiSCSIServers",
21410     g_variant_new ("()"),
21411     G_DBUS_CALL_FLAGS_NONE,
21412     -1,
21413     cancellable,
21414     callback,
21415     user_data);
21416 }
21417
21418 /**
21419  * foo_igen_test_ugly_case_interface_call_get_iscsi_servers_finish:
21420  * @proxy: A #FooiGenTesTuglyCASEInterfaceProxy.
21421  * @res: The #GAsyncResult obtained from the #GAsyncReadyCallback passed to foo_igen_test_ugly_case_interface_call_get_iscsi_servers().
21422  * @error: Return location for error or %NULL.
21423  *
21424  * Finishes an operation started with foo_igen_test_ugly_case_interface_call_get_iscsi_servers().
21425  *
21426  * Returns: (skip): %TRUE if the call succeded, %FALSE if @error is set.
21427  */
21428 gboolean
21429 foo_igen_test_ugly_case_interface_call_get_iscsi_servers_finish (
21430     FooiGenTesTuglyCASEInterface *proxy,
21431     GAsyncResult *res,
21432     GError **error)
21433 {
21434   GVariant *_ret;
21435   _ret = g_dbus_proxy_call_finish (G_DBUS_PROXY (proxy), res, error);
21436   if (_ret == NULL)
21437     goto _out;
21438   g_variant_get (_ret,
21439                  "()");
21440   g_variant_unref (_ret);
21441 _out:
21442   return _ret != NULL;
21443 }
21444
21445 /**
21446  * foo_igen_test_ugly_case_interface_call_get_iscsi_servers_sync:
21447  * @proxy: A #FooiGenTesTuglyCASEInterfaceProxy.
21448  * @cancellable: (allow-none): A #GCancellable or %NULL.
21449  * @error: Return location for error or %NULL.
21450  *
21451  * Synchronously invokes the <link linkend="gdbus-method-TestUglyCaseInterface.GetiSCSIServers">GetiSCSIServers()</link> D-Bus method on @proxy. The calling thread is blocked until a reply is received.
21452  *
21453  * See foo_igen_test_ugly_case_interface_call_get_iscsi_servers() for the asynchronous version of this method.
21454  *
21455  * Returns: (skip): %TRUE if the call succeded, %FALSE if @error is set.
21456  */
21457 gboolean
21458 foo_igen_test_ugly_case_interface_call_get_iscsi_servers_sync (
21459     FooiGenTesTuglyCASEInterface *proxy,
21460     GCancellable *cancellable,
21461     GError **error)
21462 {
21463   GVariant *_ret;
21464   _ret = g_dbus_proxy_call_sync (G_DBUS_PROXY (proxy),
21465     "GetiSCSIServers",
21466     g_variant_new ("()"),
21467     G_DBUS_CALL_FLAGS_NONE,
21468     -1,
21469     cancellable,
21470     error);
21471   if (_ret == NULL)
21472     goto _out;
21473   g_variant_get (_ret,
21474                  "()");
21475   g_variant_unref (_ret);
21476 _out:
21477   return _ret != NULL;
21478 }
21479
21480 /**
21481  * foo_igen_test_ugly_case_interface_complete_get_iscsi_servers:
21482  * @object: A #FooiGenTesTuglyCASEInterface.
21483  * @invocation: (transfer full): A #GDBusMethodInvocation.
21484  *
21485  * Helper function used in service implementations to finish handling invocations of the <link linkend="gdbus-method-TestUglyCaseInterface.GetiSCSIServers">GetiSCSIServers()</link> D-Bus method. If you instead want to finish handling an invocation by returning an error, use g_dbus_method_invocation_return_error() or similar.
21486  *
21487  * This method will free @invocation, you cannot use it afterwards.
21488  */
21489 void
21490 foo_igen_test_ugly_case_interface_complete_get_iscsi_servers (
21491     FooiGenTesTuglyCASEInterface *object,
21492     GDBusMethodInvocation *invocation)
21493 {
21494   g_dbus_method_invocation_return_value (invocation,
21495     g_variant_new ("()"));
21496 }
21497
21498 /* ------------------------------------------------------------------------ */
21499
21500 /**
21501  * FooiGenTesTuglyCASEInterfaceProxy:
21502  *
21503  * The #FooiGenTesTuglyCASEInterfaceProxy structure contains only private data and should only be accessed using the provided API.
21504  */
21505
21506 /**
21507  * FooiGenTesTuglyCASEInterfaceProxyClass:
21508  * @parent_class: The parent class.
21509  *
21510  * Class structure for #FooiGenTesTuglyCASEInterfaceProxy.
21511  */
21512
21513 struct _FooiGenTesTuglyCASEInterfaceProxyPrivate
21514 {
21515   GData *qdata;
21516 };
21517
21518 static void foo_igen_test_ugly_case_interface_proxy_iface_init (FooiGenTesTuglyCASEInterfaceIface *iface);
21519
21520 G_DEFINE_TYPE_WITH_CODE (FooiGenTesTuglyCASEInterfaceProxy, foo_igen_test_ugly_case_interface_proxy, G_TYPE_DBUS_PROXY,
21521                          G_IMPLEMENT_INTERFACE (FOO_IGEN_TYPE_TEST_UGLY_CASE_INTERFACE, foo_igen_test_ugly_case_interface_proxy_iface_init));
21522
21523 static void
21524 foo_igen_test_ugly_case_interface_proxy_finalize (GObject *object)
21525 {
21526   FooiGenTesTuglyCASEInterfaceProxy *proxy = FOO_IGEN_TEST_UGLY_CASE_INTERFACE_PROXY (object);
21527   g_datalist_clear (&proxy->priv->qdata);
21528   G_OBJECT_CLASS (foo_igen_test_ugly_case_interface_proxy_parent_class)->finalize (object);
21529 }
21530
21531 static void
21532 foo_igen_test_ugly_case_interface_proxy_get_property (GObject      *object,
21533   guint         prop_id,
21534   GValue       *value,
21535   GParamSpec   *pspec)
21536 {
21537   const _ExtendedGDBusPropertyInfo *info;
21538   GVariant *variant;
21539   g_assert (prop_id != 0 && prop_id - 1 < 1);
21540   info = _foo_igen_test_ugly_case_interface_property_info_pointers[prop_id - 1];
21541   variant = g_dbus_proxy_get_cached_property (G_DBUS_PROXY (object), info->parent_struct.name);
21542   if (info->use_gvariant)
21543     {
21544       g_value_set_variant (value, variant);
21545     }
21546   else
21547     {
21548       if (variant != NULL)
21549         g_dbus_gvariant_to_gvalue (variant, value);
21550     }
21551   if (variant != NULL)
21552     g_variant_unref (variant);
21553 }
21554
21555 static void
21556 foo_igen_test_ugly_case_interface_proxy_set_property_cb (GDBusProxy *proxy,
21557   GAsyncResult *res,
21558   gpointer      user_data)
21559 {
21560   const _ExtendedGDBusPropertyInfo *info = user_data;
21561   GError *error;
21562   error = NULL;
21563   if (!g_dbus_proxy_call_finish (proxy, res, &error))
21564     {
21565       g_warning ("Error setting property `%s' on interface TestUglyCaseInterface: %s (%s, %d)",
21566                  info->parent_struct.name, 
21567                  error->message, g_quark_to_string (error->domain), error->code);
21568       g_error_free (error);
21569     }
21570 }
21571
21572 static void
21573 foo_igen_test_ugly_case_interface_proxy_set_property (GObject      *object,
21574   guint         prop_id,
21575   const GValue *value,
21576   GParamSpec   *pspec)
21577 {
21578   const _ExtendedGDBusPropertyInfo *info;
21579   GVariant *variant;
21580   g_assert (prop_id != 0 && prop_id - 1 < 1);
21581   info = _foo_igen_test_ugly_case_interface_property_info_pointers[prop_id - 1];
21582   variant = g_dbus_gvalue_to_gvariant (value, G_VARIANT_TYPE (info->parent_struct.signature));
21583   g_dbus_proxy_call (G_DBUS_PROXY (object),
21584     "org.freedesktop.DBus.Properties.Set",
21585     g_variant_new ("(ssv)", "TestUglyCaseInterface", info->parent_struct.name, variant),
21586     G_DBUS_CALL_FLAGS_NONE,
21587     -1,
21588     NULL, (GAsyncReadyCallback) foo_igen_test_ugly_case_interface_proxy_set_property_cb, (gpointer) info);
21589   g_variant_unref (variant);
21590 }
21591
21592 static void
21593 foo_igen_test_ugly_case_interface_proxy_g_signal (GDBusProxy *proxy,
21594   const gchar *sender_name,
21595   const gchar *signal_name,
21596   GVariant *parameters)
21597 {
21598   _ExtendedGDBusSignalInfo *info;
21599   GVariantIter iter;
21600   GVariant *child;
21601   GValue *paramv;
21602   guint num_params;
21603   guint n;
21604   guint signal_id;
21605   info = (_ExtendedGDBusSignalInfo *) g_dbus_interface_info_lookup_signal ((GDBusInterfaceInfo *) &_foo_igen_test_ugly_case_interface_interface_info, signal_name);
21606   if (info == NULL)
21607     return;
21608   num_params = g_variant_n_children (parameters);
21609   paramv = g_new0 (GValue, num_params + 1);
21610   g_value_init (&paramv[0], FOO_IGEN_TYPE_TEST_UGLY_CASE_INTERFACE);
21611   g_value_set_object (&paramv[0], proxy);
21612   g_variant_iter_init (&iter, parameters);
21613   n = 1;
21614   while ((child = g_variant_iter_next_value (&iter)) != NULL)
21615     {
21616       _ExtendedGDBusArgInfo *arg_info = (_ExtendedGDBusArgInfo *) info->parent_struct.args[n - 1];
21617       if (arg_info->use_gvariant)
21618         {
21619           g_value_init (&paramv[n], G_TYPE_VARIANT);
21620           g_value_set_variant (&paramv[n], child);
21621           n++;
21622         }
21623       else
21624         g_dbus_gvariant_to_gvalue (child, &paramv[n++]);
21625       g_variant_unref (child);
21626     }
21627   signal_id = g_signal_lookup (info->signal_name, FOO_IGEN_TYPE_TEST_UGLY_CASE_INTERFACE);
21628   g_signal_emitv (paramv, signal_id, 0, NULL);
21629   for (n = 0; n < num_params + 1; n++)
21630     g_value_unset (&paramv[n]);
21631   g_free (paramv);
21632 }
21633
21634 static void
21635 foo_igen_test_ugly_case_interface_proxy_g_properties_changed (GDBusProxy *_proxy,
21636   GVariant *changed_properties,
21637   const gchar *const *invalidated_properties)
21638 {
21639   FooiGenTesTuglyCASEInterfaceProxy *proxy = FOO_IGEN_TEST_UGLY_CASE_INTERFACE_PROXY (_proxy);
21640   guint n;
21641   const gchar *key;
21642   GVariantIter *iter;
21643   _ExtendedGDBusPropertyInfo *info;
21644   g_variant_get (changed_properties, "a{sv}", &iter);
21645   while (g_variant_iter_next (iter, "{&sv}", &key, NULL))
21646     {
21647       info = (_ExtendedGDBusPropertyInfo *) g_dbus_interface_info_lookup_property ((GDBusInterfaceInfo *) &_foo_igen_test_ugly_case_interface_interface_info, key);
21648       g_datalist_remove_data (&proxy->priv->qdata, key);
21649       if (info != NULL)
21650         g_object_notify (G_OBJECT (proxy), info->hyphen_name);
21651     }
21652   g_variant_iter_free (iter);
21653   for (n = 0; invalidated_properties[n] != NULL; n++)
21654     {
21655       info = (_ExtendedGDBusPropertyInfo *) g_dbus_interface_info_lookup_property ((GDBusInterfaceInfo *) &_foo_igen_test_ugly_case_interface_interface_info, invalidated_properties[n]);
21656       g_datalist_remove_data (&proxy->priv->qdata, invalidated_properties[n]);
21657       if (info != NULL)
21658         g_object_notify (G_OBJECT (proxy), info->hyphen_name);
21659     }
21660 }
21661
21662 static gint 
21663 foo_igen_test_ugly_case_interface_proxy_get_ugly_name (FooiGenTesTuglyCASEInterface *object)
21664 {
21665   FooiGenTesTuglyCASEInterfaceProxy *proxy = FOO_IGEN_TEST_UGLY_CASE_INTERFACE_PROXY (object);
21666   GVariant *variant;
21667   gint value = 0;
21668   variant = g_dbus_proxy_get_cached_property (G_DBUS_PROXY (proxy), "UGLYNAME");
21669   if (variant != NULL)
21670     {
21671       value = g_variant_get_int32 (variant);
21672       g_variant_unref (variant);
21673     }
21674   return value;
21675 }
21676
21677 static void
21678 foo_igen_test_ugly_case_interface_proxy_init (FooiGenTesTuglyCASEInterfaceProxy *proxy)
21679 {
21680   proxy->priv = G_TYPE_INSTANCE_GET_PRIVATE (proxy, FOO_IGEN_TYPE_TEST_UGLY_CASE_INTERFACE_PROXY, FooiGenTesTuglyCASEInterfaceProxyPrivate);
21681   g_dbus_proxy_set_interface_info (G_DBUS_PROXY (proxy), foo_igen_test_ugly_case_interface_interface_info ());
21682 }
21683
21684 static void
21685 foo_igen_test_ugly_case_interface_proxy_class_init (FooiGenTesTuglyCASEInterfaceProxyClass *klass)
21686 {
21687   GObjectClass *gobject_class;
21688   GDBusProxyClass *proxy_class;
21689
21690   g_type_class_add_private (klass, sizeof (FooiGenTesTuglyCASEInterfaceProxyPrivate));
21691
21692   gobject_class = G_OBJECT_CLASS (klass);
21693   gobject_class->finalize     = foo_igen_test_ugly_case_interface_proxy_finalize;
21694   gobject_class->get_property = foo_igen_test_ugly_case_interface_proxy_get_property;
21695   gobject_class->set_property = foo_igen_test_ugly_case_interface_proxy_set_property;
21696
21697   proxy_class = G_DBUS_PROXY_CLASS (klass);
21698   proxy_class->g_signal = foo_igen_test_ugly_case_interface_proxy_g_signal;
21699   proxy_class->g_properties_changed = foo_igen_test_ugly_case_interface_proxy_g_properties_changed;
21700
21701
21702   foo_igen_test_ugly_case_interface_override_properties (gobject_class, 1);
21703 }
21704
21705 static void
21706 foo_igen_test_ugly_case_interface_proxy_iface_init (FooiGenTesTuglyCASEInterfaceIface *iface)
21707 {
21708   iface->get_ugly_name = foo_igen_test_ugly_case_interface_proxy_get_ugly_name;
21709 }
21710
21711 /**
21712  * foo_igen_test_ugly_case_interface_proxy_new:
21713  * @connection: A #GDBusConnection.
21714  * @flags: Flags from the #GDBusProxyFlags enumeration.
21715  * @name: (allow-none): A bus name (well-known or unique) or %NULL if @connection is not a message bus connection.
21716  * @object_path: An object path.
21717  * @cancellable: (allow-none): A #GCancellable or %NULL.
21718  * @callback: A #GAsyncReadyCallback to call when the request is satisfied.
21719  * @user_data: User data to pass to @callback.
21720  *
21721  * Asynchronously creates a proxy for the D-Bus interface <link linkend="gdbus-interface-TestUglyCaseInterface.top_of_page">TestUglyCaseInterface</link>. See g_dbus_proxy_new() for more details.
21722  *
21723  * When the operation is finished, @callback will be invoked in the <link linkend="g-main-context-push-thread-default">thread-default main loop</link> of the thread you are calling this method from.
21724  * You can then call foo_igen_test_ugly_case_interface_proxy_new_finish() to get the result of the operation.
21725  *
21726  * See foo_igen_test_ugly_case_interface_proxy_new_sync() for the synchronous, blocking version of this constructor.
21727  */
21728 void
21729 foo_igen_test_ugly_case_interface_proxy_new (
21730     GDBusConnection     *connection,
21731     GDBusProxyFlags      flags,
21732     const gchar         *name,
21733     const gchar         *object_path,
21734     GCancellable        *cancellable,
21735     GAsyncReadyCallback  callback,
21736     gpointer             user_data)
21737 {
21738   g_async_initable_new_async (FOO_IGEN_TYPE_TEST_UGLY_CASE_INTERFACE_PROXY, G_PRIORITY_DEFAULT, cancellable, callback, user_data, "g-flags", flags, "g-name", name, "g-connection", connection, "g-object-path", object_path, "g-interface-name", "TestUglyCaseInterface", NULL);
21739 }
21740
21741 /**
21742  * foo_igen_test_ugly_case_interface_proxy_new_finish:
21743  * @res: The #GAsyncResult obtained from the #GAsyncReadyCallback passed to foo_igen_test_ugly_case_interface_proxy_new().
21744  * @error: Return location for error or %NULL
21745  *
21746  * Finishes an operation started with foo_igen_test_ugly_case_interface_proxy_new().
21747  *
21748  * Returns: (transfer full) (type FooiGenTesTuglyCASEInterfaceProxy): The constructed proxy object or %NULL if @error is set.
21749  */
21750 FooiGenTesTuglyCASEInterface *
21751 foo_igen_test_ugly_case_interface_proxy_new_finish (
21752     GAsyncResult        *res,
21753     GError             **error)
21754 {
21755   GObject *ret;
21756   GObject *source_object;
21757   source_object = g_async_result_get_source_object (res);
21758   ret = g_async_initable_new_finish (G_ASYNC_INITABLE (source_object), res, error);
21759   g_object_unref (source_object);
21760   if (ret != NULL)
21761     return FOO_IGEN_TEST_UGLY_CASE_INTERFACE (ret);
21762   else
21763     return NULL;
21764 }
21765
21766 /**
21767  * foo_igen_test_ugly_case_interface_proxy_new_sync:
21768  * @connection: A #GDBusConnection.
21769  * @flags: Flags from the #GDBusProxyFlags enumeration.
21770  * @name: (allow-none): A bus name (well-known or unique) or %NULL if @connection is not a message bus connection.
21771  * @object_path: An object path.
21772  * @cancellable: (allow-none): A #GCancellable or %NULL.
21773  * @error: Return location for error or %NULL
21774  *
21775  * Synchronously creates a proxy for the D-Bus interface <link linkend="gdbus-interface-TestUglyCaseInterface.top_of_page">TestUglyCaseInterface</link>. See g_dbus_proxy_new_sync() for more details.
21776  *
21777  * The calling thread is blocked until a reply is received.
21778  *
21779  * See foo_igen_test_ugly_case_interface_proxy_new() for the asynchronous version of this constructor.
21780  *
21781  * Returns: (transfer full) (type FooiGenTesTuglyCASEInterfaceProxy): The constructed proxy object or %NULL if @error is set.
21782  */
21783 FooiGenTesTuglyCASEInterface *
21784 foo_igen_test_ugly_case_interface_proxy_new_sync (
21785     GDBusConnection     *connection,
21786     GDBusProxyFlags      flags,
21787     const gchar         *name,
21788     const gchar         *object_path,
21789     GCancellable        *cancellable,
21790     GError             **error)
21791 {
21792   GInitable *ret;
21793   ret = g_initable_new (FOO_IGEN_TYPE_TEST_UGLY_CASE_INTERFACE_PROXY, cancellable, error, "g-flags", flags, "g-name", name, "g-connection", connection, "g-object-path", object_path, "g-interface-name", "TestUglyCaseInterface", NULL);
21794   if (ret != NULL)
21795     return FOO_IGEN_TEST_UGLY_CASE_INTERFACE (ret);
21796   else
21797     return NULL;
21798 }
21799
21800
21801 /**
21802  * foo_igen_test_ugly_case_interface_proxy_new_for_bus:
21803  * @bus_type: A #GBusType.
21804  * @flags: Flags from the #GDBusProxyFlags enumeration.
21805  * @name: A bus name (well-known or unique).
21806  * @object_path: An object path.
21807  * @cancellable: (allow-none): A #GCancellable or %NULL.
21808  * @callback: A #GAsyncReadyCallback to call when the request is satisfied.
21809  * @user_data: User data to pass to @callback.
21810  *
21811  * Like foo_igen_test_ugly_case_interface_proxy_new() but takes a #GBusType instead of a #GDBusConnection.
21812  *
21813  * When the operation is finished, @callback will be invoked in the <link linkend="g-main-context-push-thread-default">thread-default main loop</link> of the thread you are calling this method from.
21814  * You can then call foo_igen_test_ugly_case_interface_proxy_new_for_bus_finish() to get the result of the operation.
21815  *
21816  * See foo_igen_test_ugly_case_interface_proxy_new_for_bus_sync() for the synchronous, blocking version of this constructor.
21817  */
21818 void
21819 foo_igen_test_ugly_case_interface_proxy_new_for_bus (
21820     GBusType             bus_type,
21821     GDBusProxyFlags      flags,
21822     const gchar         *name,
21823     const gchar         *object_path,
21824     GCancellable        *cancellable,
21825     GAsyncReadyCallback  callback,
21826     gpointer             user_data)
21827 {
21828   g_async_initable_new_async (FOO_IGEN_TYPE_TEST_UGLY_CASE_INTERFACE_PROXY, G_PRIORITY_DEFAULT, cancellable, callback, user_data, "g-flags", flags, "g-name", name, "g-bus-type", bus_type, "g-object-path", object_path, "g-interface-name", "TestUglyCaseInterface", NULL);
21829 }
21830
21831 /**
21832  * foo_igen_test_ugly_case_interface_proxy_new_for_bus_finish:
21833  * @res: The #GAsyncResult obtained from the #GAsyncReadyCallback passed to foo_igen_test_ugly_case_interface_proxy_new_for_bus().
21834  * @error: Return location for error or %NULL
21835  *
21836  * Finishes an operation started with foo_igen_test_ugly_case_interface_proxy_new_for_bus().
21837  *
21838  * Returns: (transfer full) (type FooiGenTesTuglyCASEInterfaceProxy): The constructed proxy object or %NULL if @error is set.
21839  */
21840 FooiGenTesTuglyCASEInterface *
21841 foo_igen_test_ugly_case_interface_proxy_new_for_bus_finish (
21842     GAsyncResult        *res,
21843     GError             **error)
21844 {
21845   GObject *ret;
21846   GObject *source_object;
21847   source_object = g_async_result_get_source_object (res);
21848   ret = g_async_initable_new_finish (G_ASYNC_INITABLE (source_object), res, error);
21849   g_object_unref (source_object);
21850   if (ret != NULL)
21851     return FOO_IGEN_TEST_UGLY_CASE_INTERFACE (ret);
21852   else
21853     return NULL;
21854 }
21855
21856 /**
21857  * foo_igen_test_ugly_case_interface_proxy_new_for_bus_sync:
21858  * @bus_type: A #GBusType.
21859  * @flags: Flags from the #GDBusProxyFlags enumeration.
21860  * @name: A bus name (well-known or unique).
21861  * @object_path: An object path.
21862  * @cancellable: (allow-none): A #GCancellable or %NULL.
21863  * @error: Return location for error or %NULL
21864  *
21865  * Like foo_igen_test_ugly_case_interface_proxy_new_sync() but takes a #GBusType instead of a #GDBusConnection.
21866  *
21867  * The calling thread is blocked until a reply is received.
21868  *
21869  * See foo_igen_test_ugly_case_interface_proxy_new_for_bus() for the asynchronous version of this constructor.
21870  *
21871  * Returns: (transfer full) (type FooiGenTesTuglyCASEInterfaceProxy): The constructed proxy object or %NULL if @error is set.
21872  */
21873 FooiGenTesTuglyCASEInterface *
21874 foo_igen_test_ugly_case_interface_proxy_new_for_bus_sync (
21875     GBusType             bus_type,
21876     GDBusProxyFlags      flags,
21877     const gchar         *name,
21878     const gchar         *object_path,
21879     GCancellable        *cancellable,
21880     GError             **error)
21881 {
21882   GInitable *ret;
21883   ret = g_initable_new (FOO_IGEN_TYPE_TEST_UGLY_CASE_INTERFACE_PROXY, cancellable, error, "g-flags", flags, "g-name", name, "g-bus-type", bus_type, "g-object-path", object_path, "g-interface-name", "TestUglyCaseInterface", NULL);
21884   if (ret != NULL)
21885     return FOO_IGEN_TEST_UGLY_CASE_INTERFACE (ret);
21886   else
21887     return NULL;
21888 }
21889
21890
21891 /* ------------------------------------------------------------------------ */
21892
21893 /**
21894  * FooiGenTesTuglyCASEInterfaceSkeleton:
21895  *
21896  * The #FooiGenTesTuglyCASEInterfaceSkeleton structure contains only private data and should only be accessed using the provided API.
21897  */
21898
21899 /**
21900  * FooiGenTesTuglyCASEInterfaceSkeletonClass:
21901  * @parent_class: The parent class.
21902  *
21903  * Class structure for #FooiGenTesTuglyCASEInterfaceSkeleton.
21904  */
21905
21906 struct _FooiGenTesTuglyCASEInterfaceSkeletonPrivate
21907 {
21908   GValue *properties;
21909   GList *changed_properties;
21910   GSource *changed_properties_idle_source;
21911   GMainContext *context;
21912   GMutex lock;
21913 };
21914
21915 static void
21916 _foo_igen_test_ugly_case_interface_skeleton_handle_method_call (
21917   GDBusConnection *connection,
21918   const gchar *sender,
21919   const gchar *object_path,
21920   const gchar *interface_name,
21921   const gchar *method_name,
21922   GVariant *parameters,
21923   GDBusMethodInvocation *invocation,
21924   gpointer user_data)
21925 {
21926   FooiGenTesTuglyCASEInterfaceSkeleton *skeleton = FOO_IGEN_TEST_UGLY_CASE_INTERFACE_SKELETON (user_data);
21927   _ExtendedGDBusMethodInfo *info;
21928   GVariantIter iter;
21929   GVariant *child;
21930   GValue *paramv;
21931   guint num_params;
21932   guint num_extra;
21933   guint n;
21934   guint signal_id;
21935   GValue return_value = G_VALUE_INIT;
21936   info = (_ExtendedGDBusMethodInfo *) g_dbus_method_invocation_get_method_info (invocation);
21937   g_assert (info != NULL);
21938   num_params = g_variant_n_children (parameters);
21939   num_extra = info->pass_fdlist ? 3 : 2;  paramv = g_new0 (GValue, num_params + num_extra);
21940   n = 0;
21941   g_value_init (&paramv[n], FOO_IGEN_TYPE_TEST_UGLY_CASE_INTERFACE);
21942   g_value_set_object (&paramv[n++], skeleton);
21943   g_value_init (&paramv[n], G_TYPE_DBUS_METHOD_INVOCATION);
21944   g_value_set_object (&paramv[n++], invocation);
21945   if (info->pass_fdlist)
21946     {
21947 #ifdef G_OS_UNIX
21948       g_value_init (&paramv[n], G_TYPE_UNIX_FD_LIST);
21949       g_value_set_object (&paramv[n++], g_dbus_message_get_unix_fd_list (g_dbus_method_invocation_get_message (invocation)));
21950 #else
21951       g_assert_not_reached ();
21952 #endif
21953     }
21954   g_variant_iter_init (&iter, parameters);
21955   while ((child = g_variant_iter_next_value (&iter)) != NULL)
21956     {
21957       _ExtendedGDBusArgInfo *arg_info = (_ExtendedGDBusArgInfo *) info->parent_struct.in_args[n - num_extra];
21958       if (arg_info->use_gvariant)
21959         {
21960           g_value_init (&paramv[n], G_TYPE_VARIANT);
21961           g_value_set_variant (&paramv[n], child);
21962           n++;
21963         }
21964       else
21965         g_dbus_gvariant_to_gvalue (child, &paramv[n++]);
21966       g_variant_unref (child);
21967     }
21968   signal_id = g_signal_lookup (info->signal_name, FOO_IGEN_TYPE_TEST_UGLY_CASE_INTERFACE);
21969   g_value_init (&return_value, G_TYPE_BOOLEAN);
21970   g_signal_emitv (paramv, signal_id, 0, &return_value);
21971   if (!g_value_get_boolean (&return_value))
21972     g_dbus_method_invocation_return_error (invocation, G_DBUS_ERROR, G_DBUS_ERROR_UNKNOWN_METHOD, "Method %s is not implemented on interface %s", method_name, interface_name);
21973   g_value_unset (&return_value);
21974   for (n = 0; n < num_params + num_extra; n++)
21975     g_value_unset (&paramv[n]);
21976   g_free (paramv);
21977 }
21978
21979 static GVariant *
21980 _foo_igen_test_ugly_case_interface_skeleton_handle_get_property (
21981   GDBusConnection *connection,
21982   const gchar *sender,
21983   const gchar *object_path,
21984   const gchar *interface_name,
21985   const gchar *property_name,
21986   GError **error,
21987   gpointer user_data)
21988 {
21989   FooiGenTesTuglyCASEInterfaceSkeleton *skeleton = FOO_IGEN_TEST_UGLY_CASE_INTERFACE_SKELETON (user_data);
21990   GValue value = G_VALUE_INIT;
21991   GParamSpec *pspec;
21992   _ExtendedGDBusPropertyInfo *info;
21993   GVariant *ret;
21994   ret = NULL;
21995   info = (_ExtendedGDBusPropertyInfo *) g_dbus_interface_info_lookup_property ((GDBusInterfaceInfo *) &_foo_igen_test_ugly_case_interface_interface_info, property_name);
21996   g_assert (info != NULL);
21997   pspec = g_object_class_find_property (G_OBJECT_GET_CLASS (skeleton), info->hyphen_name);
21998   if (pspec == NULL)
21999     {
22000       g_set_error (error, G_DBUS_ERROR, G_DBUS_ERROR_INVALID_ARGS, "No property with name %s", property_name);
22001     }
22002   else
22003     {
22004       g_value_init (&value, pspec->value_type);
22005       g_object_get_property (G_OBJECT (skeleton), info->hyphen_name, &value);
22006       ret = g_dbus_gvalue_to_gvariant (&value, G_VARIANT_TYPE (info->parent_struct.signature));
22007       g_value_unset (&value);
22008     }
22009   return ret;
22010 }
22011
22012 static gboolean
22013 _foo_igen_test_ugly_case_interface_skeleton_handle_set_property (
22014   GDBusConnection *connection,
22015   const gchar *sender,
22016   const gchar *object_path,
22017   const gchar *interface_name,
22018   const gchar *property_name,
22019   GVariant *variant,
22020   GError **error,
22021   gpointer user_data)
22022 {
22023   FooiGenTesTuglyCASEInterfaceSkeleton *skeleton = FOO_IGEN_TEST_UGLY_CASE_INTERFACE_SKELETON (user_data);
22024   GValue value = G_VALUE_INIT;
22025   GParamSpec *pspec;
22026   _ExtendedGDBusPropertyInfo *info;
22027   gboolean ret;
22028   ret = FALSE;
22029   info = (_ExtendedGDBusPropertyInfo *) g_dbus_interface_info_lookup_property ((GDBusInterfaceInfo *) &_foo_igen_test_ugly_case_interface_interface_info, property_name);
22030   g_assert (info != NULL);
22031   pspec = g_object_class_find_property (G_OBJECT_GET_CLASS (skeleton), info->hyphen_name);
22032   if (pspec == NULL)
22033     {
22034       g_set_error (error, G_DBUS_ERROR, G_DBUS_ERROR_INVALID_ARGS, "No property with name %s", property_name);
22035     }
22036   else
22037     {
22038       if (info->use_gvariant)
22039         g_value_set_variant (&value, variant);
22040       else
22041         g_dbus_gvariant_to_gvalue (variant, &value);
22042       g_object_set_property (G_OBJECT (skeleton), info->hyphen_name, &value);
22043       g_value_unset (&value);
22044       ret = TRUE;
22045     }
22046   return ret;
22047 }
22048
22049 static const GDBusInterfaceVTable _foo_igen_test_ugly_case_interface_skeleton_vtable =
22050 {
22051   _foo_igen_test_ugly_case_interface_skeleton_handle_method_call,
22052   _foo_igen_test_ugly_case_interface_skeleton_handle_get_property,
22053   _foo_igen_test_ugly_case_interface_skeleton_handle_set_property
22054 };
22055
22056 static GDBusInterfaceInfo *
22057 foo_igen_test_ugly_case_interface_skeleton_dbus_interface_get_info (GDBusInterfaceSkeleton *skeleton)
22058 {
22059   return foo_igen_test_ugly_case_interface_interface_info ();
22060 }
22061
22062 static GDBusInterfaceVTable *
22063 foo_igen_test_ugly_case_interface_skeleton_dbus_interface_get_vtable (GDBusInterfaceSkeleton *skeleton)
22064 {
22065   return (GDBusInterfaceVTable *) &_foo_igen_test_ugly_case_interface_skeleton_vtable;
22066 }
22067
22068 static GVariant *
22069 foo_igen_test_ugly_case_interface_skeleton_dbus_interface_get_properties (GDBusInterfaceSkeleton *_skeleton)
22070 {
22071   FooiGenTesTuglyCASEInterfaceSkeleton *skeleton = FOO_IGEN_TEST_UGLY_CASE_INTERFACE_SKELETON (_skeleton);
22072
22073   GVariantBuilder builder;
22074   guint n;
22075   g_variant_builder_init (&builder, G_VARIANT_TYPE ("a{sv}"));
22076   if (_foo_igen_test_ugly_case_interface_interface_info.parent_struct.properties == NULL)
22077     goto out;
22078   for (n = 0; _foo_igen_test_ugly_case_interface_interface_info.parent_struct.properties[n] != NULL; n++)
22079     {
22080       GDBusPropertyInfo *info = _foo_igen_test_ugly_case_interface_interface_info.parent_struct.properties[n];
22081       if (info->flags & G_DBUS_PROPERTY_INFO_FLAGS_READABLE)
22082         {
22083           GVariant *value;
22084           value = _foo_igen_test_ugly_case_interface_skeleton_handle_get_property (g_dbus_interface_skeleton_get_connection (G_DBUS_INTERFACE_SKELETON (skeleton)), NULL, g_dbus_interface_skeleton_get_object_path (G_DBUS_INTERFACE_SKELETON (skeleton)), "TestUglyCaseInterface", info->name, NULL, skeleton);
22085           if (value != NULL)
22086             {
22087               g_variant_take_ref (value);
22088               g_variant_builder_add (&builder, "{sv}", info->name, value);
22089               g_variant_unref (value);
22090             }
22091         }
22092     }
22093 out:
22094   return g_variant_builder_end (&builder);
22095 }
22096
22097 static gboolean _foo_igen_test_ugly_case_interface_emit_changed (gpointer user_data);
22098
22099 static void
22100 foo_igen_test_ugly_case_interface_skeleton_dbus_interface_flush (GDBusInterfaceSkeleton *_skeleton)
22101 {
22102   FooiGenTesTuglyCASEInterfaceSkeleton *skeleton = FOO_IGEN_TEST_UGLY_CASE_INTERFACE_SKELETON (_skeleton);
22103   gboolean emit_changed = FALSE;
22104
22105   g_mutex_lock (&skeleton->priv->lock);
22106   if (skeleton->priv->changed_properties_idle_source != NULL)
22107     {
22108       g_source_destroy (skeleton->priv->changed_properties_idle_source);
22109       skeleton->priv->changed_properties_idle_source = NULL;
22110       emit_changed = TRUE;
22111     }
22112   g_mutex_unlock (&skeleton->priv->lock);
22113
22114   if (emit_changed)
22115     _foo_igen_test_ugly_case_interface_emit_changed (skeleton);
22116 }
22117
22118 static void
22119 _foo_igen_test_ugly_case_interface_on_signal_servers_updated_now (
22120     FooiGenTesTuglyCASEInterface *object)
22121 {
22122   FooiGenTesTuglyCASEInterfaceSkeleton *skeleton = FOO_IGEN_TEST_UGLY_CASE_INTERFACE_SKELETON (object);
22123
22124   GList      *connections, *l;
22125   GVariant   *signal_variant;
22126   connections = g_dbus_interface_skeleton_get_connections (G_DBUS_INTERFACE_SKELETON (skeleton));
22127
22128   signal_variant = g_variant_ref_sink (g_variant_new ("()"));
22129   for (l = connections; l != NULL; l = l->next)
22130     {
22131       GDBusConnection *connection = l->data;
22132       g_dbus_connection_emit_signal (connection,
22133         NULL, g_dbus_interface_skeleton_get_object_path (G_DBUS_INTERFACE_SKELETON (skeleton)), "TestUglyCaseInterface", "serversUPDATEDNOW",
22134         signal_variant, NULL);
22135     }
22136   g_variant_unref (signal_variant);
22137   g_list_free_full (connections, g_object_unref);
22138 }
22139
22140 static void foo_igen_test_ugly_case_interface_skeleton_iface_init (FooiGenTesTuglyCASEInterfaceIface *iface);
22141 G_DEFINE_TYPE_WITH_CODE (FooiGenTesTuglyCASEInterfaceSkeleton, foo_igen_test_ugly_case_interface_skeleton, G_TYPE_DBUS_INTERFACE_SKELETON,
22142                          G_IMPLEMENT_INTERFACE (FOO_IGEN_TYPE_TEST_UGLY_CASE_INTERFACE, foo_igen_test_ugly_case_interface_skeleton_iface_init));
22143
22144 static void
22145 foo_igen_test_ugly_case_interface_skeleton_finalize (GObject *object)
22146 {
22147   FooiGenTesTuglyCASEInterfaceSkeleton *skeleton = FOO_IGEN_TEST_UGLY_CASE_INTERFACE_SKELETON (object);
22148   guint n;
22149   for (n = 0; n < 1; n++)
22150     g_value_unset (&skeleton->priv->properties[n]);
22151   g_free (skeleton->priv->properties);
22152   g_list_free_full (skeleton->priv->changed_properties, (GDestroyNotify) _changed_property_free);
22153   if (skeleton->priv->changed_properties_idle_source != NULL)
22154     g_source_destroy (skeleton->priv->changed_properties_idle_source);
22155   g_main_context_unref (skeleton->priv->context);
22156   g_mutex_clear (&skeleton->priv->lock);
22157   G_OBJECT_CLASS (foo_igen_test_ugly_case_interface_skeleton_parent_class)->finalize (object);
22158 }
22159
22160 static void
22161 foo_igen_test_ugly_case_interface_skeleton_get_property (GObject      *object,
22162   guint         prop_id,
22163   GValue       *value,
22164   GParamSpec   *pspec)
22165 {
22166   FooiGenTesTuglyCASEInterfaceSkeleton *skeleton = FOO_IGEN_TEST_UGLY_CASE_INTERFACE_SKELETON (object);
22167   g_assert (prop_id != 0 && prop_id - 1 < 1);
22168   g_mutex_lock (&skeleton->priv->lock);
22169   g_value_copy (&skeleton->priv->properties[prop_id - 1], value);
22170   g_mutex_unlock (&skeleton->priv->lock);
22171 }
22172
22173 static gboolean
22174 _foo_igen_test_ugly_case_interface_emit_changed (gpointer user_data)
22175 {
22176   FooiGenTesTuglyCASEInterfaceSkeleton *skeleton = FOO_IGEN_TEST_UGLY_CASE_INTERFACE_SKELETON (user_data);
22177   GList *l;
22178   GVariantBuilder builder;
22179   GVariantBuilder invalidated_builder;
22180   guint num_changes;
22181
22182   g_mutex_lock (&skeleton->priv->lock);
22183   g_variant_builder_init (&builder, G_VARIANT_TYPE ("a{sv}"));
22184   g_variant_builder_init (&invalidated_builder, G_VARIANT_TYPE ("as"));
22185   for (l = skeleton->priv->changed_properties, num_changes = 0; l != NULL; l = l->next)
22186     {
22187       ChangedProperty *cp = l->data;
22188       GVariant *variant;
22189       const GValue *cur_value;
22190
22191       cur_value = &skeleton->priv->properties[cp->prop_id - 1];
22192       if (!_g_value_equal (cur_value, &cp->orig_value))
22193         {
22194           variant = g_dbus_gvalue_to_gvariant (cur_value, G_VARIANT_TYPE (cp->info->parent_struct.signature));
22195           g_variant_builder_add (&builder, "{sv}", cp->info->parent_struct.name, variant);
22196           g_variant_unref (variant);
22197           num_changes++;
22198         }
22199     }
22200   if (num_changes > 0)
22201     {
22202       GList *connections, *l;
22203       GVariant *signal_variant;
22204       signal_variant = g_variant_ref_sink (g_variant_new ("(sa{sv}as)", "TestUglyCaseInterface",
22205                                            &builder, &invalidated_builder));
22206       connections = g_dbus_interface_skeleton_get_connections (G_DBUS_INTERFACE_SKELETON (skeleton));
22207       for (l = connections; l != NULL; l = l->next)
22208         {
22209           GDBusConnection *connection = l->data;
22210
22211           g_dbus_connection_emit_signal (connection,
22212                                          NULL, g_dbus_interface_skeleton_get_object_path (G_DBUS_INTERFACE_SKELETON (skeleton)),
22213                                          "org.freedesktop.DBus.Properties",
22214                                          "PropertiesChanged",
22215                                          signal_variant,
22216                                          NULL);
22217         }
22218       g_variant_unref (signal_variant);
22219       g_list_free_full (connections, g_object_unref);
22220     }
22221   else
22222     {
22223       g_variant_builder_clear (&builder);
22224       g_variant_builder_clear (&invalidated_builder);
22225     }
22226   g_list_free_full (skeleton->priv->changed_properties, (GDestroyNotify) _changed_property_free);
22227   skeleton->priv->changed_properties = NULL;
22228   skeleton->priv->changed_properties_idle_source = NULL;
22229   g_mutex_unlock (&skeleton->priv->lock);
22230   return FALSE;
22231 }
22232
22233 static void
22234 _foo_igen_test_ugly_case_interface_schedule_emit_changed (FooiGenTesTuglyCASEInterfaceSkeleton *skeleton, const _ExtendedGDBusPropertyInfo *info, guint prop_id, const GValue *orig_value)
22235 {
22236   ChangedProperty *cp;
22237   GList *l;
22238   cp = NULL;
22239   for (l = skeleton->priv->changed_properties; l != NULL; l = l->next)
22240     {
22241       ChangedProperty *i_cp = l->data;
22242       if (i_cp->info == info)
22243         {
22244           cp = i_cp;
22245           break;
22246         }
22247     }
22248   if (cp == NULL)
22249     {
22250       cp = g_new0 (ChangedProperty, 1);
22251       cp->prop_id = prop_id;
22252       cp->info = info;
22253       skeleton->priv->changed_properties = g_list_prepend (skeleton->priv->changed_properties, cp);
22254       g_value_init (&cp->orig_value, G_VALUE_TYPE (orig_value));
22255       g_value_copy (orig_value, &cp->orig_value);
22256     }
22257 }
22258
22259 static void
22260 foo_igen_test_ugly_case_interface_skeleton_notify (GObject      *object,
22261   GParamSpec *pspec)
22262 {
22263   FooiGenTesTuglyCASEInterfaceSkeleton *skeleton = FOO_IGEN_TEST_UGLY_CASE_INTERFACE_SKELETON (object);
22264   g_mutex_lock (&skeleton->priv->lock);
22265   if (skeleton->priv->changed_properties != NULL &&
22266       skeleton->priv->changed_properties_idle_source == NULL)
22267     {
22268       skeleton->priv->changed_properties_idle_source = g_idle_source_new ();
22269       g_source_set_priority (skeleton->priv->changed_properties_idle_source, G_PRIORITY_DEFAULT);
22270       g_source_set_callback (skeleton->priv->changed_properties_idle_source, _foo_igen_test_ugly_case_interface_emit_changed, g_object_ref (skeleton), (GDestroyNotify) g_object_unref);
22271       g_source_attach (skeleton->priv->changed_properties_idle_source, skeleton->priv->context);
22272       g_source_unref (skeleton->priv->changed_properties_idle_source);
22273     }
22274   g_mutex_unlock (&skeleton->priv->lock);
22275 }
22276
22277 static void
22278 foo_igen_test_ugly_case_interface_skeleton_set_property (GObject      *object,
22279   guint         prop_id,
22280   const GValue *value,
22281   GParamSpec   *pspec)
22282 {
22283   FooiGenTesTuglyCASEInterfaceSkeleton *skeleton = FOO_IGEN_TEST_UGLY_CASE_INTERFACE_SKELETON (object);
22284   g_assert (prop_id != 0 && prop_id - 1 < 1);
22285   g_mutex_lock (&skeleton->priv->lock);
22286   g_object_freeze_notify (object);
22287   if (!_g_value_equal (value, &skeleton->priv->properties[prop_id - 1]))
22288     {
22289       if (g_dbus_interface_skeleton_get_connection (G_DBUS_INTERFACE_SKELETON (skeleton)) != NULL)
22290         _foo_igen_test_ugly_case_interface_schedule_emit_changed (skeleton, _foo_igen_test_ugly_case_interface_property_info_pointers[prop_id - 1], prop_id, &skeleton->priv->properties[prop_id - 1]);
22291       g_value_copy (value, &skeleton->priv->properties[prop_id - 1]);
22292       g_object_notify_by_pspec (object, pspec);
22293     }
22294   g_mutex_unlock (&skeleton->priv->lock);
22295   g_object_thaw_notify (object);
22296 }
22297
22298 static void
22299 foo_igen_test_ugly_case_interface_skeleton_init (FooiGenTesTuglyCASEInterfaceSkeleton *skeleton)
22300 {
22301   skeleton->priv = G_TYPE_INSTANCE_GET_PRIVATE (skeleton, FOO_IGEN_TYPE_TEST_UGLY_CASE_INTERFACE_SKELETON, FooiGenTesTuglyCASEInterfaceSkeletonPrivate);
22302   g_mutex_init (&skeleton->priv->lock);
22303   skeleton->priv->context = g_main_context_ref_thread_default ();
22304   skeleton->priv->properties = g_new0 (GValue, 1);
22305   g_value_init (&skeleton->priv->properties[0], G_TYPE_INT);
22306 }
22307
22308 static gint 
22309 foo_igen_test_ugly_case_interface_skeleton_get_ugly_name (FooiGenTesTuglyCASEInterface *object)
22310 {
22311   FooiGenTesTuglyCASEInterfaceSkeleton *skeleton = FOO_IGEN_TEST_UGLY_CASE_INTERFACE_SKELETON (object);
22312   gint value;
22313   g_mutex_lock (&skeleton->priv->lock);
22314   value = g_value_get_int (&(skeleton->priv->properties[0]));
22315   g_mutex_unlock (&skeleton->priv->lock);
22316   return value;
22317 }
22318
22319 static void
22320 foo_igen_test_ugly_case_interface_skeleton_class_init (FooiGenTesTuglyCASEInterfaceSkeletonClass *klass)
22321 {
22322   GObjectClass *gobject_class;
22323   GDBusInterfaceSkeletonClass *skeleton_class;
22324
22325   g_type_class_add_private (klass, sizeof (FooiGenTesTuglyCASEInterfaceSkeletonPrivate));
22326
22327   gobject_class = G_OBJECT_CLASS (klass);
22328   gobject_class->finalize = foo_igen_test_ugly_case_interface_skeleton_finalize;
22329   gobject_class->get_property = foo_igen_test_ugly_case_interface_skeleton_get_property;
22330   gobject_class->set_property = foo_igen_test_ugly_case_interface_skeleton_set_property;
22331   gobject_class->notify       = foo_igen_test_ugly_case_interface_skeleton_notify;
22332
22333
22334   foo_igen_test_ugly_case_interface_override_properties (gobject_class, 1);
22335
22336   skeleton_class = G_DBUS_INTERFACE_SKELETON_CLASS (klass);
22337   skeleton_class->get_info = foo_igen_test_ugly_case_interface_skeleton_dbus_interface_get_info;
22338   skeleton_class->get_properties = foo_igen_test_ugly_case_interface_skeleton_dbus_interface_get_properties;
22339   skeleton_class->flush = foo_igen_test_ugly_case_interface_skeleton_dbus_interface_flush;
22340   skeleton_class->get_vtable = foo_igen_test_ugly_case_interface_skeleton_dbus_interface_get_vtable;
22341 }
22342
22343 static void
22344 foo_igen_test_ugly_case_interface_skeleton_iface_init (FooiGenTesTuglyCASEInterfaceIface *iface)
22345 {
22346   iface->servers_updated_now = _foo_igen_test_ugly_case_interface_on_signal_servers_updated_now;
22347   iface->get_ugly_name = foo_igen_test_ugly_case_interface_skeleton_get_ugly_name;
22348 }
22349
22350 /**
22351  * foo_igen_test_ugly_case_interface_skeleton_new:
22352  *
22353  * Creates a skeleton object for the D-Bus interface <link linkend="gdbus-interface-TestUglyCaseInterface.top_of_page">TestUglyCaseInterface</link>.
22354  *
22355  * Returns: (transfer full) (type FooiGenTesTuglyCASEInterfaceSkeleton): The skeleton object.
22356  */
22357 FooiGenTesTuglyCASEInterface *
22358 foo_igen_test_ugly_case_interface_skeleton_new (void)
22359 {
22360   return FOO_IGEN_TEST_UGLY_CASE_INTERFACE (g_object_new (FOO_IGEN_TYPE_TEST_UGLY_CASE_INTERFACE_SKELETON, NULL));
22361 }
22362
22363 /* ------------------------------------------------------------------------
22364  * Code for interface OldieInterface
22365  * ------------------------------------------------------------------------
22366  */
22367
22368 /**
22369  * SECTION:FooiGenOldieInterface
22370  * @title: FooiGenOldieInterface
22371  * @short_description: Generated C code for the OldieInterface D-Bus interface
22372  *
22373  * This section contains code for working with the <link linkend="gdbus-interface-OldieInterface.top_of_page">OldieInterface</link> D-Bus interface in C.
22374  */
22375
22376 /* ---- Introspection data for OldieInterface ---- */
22377
22378 static const GDBusAnnotationInfo _foo_igen_oldie_interface_method_foo_annotation_info_0 =
22379 {
22380   -1,
22381   "org.freedesktop.DBus.Deprecated",
22382   "true",
22383   NULL
22384 };
22385
22386 static const GDBusAnnotationInfo * const _foo_igen_oldie_interface_method_foo_annotation_info_pointers[] =
22387 {
22388   &_foo_igen_oldie_interface_method_foo_annotation_info_0,
22389   NULL
22390 };
22391
22392 static const _ExtendedGDBusMethodInfo _foo_igen_oldie_interface_method_info_foo =
22393 {
22394   {
22395     -1,
22396     "Foo",
22397     NULL,
22398     NULL,
22399     (GDBusAnnotationInfo **) &_foo_igen_oldie_interface_method_foo_annotation_info_pointers
22400   },
22401   "handle-foo",
22402   FALSE
22403 };
22404
22405 static const _ExtendedGDBusMethodInfo * const _foo_igen_oldie_interface_method_info_pointers[] =
22406 {
22407   &_foo_igen_oldie_interface_method_info_foo,
22408   NULL
22409 };
22410
22411 static const GDBusAnnotationInfo _foo_igen_oldie_interface_signal_bar_annotation_info_0 =
22412 {
22413   -1,
22414   "org.freedesktop.DBus.Deprecated",
22415   "true",
22416   NULL
22417 };
22418
22419 static const GDBusAnnotationInfo * const _foo_igen_oldie_interface_signal_bar_annotation_info_pointers[] =
22420 {
22421   &_foo_igen_oldie_interface_signal_bar_annotation_info_0,
22422   NULL
22423 };
22424
22425 static const _ExtendedGDBusSignalInfo _foo_igen_oldie_interface_signal_info_bar =
22426 {
22427   {
22428     -1,
22429     "Bar",
22430     NULL,
22431     (GDBusAnnotationInfo **) &_foo_igen_oldie_interface_signal_bar_annotation_info_pointers
22432   },
22433   "bar"
22434 };
22435
22436 static const _ExtendedGDBusSignalInfo * const _foo_igen_oldie_interface_signal_info_pointers[] =
22437 {
22438   &_foo_igen_oldie_interface_signal_info_bar,
22439   NULL
22440 };
22441
22442 static const GDBusAnnotationInfo _foo_igen_oldie_interface_property_bat_annotation_info_0 =
22443 {
22444   -1,
22445   "org.freedesktop.DBus.Deprecated",
22446   "true",
22447   NULL
22448 };
22449
22450 static const GDBusAnnotationInfo * const _foo_igen_oldie_interface_property_bat_annotation_info_pointers[] =
22451 {
22452   &_foo_igen_oldie_interface_property_bat_annotation_info_0,
22453   NULL
22454 };
22455
22456 static const _ExtendedGDBusPropertyInfo _foo_igen_oldie_interface_property_info_bat =
22457 {
22458   {
22459     -1,
22460     "Bat",
22461     "i",
22462     G_DBUS_PROPERTY_INFO_FLAGS_READABLE | G_DBUS_PROPERTY_INFO_FLAGS_WRITABLE,
22463     (GDBusAnnotationInfo **) &_foo_igen_oldie_interface_property_bat_annotation_info_pointers
22464   },
22465   "bat",
22466   FALSE
22467 };
22468
22469 static const _ExtendedGDBusPropertyInfo * const _foo_igen_oldie_interface_property_info_pointers[] =
22470 {
22471   &_foo_igen_oldie_interface_property_info_bat,
22472   NULL
22473 };
22474
22475 static const GDBusAnnotationInfo _foo_igen_oldie_interface_annotation_info_0 =
22476 {
22477   -1,
22478   "org.freedesktop.DBus.Deprecated",
22479   "true",
22480   NULL
22481 };
22482
22483 static const GDBusAnnotationInfo * const _foo_igen_oldie_interface_annotation_info_pointers[] =
22484 {
22485   &_foo_igen_oldie_interface_annotation_info_0,
22486   NULL
22487 };
22488
22489 static const _ExtendedGDBusInterfaceInfo _foo_igen_oldie_interface_interface_info =
22490 {
22491   {
22492     -1,
22493     "OldieInterface",
22494     (GDBusMethodInfo **) &_foo_igen_oldie_interface_method_info_pointers,
22495     (GDBusSignalInfo **) &_foo_igen_oldie_interface_signal_info_pointers,
22496     (GDBusPropertyInfo **) &_foo_igen_oldie_interface_property_info_pointers,
22497     (GDBusAnnotationInfo **) &_foo_igen_oldie_interface_annotation_info_pointers
22498   },
22499   "oldie-interface",
22500 };
22501
22502
22503 /**
22504  * foo_igen_oldie_interface_interface_info:
22505  *
22506  * Gets a machine-readable description of the <link linkend="gdbus-interface-OldieInterface.top_of_page">OldieInterface</link> D-Bus interface.
22507  *
22508  * Returns: (transfer none): A #GDBusInterfaceInfo. Do not free.
22509  *
22510  * Deprecated: The D-Bus interface has been deprecated.
22511  */
22512 GDBusInterfaceInfo *
22513 foo_igen_oldie_interface_interface_info (void)
22514 {
22515   return (GDBusInterfaceInfo *) &_foo_igen_oldie_interface_interface_info;
22516 }
22517
22518 /**
22519  * foo_igen_oldie_interface_override_properties:
22520  * @klass: The class structure for a #GObject<!-- -->-derived class.
22521  * @property_id_begin: The property id to assign to the first overridden property.
22522  *
22523  * Overrides all #GObject properties in the #FooiGenOldieInterface interface for a concrete class.
22524  * The properties are overridden in the order they are defined.
22525  *
22526  * Returns: The last property id.
22527  *
22528  * Deprecated: The D-Bus interface has been deprecated.
22529  */
22530 guint
22531 foo_igen_oldie_interface_override_properties (GObjectClass *klass, guint property_id_begin)
22532 {
22533   g_object_class_override_property (klass, property_id_begin++, "bat");
22534   return property_id_begin - 1;
22535 }
22536
22537
22538
22539 /**
22540  * FooiGenOldieInterface:
22541  *
22542  * Abstract interface type for the D-Bus interface <link linkend="gdbus-interface-OldieInterface.top_of_page">OldieInterface</link>.
22543  *
22544  * Deprecated: The D-Bus interface has been deprecated.
22545  */
22546
22547 /**
22548  * FooiGenOldieInterfaceIface:
22549  * @parent_iface: The parent interface.
22550  * @handle_foo: Handler for the #FooiGenOldieInterface::handle-foo signal.
22551  * @get_bat: Getter for the #FooiGenOldieInterface:bat property.
22552  * @bar: Handler for the #FooiGenOldieInterface::bar signal.
22553  *
22554  * Virtual table for the D-Bus interface <link linkend="gdbus-interface-OldieInterface.top_of_page">OldieInterface</link>.
22555  *
22556  * Deprecated: The D-Bus interface has been deprecated.
22557  */
22558
22559 static void
22560 foo_igen_oldie_interface_default_init (FooiGenOldieInterfaceIface *iface)
22561 {
22562   /* GObject signals for incoming D-Bus method calls: */
22563   /**
22564    * FooiGenOldieInterface::handle-foo:
22565    * @object: A #FooiGenOldieInterface.
22566    * @invocation: A #GDBusMethodInvocation.
22567    *
22568    * Signal emitted when a remote caller is invoking the <link linkend="gdbus-method-OldieInterface.Foo">Foo()</link> D-Bus method.
22569    *
22570    * If a signal handler returns %TRUE, it means the signal handler will handle the invocation (e.g. take a reference to @invocation and eventually call foo_igen_oldie_interface_complete_foo() or e.g. g_dbus_method_invocation_return_error() on it) and no order signal handlers will run. If no signal handler handles the invocation, the %G_DBUS_ERROR_UNKNOWN_METHOD error is returned.
22571    *
22572    * Returns: %TRUE if the invocation was handled, %FALSE to let other signal handlers run.
22573    *
22574    * Deprecated: The D-Bus method has been deprecated.
22575    */
22576   g_signal_new ("handle-foo",
22577     G_TYPE_FROM_INTERFACE (iface),
22578     G_SIGNAL_RUN_LAST,
22579     G_STRUCT_OFFSET (FooiGenOldieInterfaceIface, handle_foo),
22580     g_signal_accumulator_true_handled,
22581     NULL,
22582     g_cclosure_marshal_generic,
22583     G_TYPE_BOOLEAN,
22584     1,
22585     G_TYPE_DBUS_METHOD_INVOCATION);
22586
22587   /* GObject signals for received D-Bus signals: */
22588   /**
22589    * FooiGenOldieInterface::bar:
22590    * @object: A #FooiGenOldieInterface.
22591    *
22592    * On the client-side, this signal is emitted whenever the D-Bus signal <link linkend="gdbus-signal-OldieInterface.Bar">"Bar"</link> is received.
22593    *
22594    * On the service-side, this signal can be used with e.g. g_signal_emit_by_name() to make the object emit the D-Bus signal.
22595    *
22596    * Deprecated: The D-Bus signal has been deprecated.
22597    */
22598   g_signal_new ("bar",
22599     G_TYPE_FROM_INTERFACE (iface),
22600     G_SIGNAL_RUN_LAST,
22601     G_STRUCT_OFFSET (FooiGenOldieInterfaceIface, bar),
22602     NULL,
22603     NULL,
22604     g_cclosure_marshal_generic,
22605     G_TYPE_NONE,
22606     0);
22607
22608   /* GObject properties for D-Bus properties: */
22609   /**
22610    * FooiGenOldieInterface:bat:
22611    *
22612    * Represents the D-Bus property <link linkend="gdbus-property-OldieInterface.Bat">"Bat"</link>.
22613    *
22614    * Since the D-Bus property for this #GObject property is both readable and writable, it is meaningful to both read from it and write to it on both the service- and client-side.
22615    *
22616    * Deprecated: The D-Bus property has been deprecated.
22617    */
22618   g_object_interface_install_property (iface,
22619     g_param_spec_int ("bat", "Bat", "Bat", G_MININT32, G_MAXINT32, 0, G_PARAM_READWRITE | G_PARAM_STATIC_STRINGS));
22620 }
22621
22622 typedef FooiGenOldieInterfaceIface FooiGenOldieInterfaceInterface;
22623 G_DEFINE_INTERFACE (FooiGenOldieInterface, foo_igen_oldie_interface, G_TYPE_OBJECT);
22624
22625 /**
22626  * foo_igen_oldie_interface_get_bat: (skip)
22627  * @object: A #FooiGenOldieInterface.
22628  *
22629  * Gets the value of the <link linkend="gdbus-property-OldieInterface.Bat">"Bat"</link> D-Bus property.
22630  *
22631  * Since this D-Bus property is both readable and writable, it is meaningful to use this function on both the client- and service-side.
22632  *
22633  * Returns: The property value.
22634  *
22635  * Deprecated: The D-Bus property has been deprecated.
22636  */
22637 gint 
22638 foo_igen_oldie_interface_get_bat (FooiGenOldieInterface *object)
22639 {
22640   return FOO_IGEN_OLDIE_INTERFACE_GET_IFACE (object)->get_bat (object);
22641 }
22642
22643 /**
22644  * foo_igen_oldie_interface_set_bat: (skip)
22645  * @object: A #FooiGenOldieInterface.
22646  * @value: The value to set.
22647  *
22648  * Sets the <link linkend="gdbus-property-OldieInterface.Bat">"Bat"</link> D-Bus property to @value.
22649  *
22650  * Since this D-Bus property is both readable and writable, it is meaningful to use this function on both the client- and service-side.
22651  *
22652  * Deprecated: The D-Bus property has been deprecated.
22653  */
22654 void
22655 foo_igen_oldie_interface_set_bat (FooiGenOldieInterface *object, gint value)
22656 {
22657   g_object_set (G_OBJECT (object), "bat", value, NULL);
22658 }
22659
22660 /**
22661  * foo_igen_oldie_interface_emit_bar:
22662  * @object: A #FooiGenOldieInterface.
22663  *
22664  * Emits the <link linkend="gdbus-signal-OldieInterface.Bar">"Bar"</link> D-Bus signal.
22665  *
22666  * Deprecated: The D-Bus signal has been deprecated.
22667  */
22668 void
22669 foo_igen_oldie_interface_emit_bar (
22670     FooiGenOldieInterface *object)
22671 {
22672   g_signal_emit_by_name (object, "bar");
22673 }
22674
22675 /**
22676  * foo_igen_oldie_interface_call_foo:
22677  * @proxy: A #FooiGenOldieInterfaceProxy.
22678  * @cancellable: (allow-none): A #GCancellable or %NULL.
22679  * @callback: A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
22680  * @user_data: User data to pass to @callback.
22681  *
22682  * Asynchronously invokes the <link linkend="gdbus-method-OldieInterface.Foo">Foo()</link> D-Bus method on @proxy.
22683  * When the operation is finished, @callback will be invoked in the <link linkend="g-main-context-push-thread-default">thread-default main loop</link> of the thread you are calling this method from.
22684  * You can then call foo_igen_oldie_interface_call_foo_finish() to get the result of the operation.
22685  *
22686  * See foo_igen_oldie_interface_call_foo_sync() for the synchronous, blocking version of this method.
22687  *
22688  * Deprecated: The D-Bus method has been deprecated.
22689  */
22690 void
22691 foo_igen_oldie_interface_call_foo (
22692     FooiGenOldieInterface *proxy,
22693     GCancellable *cancellable,
22694     GAsyncReadyCallback callback,
22695     gpointer user_data)
22696 {
22697   g_dbus_proxy_call (G_DBUS_PROXY (proxy),
22698     "Foo",
22699     g_variant_new ("()"),
22700     G_DBUS_CALL_FLAGS_NONE,
22701     -1,
22702     cancellable,
22703     callback,
22704     user_data);
22705 }
22706
22707 /**
22708  * foo_igen_oldie_interface_call_foo_finish:
22709  * @proxy: A #FooiGenOldieInterfaceProxy.
22710  * @res: The #GAsyncResult obtained from the #GAsyncReadyCallback passed to foo_igen_oldie_interface_call_foo().
22711  * @error: Return location for error or %NULL.
22712  *
22713  * Finishes an operation started with foo_igen_oldie_interface_call_foo().
22714  *
22715  * Returns: (skip): %TRUE if the call succeded, %FALSE if @error is set.
22716  *
22717  * Deprecated: The D-Bus method has been deprecated.
22718  */
22719 gboolean
22720 foo_igen_oldie_interface_call_foo_finish (
22721     FooiGenOldieInterface *proxy,
22722     GAsyncResult *res,
22723     GError **error)
22724 {
22725   GVariant *_ret;
22726   _ret = g_dbus_proxy_call_finish (G_DBUS_PROXY (proxy), res, error);
22727   if (_ret == NULL)
22728     goto _out;
22729   g_variant_get (_ret,
22730                  "()");
22731   g_variant_unref (_ret);
22732 _out:
22733   return _ret != NULL;
22734 }
22735
22736 /**
22737  * foo_igen_oldie_interface_call_foo_sync:
22738  * @proxy: A #FooiGenOldieInterfaceProxy.
22739  * @cancellable: (allow-none): A #GCancellable or %NULL.
22740  * @error: Return location for error or %NULL.
22741  *
22742  * Synchronously invokes the <link linkend="gdbus-method-OldieInterface.Foo">Foo()</link> D-Bus method on @proxy. The calling thread is blocked until a reply is received.
22743  *
22744  * See foo_igen_oldie_interface_call_foo() for the asynchronous version of this method.
22745  *
22746  * Returns: (skip): %TRUE if the call succeded, %FALSE if @error is set.
22747  *
22748  * Deprecated: The D-Bus method has been deprecated.
22749  */
22750 gboolean
22751 foo_igen_oldie_interface_call_foo_sync (
22752     FooiGenOldieInterface *proxy,
22753     GCancellable *cancellable,
22754     GError **error)
22755 {
22756   GVariant *_ret;
22757   _ret = g_dbus_proxy_call_sync (G_DBUS_PROXY (proxy),
22758     "Foo",
22759     g_variant_new ("()"),
22760     G_DBUS_CALL_FLAGS_NONE,
22761     -1,
22762     cancellable,
22763     error);
22764   if (_ret == NULL)
22765     goto _out;
22766   g_variant_get (_ret,
22767                  "()");
22768   g_variant_unref (_ret);
22769 _out:
22770   return _ret != NULL;
22771 }
22772
22773 /**
22774  * foo_igen_oldie_interface_complete_foo:
22775  * @object: A #FooiGenOldieInterface.
22776  * @invocation: (transfer full): A #GDBusMethodInvocation.
22777  *
22778  * Helper function used in service implementations to finish handling invocations of the <link linkend="gdbus-method-OldieInterface.Foo">Foo()</link> D-Bus method. If you instead want to finish handling an invocation by returning an error, use g_dbus_method_invocation_return_error() or similar.
22779  *
22780  * This method will free @invocation, you cannot use it afterwards.
22781  *
22782  * Deprecated: The D-Bus method has been deprecated.
22783  */
22784 void
22785 foo_igen_oldie_interface_complete_foo (
22786     FooiGenOldieInterface *object,
22787     GDBusMethodInvocation *invocation)
22788 {
22789   g_dbus_method_invocation_return_value (invocation,
22790     g_variant_new ("()"));
22791 }
22792
22793 /* ------------------------------------------------------------------------ */
22794
22795 /**
22796  * FooiGenOldieInterfaceProxy:
22797  *
22798  * The #FooiGenOldieInterfaceProxy structure contains only private data and should only be accessed using the provided API.
22799  *
22800  * Deprecated: The D-Bus interface has been deprecated.
22801  */
22802
22803 /**
22804  * FooiGenOldieInterfaceProxyClass:
22805  * @parent_class: The parent class.
22806  *
22807  * Class structure for #FooiGenOldieInterfaceProxy.
22808  *
22809  * Deprecated: The D-Bus interface has been deprecated.
22810  */
22811
22812 struct _FooiGenOldieInterfaceProxyPrivate
22813 {
22814   GData *qdata;
22815 };
22816
22817 static void foo_igen_oldie_interface_proxy_iface_init (FooiGenOldieInterfaceIface *iface);
22818
22819 G_DEFINE_TYPE_WITH_CODE (FooiGenOldieInterfaceProxy, foo_igen_oldie_interface_proxy, G_TYPE_DBUS_PROXY,
22820                          G_IMPLEMENT_INTERFACE (FOO_IGEN_TYPE_OLDIE_INTERFACE, foo_igen_oldie_interface_proxy_iface_init));
22821
22822 static void
22823 foo_igen_oldie_interface_proxy_finalize (GObject *object)
22824 {
22825   FooiGenOldieInterfaceProxy *proxy = FOO_IGEN_OLDIE_INTERFACE_PROXY (object);
22826   g_datalist_clear (&proxy->priv->qdata);
22827   G_OBJECT_CLASS (foo_igen_oldie_interface_proxy_parent_class)->finalize (object);
22828 }
22829
22830 static void
22831 foo_igen_oldie_interface_proxy_get_property (GObject      *object,
22832   guint         prop_id,
22833   GValue       *value,
22834   GParamSpec   *pspec)
22835 {
22836   const _ExtendedGDBusPropertyInfo *info;
22837   GVariant *variant;
22838   g_assert (prop_id != 0 && prop_id - 1 < 1);
22839   info = _foo_igen_oldie_interface_property_info_pointers[prop_id - 1];
22840   variant = g_dbus_proxy_get_cached_property (G_DBUS_PROXY (object), info->parent_struct.name);
22841   if (info->use_gvariant)
22842     {
22843       g_value_set_variant (value, variant);
22844     }
22845   else
22846     {
22847       if (variant != NULL)
22848         g_dbus_gvariant_to_gvalue (variant, value);
22849     }
22850   if (variant != NULL)
22851     g_variant_unref (variant);
22852 }
22853
22854 static void
22855 foo_igen_oldie_interface_proxy_set_property_cb (GDBusProxy *proxy,
22856   GAsyncResult *res,
22857   gpointer      user_data)
22858 {
22859   const _ExtendedGDBusPropertyInfo *info = user_data;
22860   GError *error;
22861   error = NULL;
22862   if (!g_dbus_proxy_call_finish (proxy, res, &error))
22863     {
22864       g_warning ("Error setting property `%s' on interface OldieInterface: %s (%s, %d)",
22865                  info->parent_struct.name, 
22866                  error->message, g_quark_to_string (error->domain), error->code);
22867       g_error_free (error);
22868     }
22869 }
22870
22871 static void
22872 foo_igen_oldie_interface_proxy_set_property (GObject      *object,
22873   guint         prop_id,
22874   const GValue *value,
22875   GParamSpec   *pspec)
22876 {
22877   const _ExtendedGDBusPropertyInfo *info;
22878   GVariant *variant;
22879   g_assert (prop_id != 0 && prop_id - 1 < 1);
22880   info = _foo_igen_oldie_interface_property_info_pointers[prop_id - 1];
22881   variant = g_dbus_gvalue_to_gvariant (value, G_VARIANT_TYPE (info->parent_struct.signature));
22882   g_dbus_proxy_call (G_DBUS_PROXY (object),
22883     "org.freedesktop.DBus.Properties.Set",
22884     g_variant_new ("(ssv)", "OldieInterface", info->parent_struct.name, variant),
22885     G_DBUS_CALL_FLAGS_NONE,
22886     -1,
22887     NULL, (GAsyncReadyCallback) foo_igen_oldie_interface_proxy_set_property_cb, (gpointer) info);
22888   g_variant_unref (variant);
22889 }
22890
22891 static void
22892 foo_igen_oldie_interface_proxy_g_signal (GDBusProxy *proxy,
22893   const gchar *sender_name,
22894   const gchar *signal_name,
22895   GVariant *parameters)
22896 {
22897   _ExtendedGDBusSignalInfo *info;
22898   GVariantIter iter;
22899   GVariant *child;
22900   GValue *paramv;
22901   guint num_params;
22902   guint n;
22903   guint signal_id;
22904   info = (_ExtendedGDBusSignalInfo *) g_dbus_interface_info_lookup_signal ((GDBusInterfaceInfo *) &_foo_igen_oldie_interface_interface_info, signal_name);
22905   if (info == NULL)
22906     return;
22907   num_params = g_variant_n_children (parameters);
22908   paramv = g_new0 (GValue, num_params + 1);
22909   g_value_init (&paramv[0], FOO_IGEN_TYPE_OLDIE_INTERFACE);
22910   g_value_set_object (&paramv[0], proxy);
22911   g_variant_iter_init (&iter, parameters);
22912   n = 1;
22913   while ((child = g_variant_iter_next_value (&iter)) != NULL)
22914     {
22915       _ExtendedGDBusArgInfo *arg_info = (_ExtendedGDBusArgInfo *) info->parent_struct.args[n - 1];
22916       if (arg_info->use_gvariant)
22917         {
22918           g_value_init (&paramv[n], G_TYPE_VARIANT);
22919           g_value_set_variant (&paramv[n], child);
22920           n++;
22921         }
22922       else
22923         g_dbus_gvariant_to_gvalue (child, &paramv[n++]);
22924       g_variant_unref (child);
22925     }
22926   signal_id = g_signal_lookup (info->signal_name, FOO_IGEN_TYPE_OLDIE_INTERFACE);
22927   g_signal_emitv (paramv, signal_id, 0, NULL);
22928   for (n = 0; n < num_params + 1; n++)
22929     g_value_unset (&paramv[n]);
22930   g_free (paramv);
22931 }
22932
22933 static void
22934 foo_igen_oldie_interface_proxy_g_properties_changed (GDBusProxy *_proxy,
22935   GVariant *changed_properties,
22936   const gchar *const *invalidated_properties)
22937 {
22938   FooiGenOldieInterfaceProxy *proxy = FOO_IGEN_OLDIE_INTERFACE_PROXY (_proxy);
22939   guint n;
22940   const gchar *key;
22941   GVariantIter *iter;
22942   _ExtendedGDBusPropertyInfo *info;
22943   g_variant_get (changed_properties, "a{sv}", &iter);
22944   while (g_variant_iter_next (iter, "{&sv}", &key, NULL))
22945     {
22946       info = (_ExtendedGDBusPropertyInfo *) g_dbus_interface_info_lookup_property ((GDBusInterfaceInfo *) &_foo_igen_oldie_interface_interface_info, key);
22947       g_datalist_remove_data (&proxy->priv->qdata, key);
22948       if (info != NULL)
22949         g_object_notify (G_OBJECT (proxy), info->hyphen_name);
22950     }
22951   g_variant_iter_free (iter);
22952   for (n = 0; invalidated_properties[n] != NULL; n++)
22953     {
22954       info = (_ExtendedGDBusPropertyInfo *) g_dbus_interface_info_lookup_property ((GDBusInterfaceInfo *) &_foo_igen_oldie_interface_interface_info, invalidated_properties[n]);
22955       g_datalist_remove_data (&proxy->priv->qdata, invalidated_properties[n]);
22956       if (info != NULL)
22957         g_object_notify (G_OBJECT (proxy), info->hyphen_name);
22958     }
22959 }
22960
22961 static gint 
22962 foo_igen_oldie_interface_proxy_get_bat (FooiGenOldieInterface *object)
22963 {
22964   FooiGenOldieInterfaceProxy *proxy = FOO_IGEN_OLDIE_INTERFACE_PROXY (object);
22965   GVariant *variant;
22966   gint value = 0;
22967   variant = g_dbus_proxy_get_cached_property (G_DBUS_PROXY (proxy), "Bat");
22968   if (variant != NULL)
22969     {
22970       value = g_variant_get_int32 (variant);
22971       g_variant_unref (variant);
22972     }
22973   return value;
22974 }
22975
22976 static void
22977 foo_igen_oldie_interface_proxy_init (FooiGenOldieInterfaceProxy *proxy)
22978 {
22979   proxy->priv = G_TYPE_INSTANCE_GET_PRIVATE (proxy, FOO_IGEN_TYPE_OLDIE_INTERFACE_PROXY, FooiGenOldieInterfaceProxyPrivate);
22980   g_dbus_proxy_set_interface_info (G_DBUS_PROXY (proxy), foo_igen_oldie_interface_interface_info ());
22981 }
22982
22983 static void
22984 foo_igen_oldie_interface_proxy_class_init (FooiGenOldieInterfaceProxyClass *klass)
22985 {
22986   GObjectClass *gobject_class;
22987   GDBusProxyClass *proxy_class;
22988
22989   g_type_class_add_private (klass, sizeof (FooiGenOldieInterfaceProxyPrivate));
22990
22991   gobject_class = G_OBJECT_CLASS (klass);
22992   gobject_class->finalize     = foo_igen_oldie_interface_proxy_finalize;
22993   gobject_class->get_property = foo_igen_oldie_interface_proxy_get_property;
22994   gobject_class->set_property = foo_igen_oldie_interface_proxy_set_property;
22995
22996   proxy_class = G_DBUS_PROXY_CLASS (klass);
22997   proxy_class->g_signal = foo_igen_oldie_interface_proxy_g_signal;
22998   proxy_class->g_properties_changed = foo_igen_oldie_interface_proxy_g_properties_changed;
22999
23000
23001   foo_igen_oldie_interface_override_properties (gobject_class, 1);
23002 }
23003
23004 static void
23005 foo_igen_oldie_interface_proxy_iface_init (FooiGenOldieInterfaceIface *iface)
23006 {
23007   iface->get_bat = foo_igen_oldie_interface_proxy_get_bat;
23008 }
23009
23010 /**
23011  * foo_igen_oldie_interface_proxy_new:
23012  * @connection: A #GDBusConnection.
23013  * @flags: Flags from the #GDBusProxyFlags enumeration.
23014  * @name: (allow-none): A bus name (well-known or unique) or %NULL if @connection is not a message bus connection.
23015  * @object_path: An object path.
23016  * @cancellable: (allow-none): A #GCancellable or %NULL.
23017  * @callback: A #GAsyncReadyCallback to call when the request is satisfied.
23018  * @user_data: User data to pass to @callback.
23019  *
23020  * Asynchronously creates a proxy for the D-Bus interface <link linkend="gdbus-interface-OldieInterface.top_of_page">OldieInterface</link>. See g_dbus_proxy_new() for more details.
23021  *
23022  * When the operation is finished, @callback will be invoked in the <link linkend="g-main-context-push-thread-default">thread-default main loop</link> of the thread you are calling this method from.
23023  * You can then call foo_igen_oldie_interface_proxy_new_finish() to get the result of the operation.
23024  *
23025  * See foo_igen_oldie_interface_proxy_new_sync() for the synchronous, blocking version of this constructor.
23026  *
23027  * Deprecated: The D-Bus interface has been deprecated.
23028  */
23029 void
23030 foo_igen_oldie_interface_proxy_new (
23031     GDBusConnection     *connection,
23032     GDBusProxyFlags      flags,
23033     const gchar         *name,
23034     const gchar         *object_path,
23035     GCancellable        *cancellable,
23036     GAsyncReadyCallback  callback,
23037     gpointer             user_data)
23038 {
23039   g_async_initable_new_async (FOO_IGEN_TYPE_OLDIE_INTERFACE_PROXY, G_PRIORITY_DEFAULT, cancellable, callback, user_data, "g-flags", flags, "g-name", name, "g-connection", connection, "g-object-path", object_path, "g-interface-name", "OldieInterface", NULL);
23040 }
23041
23042 /**
23043  * foo_igen_oldie_interface_proxy_new_finish:
23044  * @res: The #GAsyncResult obtained from the #GAsyncReadyCallback passed to foo_igen_oldie_interface_proxy_new().
23045  * @error: Return location for error or %NULL
23046  *
23047  * Finishes an operation started with foo_igen_oldie_interface_proxy_new().
23048  *
23049  * Returns: (transfer full) (type FooiGenOldieInterfaceProxy): The constructed proxy object or %NULL if @error is set.
23050  *
23051  * Deprecated: The D-Bus interface has been deprecated.
23052  */
23053 FooiGenOldieInterface *
23054 foo_igen_oldie_interface_proxy_new_finish (
23055     GAsyncResult        *res,
23056     GError             **error)
23057 {
23058   GObject *ret;
23059   GObject *source_object;
23060   source_object = g_async_result_get_source_object (res);
23061   ret = g_async_initable_new_finish (G_ASYNC_INITABLE (source_object), res, error);
23062   g_object_unref (source_object);
23063   if (ret != NULL)
23064     return FOO_IGEN_OLDIE_INTERFACE (ret);
23065   else
23066     return NULL;
23067 }
23068
23069 /**
23070  * foo_igen_oldie_interface_proxy_new_sync:
23071  * @connection: A #GDBusConnection.
23072  * @flags: Flags from the #GDBusProxyFlags enumeration.
23073  * @name: (allow-none): A bus name (well-known or unique) or %NULL if @connection is not a message bus connection.
23074  * @object_path: An object path.
23075  * @cancellable: (allow-none): A #GCancellable or %NULL.
23076  * @error: Return location for error or %NULL
23077  *
23078  * Synchronously creates a proxy for the D-Bus interface <link linkend="gdbus-interface-OldieInterface.top_of_page">OldieInterface</link>. See g_dbus_proxy_new_sync() for more details.
23079  *
23080  * The calling thread is blocked until a reply is received.
23081  *
23082  * See foo_igen_oldie_interface_proxy_new() for the asynchronous version of this constructor.
23083  *
23084  * Returns: (transfer full) (type FooiGenOldieInterfaceProxy): The constructed proxy object or %NULL if @error is set.
23085  *
23086  * Deprecated: The D-Bus interface has been deprecated.
23087  */
23088 FooiGenOldieInterface *
23089 foo_igen_oldie_interface_proxy_new_sync (
23090     GDBusConnection     *connection,
23091     GDBusProxyFlags      flags,
23092     const gchar         *name,
23093     const gchar         *object_path,
23094     GCancellable        *cancellable,
23095     GError             **error)
23096 {
23097   GInitable *ret;
23098   ret = g_initable_new (FOO_IGEN_TYPE_OLDIE_INTERFACE_PROXY, cancellable, error, "g-flags", flags, "g-name", name, "g-connection", connection, "g-object-path", object_path, "g-interface-name", "OldieInterface", NULL);
23099   if (ret != NULL)
23100     return FOO_IGEN_OLDIE_INTERFACE (ret);
23101   else
23102     return NULL;
23103 }
23104
23105
23106 /**
23107  * foo_igen_oldie_interface_proxy_new_for_bus:
23108  * @bus_type: A #GBusType.
23109  * @flags: Flags from the #GDBusProxyFlags enumeration.
23110  * @name: A bus name (well-known or unique).
23111  * @object_path: An object path.
23112  * @cancellable: (allow-none): A #GCancellable or %NULL.
23113  * @callback: A #GAsyncReadyCallback to call when the request is satisfied.
23114  * @user_data: User data to pass to @callback.
23115  *
23116  * Like foo_igen_oldie_interface_proxy_new() but takes a #GBusType instead of a #GDBusConnection.
23117  *
23118  * When the operation is finished, @callback will be invoked in the <link linkend="g-main-context-push-thread-default">thread-default main loop</link> of the thread you are calling this method from.
23119  * You can then call foo_igen_oldie_interface_proxy_new_for_bus_finish() to get the result of the operation.
23120  *
23121  * See foo_igen_oldie_interface_proxy_new_for_bus_sync() for the synchronous, blocking version of this constructor.
23122  *
23123  * Deprecated: The D-Bus interface has been deprecated.
23124  */
23125 void
23126 foo_igen_oldie_interface_proxy_new_for_bus (
23127     GBusType             bus_type,
23128     GDBusProxyFlags      flags,
23129     const gchar         *name,
23130     const gchar         *object_path,
23131     GCancellable        *cancellable,
23132     GAsyncReadyCallback  callback,
23133     gpointer             user_data)
23134 {
23135   g_async_initable_new_async (FOO_IGEN_TYPE_OLDIE_INTERFACE_PROXY, G_PRIORITY_DEFAULT, cancellable, callback, user_data, "g-flags", flags, "g-name", name, "g-bus-type", bus_type, "g-object-path", object_path, "g-interface-name", "OldieInterface", NULL);
23136 }
23137
23138 /**
23139  * foo_igen_oldie_interface_proxy_new_for_bus_finish:
23140  * @res: The #GAsyncResult obtained from the #GAsyncReadyCallback passed to foo_igen_oldie_interface_proxy_new_for_bus().
23141  * @error: Return location for error or %NULL
23142  *
23143  * Finishes an operation started with foo_igen_oldie_interface_proxy_new_for_bus().
23144  *
23145  * Returns: (transfer full) (type FooiGenOldieInterfaceProxy): The constructed proxy object or %NULL if @error is set.
23146  *
23147  * Deprecated: The D-Bus interface has been deprecated.
23148  */
23149 FooiGenOldieInterface *
23150 foo_igen_oldie_interface_proxy_new_for_bus_finish (
23151     GAsyncResult        *res,
23152     GError             **error)
23153 {
23154   GObject *ret;
23155   GObject *source_object;
23156   source_object = g_async_result_get_source_object (res);
23157   ret = g_async_initable_new_finish (G_ASYNC_INITABLE (source_object), res, error);
23158   g_object_unref (source_object);
23159   if (ret != NULL)
23160     return FOO_IGEN_OLDIE_INTERFACE (ret);
23161   else
23162     return NULL;
23163 }
23164
23165 /**
23166  * foo_igen_oldie_interface_proxy_new_for_bus_sync:
23167  * @bus_type: A #GBusType.
23168  * @flags: Flags from the #GDBusProxyFlags enumeration.
23169  * @name: A bus name (well-known or unique).
23170  * @object_path: An object path.
23171  * @cancellable: (allow-none): A #GCancellable or %NULL.
23172  * @error: Return location for error or %NULL
23173  *
23174  * Like foo_igen_oldie_interface_proxy_new_sync() but takes a #GBusType instead of a #GDBusConnection.
23175  *
23176  * The calling thread is blocked until a reply is received.
23177  *
23178  * See foo_igen_oldie_interface_proxy_new_for_bus() for the asynchronous version of this constructor.
23179  *
23180  * Returns: (transfer full) (type FooiGenOldieInterfaceProxy): The constructed proxy object or %NULL if @error is set.
23181  *
23182  * Deprecated: The D-Bus interface has been deprecated.
23183  */
23184 FooiGenOldieInterface *
23185 foo_igen_oldie_interface_proxy_new_for_bus_sync (
23186     GBusType             bus_type,
23187     GDBusProxyFlags      flags,
23188     const gchar         *name,
23189     const gchar         *object_path,
23190     GCancellable        *cancellable,
23191     GError             **error)
23192 {
23193   GInitable *ret;
23194   ret = g_initable_new (FOO_IGEN_TYPE_OLDIE_INTERFACE_PROXY, cancellable, error, "g-flags", flags, "g-name", name, "g-bus-type", bus_type, "g-object-path", object_path, "g-interface-name", "OldieInterface", NULL);
23195   if (ret != NULL)
23196     return FOO_IGEN_OLDIE_INTERFACE (ret);
23197   else
23198     return NULL;
23199 }
23200
23201
23202 /* ------------------------------------------------------------------------ */
23203
23204 /**
23205  * FooiGenOldieInterfaceSkeleton:
23206  *
23207  * The #FooiGenOldieInterfaceSkeleton structure contains only private data and should only be accessed using the provided API.
23208  *
23209  * Deprecated: The D-Bus interface has been deprecated.
23210  */
23211
23212 /**
23213  * FooiGenOldieInterfaceSkeletonClass:
23214  * @parent_class: The parent class.
23215  *
23216  * Class structure for #FooiGenOldieInterfaceSkeleton.
23217  *
23218  * Deprecated: The D-Bus interface has been deprecated.
23219  */
23220
23221 struct _FooiGenOldieInterfaceSkeletonPrivate
23222 {
23223   GValue *properties;
23224   GList *changed_properties;
23225   GSource *changed_properties_idle_source;
23226   GMainContext *context;
23227   GMutex lock;
23228 };
23229
23230 static void
23231 _foo_igen_oldie_interface_skeleton_handle_method_call (
23232   GDBusConnection *connection,
23233   const gchar *sender,
23234   const gchar *object_path,
23235   const gchar *interface_name,
23236   const gchar *method_name,
23237   GVariant *parameters,
23238   GDBusMethodInvocation *invocation,
23239   gpointer user_data)
23240 {
23241   FooiGenOldieInterfaceSkeleton *skeleton = FOO_IGEN_OLDIE_INTERFACE_SKELETON (user_data);
23242   _ExtendedGDBusMethodInfo *info;
23243   GVariantIter iter;
23244   GVariant *child;
23245   GValue *paramv;
23246   guint num_params;
23247   guint num_extra;
23248   guint n;
23249   guint signal_id;
23250   GValue return_value = G_VALUE_INIT;
23251   info = (_ExtendedGDBusMethodInfo *) g_dbus_method_invocation_get_method_info (invocation);
23252   g_assert (info != NULL);
23253   num_params = g_variant_n_children (parameters);
23254   num_extra = info->pass_fdlist ? 3 : 2;  paramv = g_new0 (GValue, num_params + num_extra);
23255   n = 0;
23256   g_value_init (&paramv[n], FOO_IGEN_TYPE_OLDIE_INTERFACE);
23257   g_value_set_object (&paramv[n++], skeleton);
23258   g_value_init (&paramv[n], G_TYPE_DBUS_METHOD_INVOCATION);
23259   g_value_set_object (&paramv[n++], invocation);
23260   if (info->pass_fdlist)
23261     {
23262 #ifdef G_OS_UNIX
23263       g_value_init (&paramv[n], G_TYPE_UNIX_FD_LIST);
23264       g_value_set_object (&paramv[n++], g_dbus_message_get_unix_fd_list (g_dbus_method_invocation_get_message (invocation)));
23265 #else
23266       g_assert_not_reached ();
23267 #endif
23268     }
23269   g_variant_iter_init (&iter, parameters);
23270   while ((child = g_variant_iter_next_value (&iter)) != NULL)
23271     {
23272       _ExtendedGDBusArgInfo *arg_info = (_ExtendedGDBusArgInfo *) info->parent_struct.in_args[n - num_extra];
23273       if (arg_info->use_gvariant)
23274         {
23275           g_value_init (&paramv[n], G_TYPE_VARIANT);
23276           g_value_set_variant (&paramv[n], child);
23277           n++;
23278         }
23279       else
23280         g_dbus_gvariant_to_gvalue (child, &paramv[n++]);
23281       g_variant_unref (child);
23282     }
23283   signal_id = g_signal_lookup (info->signal_name, FOO_IGEN_TYPE_OLDIE_INTERFACE);
23284   g_value_init (&return_value, G_TYPE_BOOLEAN);
23285   g_signal_emitv (paramv, signal_id, 0, &return_value);
23286   if (!g_value_get_boolean (&return_value))
23287     g_dbus_method_invocation_return_error (invocation, G_DBUS_ERROR, G_DBUS_ERROR_UNKNOWN_METHOD, "Method %s is not implemented on interface %s", method_name, interface_name);
23288   g_value_unset (&return_value);
23289   for (n = 0; n < num_params + num_extra; n++)
23290     g_value_unset (&paramv[n]);
23291   g_free (paramv);
23292 }
23293
23294 static GVariant *
23295 _foo_igen_oldie_interface_skeleton_handle_get_property (
23296   GDBusConnection *connection,
23297   const gchar *sender,
23298   const gchar *object_path,
23299   const gchar *interface_name,
23300   const gchar *property_name,
23301   GError **error,
23302   gpointer user_data)
23303 {
23304   FooiGenOldieInterfaceSkeleton *skeleton = FOO_IGEN_OLDIE_INTERFACE_SKELETON (user_data);
23305   GValue value = G_VALUE_INIT;
23306   GParamSpec *pspec;
23307   _ExtendedGDBusPropertyInfo *info;
23308   GVariant *ret;
23309   ret = NULL;
23310   info = (_ExtendedGDBusPropertyInfo *) g_dbus_interface_info_lookup_property ((GDBusInterfaceInfo *) &_foo_igen_oldie_interface_interface_info, property_name);
23311   g_assert (info != NULL);
23312   pspec = g_object_class_find_property (G_OBJECT_GET_CLASS (skeleton), info->hyphen_name);
23313   if (pspec == NULL)
23314     {
23315       g_set_error (error, G_DBUS_ERROR, G_DBUS_ERROR_INVALID_ARGS, "No property with name %s", property_name);
23316     }
23317   else
23318     {
23319       g_value_init (&value, pspec->value_type);
23320       g_object_get_property (G_OBJECT (skeleton), info->hyphen_name, &value);
23321       ret = g_dbus_gvalue_to_gvariant (&value, G_VARIANT_TYPE (info->parent_struct.signature));
23322       g_value_unset (&value);
23323     }
23324   return ret;
23325 }
23326
23327 static gboolean
23328 _foo_igen_oldie_interface_skeleton_handle_set_property (
23329   GDBusConnection *connection,
23330   const gchar *sender,
23331   const gchar *object_path,
23332   const gchar *interface_name,
23333   const gchar *property_name,
23334   GVariant *variant,
23335   GError **error,
23336   gpointer user_data)
23337 {
23338   FooiGenOldieInterfaceSkeleton *skeleton = FOO_IGEN_OLDIE_INTERFACE_SKELETON (user_data);
23339   GValue value = G_VALUE_INIT;
23340   GParamSpec *pspec;
23341   _ExtendedGDBusPropertyInfo *info;
23342   gboolean ret;
23343   ret = FALSE;
23344   info = (_ExtendedGDBusPropertyInfo *) g_dbus_interface_info_lookup_property ((GDBusInterfaceInfo *) &_foo_igen_oldie_interface_interface_info, property_name);
23345   g_assert (info != NULL);
23346   pspec = g_object_class_find_property (G_OBJECT_GET_CLASS (skeleton), info->hyphen_name);
23347   if (pspec == NULL)
23348     {
23349       g_set_error (error, G_DBUS_ERROR, G_DBUS_ERROR_INVALID_ARGS, "No property with name %s", property_name);
23350     }
23351   else
23352     {
23353       if (info->use_gvariant)
23354         g_value_set_variant (&value, variant);
23355       else
23356         g_dbus_gvariant_to_gvalue (variant, &value);
23357       g_object_set_property (G_OBJECT (skeleton), info->hyphen_name, &value);
23358       g_value_unset (&value);
23359       ret = TRUE;
23360     }
23361   return ret;
23362 }
23363
23364 static const GDBusInterfaceVTable _foo_igen_oldie_interface_skeleton_vtable =
23365 {
23366   _foo_igen_oldie_interface_skeleton_handle_method_call,
23367   _foo_igen_oldie_interface_skeleton_handle_get_property,
23368   _foo_igen_oldie_interface_skeleton_handle_set_property
23369 };
23370
23371 static GDBusInterfaceInfo *
23372 foo_igen_oldie_interface_skeleton_dbus_interface_get_info (GDBusInterfaceSkeleton *skeleton)
23373 {
23374   return foo_igen_oldie_interface_interface_info ();
23375 }
23376
23377 static GDBusInterfaceVTable *
23378 foo_igen_oldie_interface_skeleton_dbus_interface_get_vtable (GDBusInterfaceSkeleton *skeleton)
23379 {
23380   return (GDBusInterfaceVTable *) &_foo_igen_oldie_interface_skeleton_vtable;
23381 }
23382
23383 static GVariant *
23384 foo_igen_oldie_interface_skeleton_dbus_interface_get_properties (GDBusInterfaceSkeleton *_skeleton)
23385 {
23386   FooiGenOldieInterfaceSkeleton *skeleton = FOO_IGEN_OLDIE_INTERFACE_SKELETON (_skeleton);
23387
23388   GVariantBuilder builder;
23389   guint n;
23390   g_variant_builder_init (&builder, G_VARIANT_TYPE ("a{sv}"));
23391   if (_foo_igen_oldie_interface_interface_info.parent_struct.properties == NULL)
23392     goto out;
23393   for (n = 0; _foo_igen_oldie_interface_interface_info.parent_struct.properties[n] != NULL; n++)
23394     {
23395       GDBusPropertyInfo *info = _foo_igen_oldie_interface_interface_info.parent_struct.properties[n];
23396       if (info->flags & G_DBUS_PROPERTY_INFO_FLAGS_READABLE)
23397         {
23398           GVariant *value;
23399           value = _foo_igen_oldie_interface_skeleton_handle_get_property (g_dbus_interface_skeleton_get_connection (G_DBUS_INTERFACE_SKELETON (skeleton)), NULL, g_dbus_interface_skeleton_get_object_path (G_DBUS_INTERFACE_SKELETON (skeleton)), "OldieInterface", info->name, NULL, skeleton);
23400           if (value != NULL)
23401             {
23402               g_variant_take_ref (value);
23403               g_variant_builder_add (&builder, "{sv}", info->name, value);
23404               g_variant_unref (value);
23405             }
23406         }
23407     }
23408 out:
23409   return g_variant_builder_end (&builder);
23410 }
23411
23412 static gboolean _foo_igen_oldie_interface_emit_changed (gpointer user_data);
23413
23414 static void
23415 foo_igen_oldie_interface_skeleton_dbus_interface_flush (GDBusInterfaceSkeleton *_skeleton)
23416 {
23417   FooiGenOldieInterfaceSkeleton *skeleton = FOO_IGEN_OLDIE_INTERFACE_SKELETON (_skeleton);
23418   gboolean emit_changed = FALSE;
23419
23420   g_mutex_lock (&skeleton->priv->lock);
23421   if (skeleton->priv->changed_properties_idle_source != NULL)
23422     {
23423       g_source_destroy (skeleton->priv->changed_properties_idle_source);
23424       skeleton->priv->changed_properties_idle_source = NULL;
23425       emit_changed = TRUE;
23426     }
23427   g_mutex_unlock (&skeleton->priv->lock);
23428
23429   if (emit_changed)
23430     _foo_igen_oldie_interface_emit_changed (skeleton);
23431 }
23432
23433 static void
23434 _foo_igen_oldie_interface_on_signal_bar (
23435     FooiGenOldieInterface *object)
23436 {
23437   FooiGenOldieInterfaceSkeleton *skeleton = FOO_IGEN_OLDIE_INTERFACE_SKELETON (object);
23438
23439   GList      *connections, *l;
23440   GVariant   *signal_variant;
23441   connections = g_dbus_interface_skeleton_get_connections (G_DBUS_INTERFACE_SKELETON (skeleton));
23442
23443   signal_variant = g_variant_ref_sink (g_variant_new ("()"));
23444   for (l = connections; l != NULL; l = l->next)
23445     {
23446       GDBusConnection *connection = l->data;
23447       g_dbus_connection_emit_signal (connection,
23448         NULL, g_dbus_interface_skeleton_get_object_path (G_DBUS_INTERFACE_SKELETON (skeleton)), "OldieInterface", "Bar",
23449         signal_variant, NULL);
23450     }
23451   g_variant_unref (signal_variant);
23452   g_list_free_full (connections, g_object_unref);
23453 }
23454
23455 static void foo_igen_oldie_interface_skeleton_iface_init (FooiGenOldieInterfaceIface *iface);
23456 G_DEFINE_TYPE_WITH_CODE (FooiGenOldieInterfaceSkeleton, foo_igen_oldie_interface_skeleton, G_TYPE_DBUS_INTERFACE_SKELETON,
23457                          G_IMPLEMENT_INTERFACE (FOO_IGEN_TYPE_OLDIE_INTERFACE, foo_igen_oldie_interface_skeleton_iface_init));
23458
23459 static void
23460 foo_igen_oldie_interface_skeleton_finalize (GObject *object)
23461 {
23462   FooiGenOldieInterfaceSkeleton *skeleton = FOO_IGEN_OLDIE_INTERFACE_SKELETON (object);
23463   guint n;
23464   for (n = 0; n < 1; n++)
23465     g_value_unset (&skeleton->priv->properties[n]);
23466   g_free (skeleton->priv->properties);
23467   g_list_free_full (skeleton->priv->changed_properties, (GDestroyNotify) _changed_property_free);
23468   if (skeleton->priv->changed_properties_idle_source != NULL)
23469     g_source_destroy (skeleton->priv->changed_properties_idle_source);
23470   g_main_context_unref (skeleton->priv->context);
23471   g_mutex_clear (&skeleton->priv->lock);
23472   G_OBJECT_CLASS (foo_igen_oldie_interface_skeleton_parent_class)->finalize (object);
23473 }
23474
23475 static void
23476 foo_igen_oldie_interface_skeleton_get_property (GObject      *object,
23477   guint         prop_id,
23478   GValue       *value,
23479   GParamSpec   *pspec)
23480 {
23481   FooiGenOldieInterfaceSkeleton *skeleton = FOO_IGEN_OLDIE_INTERFACE_SKELETON (object);
23482   g_assert (prop_id != 0 && prop_id - 1 < 1);
23483   g_mutex_lock (&skeleton->priv->lock);
23484   g_value_copy (&skeleton->priv->properties[prop_id - 1], value);
23485   g_mutex_unlock (&skeleton->priv->lock);
23486 }
23487
23488 static gboolean
23489 _foo_igen_oldie_interface_emit_changed (gpointer user_data)
23490 {
23491   FooiGenOldieInterfaceSkeleton *skeleton = FOO_IGEN_OLDIE_INTERFACE_SKELETON (user_data);
23492   GList *l;
23493   GVariantBuilder builder;
23494   GVariantBuilder invalidated_builder;
23495   guint num_changes;
23496
23497   g_mutex_lock (&skeleton->priv->lock);
23498   g_variant_builder_init (&builder, G_VARIANT_TYPE ("a{sv}"));
23499   g_variant_builder_init (&invalidated_builder, G_VARIANT_TYPE ("as"));
23500   for (l = skeleton->priv->changed_properties, num_changes = 0; l != NULL; l = l->next)
23501     {
23502       ChangedProperty *cp = l->data;
23503       GVariant *variant;
23504       const GValue *cur_value;
23505
23506       cur_value = &skeleton->priv->properties[cp->prop_id - 1];
23507       if (!_g_value_equal (cur_value, &cp->orig_value))
23508         {
23509           variant = g_dbus_gvalue_to_gvariant (cur_value, G_VARIANT_TYPE (cp->info->parent_struct.signature));
23510           g_variant_builder_add (&builder, "{sv}", cp->info->parent_struct.name, variant);
23511           g_variant_unref (variant);
23512           num_changes++;
23513         }
23514     }
23515   if (num_changes > 0)
23516     {
23517       GList *connections, *l;
23518       GVariant *signal_variant;
23519       signal_variant = g_variant_ref_sink (g_variant_new ("(sa{sv}as)", "OldieInterface",
23520                                            &builder, &invalidated_builder));
23521       connections = g_dbus_interface_skeleton_get_connections (G_DBUS_INTERFACE_SKELETON (skeleton));
23522       for (l = connections; l != NULL; l = l->next)
23523         {
23524           GDBusConnection *connection = l->data;
23525
23526           g_dbus_connection_emit_signal (connection,
23527                                          NULL, g_dbus_interface_skeleton_get_object_path (G_DBUS_INTERFACE_SKELETON (skeleton)),
23528                                          "org.freedesktop.DBus.Properties",
23529                                          "PropertiesChanged",
23530                                          signal_variant,
23531                                          NULL);
23532         }
23533       g_variant_unref (signal_variant);
23534       g_list_free_full (connections, g_object_unref);
23535     }
23536   else
23537     {
23538       g_variant_builder_clear (&builder);
23539       g_variant_builder_clear (&invalidated_builder);
23540     }
23541   g_list_free_full (skeleton->priv->changed_properties, (GDestroyNotify) _changed_property_free);
23542   skeleton->priv->changed_properties = NULL;
23543   skeleton->priv->changed_properties_idle_source = NULL;
23544   g_mutex_unlock (&skeleton->priv->lock);
23545   return FALSE;
23546 }
23547
23548 static void
23549 _foo_igen_oldie_interface_schedule_emit_changed (FooiGenOldieInterfaceSkeleton *skeleton, const _ExtendedGDBusPropertyInfo *info, guint prop_id, const GValue *orig_value)
23550 {
23551   ChangedProperty *cp;
23552   GList *l;
23553   cp = NULL;
23554   for (l = skeleton->priv->changed_properties; l != NULL; l = l->next)
23555     {
23556       ChangedProperty *i_cp = l->data;
23557       if (i_cp->info == info)
23558         {
23559           cp = i_cp;
23560           break;
23561         }
23562     }
23563   if (cp == NULL)
23564     {
23565       cp = g_new0 (ChangedProperty, 1);
23566       cp->prop_id = prop_id;
23567       cp->info = info;
23568       skeleton->priv->changed_properties = g_list_prepend (skeleton->priv->changed_properties, cp);
23569       g_value_init (&cp->orig_value, G_VALUE_TYPE (orig_value));
23570       g_value_copy (orig_value, &cp->orig_value);
23571     }
23572 }
23573
23574 static void
23575 foo_igen_oldie_interface_skeleton_notify (GObject      *object,
23576   GParamSpec *pspec)
23577 {
23578   FooiGenOldieInterfaceSkeleton *skeleton = FOO_IGEN_OLDIE_INTERFACE_SKELETON (object);
23579   g_mutex_lock (&skeleton->priv->lock);
23580   if (skeleton->priv->changed_properties != NULL &&
23581       skeleton->priv->changed_properties_idle_source == NULL)
23582     {
23583       skeleton->priv->changed_properties_idle_source = g_idle_source_new ();
23584       g_source_set_priority (skeleton->priv->changed_properties_idle_source, G_PRIORITY_DEFAULT);
23585       g_source_set_callback (skeleton->priv->changed_properties_idle_source, _foo_igen_oldie_interface_emit_changed, g_object_ref (skeleton), (GDestroyNotify) g_object_unref);
23586       g_source_attach (skeleton->priv->changed_properties_idle_source, skeleton->priv->context);
23587       g_source_unref (skeleton->priv->changed_properties_idle_source);
23588     }
23589   g_mutex_unlock (&skeleton->priv->lock);
23590 }
23591
23592 static void
23593 foo_igen_oldie_interface_skeleton_set_property (GObject      *object,
23594   guint         prop_id,
23595   const GValue *value,
23596   GParamSpec   *pspec)
23597 {
23598   FooiGenOldieInterfaceSkeleton *skeleton = FOO_IGEN_OLDIE_INTERFACE_SKELETON (object);
23599   g_assert (prop_id != 0 && prop_id - 1 < 1);
23600   g_mutex_lock (&skeleton->priv->lock);
23601   g_object_freeze_notify (object);
23602   if (!_g_value_equal (value, &skeleton->priv->properties[prop_id - 1]))
23603     {
23604       if (g_dbus_interface_skeleton_get_connection (G_DBUS_INTERFACE_SKELETON (skeleton)) != NULL)
23605         _foo_igen_oldie_interface_schedule_emit_changed (skeleton, _foo_igen_oldie_interface_property_info_pointers[prop_id - 1], prop_id, &skeleton->priv->properties[prop_id - 1]);
23606       g_value_copy (value, &skeleton->priv->properties[prop_id - 1]);
23607       g_object_notify_by_pspec (object, pspec);
23608     }
23609   g_mutex_unlock (&skeleton->priv->lock);
23610   g_object_thaw_notify (object);
23611 }
23612
23613 static void
23614 foo_igen_oldie_interface_skeleton_init (FooiGenOldieInterfaceSkeleton *skeleton)
23615 {
23616   skeleton->priv = G_TYPE_INSTANCE_GET_PRIVATE (skeleton, FOO_IGEN_TYPE_OLDIE_INTERFACE_SKELETON, FooiGenOldieInterfaceSkeletonPrivate);
23617   g_mutex_init (&skeleton->priv->lock);
23618   skeleton->priv->context = g_main_context_ref_thread_default ();
23619   skeleton->priv->properties = g_new0 (GValue, 1);
23620   g_value_init (&skeleton->priv->properties[0], G_TYPE_INT);
23621 }
23622
23623 static gint 
23624 foo_igen_oldie_interface_skeleton_get_bat (FooiGenOldieInterface *object)
23625 {
23626   FooiGenOldieInterfaceSkeleton *skeleton = FOO_IGEN_OLDIE_INTERFACE_SKELETON (object);
23627   gint value;
23628   g_mutex_lock (&skeleton->priv->lock);
23629   value = g_value_get_int (&(skeleton->priv->properties[0]));
23630   g_mutex_unlock (&skeleton->priv->lock);
23631   return value;
23632 }
23633
23634 static void
23635 foo_igen_oldie_interface_skeleton_class_init (FooiGenOldieInterfaceSkeletonClass *klass)
23636 {
23637   GObjectClass *gobject_class;
23638   GDBusInterfaceSkeletonClass *skeleton_class;
23639
23640   g_type_class_add_private (klass, sizeof (FooiGenOldieInterfaceSkeletonPrivate));
23641
23642   gobject_class = G_OBJECT_CLASS (klass);
23643   gobject_class->finalize = foo_igen_oldie_interface_skeleton_finalize;
23644   gobject_class->get_property = foo_igen_oldie_interface_skeleton_get_property;
23645   gobject_class->set_property = foo_igen_oldie_interface_skeleton_set_property;
23646   gobject_class->notify       = foo_igen_oldie_interface_skeleton_notify;
23647
23648
23649   foo_igen_oldie_interface_override_properties (gobject_class, 1);
23650
23651   skeleton_class = G_DBUS_INTERFACE_SKELETON_CLASS (klass);
23652   skeleton_class->get_info = foo_igen_oldie_interface_skeleton_dbus_interface_get_info;
23653   skeleton_class->get_properties = foo_igen_oldie_interface_skeleton_dbus_interface_get_properties;
23654   skeleton_class->flush = foo_igen_oldie_interface_skeleton_dbus_interface_flush;
23655   skeleton_class->get_vtable = foo_igen_oldie_interface_skeleton_dbus_interface_get_vtable;
23656 }
23657
23658 static void
23659 foo_igen_oldie_interface_skeleton_iface_init (FooiGenOldieInterfaceIface *iface)
23660 {
23661   iface->bar = _foo_igen_oldie_interface_on_signal_bar;
23662   iface->get_bat = foo_igen_oldie_interface_skeleton_get_bat;
23663 }
23664
23665 /**
23666  * foo_igen_oldie_interface_skeleton_new:
23667  *
23668  * Creates a skeleton object for the D-Bus interface <link linkend="gdbus-interface-OldieInterface.top_of_page">OldieInterface</link>.
23669  *
23670  * Returns: (transfer full) (type FooiGenOldieInterfaceSkeleton): The skeleton object.
23671  *
23672  * Deprecated: The D-Bus interface has been deprecated.
23673  */
23674 FooiGenOldieInterface *
23675 foo_igen_oldie_interface_skeleton_new (void)
23676 {
23677   return FOO_IGEN_OLDIE_INTERFACE (g_object_new (FOO_IGEN_TYPE_OLDIE_INTERFACE_SKELETON, NULL));
23678 }
23679
23680 /* ------------------------------------------------------------------------
23681  * Code for interface UnknownXmlTags
23682  * ------------------------------------------------------------------------
23683  */
23684
23685 /**
23686  * SECTION:FooiGenUnknownXmlTags
23687  * @title: FooiGenUnknownXmlTags
23688  * @short_description: Generated C code for the UnknownXmlTags D-Bus interface
23689  *
23690  * This section contains code for working with the <link linkend="gdbus-interface-UnknownXmlTags.top_of_page">UnknownXmlTags</link> D-Bus interface in C.
23691  */
23692
23693 /* ---- Introspection data for UnknownXmlTags ---- */
23694
23695 static const _ExtendedGDBusArgInfo _foo_igen_unknown_xml_tags_method_info_can_set_timezone_OUT_ARG_value =
23696 {
23697   {
23698     -1,
23699     "value",
23700     "i",
23701     NULL
23702   },
23703   FALSE
23704 };
23705
23706 static const _ExtendedGDBusArgInfo * const _foo_igen_unknown_xml_tags_method_info_can_set_timezone_OUT_ARG_pointers[] =
23707 {
23708   &_foo_igen_unknown_xml_tags_method_info_can_set_timezone_OUT_ARG_value,
23709   NULL
23710 };
23711
23712 static const GDBusAnnotationInfo _foo_igen_unknown_xml_tags_method_can_set_timezone_annotation_info_0 =
23713 {
23714   -1,
23715   "org.freedesktop.DBus.GLib.Async",
23716   "",
23717   NULL
23718 };
23719
23720 static const GDBusAnnotationInfo * const _foo_igen_unknown_xml_tags_method_can_set_timezone_annotation_info_pointers[] =
23721 {
23722   &_foo_igen_unknown_xml_tags_method_can_set_timezone_annotation_info_0,
23723   NULL
23724 };
23725
23726 static const _ExtendedGDBusMethodInfo _foo_igen_unknown_xml_tags_method_info_can_set_timezone =
23727 {
23728   {
23729     -1,
23730     "CanSetTimezone",
23731     NULL,
23732     (GDBusArgInfo **) &_foo_igen_unknown_xml_tags_method_info_can_set_timezone_OUT_ARG_pointers,
23733     (GDBusAnnotationInfo **) &_foo_igen_unknown_xml_tags_method_can_set_timezone_annotation_info_pointers
23734   },
23735   "handle-can-set-timezone",
23736   FALSE
23737 };
23738
23739 static const _ExtendedGDBusMethodInfo * const _foo_igen_unknown_xml_tags_method_info_pointers[] =
23740 {
23741   &_foo_igen_unknown_xml_tags_method_info_can_set_timezone,
23742   NULL
23743 };
23744
23745 static const _ExtendedGDBusSignalInfo _foo_igen_unknown_xml_tags_signal_info_some_signal =
23746 {
23747   {
23748     -1,
23749     "SomeSignal",
23750     NULL,
23751     NULL
23752   },
23753   "some-signal"
23754 };
23755
23756 static const _ExtendedGDBusSignalInfo * const _foo_igen_unknown_xml_tags_signal_info_pointers[] =
23757 {
23758   &_foo_igen_unknown_xml_tags_signal_info_some_signal,
23759   NULL
23760 };
23761
23762 static const _ExtendedGDBusPropertyInfo _foo_igen_unknown_xml_tags_property_info_some_property =
23763 {
23764   {
23765     -1,
23766     "SomeProperty",
23767     "s",
23768     G_DBUS_PROPERTY_INFO_FLAGS_READABLE | G_DBUS_PROPERTY_INFO_FLAGS_WRITABLE,
23769     NULL
23770   },
23771   "some-property",
23772   FALSE
23773 };
23774
23775 static const _ExtendedGDBusPropertyInfo * const _foo_igen_unknown_xml_tags_property_info_pointers[] =
23776 {
23777   &_foo_igen_unknown_xml_tags_property_info_some_property,
23778   NULL
23779 };
23780
23781 static const _ExtendedGDBusInterfaceInfo _foo_igen_unknown_xml_tags_interface_info =
23782 {
23783   {
23784     -1,
23785     "UnknownXmlTags",
23786     (GDBusMethodInfo **) &_foo_igen_unknown_xml_tags_method_info_pointers,
23787     (GDBusSignalInfo **) &_foo_igen_unknown_xml_tags_signal_info_pointers,
23788     (GDBusPropertyInfo **) &_foo_igen_unknown_xml_tags_property_info_pointers,
23789     NULL
23790   },
23791   "unknown-xml-tags",
23792 };
23793
23794
23795 /**
23796  * foo_igen_unknown_xml_tags_interface_info:
23797  *
23798  * Gets a machine-readable description of the <link linkend="gdbus-interface-UnknownXmlTags.top_of_page">UnknownXmlTags</link> D-Bus interface.
23799  *
23800  * Returns: (transfer none): A #GDBusInterfaceInfo. Do not free.
23801  */
23802 GDBusInterfaceInfo *
23803 foo_igen_unknown_xml_tags_interface_info (void)
23804 {
23805   return (GDBusInterfaceInfo *) &_foo_igen_unknown_xml_tags_interface_info;
23806 }
23807
23808 /**
23809  * foo_igen_unknown_xml_tags_override_properties:
23810  * @klass: The class structure for a #GObject<!-- -->-derived class.
23811  * @property_id_begin: The property id to assign to the first overridden property.
23812  *
23813  * Overrides all #GObject properties in the #FooiGenUnknownXmlTags interface for a concrete class.
23814  * The properties are overridden in the order they are defined.
23815  *
23816  * Returns: The last property id.
23817  */
23818 guint
23819 foo_igen_unknown_xml_tags_override_properties (GObjectClass *klass, guint property_id_begin)
23820 {
23821   g_object_class_override_property (klass, property_id_begin++, "some-property");
23822   return property_id_begin - 1;
23823 }
23824
23825
23826
23827 /**
23828  * FooiGenUnknownXmlTags:
23829  *
23830  * Abstract interface type for the D-Bus interface <link linkend="gdbus-interface-UnknownXmlTags.top_of_page">UnknownXmlTags</link>.
23831  */
23832
23833 /**
23834  * FooiGenUnknownXmlTagsIface:
23835  * @parent_iface: The parent interface.
23836  * @handle_can_set_timezone: Handler for the #FooiGenUnknownXmlTags::handle-can-set-timezone signal.
23837  * @get_some_property: Getter for the #FooiGenUnknownXmlTags:some-property property.
23838  * @some_signal: Handler for the #FooiGenUnknownXmlTags::some-signal signal.
23839  *
23840  * Virtual table for the D-Bus interface <link linkend="gdbus-interface-UnknownXmlTags.top_of_page">UnknownXmlTags</link>.
23841  */
23842
23843 static void
23844 foo_igen_unknown_xml_tags_default_init (FooiGenUnknownXmlTagsIface *iface)
23845 {
23846   /* GObject signals for incoming D-Bus method calls: */
23847   /**
23848    * FooiGenUnknownXmlTags::handle-can-set-timezone:
23849    * @object: A #FooiGenUnknownXmlTags.
23850    * @invocation: A #GDBusMethodInvocation.
23851    *
23852    * Signal emitted when a remote caller is invoking the <link linkend="gdbus-method-UnknownXmlTags.CanSetTimezone">CanSetTimezone()</link> D-Bus method.
23853    *
23854    * If a signal handler returns %TRUE, it means the signal handler will handle the invocation (e.g. take a reference to @invocation and eventually call foo_igen_unknown_xml_tags_complete_can_set_timezone() or e.g. g_dbus_method_invocation_return_error() on it) and no order signal handlers will run. If no signal handler handles the invocation, the %G_DBUS_ERROR_UNKNOWN_METHOD error is returned.
23855    *
23856    * Returns: %TRUE if the invocation was handled, %FALSE to let other signal handlers run.
23857    */
23858   g_signal_new ("handle-can-set-timezone",
23859     G_TYPE_FROM_INTERFACE (iface),
23860     G_SIGNAL_RUN_LAST,
23861     G_STRUCT_OFFSET (FooiGenUnknownXmlTagsIface, handle_can_set_timezone),
23862     g_signal_accumulator_true_handled,
23863     NULL,
23864     g_cclosure_marshal_generic,
23865     G_TYPE_BOOLEAN,
23866     1,
23867     G_TYPE_DBUS_METHOD_INVOCATION);
23868
23869   /* GObject signals for received D-Bus signals: */
23870   /**
23871    * FooiGenUnknownXmlTags::some-signal:
23872    * @object: A #FooiGenUnknownXmlTags.
23873    *
23874    * On the client-side, this signal is emitted whenever the D-Bus signal <link linkend="gdbus-signal-UnknownXmlTags.SomeSignal">"SomeSignal"</link> is received.
23875    *
23876    * On the service-side, this signal can be used with e.g. g_signal_emit_by_name() to make the object emit the D-Bus signal.
23877    */
23878   g_signal_new ("some-signal",
23879     G_TYPE_FROM_INTERFACE (iface),
23880     G_SIGNAL_RUN_LAST,
23881     G_STRUCT_OFFSET (FooiGenUnknownXmlTagsIface, some_signal),
23882     NULL,
23883     NULL,
23884     g_cclosure_marshal_generic,
23885     G_TYPE_NONE,
23886     0);
23887
23888   /* GObject properties for D-Bus properties: */
23889   /**
23890    * FooiGenUnknownXmlTags:some-property:
23891    *
23892    * Represents the D-Bus property <link linkend="gdbus-property-UnknownXmlTags.SomeProperty">"SomeProperty"</link>.
23893    *
23894    * Since the D-Bus property for this #GObject property is both readable and writable, it is meaningful to both read from it and write to it on both the service- and client-side.
23895    */
23896   g_object_interface_install_property (iface,
23897     g_param_spec_string ("some-property", "SomeProperty", "SomeProperty", NULL, G_PARAM_READWRITE | G_PARAM_STATIC_STRINGS));
23898 }
23899
23900 typedef FooiGenUnknownXmlTagsIface FooiGenUnknownXmlTagsInterface;
23901 G_DEFINE_INTERFACE (FooiGenUnknownXmlTags, foo_igen_unknown_xml_tags, G_TYPE_OBJECT);
23902
23903 /**
23904  * foo_igen_unknown_xml_tags_get_some_property: (skip)
23905  * @object: A #FooiGenUnknownXmlTags.
23906  *
23907  * Gets the value of the <link linkend="gdbus-property-UnknownXmlTags.SomeProperty">"SomeProperty"</link> D-Bus property.
23908  *
23909  * Since this D-Bus property is both readable and writable, it is meaningful to use this function on both the client- and service-side.
23910  *
23911  * <warning>The returned value is only valid until the property changes so on the client-side it is only safe to use this function on the thread where @object was constructed. Use foo_igen_unknown_xml_tags_dup_some_property() if on another thread.</warning>
23912  *
23913  * Returns: (transfer none): The property value or %NULL if the property is not set. Do not free the returned value, it belongs to @object.
23914  */
23915 const gchar *
23916 foo_igen_unknown_xml_tags_get_some_property (FooiGenUnknownXmlTags *object)
23917 {
23918   return FOO_IGEN_UNKNOWN_XML_TAGS_GET_IFACE (object)->get_some_property (object);
23919 }
23920
23921 /**
23922  * foo_igen_unknown_xml_tags_dup_some_property: (skip)
23923  * @object: A #FooiGenUnknownXmlTags.
23924  *
23925  * Gets a copy of the <link linkend="gdbus-property-UnknownXmlTags.SomeProperty">"SomeProperty"</link> D-Bus property.
23926  *
23927  * Since this D-Bus property is both readable and writable, it is meaningful to use this function on both the client- and service-side.
23928  *
23929  * Returns: (transfer full): The property value or %NULL if the property is not set. The returned value should be freed with g_free().
23930  */
23931 gchar *
23932 foo_igen_unknown_xml_tags_dup_some_property (FooiGenUnknownXmlTags *object)
23933 {
23934   gchar *value;
23935   g_object_get (G_OBJECT (object), "some-property", &value, NULL);
23936   return value;
23937 }
23938
23939 /**
23940  * foo_igen_unknown_xml_tags_set_some_property: (skip)
23941  * @object: A #FooiGenUnknownXmlTags.
23942  * @value: The value to set.
23943  *
23944  * Sets the <link linkend="gdbus-property-UnknownXmlTags.SomeProperty">"SomeProperty"</link> D-Bus property to @value.
23945  *
23946  * Since this D-Bus property is both readable and writable, it is meaningful to use this function on both the client- and service-side.
23947  */
23948 void
23949 foo_igen_unknown_xml_tags_set_some_property (FooiGenUnknownXmlTags *object, const gchar *value)
23950 {
23951   g_object_set (G_OBJECT (object), "some-property", value, NULL);
23952 }
23953
23954 /**
23955  * foo_igen_unknown_xml_tags_emit_some_signal:
23956  * @object: A #FooiGenUnknownXmlTags.
23957  *
23958  * Emits the <link linkend="gdbus-signal-UnknownXmlTags.SomeSignal">"SomeSignal"</link> D-Bus signal.
23959  */
23960 void
23961 foo_igen_unknown_xml_tags_emit_some_signal (
23962     FooiGenUnknownXmlTags *object)
23963 {
23964   g_signal_emit_by_name (object, "some-signal");
23965 }
23966
23967 /**
23968  * foo_igen_unknown_xml_tags_call_can_set_timezone:
23969  * @proxy: A #FooiGenUnknownXmlTagsProxy.
23970  * @cancellable: (allow-none): A #GCancellable or %NULL.
23971  * @callback: A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
23972  * @user_data: User data to pass to @callback.
23973  *
23974  * Asynchronously invokes the <link linkend="gdbus-method-UnknownXmlTags.CanSetTimezone">CanSetTimezone()</link> D-Bus method on @proxy.
23975  * When the operation is finished, @callback will be invoked in the <link linkend="g-main-context-push-thread-default">thread-default main loop</link> of the thread you are calling this method from.
23976  * You can then call foo_igen_unknown_xml_tags_call_can_set_timezone_finish() to get the result of the operation.
23977  *
23978  * See foo_igen_unknown_xml_tags_call_can_set_timezone_sync() for the synchronous, blocking version of this method.
23979  */
23980 void
23981 foo_igen_unknown_xml_tags_call_can_set_timezone (
23982     FooiGenUnknownXmlTags *proxy,
23983     GCancellable *cancellable,
23984     GAsyncReadyCallback callback,
23985     gpointer user_data)
23986 {
23987   g_dbus_proxy_call (G_DBUS_PROXY (proxy),
23988     "CanSetTimezone",
23989     g_variant_new ("()"),
23990     G_DBUS_CALL_FLAGS_NONE,
23991     -1,
23992     cancellable,
23993     callback,
23994     user_data);
23995 }
23996
23997 /**
23998  * foo_igen_unknown_xml_tags_call_can_set_timezone_finish:
23999  * @proxy: A #FooiGenUnknownXmlTagsProxy.
24000  * @out_value: (out): Return location for return parameter or %NULL to ignore.
24001  * @res: The #GAsyncResult obtained from the #GAsyncReadyCallback passed to foo_igen_unknown_xml_tags_call_can_set_timezone().
24002  * @error: Return location for error or %NULL.
24003  *
24004  * Finishes an operation started with foo_igen_unknown_xml_tags_call_can_set_timezone().
24005  *
24006  * Returns: (skip): %TRUE if the call succeded, %FALSE if @error is set.
24007  */
24008 gboolean
24009 foo_igen_unknown_xml_tags_call_can_set_timezone_finish (
24010     FooiGenUnknownXmlTags *proxy,
24011     gint *out_value,
24012     GAsyncResult *res,
24013     GError **error)
24014 {
24015   GVariant *_ret;
24016   _ret = g_dbus_proxy_call_finish (G_DBUS_PROXY (proxy), res, error);
24017   if (_ret == NULL)
24018     goto _out;
24019   g_variant_get (_ret,
24020                  "(i)",
24021                  out_value);
24022   g_variant_unref (_ret);
24023 _out:
24024   return _ret != NULL;
24025 }
24026
24027 /**
24028  * foo_igen_unknown_xml_tags_call_can_set_timezone_sync:
24029  * @proxy: A #FooiGenUnknownXmlTagsProxy.
24030  * @out_value: (out): Return location for return parameter or %NULL to ignore.
24031  * @cancellable: (allow-none): A #GCancellable or %NULL.
24032  * @error: Return location for error or %NULL.
24033  *
24034  * Synchronously invokes the <link linkend="gdbus-method-UnknownXmlTags.CanSetTimezone">CanSetTimezone()</link> D-Bus method on @proxy. The calling thread is blocked until a reply is received.
24035  *
24036  * See foo_igen_unknown_xml_tags_call_can_set_timezone() for the asynchronous version of this method.
24037  *
24038  * Returns: (skip): %TRUE if the call succeded, %FALSE if @error is set.
24039  */
24040 gboolean
24041 foo_igen_unknown_xml_tags_call_can_set_timezone_sync (
24042     FooiGenUnknownXmlTags *proxy,
24043     gint *out_value,
24044     GCancellable *cancellable,
24045     GError **error)
24046 {
24047   GVariant *_ret;
24048   _ret = g_dbus_proxy_call_sync (G_DBUS_PROXY (proxy),
24049     "CanSetTimezone",
24050     g_variant_new ("()"),
24051     G_DBUS_CALL_FLAGS_NONE,
24052     -1,
24053     cancellable,
24054     error);
24055   if (_ret == NULL)
24056     goto _out;
24057   g_variant_get (_ret,
24058                  "(i)",
24059                  out_value);
24060   g_variant_unref (_ret);
24061 _out:
24062   return _ret != NULL;
24063 }
24064
24065 /**
24066  * foo_igen_unknown_xml_tags_complete_can_set_timezone:
24067  * @object: A #FooiGenUnknownXmlTags.
24068  * @invocation: (transfer full): A #GDBusMethodInvocation.
24069  * @value: Parameter to return.
24070  *
24071  * Helper function used in service implementations to finish handling invocations of the <link linkend="gdbus-method-UnknownXmlTags.CanSetTimezone">CanSetTimezone()</link> D-Bus method. If you instead want to finish handling an invocation by returning an error, use g_dbus_method_invocation_return_error() or similar.
24072  *
24073  * This method will free @invocation, you cannot use it afterwards.
24074  */
24075 void
24076 foo_igen_unknown_xml_tags_complete_can_set_timezone (
24077     FooiGenUnknownXmlTags *object,
24078     GDBusMethodInvocation *invocation,
24079     gint value)
24080 {
24081   g_dbus_method_invocation_return_value (invocation,
24082     g_variant_new ("(i)",
24083                    value));
24084 }
24085
24086 /* ------------------------------------------------------------------------ */
24087
24088 /**
24089  * FooiGenUnknownXmlTagsProxy:
24090  *
24091  * The #FooiGenUnknownXmlTagsProxy structure contains only private data and should only be accessed using the provided API.
24092  */
24093
24094 /**
24095  * FooiGenUnknownXmlTagsProxyClass:
24096  * @parent_class: The parent class.
24097  *
24098  * Class structure for #FooiGenUnknownXmlTagsProxy.
24099  */
24100
24101 struct _FooiGenUnknownXmlTagsProxyPrivate
24102 {
24103   GData *qdata;
24104 };
24105
24106 static void foo_igen_unknown_xml_tags_proxy_iface_init (FooiGenUnknownXmlTagsIface *iface);
24107
24108 G_DEFINE_TYPE_WITH_CODE (FooiGenUnknownXmlTagsProxy, foo_igen_unknown_xml_tags_proxy, G_TYPE_DBUS_PROXY,
24109                          G_IMPLEMENT_INTERFACE (FOO_IGEN_TYPE_UNKNOWN_XML_TAGS, foo_igen_unknown_xml_tags_proxy_iface_init));
24110
24111 static void
24112 foo_igen_unknown_xml_tags_proxy_finalize (GObject *object)
24113 {
24114   FooiGenUnknownXmlTagsProxy *proxy = FOO_IGEN_UNKNOWN_XML_TAGS_PROXY (object);
24115   g_datalist_clear (&proxy->priv->qdata);
24116   G_OBJECT_CLASS (foo_igen_unknown_xml_tags_proxy_parent_class)->finalize (object);
24117 }
24118
24119 static void
24120 foo_igen_unknown_xml_tags_proxy_get_property (GObject      *object,
24121   guint         prop_id,
24122   GValue       *value,
24123   GParamSpec   *pspec)
24124 {
24125   const _ExtendedGDBusPropertyInfo *info;
24126   GVariant *variant;
24127   g_assert (prop_id != 0 && prop_id - 1 < 1);
24128   info = _foo_igen_unknown_xml_tags_property_info_pointers[prop_id - 1];
24129   variant = g_dbus_proxy_get_cached_property (G_DBUS_PROXY (object), info->parent_struct.name);
24130   if (info->use_gvariant)
24131     {
24132       g_value_set_variant (value, variant);
24133     }
24134   else
24135     {
24136       if (variant != NULL)
24137         g_dbus_gvariant_to_gvalue (variant, value);
24138     }
24139   if (variant != NULL)
24140     g_variant_unref (variant);
24141 }
24142
24143 static void
24144 foo_igen_unknown_xml_tags_proxy_set_property_cb (GDBusProxy *proxy,
24145   GAsyncResult *res,
24146   gpointer      user_data)
24147 {
24148   const _ExtendedGDBusPropertyInfo *info = user_data;
24149   GError *error;
24150   error = NULL;
24151   if (!g_dbus_proxy_call_finish (proxy, res, &error))
24152     {
24153       g_warning ("Error setting property `%s' on interface UnknownXmlTags: %s (%s, %d)",
24154                  info->parent_struct.name, 
24155                  error->message, g_quark_to_string (error->domain), error->code);
24156       g_error_free (error);
24157     }
24158 }
24159
24160 static void
24161 foo_igen_unknown_xml_tags_proxy_set_property (GObject      *object,
24162   guint         prop_id,
24163   const GValue *value,
24164   GParamSpec   *pspec)
24165 {
24166   const _ExtendedGDBusPropertyInfo *info;
24167   GVariant *variant;
24168   g_assert (prop_id != 0 && prop_id - 1 < 1);
24169   info = _foo_igen_unknown_xml_tags_property_info_pointers[prop_id - 1];
24170   variant = g_dbus_gvalue_to_gvariant (value, G_VARIANT_TYPE (info->parent_struct.signature));
24171   g_dbus_proxy_call (G_DBUS_PROXY (object),
24172     "org.freedesktop.DBus.Properties.Set",
24173     g_variant_new ("(ssv)", "UnknownXmlTags", info->parent_struct.name, variant),
24174     G_DBUS_CALL_FLAGS_NONE,
24175     -1,
24176     NULL, (GAsyncReadyCallback) foo_igen_unknown_xml_tags_proxy_set_property_cb, (gpointer) info);
24177   g_variant_unref (variant);
24178 }
24179
24180 static void
24181 foo_igen_unknown_xml_tags_proxy_g_signal (GDBusProxy *proxy,
24182   const gchar *sender_name,
24183   const gchar *signal_name,
24184   GVariant *parameters)
24185 {
24186   _ExtendedGDBusSignalInfo *info;
24187   GVariantIter iter;
24188   GVariant *child;
24189   GValue *paramv;
24190   guint num_params;
24191   guint n;
24192   guint signal_id;
24193   info = (_ExtendedGDBusSignalInfo *) g_dbus_interface_info_lookup_signal ((GDBusInterfaceInfo *) &_foo_igen_unknown_xml_tags_interface_info, signal_name);
24194   if (info == NULL)
24195     return;
24196   num_params = g_variant_n_children (parameters);
24197   paramv = g_new0 (GValue, num_params + 1);
24198   g_value_init (&paramv[0], FOO_IGEN_TYPE_UNKNOWN_XML_TAGS);
24199   g_value_set_object (&paramv[0], proxy);
24200   g_variant_iter_init (&iter, parameters);
24201   n = 1;
24202   while ((child = g_variant_iter_next_value (&iter)) != NULL)
24203     {
24204       _ExtendedGDBusArgInfo *arg_info = (_ExtendedGDBusArgInfo *) info->parent_struct.args[n - 1];
24205       if (arg_info->use_gvariant)
24206         {
24207           g_value_init (&paramv[n], G_TYPE_VARIANT);
24208           g_value_set_variant (&paramv[n], child);
24209           n++;
24210         }
24211       else
24212         g_dbus_gvariant_to_gvalue (child, &paramv[n++]);
24213       g_variant_unref (child);
24214     }
24215   signal_id = g_signal_lookup (info->signal_name, FOO_IGEN_TYPE_UNKNOWN_XML_TAGS);
24216   g_signal_emitv (paramv, signal_id, 0, NULL);
24217   for (n = 0; n < num_params + 1; n++)
24218     g_value_unset (&paramv[n]);
24219   g_free (paramv);
24220 }
24221
24222 static void
24223 foo_igen_unknown_xml_tags_proxy_g_properties_changed (GDBusProxy *_proxy,
24224   GVariant *changed_properties,
24225   const gchar *const *invalidated_properties)
24226 {
24227   FooiGenUnknownXmlTagsProxy *proxy = FOO_IGEN_UNKNOWN_XML_TAGS_PROXY (_proxy);
24228   guint n;
24229   const gchar *key;
24230   GVariantIter *iter;
24231   _ExtendedGDBusPropertyInfo *info;
24232   g_variant_get (changed_properties, "a{sv}", &iter);
24233   while (g_variant_iter_next (iter, "{&sv}", &key, NULL))
24234     {
24235       info = (_ExtendedGDBusPropertyInfo *) g_dbus_interface_info_lookup_property ((GDBusInterfaceInfo *) &_foo_igen_unknown_xml_tags_interface_info, key);
24236       g_datalist_remove_data (&proxy->priv->qdata, key);
24237       if (info != NULL)
24238         g_object_notify (G_OBJECT (proxy), info->hyphen_name);
24239     }
24240   g_variant_iter_free (iter);
24241   for (n = 0; invalidated_properties[n] != NULL; n++)
24242     {
24243       info = (_ExtendedGDBusPropertyInfo *) g_dbus_interface_info_lookup_property ((GDBusInterfaceInfo *) &_foo_igen_unknown_xml_tags_interface_info, invalidated_properties[n]);
24244       g_datalist_remove_data (&proxy->priv->qdata, invalidated_properties[n]);
24245       if (info != NULL)
24246         g_object_notify (G_OBJECT (proxy), info->hyphen_name);
24247     }
24248 }
24249
24250 static const gchar *
24251 foo_igen_unknown_xml_tags_proxy_get_some_property (FooiGenUnknownXmlTags *object)
24252 {
24253   FooiGenUnknownXmlTagsProxy *proxy = FOO_IGEN_UNKNOWN_XML_TAGS_PROXY (object);
24254   GVariant *variant;
24255   const gchar *value = NULL;
24256   variant = g_dbus_proxy_get_cached_property (G_DBUS_PROXY (proxy), "SomeProperty");
24257   if (variant != NULL)
24258     {
24259       value = g_variant_get_string (variant, NULL);
24260       g_variant_unref (variant);
24261     }
24262   return value;
24263 }
24264
24265 static void
24266 foo_igen_unknown_xml_tags_proxy_init (FooiGenUnknownXmlTagsProxy *proxy)
24267 {
24268   proxy->priv = G_TYPE_INSTANCE_GET_PRIVATE (proxy, FOO_IGEN_TYPE_UNKNOWN_XML_TAGS_PROXY, FooiGenUnknownXmlTagsProxyPrivate);
24269   g_dbus_proxy_set_interface_info (G_DBUS_PROXY (proxy), foo_igen_unknown_xml_tags_interface_info ());
24270 }
24271
24272 static void
24273 foo_igen_unknown_xml_tags_proxy_class_init (FooiGenUnknownXmlTagsProxyClass *klass)
24274 {
24275   GObjectClass *gobject_class;
24276   GDBusProxyClass *proxy_class;
24277
24278   g_type_class_add_private (klass, sizeof (FooiGenUnknownXmlTagsProxyPrivate));
24279
24280   gobject_class = G_OBJECT_CLASS (klass);
24281   gobject_class->finalize     = foo_igen_unknown_xml_tags_proxy_finalize;
24282   gobject_class->get_property = foo_igen_unknown_xml_tags_proxy_get_property;
24283   gobject_class->set_property = foo_igen_unknown_xml_tags_proxy_set_property;
24284
24285   proxy_class = G_DBUS_PROXY_CLASS (klass);
24286   proxy_class->g_signal = foo_igen_unknown_xml_tags_proxy_g_signal;
24287   proxy_class->g_properties_changed = foo_igen_unknown_xml_tags_proxy_g_properties_changed;
24288
24289
24290   foo_igen_unknown_xml_tags_override_properties (gobject_class, 1);
24291 }
24292
24293 static void
24294 foo_igen_unknown_xml_tags_proxy_iface_init (FooiGenUnknownXmlTagsIface *iface)
24295 {
24296   iface->get_some_property = foo_igen_unknown_xml_tags_proxy_get_some_property;
24297 }
24298
24299 /**
24300  * foo_igen_unknown_xml_tags_proxy_new:
24301  * @connection: A #GDBusConnection.
24302  * @flags: Flags from the #GDBusProxyFlags enumeration.
24303  * @name: (allow-none): A bus name (well-known or unique) or %NULL if @connection is not a message bus connection.
24304  * @object_path: An object path.
24305  * @cancellable: (allow-none): A #GCancellable or %NULL.
24306  * @callback: A #GAsyncReadyCallback to call when the request is satisfied.
24307  * @user_data: User data to pass to @callback.
24308  *
24309  * Asynchronously creates a proxy for the D-Bus interface <link linkend="gdbus-interface-UnknownXmlTags.top_of_page">UnknownXmlTags</link>. See g_dbus_proxy_new() for more details.
24310  *
24311  * When the operation is finished, @callback will be invoked in the <link linkend="g-main-context-push-thread-default">thread-default main loop</link> of the thread you are calling this method from.
24312  * You can then call foo_igen_unknown_xml_tags_proxy_new_finish() to get the result of the operation.
24313  *
24314  * See foo_igen_unknown_xml_tags_proxy_new_sync() for the synchronous, blocking version of this constructor.
24315  */
24316 void
24317 foo_igen_unknown_xml_tags_proxy_new (
24318     GDBusConnection     *connection,
24319     GDBusProxyFlags      flags,
24320     const gchar         *name,
24321     const gchar         *object_path,
24322     GCancellable        *cancellable,
24323     GAsyncReadyCallback  callback,
24324     gpointer             user_data)
24325 {
24326   g_async_initable_new_async (FOO_IGEN_TYPE_UNKNOWN_XML_TAGS_PROXY, G_PRIORITY_DEFAULT, cancellable, callback, user_data, "g-flags", flags, "g-name", name, "g-connection", connection, "g-object-path", object_path, "g-interface-name", "UnknownXmlTags", NULL);
24327 }
24328
24329 /**
24330  * foo_igen_unknown_xml_tags_proxy_new_finish:
24331  * @res: The #GAsyncResult obtained from the #GAsyncReadyCallback passed to foo_igen_unknown_xml_tags_proxy_new().
24332  * @error: Return location for error or %NULL
24333  *
24334  * Finishes an operation started with foo_igen_unknown_xml_tags_proxy_new().
24335  *
24336  * Returns: (transfer full) (type FooiGenUnknownXmlTagsProxy): The constructed proxy object or %NULL if @error is set.
24337  */
24338 FooiGenUnknownXmlTags *
24339 foo_igen_unknown_xml_tags_proxy_new_finish (
24340     GAsyncResult        *res,
24341     GError             **error)
24342 {
24343   GObject *ret;
24344   GObject *source_object;
24345   source_object = g_async_result_get_source_object (res);
24346   ret = g_async_initable_new_finish (G_ASYNC_INITABLE (source_object), res, error);
24347   g_object_unref (source_object);
24348   if (ret != NULL)
24349     return FOO_IGEN_UNKNOWN_XML_TAGS (ret);
24350   else
24351     return NULL;
24352 }
24353
24354 /**
24355  * foo_igen_unknown_xml_tags_proxy_new_sync:
24356  * @connection: A #GDBusConnection.
24357  * @flags: Flags from the #GDBusProxyFlags enumeration.
24358  * @name: (allow-none): A bus name (well-known or unique) or %NULL if @connection is not a message bus connection.
24359  * @object_path: An object path.
24360  * @cancellable: (allow-none): A #GCancellable or %NULL.
24361  * @error: Return location for error or %NULL
24362  *
24363  * Synchronously creates a proxy for the D-Bus interface <link linkend="gdbus-interface-UnknownXmlTags.top_of_page">UnknownXmlTags</link>. See g_dbus_proxy_new_sync() for more details.
24364  *
24365  * The calling thread is blocked until a reply is received.
24366  *
24367  * See foo_igen_unknown_xml_tags_proxy_new() for the asynchronous version of this constructor.
24368  *
24369  * Returns: (transfer full) (type FooiGenUnknownXmlTagsProxy): The constructed proxy object or %NULL if @error is set.
24370  */
24371 FooiGenUnknownXmlTags *
24372 foo_igen_unknown_xml_tags_proxy_new_sync (
24373     GDBusConnection     *connection,
24374     GDBusProxyFlags      flags,
24375     const gchar         *name,
24376     const gchar         *object_path,
24377     GCancellable        *cancellable,
24378     GError             **error)
24379 {
24380   GInitable *ret;
24381   ret = g_initable_new (FOO_IGEN_TYPE_UNKNOWN_XML_TAGS_PROXY, cancellable, error, "g-flags", flags, "g-name", name, "g-connection", connection, "g-object-path", object_path, "g-interface-name", "UnknownXmlTags", NULL);
24382   if (ret != NULL)
24383     return FOO_IGEN_UNKNOWN_XML_TAGS (ret);
24384   else
24385     return NULL;
24386 }
24387
24388
24389 /**
24390  * foo_igen_unknown_xml_tags_proxy_new_for_bus:
24391  * @bus_type: A #GBusType.
24392  * @flags: Flags from the #GDBusProxyFlags enumeration.
24393  * @name: A bus name (well-known or unique).
24394  * @object_path: An object path.
24395  * @cancellable: (allow-none): A #GCancellable or %NULL.
24396  * @callback: A #GAsyncReadyCallback to call when the request is satisfied.
24397  * @user_data: User data to pass to @callback.
24398  *
24399  * Like foo_igen_unknown_xml_tags_proxy_new() but takes a #GBusType instead of a #GDBusConnection.
24400  *
24401  * When the operation is finished, @callback will be invoked in the <link linkend="g-main-context-push-thread-default">thread-default main loop</link> of the thread you are calling this method from.
24402  * You can then call foo_igen_unknown_xml_tags_proxy_new_for_bus_finish() to get the result of the operation.
24403  *
24404  * See foo_igen_unknown_xml_tags_proxy_new_for_bus_sync() for the synchronous, blocking version of this constructor.
24405  */
24406 void
24407 foo_igen_unknown_xml_tags_proxy_new_for_bus (
24408     GBusType             bus_type,
24409     GDBusProxyFlags      flags,
24410     const gchar         *name,
24411     const gchar         *object_path,
24412     GCancellable        *cancellable,
24413     GAsyncReadyCallback  callback,
24414     gpointer             user_data)
24415 {
24416   g_async_initable_new_async (FOO_IGEN_TYPE_UNKNOWN_XML_TAGS_PROXY, G_PRIORITY_DEFAULT, cancellable, callback, user_data, "g-flags", flags, "g-name", name, "g-bus-type", bus_type, "g-object-path", object_path, "g-interface-name", "UnknownXmlTags", NULL);
24417 }
24418
24419 /**
24420  * foo_igen_unknown_xml_tags_proxy_new_for_bus_finish:
24421  * @res: The #GAsyncResult obtained from the #GAsyncReadyCallback passed to foo_igen_unknown_xml_tags_proxy_new_for_bus().
24422  * @error: Return location for error or %NULL
24423  *
24424  * Finishes an operation started with foo_igen_unknown_xml_tags_proxy_new_for_bus().
24425  *
24426  * Returns: (transfer full) (type FooiGenUnknownXmlTagsProxy): The constructed proxy object or %NULL if @error is set.
24427  */
24428 FooiGenUnknownXmlTags *
24429 foo_igen_unknown_xml_tags_proxy_new_for_bus_finish (
24430     GAsyncResult        *res,
24431     GError             **error)
24432 {
24433   GObject *ret;
24434   GObject *source_object;
24435   source_object = g_async_result_get_source_object (res);
24436   ret = g_async_initable_new_finish (G_ASYNC_INITABLE (source_object), res, error);
24437   g_object_unref (source_object);
24438   if (ret != NULL)
24439     return FOO_IGEN_UNKNOWN_XML_TAGS (ret);
24440   else
24441     return NULL;
24442 }
24443
24444 /**
24445  * foo_igen_unknown_xml_tags_proxy_new_for_bus_sync:
24446  * @bus_type: A #GBusType.
24447  * @flags: Flags from the #GDBusProxyFlags enumeration.
24448  * @name: A bus name (well-known or unique).
24449  * @object_path: An object path.
24450  * @cancellable: (allow-none): A #GCancellable or %NULL.
24451  * @error: Return location for error or %NULL
24452  *
24453  * Like foo_igen_unknown_xml_tags_proxy_new_sync() but takes a #GBusType instead of a #GDBusConnection.
24454  *
24455  * The calling thread is blocked until a reply is received.
24456  *
24457  * See foo_igen_unknown_xml_tags_proxy_new_for_bus() for the asynchronous version of this constructor.
24458  *
24459  * Returns: (transfer full) (type FooiGenUnknownXmlTagsProxy): The constructed proxy object or %NULL if @error is set.
24460  */
24461 FooiGenUnknownXmlTags *
24462 foo_igen_unknown_xml_tags_proxy_new_for_bus_sync (
24463     GBusType             bus_type,
24464     GDBusProxyFlags      flags,
24465     const gchar         *name,
24466     const gchar         *object_path,
24467     GCancellable        *cancellable,
24468     GError             **error)
24469 {
24470   GInitable *ret;
24471   ret = g_initable_new (FOO_IGEN_TYPE_UNKNOWN_XML_TAGS_PROXY, cancellable, error, "g-flags", flags, "g-name", name, "g-bus-type", bus_type, "g-object-path", object_path, "g-interface-name", "UnknownXmlTags", NULL);
24472   if (ret != NULL)
24473     return FOO_IGEN_UNKNOWN_XML_TAGS (ret);
24474   else
24475     return NULL;
24476 }
24477
24478
24479 /* ------------------------------------------------------------------------ */
24480
24481 /**
24482  * FooiGenUnknownXmlTagsSkeleton:
24483  *
24484  * The #FooiGenUnknownXmlTagsSkeleton structure contains only private data and should only be accessed using the provided API.
24485  */
24486
24487 /**
24488  * FooiGenUnknownXmlTagsSkeletonClass:
24489  * @parent_class: The parent class.
24490  *
24491  * Class structure for #FooiGenUnknownXmlTagsSkeleton.
24492  */
24493
24494 struct _FooiGenUnknownXmlTagsSkeletonPrivate
24495 {
24496   GValue *properties;
24497   GList *changed_properties;
24498   GSource *changed_properties_idle_source;
24499   GMainContext *context;
24500   GMutex lock;
24501 };
24502
24503 static void
24504 _foo_igen_unknown_xml_tags_skeleton_handle_method_call (
24505   GDBusConnection *connection,
24506   const gchar *sender,
24507   const gchar *object_path,
24508   const gchar *interface_name,
24509   const gchar *method_name,
24510   GVariant *parameters,
24511   GDBusMethodInvocation *invocation,
24512   gpointer user_data)
24513 {
24514   FooiGenUnknownXmlTagsSkeleton *skeleton = FOO_IGEN_UNKNOWN_XML_TAGS_SKELETON (user_data);
24515   _ExtendedGDBusMethodInfo *info;
24516   GVariantIter iter;
24517   GVariant *child;
24518   GValue *paramv;
24519   guint num_params;
24520   guint num_extra;
24521   guint n;
24522   guint signal_id;
24523   GValue return_value = G_VALUE_INIT;
24524   info = (_ExtendedGDBusMethodInfo *) g_dbus_method_invocation_get_method_info (invocation);
24525   g_assert (info != NULL);
24526   num_params = g_variant_n_children (parameters);
24527   num_extra = info->pass_fdlist ? 3 : 2;  paramv = g_new0 (GValue, num_params + num_extra);
24528   n = 0;
24529   g_value_init (&paramv[n], FOO_IGEN_TYPE_UNKNOWN_XML_TAGS);
24530   g_value_set_object (&paramv[n++], skeleton);
24531   g_value_init (&paramv[n], G_TYPE_DBUS_METHOD_INVOCATION);
24532   g_value_set_object (&paramv[n++], invocation);
24533   if (info->pass_fdlist)
24534     {
24535 #ifdef G_OS_UNIX
24536       g_value_init (&paramv[n], G_TYPE_UNIX_FD_LIST);
24537       g_value_set_object (&paramv[n++], g_dbus_message_get_unix_fd_list (g_dbus_method_invocation_get_message (invocation)));
24538 #else
24539       g_assert_not_reached ();
24540 #endif
24541     }
24542   g_variant_iter_init (&iter, parameters);
24543   while ((child = g_variant_iter_next_value (&iter)) != NULL)
24544     {
24545       _ExtendedGDBusArgInfo *arg_info = (_ExtendedGDBusArgInfo *) info->parent_struct.in_args[n - num_extra];
24546       if (arg_info->use_gvariant)
24547         {
24548           g_value_init (&paramv[n], G_TYPE_VARIANT);
24549           g_value_set_variant (&paramv[n], child);
24550           n++;
24551         }
24552       else
24553         g_dbus_gvariant_to_gvalue (child, &paramv[n++]);
24554       g_variant_unref (child);
24555     }
24556   signal_id = g_signal_lookup (info->signal_name, FOO_IGEN_TYPE_UNKNOWN_XML_TAGS);
24557   g_value_init (&return_value, G_TYPE_BOOLEAN);
24558   g_signal_emitv (paramv, signal_id, 0, &return_value);
24559   if (!g_value_get_boolean (&return_value))
24560     g_dbus_method_invocation_return_error (invocation, G_DBUS_ERROR, G_DBUS_ERROR_UNKNOWN_METHOD, "Method %s is not implemented on interface %s", method_name, interface_name);
24561   g_value_unset (&return_value);
24562   for (n = 0; n < num_params + num_extra; n++)
24563     g_value_unset (&paramv[n]);
24564   g_free (paramv);
24565 }
24566
24567 static GVariant *
24568 _foo_igen_unknown_xml_tags_skeleton_handle_get_property (
24569   GDBusConnection *connection,
24570   const gchar *sender,
24571   const gchar *object_path,
24572   const gchar *interface_name,
24573   const gchar *property_name,
24574   GError **error,
24575   gpointer user_data)
24576 {
24577   FooiGenUnknownXmlTagsSkeleton *skeleton = FOO_IGEN_UNKNOWN_XML_TAGS_SKELETON (user_data);
24578   GValue value = G_VALUE_INIT;
24579   GParamSpec *pspec;
24580   _ExtendedGDBusPropertyInfo *info;
24581   GVariant *ret;
24582   ret = NULL;
24583   info = (_ExtendedGDBusPropertyInfo *) g_dbus_interface_info_lookup_property ((GDBusInterfaceInfo *) &_foo_igen_unknown_xml_tags_interface_info, property_name);
24584   g_assert (info != NULL);
24585   pspec = g_object_class_find_property (G_OBJECT_GET_CLASS (skeleton), info->hyphen_name);
24586   if (pspec == NULL)
24587     {
24588       g_set_error (error, G_DBUS_ERROR, G_DBUS_ERROR_INVALID_ARGS, "No property with name %s", property_name);
24589     }
24590   else
24591     {
24592       g_value_init (&value, pspec->value_type);
24593       g_object_get_property (G_OBJECT (skeleton), info->hyphen_name, &value);
24594       ret = g_dbus_gvalue_to_gvariant (&value, G_VARIANT_TYPE (info->parent_struct.signature));
24595       g_value_unset (&value);
24596     }
24597   return ret;
24598 }
24599
24600 static gboolean
24601 _foo_igen_unknown_xml_tags_skeleton_handle_set_property (
24602   GDBusConnection *connection,
24603   const gchar *sender,
24604   const gchar *object_path,
24605   const gchar *interface_name,
24606   const gchar *property_name,
24607   GVariant *variant,
24608   GError **error,
24609   gpointer user_data)
24610 {
24611   FooiGenUnknownXmlTagsSkeleton *skeleton = FOO_IGEN_UNKNOWN_XML_TAGS_SKELETON (user_data);
24612   GValue value = G_VALUE_INIT;
24613   GParamSpec *pspec;
24614   _ExtendedGDBusPropertyInfo *info;
24615   gboolean ret;
24616   ret = FALSE;
24617   info = (_ExtendedGDBusPropertyInfo *) g_dbus_interface_info_lookup_property ((GDBusInterfaceInfo *) &_foo_igen_unknown_xml_tags_interface_info, property_name);
24618   g_assert (info != NULL);
24619   pspec = g_object_class_find_property (G_OBJECT_GET_CLASS (skeleton), info->hyphen_name);
24620   if (pspec == NULL)
24621     {
24622       g_set_error (error, G_DBUS_ERROR, G_DBUS_ERROR_INVALID_ARGS, "No property with name %s", property_name);
24623     }
24624   else
24625     {
24626       if (info->use_gvariant)
24627         g_value_set_variant (&value, variant);
24628       else
24629         g_dbus_gvariant_to_gvalue (variant, &value);
24630       g_object_set_property (G_OBJECT (skeleton), info->hyphen_name, &value);
24631       g_value_unset (&value);
24632       ret = TRUE;
24633     }
24634   return ret;
24635 }
24636
24637 static const GDBusInterfaceVTable _foo_igen_unknown_xml_tags_skeleton_vtable =
24638 {
24639   _foo_igen_unknown_xml_tags_skeleton_handle_method_call,
24640   _foo_igen_unknown_xml_tags_skeleton_handle_get_property,
24641   _foo_igen_unknown_xml_tags_skeleton_handle_set_property
24642 };
24643
24644 static GDBusInterfaceInfo *
24645 foo_igen_unknown_xml_tags_skeleton_dbus_interface_get_info (GDBusInterfaceSkeleton *skeleton)
24646 {
24647   return foo_igen_unknown_xml_tags_interface_info ();
24648 }
24649
24650 static GDBusInterfaceVTable *
24651 foo_igen_unknown_xml_tags_skeleton_dbus_interface_get_vtable (GDBusInterfaceSkeleton *skeleton)
24652 {
24653   return (GDBusInterfaceVTable *) &_foo_igen_unknown_xml_tags_skeleton_vtable;
24654 }
24655
24656 static GVariant *
24657 foo_igen_unknown_xml_tags_skeleton_dbus_interface_get_properties (GDBusInterfaceSkeleton *_skeleton)
24658 {
24659   FooiGenUnknownXmlTagsSkeleton *skeleton = FOO_IGEN_UNKNOWN_XML_TAGS_SKELETON (_skeleton);
24660
24661   GVariantBuilder builder;
24662   guint n;
24663   g_variant_builder_init (&builder, G_VARIANT_TYPE ("a{sv}"));
24664   if (_foo_igen_unknown_xml_tags_interface_info.parent_struct.properties == NULL)
24665     goto out;
24666   for (n = 0; _foo_igen_unknown_xml_tags_interface_info.parent_struct.properties[n] != NULL; n++)
24667     {
24668       GDBusPropertyInfo *info = _foo_igen_unknown_xml_tags_interface_info.parent_struct.properties[n];
24669       if (info->flags & G_DBUS_PROPERTY_INFO_FLAGS_READABLE)
24670         {
24671           GVariant *value;
24672           value = _foo_igen_unknown_xml_tags_skeleton_handle_get_property (g_dbus_interface_skeleton_get_connection (G_DBUS_INTERFACE_SKELETON (skeleton)), NULL, g_dbus_interface_skeleton_get_object_path (G_DBUS_INTERFACE_SKELETON (skeleton)), "UnknownXmlTags", info->name, NULL, skeleton);
24673           if (value != NULL)
24674             {
24675               g_variant_take_ref (value);
24676               g_variant_builder_add (&builder, "{sv}", info->name, value);
24677               g_variant_unref (value);
24678             }
24679         }
24680     }
24681 out:
24682   return g_variant_builder_end (&builder);
24683 }
24684
24685 static gboolean _foo_igen_unknown_xml_tags_emit_changed (gpointer user_data);
24686
24687 static void
24688 foo_igen_unknown_xml_tags_skeleton_dbus_interface_flush (GDBusInterfaceSkeleton *_skeleton)
24689 {
24690   FooiGenUnknownXmlTagsSkeleton *skeleton = FOO_IGEN_UNKNOWN_XML_TAGS_SKELETON (_skeleton);
24691   gboolean emit_changed = FALSE;
24692
24693   g_mutex_lock (&skeleton->priv->lock);
24694   if (skeleton->priv->changed_properties_idle_source != NULL)
24695     {
24696       g_source_destroy (skeleton->priv->changed_properties_idle_source);
24697       skeleton->priv->changed_properties_idle_source = NULL;
24698       emit_changed = TRUE;
24699     }
24700   g_mutex_unlock (&skeleton->priv->lock);
24701
24702   if (emit_changed)
24703     _foo_igen_unknown_xml_tags_emit_changed (skeleton);
24704 }
24705
24706 static void
24707 _foo_igen_unknown_xml_tags_on_signal_some_signal (
24708     FooiGenUnknownXmlTags *object)
24709 {
24710   FooiGenUnknownXmlTagsSkeleton *skeleton = FOO_IGEN_UNKNOWN_XML_TAGS_SKELETON (object);
24711
24712   GList      *connections, *l;
24713   GVariant   *signal_variant;
24714   connections = g_dbus_interface_skeleton_get_connections (G_DBUS_INTERFACE_SKELETON (skeleton));
24715
24716   signal_variant = g_variant_ref_sink (g_variant_new ("()"));
24717   for (l = connections; l != NULL; l = l->next)
24718     {
24719       GDBusConnection *connection = l->data;
24720       g_dbus_connection_emit_signal (connection,
24721         NULL, g_dbus_interface_skeleton_get_object_path (G_DBUS_INTERFACE_SKELETON (skeleton)), "UnknownXmlTags", "SomeSignal",
24722         signal_variant, NULL);
24723     }
24724   g_variant_unref (signal_variant);
24725   g_list_free_full (connections, g_object_unref);
24726 }
24727
24728 static void foo_igen_unknown_xml_tags_skeleton_iface_init (FooiGenUnknownXmlTagsIface *iface);
24729 G_DEFINE_TYPE_WITH_CODE (FooiGenUnknownXmlTagsSkeleton, foo_igen_unknown_xml_tags_skeleton, G_TYPE_DBUS_INTERFACE_SKELETON,
24730                          G_IMPLEMENT_INTERFACE (FOO_IGEN_TYPE_UNKNOWN_XML_TAGS, foo_igen_unknown_xml_tags_skeleton_iface_init));
24731
24732 static void
24733 foo_igen_unknown_xml_tags_skeleton_finalize (GObject *object)
24734 {
24735   FooiGenUnknownXmlTagsSkeleton *skeleton = FOO_IGEN_UNKNOWN_XML_TAGS_SKELETON (object);
24736   guint n;
24737   for (n = 0; n < 1; n++)
24738     g_value_unset (&skeleton->priv->properties[n]);
24739   g_free (skeleton->priv->properties);
24740   g_list_free_full (skeleton->priv->changed_properties, (GDestroyNotify) _changed_property_free);
24741   if (skeleton->priv->changed_properties_idle_source != NULL)
24742     g_source_destroy (skeleton->priv->changed_properties_idle_source);
24743   g_main_context_unref (skeleton->priv->context);
24744   g_mutex_clear (&skeleton->priv->lock);
24745   G_OBJECT_CLASS (foo_igen_unknown_xml_tags_skeleton_parent_class)->finalize (object);
24746 }
24747
24748 static void
24749 foo_igen_unknown_xml_tags_skeleton_get_property (GObject      *object,
24750   guint         prop_id,
24751   GValue       *value,
24752   GParamSpec   *pspec)
24753 {
24754   FooiGenUnknownXmlTagsSkeleton *skeleton = FOO_IGEN_UNKNOWN_XML_TAGS_SKELETON (object);
24755   g_assert (prop_id != 0 && prop_id - 1 < 1);
24756   g_mutex_lock (&skeleton->priv->lock);
24757   g_value_copy (&skeleton->priv->properties[prop_id - 1], value);
24758   g_mutex_unlock (&skeleton->priv->lock);
24759 }
24760
24761 static gboolean
24762 _foo_igen_unknown_xml_tags_emit_changed (gpointer user_data)
24763 {
24764   FooiGenUnknownXmlTagsSkeleton *skeleton = FOO_IGEN_UNKNOWN_XML_TAGS_SKELETON (user_data);
24765   GList *l;
24766   GVariantBuilder builder;
24767   GVariantBuilder invalidated_builder;
24768   guint num_changes;
24769
24770   g_mutex_lock (&skeleton->priv->lock);
24771   g_variant_builder_init (&builder, G_VARIANT_TYPE ("a{sv}"));
24772   g_variant_builder_init (&invalidated_builder, G_VARIANT_TYPE ("as"));
24773   for (l = skeleton->priv->changed_properties, num_changes = 0; l != NULL; l = l->next)
24774     {
24775       ChangedProperty *cp = l->data;
24776       GVariant *variant;
24777       const GValue *cur_value;
24778
24779       cur_value = &skeleton->priv->properties[cp->prop_id - 1];
24780       if (!_g_value_equal (cur_value, &cp->orig_value))
24781         {
24782           variant = g_dbus_gvalue_to_gvariant (cur_value, G_VARIANT_TYPE (cp->info->parent_struct.signature));
24783           g_variant_builder_add (&builder, "{sv}", cp->info->parent_struct.name, variant);
24784           g_variant_unref (variant);
24785           num_changes++;
24786         }
24787     }
24788   if (num_changes > 0)
24789     {
24790       GList *connections, *l;
24791       GVariant *signal_variant;
24792       signal_variant = g_variant_ref_sink (g_variant_new ("(sa{sv}as)", "UnknownXmlTags",
24793                                            &builder, &invalidated_builder));
24794       connections = g_dbus_interface_skeleton_get_connections (G_DBUS_INTERFACE_SKELETON (skeleton));
24795       for (l = connections; l != NULL; l = l->next)
24796         {
24797           GDBusConnection *connection = l->data;
24798
24799           g_dbus_connection_emit_signal (connection,
24800                                          NULL, g_dbus_interface_skeleton_get_object_path (G_DBUS_INTERFACE_SKELETON (skeleton)),
24801                                          "org.freedesktop.DBus.Properties",
24802                                          "PropertiesChanged",
24803                                          signal_variant,
24804                                          NULL);
24805         }
24806       g_variant_unref (signal_variant);
24807       g_list_free_full (connections, g_object_unref);
24808     }
24809   else
24810     {
24811       g_variant_builder_clear (&builder);
24812       g_variant_builder_clear (&invalidated_builder);
24813     }
24814   g_list_free_full (skeleton->priv->changed_properties, (GDestroyNotify) _changed_property_free);
24815   skeleton->priv->changed_properties = NULL;
24816   skeleton->priv->changed_properties_idle_source = NULL;
24817   g_mutex_unlock (&skeleton->priv->lock);
24818   return FALSE;
24819 }
24820
24821 static void
24822 _foo_igen_unknown_xml_tags_schedule_emit_changed (FooiGenUnknownXmlTagsSkeleton *skeleton, const _ExtendedGDBusPropertyInfo *info, guint prop_id, const GValue *orig_value)
24823 {
24824   ChangedProperty *cp;
24825   GList *l;
24826   cp = NULL;
24827   for (l = skeleton->priv->changed_properties; l != NULL; l = l->next)
24828     {
24829       ChangedProperty *i_cp = l->data;
24830       if (i_cp->info == info)
24831         {
24832           cp = i_cp;
24833           break;
24834         }
24835     }
24836   if (cp == NULL)
24837     {
24838       cp = g_new0 (ChangedProperty, 1);
24839       cp->prop_id = prop_id;
24840       cp->info = info;
24841       skeleton->priv->changed_properties = g_list_prepend (skeleton->priv->changed_properties, cp);
24842       g_value_init (&cp->orig_value, G_VALUE_TYPE (orig_value));
24843       g_value_copy (orig_value, &cp->orig_value);
24844     }
24845 }
24846
24847 static void
24848 foo_igen_unknown_xml_tags_skeleton_notify (GObject      *object,
24849   GParamSpec *pspec)
24850 {
24851   FooiGenUnknownXmlTagsSkeleton *skeleton = FOO_IGEN_UNKNOWN_XML_TAGS_SKELETON (object);
24852   g_mutex_lock (&skeleton->priv->lock);
24853   if (skeleton->priv->changed_properties != NULL &&
24854       skeleton->priv->changed_properties_idle_source == NULL)
24855     {
24856       skeleton->priv->changed_properties_idle_source = g_idle_source_new ();
24857       g_source_set_priority (skeleton->priv->changed_properties_idle_source, G_PRIORITY_DEFAULT);
24858       g_source_set_callback (skeleton->priv->changed_properties_idle_source, _foo_igen_unknown_xml_tags_emit_changed, g_object_ref (skeleton), (GDestroyNotify) g_object_unref);
24859       g_source_attach (skeleton->priv->changed_properties_idle_source, skeleton->priv->context);
24860       g_source_unref (skeleton->priv->changed_properties_idle_source);
24861     }
24862   g_mutex_unlock (&skeleton->priv->lock);
24863 }
24864
24865 static void
24866 foo_igen_unknown_xml_tags_skeleton_set_property (GObject      *object,
24867   guint         prop_id,
24868   const GValue *value,
24869   GParamSpec   *pspec)
24870 {
24871   FooiGenUnknownXmlTagsSkeleton *skeleton = FOO_IGEN_UNKNOWN_XML_TAGS_SKELETON (object);
24872   g_assert (prop_id != 0 && prop_id - 1 < 1);
24873   g_mutex_lock (&skeleton->priv->lock);
24874   g_object_freeze_notify (object);
24875   if (!_g_value_equal (value, &skeleton->priv->properties[prop_id - 1]))
24876     {
24877       if (g_dbus_interface_skeleton_get_connection (G_DBUS_INTERFACE_SKELETON (skeleton)) != NULL)
24878         _foo_igen_unknown_xml_tags_schedule_emit_changed (skeleton, _foo_igen_unknown_xml_tags_property_info_pointers[prop_id - 1], prop_id, &skeleton->priv->properties[prop_id - 1]);
24879       g_value_copy (value, &skeleton->priv->properties[prop_id - 1]);
24880       g_object_notify_by_pspec (object, pspec);
24881     }
24882   g_mutex_unlock (&skeleton->priv->lock);
24883   g_object_thaw_notify (object);
24884 }
24885
24886 static void
24887 foo_igen_unknown_xml_tags_skeleton_init (FooiGenUnknownXmlTagsSkeleton *skeleton)
24888 {
24889   skeleton->priv = G_TYPE_INSTANCE_GET_PRIVATE (skeleton, FOO_IGEN_TYPE_UNKNOWN_XML_TAGS_SKELETON, FooiGenUnknownXmlTagsSkeletonPrivate);
24890   g_mutex_init (&skeleton->priv->lock);
24891   skeleton->priv->context = g_main_context_ref_thread_default ();
24892   skeleton->priv->properties = g_new0 (GValue, 1);
24893   g_value_init (&skeleton->priv->properties[0], G_TYPE_STRING);
24894 }
24895
24896 static const gchar *
24897 foo_igen_unknown_xml_tags_skeleton_get_some_property (FooiGenUnknownXmlTags *object)
24898 {
24899   FooiGenUnknownXmlTagsSkeleton *skeleton = FOO_IGEN_UNKNOWN_XML_TAGS_SKELETON (object);
24900   const gchar *value;
24901   g_mutex_lock (&skeleton->priv->lock);
24902   value = g_value_get_string (&(skeleton->priv->properties[0]));
24903   g_mutex_unlock (&skeleton->priv->lock);
24904   return value;
24905 }
24906
24907 static void
24908 foo_igen_unknown_xml_tags_skeleton_class_init (FooiGenUnknownXmlTagsSkeletonClass *klass)
24909 {
24910   GObjectClass *gobject_class;
24911   GDBusInterfaceSkeletonClass *skeleton_class;
24912
24913   g_type_class_add_private (klass, sizeof (FooiGenUnknownXmlTagsSkeletonPrivate));
24914
24915   gobject_class = G_OBJECT_CLASS (klass);
24916   gobject_class->finalize = foo_igen_unknown_xml_tags_skeleton_finalize;
24917   gobject_class->get_property = foo_igen_unknown_xml_tags_skeleton_get_property;
24918   gobject_class->set_property = foo_igen_unknown_xml_tags_skeleton_set_property;
24919   gobject_class->notify       = foo_igen_unknown_xml_tags_skeleton_notify;
24920
24921
24922   foo_igen_unknown_xml_tags_override_properties (gobject_class, 1);
24923
24924   skeleton_class = G_DBUS_INTERFACE_SKELETON_CLASS (klass);
24925   skeleton_class->get_info = foo_igen_unknown_xml_tags_skeleton_dbus_interface_get_info;
24926   skeleton_class->get_properties = foo_igen_unknown_xml_tags_skeleton_dbus_interface_get_properties;
24927   skeleton_class->flush = foo_igen_unknown_xml_tags_skeleton_dbus_interface_flush;
24928   skeleton_class->get_vtable = foo_igen_unknown_xml_tags_skeleton_dbus_interface_get_vtable;
24929 }
24930
24931 static void
24932 foo_igen_unknown_xml_tags_skeleton_iface_init (FooiGenUnknownXmlTagsIface *iface)
24933 {
24934   iface->some_signal = _foo_igen_unknown_xml_tags_on_signal_some_signal;
24935   iface->get_some_property = foo_igen_unknown_xml_tags_skeleton_get_some_property;
24936 }
24937
24938 /**
24939  * foo_igen_unknown_xml_tags_skeleton_new:
24940  *
24941  * Creates a skeleton object for the D-Bus interface <link linkend="gdbus-interface-UnknownXmlTags.top_of_page">UnknownXmlTags</link>.
24942  *
24943  * Returns: (transfer full) (type FooiGenUnknownXmlTagsSkeleton): The skeleton object.
24944  */
24945 FooiGenUnknownXmlTags *
24946 foo_igen_unknown_xml_tags_skeleton_new (void)
24947 {
24948   return FOO_IGEN_UNKNOWN_XML_TAGS (g_object_new (FOO_IGEN_TYPE_UNKNOWN_XML_TAGS_SKELETON, NULL));
24949 }
24950
24951 /* ------------------------------------------------------------------------
24952  * Code for interface FDPassing
24953  * ------------------------------------------------------------------------
24954  */
24955
24956 /**
24957  * SECTION:FooiGenFDPassing
24958  * @title: FooiGenFDPassing
24959  * @short_description: Generated C code for the FDPassing D-Bus interface
24960  *
24961  * This section contains code for working with the <link linkend="gdbus-interface-FDPassing.top_of_page">FDPassing</link> D-Bus interface in C.
24962  */
24963
24964 /* ---- Introspection data for FDPassing ---- */
24965
24966 static const _ExtendedGDBusArgInfo _foo_igen_fdpassing_method_info_hello_fd_IN_ARG_greeting =
24967 {
24968   {
24969     -1,
24970     "greeting",
24971     "s",
24972     NULL
24973   },
24974   FALSE
24975 };
24976
24977 static const _ExtendedGDBusArgInfo * const _foo_igen_fdpassing_method_info_hello_fd_IN_ARG_pointers[] =
24978 {
24979   &_foo_igen_fdpassing_method_info_hello_fd_IN_ARG_greeting,
24980   NULL
24981 };
24982
24983 static const _ExtendedGDBusArgInfo _foo_igen_fdpassing_method_info_hello_fd_OUT_ARG_response =
24984 {
24985   {
24986     -1,
24987     "response",
24988     "s",
24989     NULL
24990   },
24991   FALSE
24992 };
24993
24994 static const _ExtendedGDBusArgInfo * const _foo_igen_fdpassing_method_info_hello_fd_OUT_ARG_pointers[] =
24995 {
24996   &_foo_igen_fdpassing_method_info_hello_fd_OUT_ARG_response,
24997   NULL
24998 };
24999
25000 static const _ExtendedGDBusMethodInfo _foo_igen_fdpassing_method_info_hello_fd =
25001 {
25002   {
25003     -1,
25004     "HelloFD",
25005     (GDBusArgInfo **) &_foo_igen_fdpassing_method_info_hello_fd_IN_ARG_pointers,
25006     (GDBusArgInfo **) &_foo_igen_fdpassing_method_info_hello_fd_OUT_ARG_pointers,
25007     NULL
25008   },
25009   "handle-hello-fd",
25010   TRUE
25011 };
25012
25013 static const _ExtendedGDBusMethodInfo * const _foo_igen_fdpassing_method_info_pointers[] =
25014 {
25015   &_foo_igen_fdpassing_method_info_hello_fd,
25016   NULL
25017 };
25018
25019 static const _ExtendedGDBusInterfaceInfo _foo_igen_fdpassing_interface_info =
25020 {
25021   {
25022     -1,
25023     "FDPassing",
25024     (GDBusMethodInfo **) &_foo_igen_fdpassing_method_info_pointers,
25025     NULL,
25026     NULL,
25027     NULL
25028   },
25029   "fdpassing",
25030 };
25031
25032
25033 /**
25034  * foo_igen_fdpassing_interface_info:
25035  *
25036  * Gets a machine-readable description of the <link linkend="gdbus-interface-FDPassing.top_of_page">FDPassing</link> D-Bus interface.
25037  *
25038  * Returns: (transfer none): A #GDBusInterfaceInfo. Do not free.
25039  */
25040 GDBusInterfaceInfo *
25041 foo_igen_fdpassing_interface_info (void)
25042 {
25043   return (GDBusInterfaceInfo *) &_foo_igen_fdpassing_interface_info;
25044 }
25045
25046 /**
25047  * foo_igen_fdpassing_override_properties:
25048  * @klass: The class structure for a #GObject<!-- -->-derived class.
25049  * @property_id_begin: The property id to assign to the first overridden property.
25050  *
25051  * Overrides all #GObject properties in the #FooiGenFDPassing interface for a concrete class.
25052  * The properties are overridden in the order they are defined.
25053  *
25054  * Returns: The last property id.
25055  */
25056 guint
25057 foo_igen_fdpassing_override_properties (GObjectClass *klass, guint property_id_begin)
25058 {
25059   return property_id_begin - 1;
25060 }
25061
25062
25063
25064 /**
25065  * FooiGenFDPassing:
25066  *
25067  * Abstract interface type for the D-Bus interface <link linkend="gdbus-interface-FDPassing.top_of_page">FDPassing</link>.
25068  */
25069
25070 /**
25071  * FooiGenFDPassingIface:
25072  * @parent_iface: The parent interface.
25073  * @handle_hello_fd: Handler for the #FooiGenFDPassing::handle-hello-fd signal.
25074  *
25075  * Virtual table for the D-Bus interface <link linkend="gdbus-interface-FDPassing.top_of_page">FDPassing</link>.
25076  */
25077
25078 static void
25079 foo_igen_fdpassing_default_init (FooiGenFDPassingIface *iface)
25080 {
25081   /* GObject signals for incoming D-Bus method calls: */
25082   /**
25083    * FooiGenFDPassing::handle-hello-fd:
25084    * @object: A #FooiGenFDPassing.
25085    * @invocation: A #GDBusMethodInvocation.
25086    * @fd_list: (allow-none): A #GUnixFDList or %NULL.
25087    * @arg_greeting: Argument passed by remote caller.
25088    *
25089    * Signal emitted when a remote caller is invoking the <link linkend="gdbus-method-FDPassing.HelloFD">HelloFD()</link> D-Bus method.
25090    *
25091    * If a signal handler returns %TRUE, it means the signal handler will handle the invocation (e.g. take a reference to @invocation and eventually call foo_igen_fdpassing_complete_hello_fd() or e.g. g_dbus_method_invocation_return_error() on it) and no order signal handlers will run. If no signal handler handles the invocation, the %G_DBUS_ERROR_UNKNOWN_METHOD error is returned.
25092    *
25093    * Returns: %TRUE if the invocation was handled, %FALSE to let other signal handlers run.
25094    */
25095   g_signal_new ("handle-hello-fd",
25096     G_TYPE_FROM_INTERFACE (iface),
25097     G_SIGNAL_RUN_LAST,
25098     G_STRUCT_OFFSET (FooiGenFDPassingIface, handle_hello_fd),
25099     g_signal_accumulator_true_handled,
25100     NULL,
25101     g_cclosure_marshal_generic,
25102     G_TYPE_BOOLEAN,
25103     3,
25104     G_TYPE_DBUS_METHOD_INVOCATION, G_TYPE_UNIX_FD_LIST, G_TYPE_STRING);
25105
25106 }
25107
25108 typedef FooiGenFDPassingIface FooiGenFDPassingInterface;
25109 G_DEFINE_INTERFACE (FooiGenFDPassing, foo_igen_fdpassing, G_TYPE_OBJECT);
25110
25111 /**
25112  * foo_igen_fdpassing_call_hello_fd:
25113  * @proxy: A #FooiGenFDPassingProxy.
25114  * @arg_greeting: Argument to pass with the method invocation.
25115  * @fd_list: (allow-none): A #GUnixFDList or %NULL.
25116  * @cancellable: (allow-none): A #GCancellable or %NULL.
25117  * @callback: A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
25118  * @user_data: User data to pass to @callback.
25119  *
25120  * Asynchronously invokes the <link linkend="gdbus-method-FDPassing.HelloFD">HelloFD()</link> D-Bus method on @proxy.
25121  * When the operation is finished, @callback will be invoked in the <link linkend="g-main-context-push-thread-default">thread-default main loop</link> of the thread you are calling this method from.
25122  * You can then call foo_igen_fdpassing_call_hello_fd_finish() to get the result of the operation.
25123  *
25124  * See foo_igen_fdpassing_call_hello_fd_sync() for the synchronous, blocking version of this method.
25125  */
25126 void
25127 foo_igen_fdpassing_call_hello_fd (
25128     FooiGenFDPassing *proxy,
25129     const gchar *arg_greeting,
25130     GUnixFDList *fd_list,
25131     GCancellable *cancellable,
25132     GAsyncReadyCallback callback,
25133     gpointer user_data)
25134 {
25135   g_dbus_proxy_call_with_unix_fd_list (G_DBUS_PROXY (proxy),
25136     "HelloFD",
25137     g_variant_new ("(s)",
25138                    arg_greeting),
25139     G_DBUS_CALL_FLAGS_NONE,
25140     -1,
25141     fd_list,
25142     cancellable,
25143     callback,
25144     user_data);
25145 }
25146
25147 /**
25148  * foo_igen_fdpassing_call_hello_fd_finish:
25149  * @proxy: A #FooiGenFDPassingProxy.
25150  * @out_response: (out): Return location for return parameter or %NULL to ignore.
25151  * @out_fd_list: (out): Return location for a #GUnixFDList or %NULL.
25152  * @res: The #GAsyncResult obtained from the #GAsyncReadyCallback passed to foo_igen_fdpassing_call_hello_fd().
25153  * @error: Return location for error or %NULL.
25154  *
25155  * Finishes an operation started with foo_igen_fdpassing_call_hello_fd().
25156  *
25157  * Returns: (skip): %TRUE if the call succeded, %FALSE if @error is set.
25158  */
25159 gboolean
25160 foo_igen_fdpassing_call_hello_fd_finish (
25161     FooiGenFDPassing *proxy,
25162     gchar **out_response,
25163     GUnixFDList **out_fd_list,
25164     GAsyncResult *res,
25165     GError **error)
25166 {
25167   GVariant *_ret;
25168   _ret = g_dbus_proxy_call_with_unix_fd_list_finish (G_DBUS_PROXY (proxy), out_fd_list, res, error);
25169   if (_ret == NULL)
25170     goto _out;
25171   g_variant_get (_ret,
25172                  "(s)",
25173                  out_response);
25174   g_variant_unref (_ret);
25175 _out:
25176   return _ret != NULL;
25177 }
25178
25179 /**
25180  * foo_igen_fdpassing_call_hello_fd_sync:
25181  * @proxy: A #FooiGenFDPassingProxy.
25182  * @arg_greeting: Argument to pass with the method invocation.
25183  * @fd_list: (allow-none): A #GUnixFDList or %NULL.
25184  * @out_response: (out): Return location for return parameter or %NULL to ignore.
25185  * @out_fd_list: (out): Return location for a #GUnixFDList or %NULL.
25186  * @cancellable: (allow-none): A #GCancellable or %NULL.
25187  * @error: Return location for error or %NULL.
25188  *
25189  * Synchronously invokes the <link linkend="gdbus-method-FDPassing.HelloFD">HelloFD()</link> D-Bus method on @proxy. The calling thread is blocked until a reply is received.
25190  *
25191  * See foo_igen_fdpassing_call_hello_fd() for the asynchronous version of this method.
25192  *
25193  * Returns: (skip): %TRUE if the call succeded, %FALSE if @error is set.
25194  */
25195 gboolean
25196 foo_igen_fdpassing_call_hello_fd_sync (
25197     FooiGenFDPassing *proxy,
25198     const gchar *arg_greeting,
25199     GUnixFDList  *fd_list,
25200     gchar **out_response,
25201     GUnixFDList **out_fd_list,
25202     GCancellable *cancellable,
25203     GError **error)
25204 {
25205   GVariant *_ret;
25206   _ret = g_dbus_proxy_call_with_unix_fd_list_sync (G_DBUS_PROXY (proxy),
25207     "HelloFD",
25208     g_variant_new ("(s)",
25209                    arg_greeting),
25210     G_DBUS_CALL_FLAGS_NONE,
25211     -1,
25212     fd_list,
25213     out_fd_list,
25214     cancellable,
25215     error);
25216   if (_ret == NULL)
25217     goto _out;
25218   g_variant_get (_ret,
25219                  "(s)",
25220                  out_response);
25221   g_variant_unref (_ret);
25222 _out:
25223   return _ret != NULL;
25224 }
25225
25226 /**
25227  * foo_igen_fdpassing_complete_hello_fd:
25228  * @object: A #FooiGenFDPassing.
25229  * @invocation: (transfer full): A #GDBusMethodInvocation.
25230  * @fd_list: (allow-none): A #GUnixFDList or %NULL.
25231  * @response: Parameter to return.
25232  *
25233  * Helper function used in service implementations to finish handling invocations of the <link linkend="gdbus-method-FDPassing.HelloFD">HelloFD()</link> D-Bus method. If you instead want to finish handling an invocation by returning an error, use g_dbus_method_invocation_return_error() or similar.
25234  *
25235  * This method will free @invocation, you cannot use it afterwards.
25236  */
25237 void
25238 foo_igen_fdpassing_complete_hello_fd (
25239     FooiGenFDPassing *object,
25240     GDBusMethodInvocation *invocation,
25241     GUnixFDList *fd_list,
25242     const gchar *response)
25243 {
25244   g_dbus_method_invocation_return_value_with_unix_fd_list (invocation,
25245     g_variant_new ("(s)",
25246                    response),
25247     fd_list);
25248 }
25249
25250 /* ------------------------------------------------------------------------ */
25251
25252 /**
25253  * FooiGenFDPassingProxy:
25254  *
25255  * The #FooiGenFDPassingProxy structure contains only private data and should only be accessed using the provided API.
25256  */
25257
25258 /**
25259  * FooiGenFDPassingProxyClass:
25260  * @parent_class: The parent class.
25261  *
25262  * Class structure for #FooiGenFDPassingProxy.
25263  */
25264
25265 struct _FooiGenFDPassingProxyPrivate
25266 {
25267   GData *qdata;
25268 };
25269
25270 static void foo_igen_fdpassing_proxy_iface_init (FooiGenFDPassingIface *iface);
25271
25272 G_DEFINE_TYPE_WITH_CODE (FooiGenFDPassingProxy, foo_igen_fdpassing_proxy, G_TYPE_DBUS_PROXY,
25273                          G_IMPLEMENT_INTERFACE (FOO_IGEN_TYPE_FDPASSING, foo_igen_fdpassing_proxy_iface_init));
25274
25275 static void
25276 foo_igen_fdpassing_proxy_finalize (GObject *object)
25277 {
25278   FooiGenFDPassingProxy *proxy = FOO_IGEN_FDPASSING_PROXY (object);
25279   g_datalist_clear (&proxy->priv->qdata);
25280   G_OBJECT_CLASS (foo_igen_fdpassing_proxy_parent_class)->finalize (object);
25281 }
25282
25283 static void
25284 foo_igen_fdpassing_proxy_get_property (GObject      *object,
25285   guint         prop_id,
25286   GValue       *value,
25287   GParamSpec   *pspec)
25288 {
25289 }
25290
25291 static void
25292 foo_igen_fdpassing_proxy_set_property (GObject      *object,
25293   guint         prop_id,
25294   const GValue *value,
25295   GParamSpec   *pspec)
25296 {
25297 }
25298
25299 static void
25300 foo_igen_fdpassing_proxy_g_signal (GDBusProxy *proxy,
25301   const gchar *sender_name,
25302   const gchar *signal_name,
25303   GVariant *parameters)
25304 {
25305   _ExtendedGDBusSignalInfo *info;
25306   GVariantIter iter;
25307   GVariant *child;
25308   GValue *paramv;
25309   guint num_params;
25310   guint n;
25311   guint signal_id;
25312   info = (_ExtendedGDBusSignalInfo *) g_dbus_interface_info_lookup_signal ((GDBusInterfaceInfo *) &_foo_igen_fdpassing_interface_info, signal_name);
25313   if (info == NULL)
25314     return;
25315   num_params = g_variant_n_children (parameters);
25316   paramv = g_new0 (GValue, num_params + 1);
25317   g_value_init (&paramv[0], FOO_IGEN_TYPE_FDPASSING);
25318   g_value_set_object (&paramv[0], proxy);
25319   g_variant_iter_init (&iter, parameters);
25320   n = 1;
25321   while ((child = g_variant_iter_next_value (&iter)) != NULL)
25322     {
25323       _ExtendedGDBusArgInfo *arg_info = (_ExtendedGDBusArgInfo *) info->parent_struct.args[n - 1];
25324       if (arg_info->use_gvariant)
25325         {
25326           g_value_init (&paramv[n], G_TYPE_VARIANT);
25327           g_value_set_variant (&paramv[n], child);
25328           n++;
25329         }
25330       else
25331         g_dbus_gvariant_to_gvalue (child, &paramv[n++]);
25332       g_variant_unref (child);
25333     }
25334   signal_id = g_signal_lookup (info->signal_name, FOO_IGEN_TYPE_FDPASSING);
25335   g_signal_emitv (paramv, signal_id, 0, NULL);
25336   for (n = 0; n < num_params + 1; n++)
25337     g_value_unset (&paramv[n]);
25338   g_free (paramv);
25339 }
25340
25341 static void
25342 foo_igen_fdpassing_proxy_g_properties_changed (GDBusProxy *_proxy,
25343   GVariant *changed_properties,
25344   const gchar *const *invalidated_properties)
25345 {
25346   FooiGenFDPassingProxy *proxy = FOO_IGEN_FDPASSING_PROXY (_proxy);
25347   guint n;
25348   const gchar *key;
25349   GVariantIter *iter;
25350   _ExtendedGDBusPropertyInfo *info;
25351   g_variant_get (changed_properties, "a{sv}", &iter);
25352   while (g_variant_iter_next (iter, "{&sv}", &key, NULL))
25353     {
25354       info = (_ExtendedGDBusPropertyInfo *) g_dbus_interface_info_lookup_property ((GDBusInterfaceInfo *) &_foo_igen_fdpassing_interface_info, key);
25355       g_datalist_remove_data (&proxy->priv->qdata, key);
25356       if (info != NULL)
25357         g_object_notify (G_OBJECT (proxy), info->hyphen_name);
25358     }
25359   g_variant_iter_free (iter);
25360   for (n = 0; invalidated_properties[n] != NULL; n++)
25361     {
25362       info = (_ExtendedGDBusPropertyInfo *) g_dbus_interface_info_lookup_property ((GDBusInterfaceInfo *) &_foo_igen_fdpassing_interface_info, invalidated_properties[n]);
25363       g_datalist_remove_data (&proxy->priv->qdata, invalidated_properties[n]);
25364       if (info != NULL)
25365         g_object_notify (G_OBJECT (proxy), info->hyphen_name);
25366     }
25367 }
25368
25369 static void
25370 foo_igen_fdpassing_proxy_init (FooiGenFDPassingProxy *proxy)
25371 {
25372   proxy->priv = G_TYPE_INSTANCE_GET_PRIVATE (proxy, FOO_IGEN_TYPE_FDPASSING_PROXY, FooiGenFDPassingProxyPrivate);
25373   g_dbus_proxy_set_interface_info (G_DBUS_PROXY (proxy), foo_igen_fdpassing_interface_info ());
25374 }
25375
25376 static void
25377 foo_igen_fdpassing_proxy_class_init (FooiGenFDPassingProxyClass *klass)
25378 {
25379   GObjectClass *gobject_class;
25380   GDBusProxyClass *proxy_class;
25381
25382   g_type_class_add_private (klass, sizeof (FooiGenFDPassingProxyPrivate));
25383
25384   gobject_class = G_OBJECT_CLASS (klass);
25385   gobject_class->finalize     = foo_igen_fdpassing_proxy_finalize;
25386   gobject_class->get_property = foo_igen_fdpassing_proxy_get_property;
25387   gobject_class->set_property = foo_igen_fdpassing_proxy_set_property;
25388
25389   proxy_class = G_DBUS_PROXY_CLASS (klass);
25390   proxy_class->g_signal = foo_igen_fdpassing_proxy_g_signal;
25391   proxy_class->g_properties_changed = foo_igen_fdpassing_proxy_g_properties_changed;
25392
25393 }
25394
25395 static void
25396 foo_igen_fdpassing_proxy_iface_init (FooiGenFDPassingIface *iface)
25397 {
25398 }
25399
25400 /**
25401  * foo_igen_fdpassing_proxy_new:
25402  * @connection: A #GDBusConnection.
25403  * @flags: Flags from the #GDBusProxyFlags enumeration.
25404  * @name: (allow-none): A bus name (well-known or unique) or %NULL if @connection is not a message bus connection.
25405  * @object_path: An object path.
25406  * @cancellable: (allow-none): A #GCancellable or %NULL.
25407  * @callback: A #GAsyncReadyCallback to call when the request is satisfied.
25408  * @user_data: User data to pass to @callback.
25409  *
25410  * Asynchronously creates a proxy for the D-Bus interface <link linkend="gdbus-interface-FDPassing.top_of_page">FDPassing</link>. See g_dbus_proxy_new() for more details.
25411  *
25412  * When the operation is finished, @callback will be invoked in the <link linkend="g-main-context-push-thread-default">thread-default main loop</link> of the thread you are calling this method from.
25413  * You can then call foo_igen_fdpassing_proxy_new_finish() to get the result of the operation.
25414  *
25415  * See foo_igen_fdpassing_proxy_new_sync() for the synchronous, blocking version of this constructor.
25416  */
25417 void
25418 foo_igen_fdpassing_proxy_new (
25419     GDBusConnection     *connection,
25420     GDBusProxyFlags      flags,
25421     const gchar         *name,
25422     const gchar         *object_path,
25423     GCancellable        *cancellable,
25424     GAsyncReadyCallback  callback,
25425     gpointer             user_data)
25426 {
25427   g_async_initable_new_async (FOO_IGEN_TYPE_FDPASSING_PROXY, G_PRIORITY_DEFAULT, cancellable, callback, user_data, "g-flags", flags, "g-name", name, "g-connection", connection, "g-object-path", object_path, "g-interface-name", "FDPassing", NULL);
25428 }
25429
25430 /**
25431  * foo_igen_fdpassing_proxy_new_finish:
25432  * @res: The #GAsyncResult obtained from the #GAsyncReadyCallback passed to foo_igen_fdpassing_proxy_new().
25433  * @error: Return location for error or %NULL
25434  *
25435  * Finishes an operation started with foo_igen_fdpassing_proxy_new().
25436  *
25437  * Returns: (transfer full) (type FooiGenFDPassingProxy): The constructed proxy object or %NULL if @error is set.
25438  */
25439 FooiGenFDPassing *
25440 foo_igen_fdpassing_proxy_new_finish (
25441     GAsyncResult        *res,
25442     GError             **error)
25443 {
25444   GObject *ret;
25445   GObject *source_object;
25446   source_object = g_async_result_get_source_object (res);
25447   ret = g_async_initable_new_finish (G_ASYNC_INITABLE (source_object), res, error);
25448   g_object_unref (source_object);
25449   if (ret != NULL)
25450     return FOO_IGEN_FDPASSING (ret);
25451   else
25452     return NULL;
25453 }
25454
25455 /**
25456  * foo_igen_fdpassing_proxy_new_sync:
25457  * @connection: A #GDBusConnection.
25458  * @flags: Flags from the #GDBusProxyFlags enumeration.
25459  * @name: (allow-none): A bus name (well-known or unique) or %NULL if @connection is not a message bus connection.
25460  * @object_path: An object path.
25461  * @cancellable: (allow-none): A #GCancellable or %NULL.
25462  * @error: Return location for error or %NULL
25463  *
25464  * Synchronously creates a proxy for the D-Bus interface <link linkend="gdbus-interface-FDPassing.top_of_page">FDPassing</link>. See g_dbus_proxy_new_sync() for more details.
25465  *
25466  * The calling thread is blocked until a reply is received.
25467  *
25468  * See foo_igen_fdpassing_proxy_new() for the asynchronous version of this constructor.
25469  *
25470  * Returns: (transfer full) (type FooiGenFDPassingProxy): The constructed proxy object or %NULL if @error is set.
25471  */
25472 FooiGenFDPassing *
25473 foo_igen_fdpassing_proxy_new_sync (
25474     GDBusConnection     *connection,
25475     GDBusProxyFlags      flags,
25476     const gchar         *name,
25477     const gchar         *object_path,
25478     GCancellable        *cancellable,
25479     GError             **error)
25480 {
25481   GInitable *ret;
25482   ret = g_initable_new (FOO_IGEN_TYPE_FDPASSING_PROXY, cancellable, error, "g-flags", flags, "g-name", name, "g-connection", connection, "g-object-path", object_path, "g-interface-name", "FDPassing", NULL);
25483   if (ret != NULL)
25484     return FOO_IGEN_FDPASSING (ret);
25485   else
25486     return NULL;
25487 }
25488
25489
25490 /**
25491  * foo_igen_fdpassing_proxy_new_for_bus:
25492  * @bus_type: A #GBusType.
25493  * @flags: Flags from the #GDBusProxyFlags enumeration.
25494  * @name: A bus name (well-known or unique).
25495  * @object_path: An object path.
25496  * @cancellable: (allow-none): A #GCancellable or %NULL.
25497  * @callback: A #GAsyncReadyCallback to call when the request is satisfied.
25498  * @user_data: User data to pass to @callback.
25499  *
25500  * Like foo_igen_fdpassing_proxy_new() but takes a #GBusType instead of a #GDBusConnection.
25501  *
25502  * When the operation is finished, @callback will be invoked in the <link linkend="g-main-context-push-thread-default">thread-default main loop</link> of the thread you are calling this method from.
25503  * You can then call foo_igen_fdpassing_proxy_new_for_bus_finish() to get the result of the operation.
25504  *
25505  * See foo_igen_fdpassing_proxy_new_for_bus_sync() for the synchronous, blocking version of this constructor.
25506  */
25507 void
25508 foo_igen_fdpassing_proxy_new_for_bus (
25509     GBusType             bus_type,
25510     GDBusProxyFlags      flags,
25511     const gchar         *name,
25512     const gchar         *object_path,
25513     GCancellable        *cancellable,
25514     GAsyncReadyCallback  callback,
25515     gpointer             user_data)
25516 {
25517   g_async_initable_new_async (FOO_IGEN_TYPE_FDPASSING_PROXY, G_PRIORITY_DEFAULT, cancellable, callback, user_data, "g-flags", flags, "g-name", name, "g-bus-type", bus_type, "g-object-path", object_path, "g-interface-name", "FDPassing", NULL);
25518 }
25519
25520 /**
25521  * foo_igen_fdpassing_proxy_new_for_bus_finish:
25522  * @res: The #GAsyncResult obtained from the #GAsyncReadyCallback passed to foo_igen_fdpassing_proxy_new_for_bus().
25523  * @error: Return location for error or %NULL
25524  *
25525  * Finishes an operation started with foo_igen_fdpassing_proxy_new_for_bus().
25526  *
25527  * Returns: (transfer full) (type FooiGenFDPassingProxy): The constructed proxy object or %NULL if @error is set.
25528  */
25529 FooiGenFDPassing *
25530 foo_igen_fdpassing_proxy_new_for_bus_finish (
25531     GAsyncResult        *res,
25532     GError             **error)
25533 {
25534   GObject *ret;
25535   GObject *source_object;
25536   source_object = g_async_result_get_source_object (res);
25537   ret = g_async_initable_new_finish (G_ASYNC_INITABLE (source_object), res, error);
25538   g_object_unref (source_object);
25539   if (ret != NULL)
25540     return FOO_IGEN_FDPASSING (ret);
25541   else
25542     return NULL;
25543 }
25544
25545 /**
25546  * foo_igen_fdpassing_proxy_new_for_bus_sync:
25547  * @bus_type: A #GBusType.
25548  * @flags: Flags from the #GDBusProxyFlags enumeration.
25549  * @name: A bus name (well-known or unique).
25550  * @object_path: An object path.
25551  * @cancellable: (allow-none): A #GCancellable or %NULL.
25552  * @error: Return location for error or %NULL
25553  *
25554  * Like foo_igen_fdpassing_proxy_new_sync() but takes a #GBusType instead of a #GDBusConnection.
25555  *
25556  * The calling thread is blocked until a reply is received.
25557  *
25558  * See foo_igen_fdpassing_proxy_new_for_bus() for the asynchronous version of this constructor.
25559  *
25560  * Returns: (transfer full) (type FooiGenFDPassingProxy): The constructed proxy object or %NULL if @error is set.
25561  */
25562 FooiGenFDPassing *
25563 foo_igen_fdpassing_proxy_new_for_bus_sync (
25564     GBusType             bus_type,
25565     GDBusProxyFlags      flags,
25566     const gchar         *name,
25567     const gchar         *object_path,
25568     GCancellable        *cancellable,
25569     GError             **error)
25570 {
25571   GInitable *ret;
25572   ret = g_initable_new (FOO_IGEN_TYPE_FDPASSING_PROXY, cancellable, error, "g-flags", flags, "g-name", name, "g-bus-type", bus_type, "g-object-path", object_path, "g-interface-name", "FDPassing", NULL);
25573   if (ret != NULL)
25574     return FOO_IGEN_FDPASSING (ret);
25575   else
25576     return NULL;
25577 }
25578
25579
25580 /* ------------------------------------------------------------------------ */
25581
25582 /**
25583  * FooiGenFDPassingSkeleton:
25584  *
25585  * The #FooiGenFDPassingSkeleton structure contains only private data and should only be accessed using the provided API.
25586  */
25587
25588 /**
25589  * FooiGenFDPassingSkeletonClass:
25590  * @parent_class: The parent class.
25591  *
25592  * Class structure for #FooiGenFDPassingSkeleton.
25593  */
25594
25595 struct _FooiGenFDPassingSkeletonPrivate
25596 {
25597   GValue *properties;
25598   GList *changed_properties;
25599   GSource *changed_properties_idle_source;
25600   GMainContext *context;
25601   GMutex lock;
25602 };
25603
25604 static void
25605 _foo_igen_fdpassing_skeleton_handle_method_call (
25606   GDBusConnection *connection,
25607   const gchar *sender,
25608   const gchar *object_path,
25609   const gchar *interface_name,
25610   const gchar *method_name,
25611   GVariant *parameters,
25612   GDBusMethodInvocation *invocation,
25613   gpointer user_data)
25614 {
25615   FooiGenFDPassingSkeleton *skeleton = FOO_IGEN_FDPASSING_SKELETON (user_data);
25616   _ExtendedGDBusMethodInfo *info;
25617   GVariantIter iter;
25618   GVariant *child;
25619   GValue *paramv;
25620   guint num_params;
25621   guint num_extra;
25622   guint n;
25623   guint signal_id;
25624   GValue return_value = G_VALUE_INIT;
25625   info = (_ExtendedGDBusMethodInfo *) g_dbus_method_invocation_get_method_info (invocation);
25626   g_assert (info != NULL);
25627   num_params = g_variant_n_children (parameters);
25628   num_extra = info->pass_fdlist ? 3 : 2;  paramv = g_new0 (GValue, num_params + num_extra);
25629   n = 0;
25630   g_value_init (&paramv[n], FOO_IGEN_TYPE_FDPASSING);
25631   g_value_set_object (&paramv[n++], skeleton);
25632   g_value_init (&paramv[n], G_TYPE_DBUS_METHOD_INVOCATION);
25633   g_value_set_object (&paramv[n++], invocation);
25634   if (info->pass_fdlist)
25635     {
25636 #ifdef G_OS_UNIX
25637       g_value_init (&paramv[n], G_TYPE_UNIX_FD_LIST);
25638       g_value_set_object (&paramv[n++], g_dbus_message_get_unix_fd_list (g_dbus_method_invocation_get_message (invocation)));
25639 #else
25640       g_assert_not_reached ();
25641 #endif
25642     }
25643   g_variant_iter_init (&iter, parameters);
25644   while ((child = g_variant_iter_next_value (&iter)) != NULL)
25645     {
25646       _ExtendedGDBusArgInfo *arg_info = (_ExtendedGDBusArgInfo *) info->parent_struct.in_args[n - num_extra];
25647       if (arg_info->use_gvariant)
25648         {
25649           g_value_init (&paramv[n], G_TYPE_VARIANT);
25650           g_value_set_variant (&paramv[n], child);
25651           n++;
25652         }
25653       else
25654         g_dbus_gvariant_to_gvalue (child, &paramv[n++]);
25655       g_variant_unref (child);
25656     }
25657   signal_id = g_signal_lookup (info->signal_name, FOO_IGEN_TYPE_FDPASSING);
25658   g_value_init (&return_value, G_TYPE_BOOLEAN);
25659   g_signal_emitv (paramv, signal_id, 0, &return_value);
25660   if (!g_value_get_boolean (&return_value))
25661     g_dbus_method_invocation_return_error (invocation, G_DBUS_ERROR, G_DBUS_ERROR_UNKNOWN_METHOD, "Method %s is not implemented on interface %s", method_name, interface_name);
25662   g_value_unset (&return_value);
25663   for (n = 0; n < num_params + num_extra; n++)
25664     g_value_unset (&paramv[n]);
25665   g_free (paramv);
25666 }
25667
25668 static GVariant *
25669 _foo_igen_fdpassing_skeleton_handle_get_property (
25670   GDBusConnection *connection,
25671   const gchar *sender,
25672   const gchar *object_path,
25673   const gchar *interface_name,
25674   const gchar *property_name,
25675   GError **error,
25676   gpointer user_data)
25677 {
25678   FooiGenFDPassingSkeleton *skeleton = FOO_IGEN_FDPASSING_SKELETON (user_data);
25679   GValue value = G_VALUE_INIT;
25680   GParamSpec *pspec;
25681   _ExtendedGDBusPropertyInfo *info;
25682   GVariant *ret;
25683   ret = NULL;
25684   info = (_ExtendedGDBusPropertyInfo *) g_dbus_interface_info_lookup_property ((GDBusInterfaceInfo *) &_foo_igen_fdpassing_interface_info, property_name);
25685   g_assert (info != NULL);
25686   pspec = g_object_class_find_property (G_OBJECT_GET_CLASS (skeleton), info->hyphen_name);
25687   if (pspec == NULL)
25688     {
25689       g_set_error (error, G_DBUS_ERROR, G_DBUS_ERROR_INVALID_ARGS, "No property with name %s", property_name);
25690     }
25691   else
25692     {
25693       g_value_init (&value, pspec->value_type);
25694       g_object_get_property (G_OBJECT (skeleton), info->hyphen_name, &value);
25695       ret = g_dbus_gvalue_to_gvariant (&value, G_VARIANT_TYPE (info->parent_struct.signature));
25696       g_value_unset (&value);
25697     }
25698   return ret;
25699 }
25700
25701 static gboolean
25702 _foo_igen_fdpassing_skeleton_handle_set_property (
25703   GDBusConnection *connection,
25704   const gchar *sender,
25705   const gchar *object_path,
25706   const gchar *interface_name,
25707   const gchar *property_name,
25708   GVariant *variant,
25709   GError **error,
25710   gpointer user_data)
25711 {
25712   FooiGenFDPassingSkeleton *skeleton = FOO_IGEN_FDPASSING_SKELETON (user_data);
25713   GValue value = G_VALUE_INIT;
25714   GParamSpec *pspec;
25715   _ExtendedGDBusPropertyInfo *info;
25716   gboolean ret;
25717   ret = FALSE;
25718   info = (_ExtendedGDBusPropertyInfo *) g_dbus_interface_info_lookup_property ((GDBusInterfaceInfo *) &_foo_igen_fdpassing_interface_info, property_name);
25719   g_assert (info != NULL);
25720   pspec = g_object_class_find_property (G_OBJECT_GET_CLASS (skeleton), info->hyphen_name);
25721   if (pspec == NULL)
25722     {
25723       g_set_error (error, G_DBUS_ERROR, G_DBUS_ERROR_INVALID_ARGS, "No property with name %s", property_name);
25724     }
25725   else
25726     {
25727       if (info->use_gvariant)
25728         g_value_set_variant (&value, variant);
25729       else
25730         g_dbus_gvariant_to_gvalue (variant, &value);
25731       g_object_set_property (G_OBJECT (skeleton), info->hyphen_name, &value);
25732       g_value_unset (&value);
25733       ret = TRUE;
25734     }
25735   return ret;
25736 }
25737
25738 static const GDBusInterfaceVTable _foo_igen_fdpassing_skeleton_vtable =
25739 {
25740   _foo_igen_fdpassing_skeleton_handle_method_call,
25741   _foo_igen_fdpassing_skeleton_handle_get_property,
25742   _foo_igen_fdpassing_skeleton_handle_set_property
25743 };
25744
25745 static GDBusInterfaceInfo *
25746 foo_igen_fdpassing_skeleton_dbus_interface_get_info (GDBusInterfaceSkeleton *skeleton)
25747 {
25748   return foo_igen_fdpassing_interface_info ();
25749 }
25750
25751 static GDBusInterfaceVTable *
25752 foo_igen_fdpassing_skeleton_dbus_interface_get_vtable (GDBusInterfaceSkeleton *skeleton)
25753 {
25754   return (GDBusInterfaceVTable *) &_foo_igen_fdpassing_skeleton_vtable;
25755 }
25756
25757 static GVariant *
25758 foo_igen_fdpassing_skeleton_dbus_interface_get_properties (GDBusInterfaceSkeleton *_skeleton)
25759 {
25760   FooiGenFDPassingSkeleton *skeleton = FOO_IGEN_FDPASSING_SKELETON (_skeleton);
25761
25762   GVariantBuilder builder;
25763   guint n;
25764   g_variant_builder_init (&builder, G_VARIANT_TYPE ("a{sv}"));
25765   if (_foo_igen_fdpassing_interface_info.parent_struct.properties == NULL)
25766     goto out;
25767   for (n = 0; _foo_igen_fdpassing_interface_info.parent_struct.properties[n] != NULL; n++)
25768     {
25769       GDBusPropertyInfo *info = _foo_igen_fdpassing_interface_info.parent_struct.properties[n];
25770       if (info->flags & G_DBUS_PROPERTY_INFO_FLAGS_READABLE)
25771         {
25772           GVariant *value;
25773           value = _foo_igen_fdpassing_skeleton_handle_get_property (g_dbus_interface_skeleton_get_connection (G_DBUS_INTERFACE_SKELETON (skeleton)), NULL, g_dbus_interface_skeleton_get_object_path (G_DBUS_INTERFACE_SKELETON (skeleton)), "FDPassing", info->name, NULL, skeleton);
25774           if (value != NULL)
25775             {
25776               g_variant_take_ref (value);
25777               g_variant_builder_add (&builder, "{sv}", info->name, value);
25778               g_variant_unref (value);
25779             }
25780         }
25781     }
25782 out:
25783   return g_variant_builder_end (&builder);
25784 }
25785
25786 static void
25787 foo_igen_fdpassing_skeleton_dbus_interface_flush (GDBusInterfaceSkeleton *_skeleton)
25788 {
25789 }
25790
25791 static void foo_igen_fdpassing_skeleton_iface_init (FooiGenFDPassingIface *iface);
25792 G_DEFINE_TYPE_WITH_CODE (FooiGenFDPassingSkeleton, foo_igen_fdpassing_skeleton, G_TYPE_DBUS_INTERFACE_SKELETON,
25793                          G_IMPLEMENT_INTERFACE (FOO_IGEN_TYPE_FDPASSING, foo_igen_fdpassing_skeleton_iface_init));
25794
25795 static void
25796 foo_igen_fdpassing_skeleton_finalize (GObject *object)
25797 {
25798   FooiGenFDPassingSkeleton *skeleton = FOO_IGEN_FDPASSING_SKELETON (object);
25799   g_list_free_full (skeleton->priv->changed_properties, (GDestroyNotify) _changed_property_free);
25800   if (skeleton->priv->changed_properties_idle_source != NULL)
25801     g_source_destroy (skeleton->priv->changed_properties_idle_source);
25802   g_main_context_unref (skeleton->priv->context);
25803   g_mutex_clear (&skeleton->priv->lock);
25804   G_OBJECT_CLASS (foo_igen_fdpassing_skeleton_parent_class)->finalize (object);
25805 }
25806
25807 static void
25808 foo_igen_fdpassing_skeleton_init (FooiGenFDPassingSkeleton *skeleton)
25809 {
25810   skeleton->priv = G_TYPE_INSTANCE_GET_PRIVATE (skeleton, FOO_IGEN_TYPE_FDPASSING_SKELETON, FooiGenFDPassingSkeletonPrivate);
25811   g_mutex_init (&skeleton->priv->lock);
25812   skeleton->priv->context = g_main_context_ref_thread_default ();
25813 }
25814
25815 static void
25816 foo_igen_fdpassing_skeleton_class_init (FooiGenFDPassingSkeletonClass *klass)
25817 {
25818   GObjectClass *gobject_class;
25819   GDBusInterfaceSkeletonClass *skeleton_class;
25820
25821   g_type_class_add_private (klass, sizeof (FooiGenFDPassingSkeletonPrivate));
25822
25823   gobject_class = G_OBJECT_CLASS (klass);
25824   gobject_class->finalize = foo_igen_fdpassing_skeleton_finalize;
25825
25826   skeleton_class = G_DBUS_INTERFACE_SKELETON_CLASS (klass);
25827   skeleton_class->get_info = foo_igen_fdpassing_skeleton_dbus_interface_get_info;
25828   skeleton_class->get_properties = foo_igen_fdpassing_skeleton_dbus_interface_get_properties;
25829   skeleton_class->flush = foo_igen_fdpassing_skeleton_dbus_interface_flush;
25830   skeleton_class->get_vtable = foo_igen_fdpassing_skeleton_dbus_interface_get_vtable;
25831 }
25832
25833 static void
25834 foo_igen_fdpassing_skeleton_iface_init (FooiGenFDPassingIface *iface)
25835 {
25836 }
25837
25838 /**
25839  * foo_igen_fdpassing_skeleton_new:
25840  *
25841  * Creates a skeleton object for the D-Bus interface <link linkend="gdbus-interface-FDPassing.top_of_page">FDPassing</link>.
25842  *
25843  * Returns: (transfer full) (type FooiGenFDPassingSkeleton): The skeleton object.
25844  */
25845 FooiGenFDPassing *
25846 foo_igen_fdpassing_skeleton_new (void)
25847 {
25848   return FOO_IGEN_FDPASSING (g_object_new (FOO_IGEN_TYPE_FDPASSING_SKELETON, NULL));
25849 }
25850
25851 /* ------------------------------------------------------------------------
25852  * Code for Object, ObjectProxy and ObjectSkeleton
25853  * ------------------------------------------------------------------------
25854  */
25855
25856 /**
25857  * SECTION:FooiGenObject
25858  * @title: FooiGenObject
25859  * @short_description: Specialized GDBusObject types
25860  *
25861  * This section contains the #FooiGenObject, #FooiGenObjectProxy, and #FooiGenObjectSkeleton types which make it easier to work with objects implementing generated types for D-Bus interfaces.
25862  */
25863
25864 /**
25865  * FooiGenObject:
25866  *
25867  * The #FooiGenObject type is a specialized container of interfaces.
25868  */
25869
25870 /**
25871  * FooiGenObjectIface:
25872  * @parent_iface: The parent interface.
25873  *
25874  * Virtual table for the #FooiGenObject interface.
25875  */
25876
25877 static void
25878 foo_igen_object_default_init (FooiGenObjectIface *iface)
25879 {
25880   /**
25881    * FooiGenObject:bar:
25882    *
25883    * The #FooiGenBar instance corresponding to the D-Bus interface <link linkend="gdbus-interface-org-project-Bar.top_of_page">org.project.Bar</link>, if any.
25884    *
25885    * Connect to the #GObject::notify signal to get informed of property changes.
25886    */
25887   g_object_interface_install_property (iface, g_param_spec_object ("bar", "bar", "bar", FOO_IGEN_TYPE_BAR, G_PARAM_READWRITE|G_PARAM_STATIC_STRINGS));
25888
25889   /**
25890    * FooiGenObject:bar-frobnicator:
25891    *
25892    * The #FooiGenBarFrobnicator instance corresponding to the D-Bus interface <link linkend="gdbus-interface-org-project-Bar-Frobnicator.top_of_page">org.project.Bar.Frobnicator</link>, if any.
25893    *
25894    * Connect to the #GObject::notify signal to get informed of property changes.
25895    */
25896   g_object_interface_install_property (iface, g_param_spec_object ("bar-frobnicator", "bar-frobnicator", "bar-frobnicator", FOO_IGEN_TYPE_BAR_FROBNICATOR, G_PARAM_READWRITE|G_PARAM_STATIC_STRINGS));
25897
25898   /**
25899    * FooiGenObject:baz:
25900    *
25901    * The #FooiGenBaz instance corresponding to the D-Bus interface <link linkend="gdbus-interface-org-project-Baz.top_of_page">org.project.Baz</link>, if any.
25902    *
25903    * Connect to the #GObject::notify signal to get informed of property changes.
25904    */
25905   g_object_interface_install_property (iface, g_param_spec_object ("baz", "baz", "baz", FOO_IGEN_TYPE_BAZ, G_PARAM_READWRITE|G_PARAM_STATIC_STRINGS));
25906
25907   /**
25908    * FooiGenObject:com-acme-coyote:
25909    *
25910    * The #FooiGenComAcmeCoyote instance corresponding to the D-Bus interface <link linkend="gdbus-interface-com-acme-Coyote.top_of_page">com.acme.Coyote</link>, if any.
25911    *
25912    * Connect to the #GObject::notify signal to get informed of property changes.
25913    */
25914   g_object_interface_install_property (iface, g_param_spec_object ("com-acme-coyote", "com-acme-coyote", "com-acme-coyote", FOO_IGEN_TYPE_COM_ACME_COYOTE, G_PARAM_READWRITE|G_PARAM_STATIC_STRINGS));
25915
25916   /**
25917    * FooiGenObject:rocket123:
25918    *
25919    * The #FooiGenRocket123 instance corresponding to the D-Bus interface <link linkend="gdbus-interface-com-acme-Rocket.top_of_page">com.acme.Rocket</link>, if any.
25920    *
25921    * Connect to the #GObject::notify signal to get informed of property changes.
25922    */
25923   g_object_interface_install_property (iface, g_param_spec_object ("rocket123", "rocket123", "rocket123", FOO_IGEN_TYPE_ROCKET123, G_PARAM_READWRITE|G_PARAM_STATIC_STRINGS));
25924
25925   /**
25926    * FooiGenObject:bat:
25927    *
25928    * The #FooiGenBat instance corresponding to the D-Bus interface <link linkend="gdbus-interface-org-project-Bat.top_of_page">org.project.Bat</link>, if any.
25929    *
25930    * Connect to the #GObject::notify signal to get informed of property changes.
25931    */
25932   g_object_interface_install_property (iface, g_param_spec_object ("bat", "bat", "bat", FOO_IGEN_TYPE_BAT, G_PARAM_READWRITE|G_PARAM_STATIC_STRINGS));
25933
25934   /**
25935    * FooiGenObject:authorize:
25936    *
25937    * The #FooiGenAuthorize instance corresponding to the D-Bus interface <link linkend="gdbus-interface-org-project-Authorize.top_of_page">org.project.Authorize</link>, if any.
25938    *
25939    * Connect to the #GObject::notify signal to get informed of property changes.
25940    */
25941   g_object_interface_install_property (iface, g_param_spec_object ("authorize", "authorize", "authorize", FOO_IGEN_TYPE_AUTHORIZE, G_PARAM_READWRITE|G_PARAM_STATIC_STRINGS));
25942
25943   /**
25944    * FooiGenObject:method-threads:
25945    *
25946    * The #FooiGenMethodThreads instance corresponding to the D-Bus interface <link linkend="gdbus-interface-org-project-MethodThreads.top_of_page">org.project.MethodThreads</link>, if any.
25947    *
25948    * Connect to the #GObject::notify signal to get informed of property changes.
25949    */
25950   g_object_interface_install_property (iface, g_param_spec_object ("method-threads", "method-threads", "method-threads", FOO_IGEN_TYPE_METHOD_THREADS, G_PARAM_READWRITE|G_PARAM_STATIC_STRINGS));
25951
25952   /**
25953    * FooiGenObject:inline-docs:
25954    *
25955    * The #FooiGenInlineDocs instance corresponding to the D-Bus interface <link linkend="gdbus-interface-org-project-InlineDocs.top_of_page">org.project.InlineDocs</link>, if any.
25956    *
25957    * Connect to the #GObject::notify signal to get informed of property changes.
25958    */
25959   g_object_interface_install_property (iface, g_param_spec_object ("inline-docs", "inline-docs", "inline-docs", FOO_IGEN_TYPE_INLINE_DOCS, G_PARAM_READWRITE|G_PARAM_STATIC_STRINGS));
25960
25961   /**
25962    * FooiGenObject:changing-interface-v1:
25963    *
25964    * The #FooiGenChangingInterfaceV1 instance corresponding to the D-Bus interface <link linkend="gdbus-interface-ChangingInterfaceV1.top_of_page">ChangingInterfaceV1</link>, if any.
25965    *
25966    * Connect to the #GObject::notify signal to get informed of property changes.
25967    */
25968   g_object_interface_install_property (iface, g_param_spec_object ("changing-interface-v1", "changing-interface-v1", "changing-interface-v1", FOO_IGEN_TYPE_CHANGING_INTERFACE_V1, G_PARAM_READWRITE|G_PARAM_STATIC_STRINGS));
25969
25970   /**
25971    * FooiGenObject:changing-interface-v2:
25972    *
25973    * The #FooiGenChangingInterfaceV2 instance corresponding to the D-Bus interface <link linkend="gdbus-interface-ChangingInterfaceV2.top_of_page">ChangingInterfaceV2</link>, if any.
25974    *
25975    * Connect to the #GObject::notify signal to get informed of property changes.
25976    *
25977    * Since: 2.0
25978    */
25979   g_object_interface_install_property (iface, g_param_spec_object ("changing-interface-v2", "changing-interface-v2", "changing-interface-v2", FOO_IGEN_TYPE_CHANGING_INTERFACE_V2, G_PARAM_READWRITE|G_PARAM_STATIC_STRINGS));
25980
25981   /**
25982    * FooiGenObject:changing-interface-v10:
25983    *
25984    * The #FooiGenChangingInterfaceV10 instance corresponding to the D-Bus interface <link linkend="gdbus-interface-ChangingInterfaceV10.top_of_page">ChangingInterfaceV10</link>, if any.
25985    *
25986    * Connect to the #GObject::notify signal to get informed of property changes.
25987    *
25988    * Since: 10.0
25989    */
25990   g_object_interface_install_property (iface, g_param_spec_object ("changing-interface-v10", "changing-interface-v10", "changing-interface-v10", FOO_IGEN_TYPE_CHANGING_INTERFACE_V10, G_PARAM_READWRITE|G_PARAM_STATIC_STRINGS));
25991
25992   /**
25993    * FooiGenObject:test-ugly-case-interface:
25994    *
25995    * The #FooiGenTesTuglyCASEInterface instance corresponding to the D-Bus interface <link linkend="gdbus-interface-TestUglyCaseInterface.top_of_page">TestUglyCaseInterface</link>, if any.
25996    *
25997    * Connect to the #GObject::notify signal to get informed of property changes.
25998    */
25999   g_object_interface_install_property (iface, g_param_spec_object ("test-ugly-case-interface", "test-ugly-case-interface", "test-ugly-case-interface", FOO_IGEN_TYPE_TEST_UGLY_CASE_INTERFACE, G_PARAM_READWRITE|G_PARAM_STATIC_STRINGS));
26000
26001   /**
26002    * FooiGenObject:oldie-interface:
26003    *
26004    * The #FooiGenOldieInterface instance corresponding to the D-Bus interface <link linkend="gdbus-interface-OldieInterface.top_of_page">OldieInterface</link>, if any.
26005    *
26006    * Connect to the #GObject::notify signal to get informed of property changes.
26007    *
26008    * Deprecated: The D-Bus interface has been deprecated.
26009    */
26010   g_object_interface_install_property (iface, g_param_spec_object ("oldie-interface", "oldie-interface", "oldie-interface", FOO_IGEN_TYPE_OLDIE_INTERFACE, G_PARAM_READWRITE|G_PARAM_STATIC_STRINGS));
26011
26012   /**
26013    * FooiGenObject:unknown-xml-tags:
26014    *
26015    * The #FooiGenUnknownXmlTags instance corresponding to the D-Bus interface <link linkend="gdbus-interface-UnknownXmlTags.top_of_page">UnknownXmlTags</link>, if any.
26016    *
26017    * Connect to the #GObject::notify signal to get informed of property changes.
26018    */
26019   g_object_interface_install_property (iface, g_param_spec_object ("unknown-xml-tags", "unknown-xml-tags", "unknown-xml-tags", FOO_IGEN_TYPE_UNKNOWN_XML_TAGS, G_PARAM_READWRITE|G_PARAM_STATIC_STRINGS));
26020
26021   /**
26022    * FooiGenObject:fdpassing:
26023    *
26024    * The #FooiGenFDPassing instance corresponding to the D-Bus interface <link linkend="gdbus-interface-FDPassing.top_of_page">FDPassing</link>, if any.
26025    *
26026    * Connect to the #GObject::notify signal to get informed of property changes.
26027    */
26028   g_object_interface_install_property (iface, g_param_spec_object ("fdpassing", "fdpassing", "fdpassing", FOO_IGEN_TYPE_FDPASSING, G_PARAM_READWRITE|G_PARAM_STATIC_STRINGS));
26029
26030 }
26031
26032 typedef FooiGenObjectIface FooiGenObjectInterface;
26033 G_DEFINE_INTERFACE_WITH_CODE (FooiGenObject, foo_igen_object, G_TYPE_OBJECT, g_type_interface_add_prerequisite (g_define_type_id, G_TYPE_DBUS_OBJECT));
26034
26035 /**
26036  * foo_igen_object_get_bar:
26037  * @object: A #FooiGenObject.
26038  *
26039  * Gets the #FooiGenBar instance for the D-Bus interface <link linkend="gdbus-interface-org-project-Bar.top_of_page">org.project.Bar</link> on @object, if any.
26040  *
26041  * Returns: (transfer full): A #FooiGenBar that must be freed with g_object_unref() or %NULL if @object does not implement the interface.
26042  */
26043 FooiGenBar *foo_igen_object_get_bar (FooiGenObject *object)
26044 {
26045   GDBusInterface *ret;
26046   ret = g_dbus_object_get_interface (G_DBUS_OBJECT (object), "org.project.Bar");
26047   if (ret == NULL)
26048     return NULL;
26049   return FOO_IGEN_BAR (ret);
26050 }
26051
26052 /**
26053  * foo_igen_object_get_bar_frobnicator:
26054  * @object: A #FooiGenObject.
26055  *
26056  * Gets the #FooiGenBarFrobnicator instance for the D-Bus interface <link linkend="gdbus-interface-org-project-Bar-Frobnicator.top_of_page">org.project.Bar.Frobnicator</link> on @object, if any.
26057  *
26058  * Returns: (transfer full): A #FooiGenBarFrobnicator that must be freed with g_object_unref() or %NULL if @object does not implement the interface.
26059  */
26060 FooiGenBarFrobnicator *foo_igen_object_get_bar_frobnicator (FooiGenObject *object)
26061 {
26062   GDBusInterface *ret;
26063   ret = g_dbus_object_get_interface (G_DBUS_OBJECT (object), "org.project.Bar.Frobnicator");
26064   if (ret == NULL)
26065     return NULL;
26066   return FOO_IGEN_BAR_FROBNICATOR (ret);
26067 }
26068
26069 /**
26070  * foo_igen_object_get_baz:
26071  * @object: A #FooiGenObject.
26072  *
26073  * Gets the #FooiGenBaz instance for the D-Bus interface <link linkend="gdbus-interface-org-project-Baz.top_of_page">org.project.Baz</link> on @object, if any.
26074  *
26075  * Returns: (transfer full): A #FooiGenBaz that must be freed with g_object_unref() or %NULL if @object does not implement the interface.
26076  */
26077 FooiGenBaz *foo_igen_object_get_baz (FooiGenObject *object)
26078 {
26079   GDBusInterface *ret;
26080   ret = g_dbus_object_get_interface (G_DBUS_OBJECT (object), "org.project.Baz");
26081   if (ret == NULL)
26082     return NULL;
26083   return FOO_IGEN_BAZ (ret);
26084 }
26085
26086 /**
26087  * foo_igen_object_get_com_acme_coyote:
26088  * @object: A #FooiGenObject.
26089  *
26090  * Gets the #FooiGenComAcmeCoyote instance for the D-Bus interface <link linkend="gdbus-interface-com-acme-Coyote.top_of_page">com.acme.Coyote</link> on @object, if any.
26091  *
26092  * Returns: (transfer full): A #FooiGenComAcmeCoyote that must be freed with g_object_unref() or %NULL if @object does not implement the interface.
26093  */
26094 FooiGenComAcmeCoyote *foo_igen_object_get_com_acme_coyote (FooiGenObject *object)
26095 {
26096   GDBusInterface *ret;
26097   ret = g_dbus_object_get_interface (G_DBUS_OBJECT (object), "com.acme.Coyote");
26098   if (ret == NULL)
26099     return NULL;
26100   return FOO_IGEN_COM_ACME_COYOTE (ret);
26101 }
26102
26103 /**
26104  * foo_igen_object_get_rocket123:
26105  * @object: A #FooiGenObject.
26106  *
26107  * Gets the #FooiGenRocket123 instance for the D-Bus interface <link linkend="gdbus-interface-com-acme-Rocket.top_of_page">com.acme.Rocket</link> on @object, if any.
26108  *
26109  * Returns: (transfer full): A #FooiGenRocket123 that must be freed with g_object_unref() or %NULL if @object does not implement the interface.
26110  */
26111 FooiGenRocket123 *foo_igen_object_get_rocket123 (FooiGenObject *object)
26112 {
26113   GDBusInterface *ret;
26114   ret = g_dbus_object_get_interface (G_DBUS_OBJECT (object), "com.acme.Rocket");
26115   if (ret == NULL)
26116     return NULL;
26117   return FOO_IGEN_ROCKET123 (ret);
26118 }
26119
26120 /**
26121  * foo_igen_object_get_bat:
26122  * @object: A #FooiGenObject.
26123  *
26124  * Gets the #FooiGenBat instance for the D-Bus interface <link linkend="gdbus-interface-org-project-Bat.top_of_page">org.project.Bat</link> on @object, if any.
26125  *
26126  * Returns: (transfer full): A #FooiGenBat that must be freed with g_object_unref() or %NULL if @object does not implement the interface.
26127  */
26128 FooiGenBat *foo_igen_object_get_bat (FooiGenObject *object)
26129 {
26130   GDBusInterface *ret;
26131   ret = g_dbus_object_get_interface (G_DBUS_OBJECT (object), "org.project.Bat");
26132   if (ret == NULL)
26133     return NULL;
26134   return FOO_IGEN_BAT (ret);
26135 }
26136
26137 /**
26138  * foo_igen_object_get_authorize:
26139  * @object: A #FooiGenObject.
26140  *
26141  * Gets the #FooiGenAuthorize instance for the D-Bus interface <link linkend="gdbus-interface-org-project-Authorize.top_of_page">org.project.Authorize</link> on @object, if any.
26142  *
26143  * Returns: (transfer full): A #FooiGenAuthorize that must be freed with g_object_unref() or %NULL if @object does not implement the interface.
26144  */
26145 FooiGenAuthorize *foo_igen_object_get_authorize (FooiGenObject *object)
26146 {
26147   GDBusInterface *ret;
26148   ret = g_dbus_object_get_interface (G_DBUS_OBJECT (object), "org.project.Authorize");
26149   if (ret == NULL)
26150     return NULL;
26151   return FOO_IGEN_AUTHORIZE (ret);
26152 }
26153
26154 /**
26155  * foo_igen_object_get_method_threads:
26156  * @object: A #FooiGenObject.
26157  *
26158  * Gets the #FooiGenMethodThreads instance for the D-Bus interface <link linkend="gdbus-interface-org-project-MethodThreads.top_of_page">org.project.MethodThreads</link> on @object, if any.
26159  *
26160  * Returns: (transfer full): A #FooiGenMethodThreads that must be freed with g_object_unref() or %NULL if @object does not implement the interface.
26161  */
26162 FooiGenMethodThreads *foo_igen_object_get_method_threads (FooiGenObject *object)
26163 {
26164   GDBusInterface *ret;
26165   ret = g_dbus_object_get_interface (G_DBUS_OBJECT (object), "org.project.MethodThreads");
26166   if (ret == NULL)
26167     return NULL;
26168   return FOO_IGEN_METHOD_THREADS (ret);
26169 }
26170
26171 /**
26172  * foo_igen_object_get_inline_docs:
26173  * @object: A #FooiGenObject.
26174  *
26175  * Gets the #FooiGenInlineDocs instance for the D-Bus interface <link linkend="gdbus-interface-org-project-InlineDocs.top_of_page">org.project.InlineDocs</link> on @object, if any.
26176  *
26177  * Returns: (transfer full): A #FooiGenInlineDocs that must be freed with g_object_unref() or %NULL if @object does not implement the interface.
26178  */
26179 FooiGenInlineDocs *foo_igen_object_get_inline_docs (FooiGenObject *object)
26180 {
26181   GDBusInterface *ret;
26182   ret = g_dbus_object_get_interface (G_DBUS_OBJECT (object), "org.project.InlineDocs");
26183   if (ret == NULL)
26184     return NULL;
26185   return FOO_IGEN_INLINE_DOCS (ret);
26186 }
26187
26188 /**
26189  * foo_igen_object_get_changing_interface_v1:
26190  * @object: A #FooiGenObject.
26191  *
26192  * Gets the #FooiGenChangingInterfaceV1 instance for the D-Bus interface <link linkend="gdbus-interface-ChangingInterfaceV1.top_of_page">ChangingInterfaceV1</link> on @object, if any.
26193  *
26194  * Returns: (transfer full): A #FooiGenChangingInterfaceV1 that must be freed with g_object_unref() or %NULL if @object does not implement the interface.
26195  */
26196 FooiGenChangingInterfaceV1 *foo_igen_object_get_changing_interface_v1 (FooiGenObject *object)
26197 {
26198   GDBusInterface *ret;
26199   ret = g_dbus_object_get_interface (G_DBUS_OBJECT (object), "ChangingInterfaceV1");
26200   if (ret == NULL)
26201     return NULL;
26202   return FOO_IGEN_CHANGING_INTERFACE_V1 (ret);
26203 }
26204
26205 /**
26206  * foo_igen_object_get_changing_interface_v2:
26207  * @object: A #FooiGenObject.
26208  *
26209  * Gets the #FooiGenChangingInterfaceV2 instance for the D-Bus interface <link linkend="gdbus-interface-ChangingInterfaceV2.top_of_page">ChangingInterfaceV2</link> on @object, if any.
26210  *
26211  * Returns: (transfer full): A #FooiGenChangingInterfaceV2 that must be freed with g_object_unref() or %NULL if @object does not implement the interface.
26212  *
26213  * Since: 2.0
26214  */
26215 FooiGenChangingInterfaceV2 *foo_igen_object_get_changing_interface_v2 (FooiGenObject *object)
26216 {
26217   GDBusInterface *ret;
26218   ret = g_dbus_object_get_interface (G_DBUS_OBJECT (object), "ChangingInterfaceV2");
26219   if (ret == NULL)
26220     return NULL;
26221   return FOO_IGEN_CHANGING_INTERFACE_V2 (ret);
26222 }
26223
26224 /**
26225  * foo_igen_object_get_changing_interface_v10:
26226  * @object: A #FooiGenObject.
26227  *
26228  * Gets the #FooiGenChangingInterfaceV10 instance for the D-Bus interface <link linkend="gdbus-interface-ChangingInterfaceV10.top_of_page">ChangingInterfaceV10</link> on @object, if any.
26229  *
26230  * Returns: (transfer full): A #FooiGenChangingInterfaceV10 that must be freed with g_object_unref() or %NULL if @object does not implement the interface.
26231  *
26232  * Since: 10.0
26233  */
26234 FooiGenChangingInterfaceV10 *foo_igen_object_get_changing_interface_v10 (FooiGenObject *object)
26235 {
26236   GDBusInterface *ret;
26237   ret = g_dbus_object_get_interface (G_DBUS_OBJECT (object), "ChangingInterfaceV10");
26238   if (ret == NULL)
26239     return NULL;
26240   return FOO_IGEN_CHANGING_INTERFACE_V10 (ret);
26241 }
26242
26243 /**
26244  * foo_igen_object_get_test_ugly_case_interface:
26245  * @object: A #FooiGenObject.
26246  *
26247  * Gets the #FooiGenTesTuglyCASEInterface instance for the D-Bus interface <link linkend="gdbus-interface-TestUglyCaseInterface.top_of_page">TestUglyCaseInterface</link> on @object, if any.
26248  *
26249  * Returns: (transfer full): A #FooiGenTesTuglyCASEInterface that must be freed with g_object_unref() or %NULL if @object does not implement the interface.
26250  */
26251 FooiGenTesTuglyCASEInterface *foo_igen_object_get_test_ugly_case_interface (FooiGenObject *object)
26252 {
26253   GDBusInterface *ret;
26254   ret = g_dbus_object_get_interface (G_DBUS_OBJECT (object), "TestUglyCaseInterface");
26255   if (ret == NULL)
26256     return NULL;
26257   return FOO_IGEN_TEST_UGLY_CASE_INTERFACE (ret);
26258 }
26259
26260 /**
26261  * foo_igen_object_get_oldie_interface:
26262  * @object: A #FooiGenObject.
26263  *
26264  * Gets the #FooiGenOldieInterface instance for the D-Bus interface <link linkend="gdbus-interface-OldieInterface.top_of_page">OldieInterface</link> on @object, if any.
26265  *
26266  * Returns: (transfer full): A #FooiGenOldieInterface that must be freed with g_object_unref() or %NULL if @object does not implement the interface.
26267  *
26268  * Deprecated: The D-Bus interface has been deprecated.
26269  */
26270 FooiGenOldieInterface *foo_igen_object_get_oldie_interface (FooiGenObject *object)
26271 {
26272   GDBusInterface *ret;
26273   ret = g_dbus_object_get_interface (G_DBUS_OBJECT (object), "OldieInterface");
26274   if (ret == NULL)
26275     return NULL;
26276   return FOO_IGEN_OLDIE_INTERFACE (ret);
26277 }
26278
26279 /**
26280  * foo_igen_object_get_unknown_xml_tags:
26281  * @object: A #FooiGenObject.
26282  *
26283  * Gets the #FooiGenUnknownXmlTags instance for the D-Bus interface <link linkend="gdbus-interface-UnknownXmlTags.top_of_page">UnknownXmlTags</link> on @object, if any.
26284  *
26285  * Returns: (transfer full): A #FooiGenUnknownXmlTags that must be freed with g_object_unref() or %NULL if @object does not implement the interface.
26286  */
26287 FooiGenUnknownXmlTags *foo_igen_object_get_unknown_xml_tags (FooiGenObject *object)
26288 {
26289   GDBusInterface *ret;
26290   ret = g_dbus_object_get_interface (G_DBUS_OBJECT (object), "UnknownXmlTags");
26291   if (ret == NULL)
26292     return NULL;
26293   return FOO_IGEN_UNKNOWN_XML_TAGS (ret);
26294 }
26295
26296 /**
26297  * foo_igen_object_get_fdpassing:
26298  * @object: A #FooiGenObject.
26299  *
26300  * Gets the #FooiGenFDPassing instance for the D-Bus interface <link linkend="gdbus-interface-FDPassing.top_of_page">FDPassing</link> on @object, if any.
26301  *
26302  * Returns: (transfer full): A #FooiGenFDPassing that must be freed with g_object_unref() or %NULL if @object does not implement the interface.
26303  */
26304 FooiGenFDPassing *foo_igen_object_get_fdpassing (FooiGenObject *object)
26305 {
26306   GDBusInterface *ret;
26307   ret = g_dbus_object_get_interface (G_DBUS_OBJECT (object), "FDPassing");
26308   if (ret == NULL)
26309     return NULL;
26310   return FOO_IGEN_FDPASSING (ret);
26311 }
26312
26313
26314 /**
26315  * foo_igen_object_peek_bar: (skip)
26316  * @object: A #FooiGenObject.
26317  *
26318  * Like foo_igen_object_get_bar() but doesn't increase the reference count on the returned object.
26319  *
26320  * <warning>It is not safe to use the returned object if you are on another thread than the one where the #GDBusObjectManagerClient or #GDBusObjectManagerServer for @object is running.</warning>
26321  *
26322  * Returns: (transfer none): A #FooiGenBar or %NULL if @object does not implement the interface. Do not free the returned object, it is owned by @object.
26323  */
26324 FooiGenBar *foo_igen_object_peek_bar (FooiGenObject *object)
26325 {
26326   GDBusInterface *ret;
26327   ret = g_dbus_object_get_interface (G_DBUS_OBJECT (object), "org.project.Bar");
26328   if (ret == NULL)
26329     return NULL;
26330   g_object_unref (ret);
26331   return FOO_IGEN_BAR (ret);
26332 }
26333
26334 /**
26335  * foo_igen_object_peek_bar_frobnicator: (skip)
26336  * @object: A #FooiGenObject.
26337  *
26338  * Like foo_igen_object_get_bar_frobnicator() but doesn't increase the reference count on the returned object.
26339  *
26340  * <warning>It is not safe to use the returned object if you are on another thread than the one where the #GDBusObjectManagerClient or #GDBusObjectManagerServer for @object is running.</warning>
26341  *
26342  * Returns: (transfer none): A #FooiGenBarFrobnicator or %NULL if @object does not implement the interface. Do not free the returned object, it is owned by @object.
26343  */
26344 FooiGenBarFrobnicator *foo_igen_object_peek_bar_frobnicator (FooiGenObject *object)
26345 {
26346   GDBusInterface *ret;
26347   ret = g_dbus_object_get_interface (G_DBUS_OBJECT (object), "org.project.Bar.Frobnicator");
26348   if (ret == NULL)
26349     return NULL;
26350   g_object_unref (ret);
26351   return FOO_IGEN_BAR_FROBNICATOR (ret);
26352 }
26353
26354 /**
26355  * foo_igen_object_peek_baz: (skip)
26356  * @object: A #FooiGenObject.
26357  *
26358  * Like foo_igen_object_get_baz() but doesn't increase the reference count on the returned object.
26359  *
26360  * <warning>It is not safe to use the returned object if you are on another thread than the one where the #GDBusObjectManagerClient or #GDBusObjectManagerServer for @object is running.</warning>
26361  *
26362  * Returns: (transfer none): A #FooiGenBaz or %NULL if @object does not implement the interface. Do not free the returned object, it is owned by @object.
26363  */
26364 FooiGenBaz *foo_igen_object_peek_baz (FooiGenObject *object)
26365 {
26366   GDBusInterface *ret;
26367   ret = g_dbus_object_get_interface (G_DBUS_OBJECT (object), "org.project.Baz");
26368   if (ret == NULL)
26369     return NULL;
26370   g_object_unref (ret);
26371   return FOO_IGEN_BAZ (ret);
26372 }
26373
26374 /**
26375  * foo_igen_object_peek_com_acme_coyote: (skip)
26376  * @object: A #FooiGenObject.
26377  *
26378  * Like foo_igen_object_get_com_acme_coyote() but doesn't increase the reference count on the returned object.
26379  *
26380  * <warning>It is not safe to use the returned object if you are on another thread than the one where the #GDBusObjectManagerClient or #GDBusObjectManagerServer for @object is running.</warning>
26381  *
26382  * Returns: (transfer none): A #FooiGenComAcmeCoyote or %NULL if @object does not implement the interface. Do not free the returned object, it is owned by @object.
26383  */
26384 FooiGenComAcmeCoyote *foo_igen_object_peek_com_acme_coyote (FooiGenObject *object)
26385 {
26386   GDBusInterface *ret;
26387   ret = g_dbus_object_get_interface (G_DBUS_OBJECT (object), "com.acme.Coyote");
26388   if (ret == NULL)
26389     return NULL;
26390   g_object_unref (ret);
26391   return FOO_IGEN_COM_ACME_COYOTE (ret);
26392 }
26393
26394 /**
26395  * foo_igen_object_peek_rocket123: (skip)
26396  * @object: A #FooiGenObject.
26397  *
26398  * Like foo_igen_object_get_rocket123() but doesn't increase the reference count on the returned object.
26399  *
26400  * <warning>It is not safe to use the returned object if you are on another thread than the one where the #GDBusObjectManagerClient or #GDBusObjectManagerServer for @object is running.</warning>
26401  *
26402  * Returns: (transfer none): A #FooiGenRocket123 or %NULL if @object does not implement the interface. Do not free the returned object, it is owned by @object.
26403  */
26404 FooiGenRocket123 *foo_igen_object_peek_rocket123 (FooiGenObject *object)
26405 {
26406   GDBusInterface *ret;
26407   ret = g_dbus_object_get_interface (G_DBUS_OBJECT (object), "com.acme.Rocket");
26408   if (ret == NULL)
26409     return NULL;
26410   g_object_unref (ret);
26411   return FOO_IGEN_ROCKET123 (ret);
26412 }
26413
26414 /**
26415  * foo_igen_object_peek_bat: (skip)
26416  * @object: A #FooiGenObject.
26417  *
26418  * Like foo_igen_object_get_bat() but doesn't increase the reference count on the returned object.
26419  *
26420  * <warning>It is not safe to use the returned object if you are on another thread than the one where the #GDBusObjectManagerClient or #GDBusObjectManagerServer for @object is running.</warning>
26421  *
26422  * Returns: (transfer none): A #FooiGenBat or %NULL if @object does not implement the interface. Do not free the returned object, it is owned by @object.
26423  */
26424 FooiGenBat *foo_igen_object_peek_bat (FooiGenObject *object)
26425 {
26426   GDBusInterface *ret;
26427   ret = g_dbus_object_get_interface (G_DBUS_OBJECT (object), "org.project.Bat");
26428   if (ret == NULL)
26429     return NULL;
26430   g_object_unref (ret);
26431   return FOO_IGEN_BAT (ret);
26432 }
26433
26434 /**
26435  * foo_igen_object_peek_authorize: (skip)
26436  * @object: A #FooiGenObject.
26437  *
26438  * Like foo_igen_object_get_authorize() but doesn't increase the reference count on the returned object.
26439  *
26440  * <warning>It is not safe to use the returned object if you are on another thread than the one where the #GDBusObjectManagerClient or #GDBusObjectManagerServer for @object is running.</warning>
26441  *
26442  * Returns: (transfer none): A #FooiGenAuthorize or %NULL if @object does not implement the interface. Do not free the returned object, it is owned by @object.
26443  */
26444 FooiGenAuthorize *foo_igen_object_peek_authorize (FooiGenObject *object)
26445 {
26446   GDBusInterface *ret;
26447   ret = g_dbus_object_get_interface (G_DBUS_OBJECT (object), "org.project.Authorize");
26448   if (ret == NULL)
26449     return NULL;
26450   g_object_unref (ret);
26451   return FOO_IGEN_AUTHORIZE (ret);
26452 }
26453
26454 /**
26455  * foo_igen_object_peek_method_threads: (skip)
26456  * @object: A #FooiGenObject.
26457  *
26458  * Like foo_igen_object_get_method_threads() but doesn't increase the reference count on the returned object.
26459  *
26460  * <warning>It is not safe to use the returned object if you are on another thread than the one where the #GDBusObjectManagerClient or #GDBusObjectManagerServer for @object is running.</warning>
26461  *
26462  * Returns: (transfer none): A #FooiGenMethodThreads or %NULL if @object does not implement the interface. Do not free the returned object, it is owned by @object.
26463  */
26464 FooiGenMethodThreads *foo_igen_object_peek_method_threads (FooiGenObject *object)
26465 {
26466   GDBusInterface *ret;
26467   ret = g_dbus_object_get_interface (G_DBUS_OBJECT (object), "org.project.MethodThreads");
26468   if (ret == NULL)
26469     return NULL;
26470   g_object_unref (ret);
26471   return FOO_IGEN_METHOD_THREADS (ret);
26472 }
26473
26474 /**
26475  * foo_igen_object_peek_inline_docs: (skip)
26476  * @object: A #FooiGenObject.
26477  *
26478  * Like foo_igen_object_get_inline_docs() but doesn't increase the reference count on the returned object.
26479  *
26480  * <warning>It is not safe to use the returned object if you are on another thread than the one where the #GDBusObjectManagerClient or #GDBusObjectManagerServer for @object is running.</warning>
26481  *
26482  * Returns: (transfer none): A #FooiGenInlineDocs or %NULL if @object does not implement the interface. Do not free the returned object, it is owned by @object.
26483  */
26484 FooiGenInlineDocs *foo_igen_object_peek_inline_docs (FooiGenObject *object)
26485 {
26486   GDBusInterface *ret;
26487   ret = g_dbus_object_get_interface (G_DBUS_OBJECT (object), "org.project.InlineDocs");
26488   if (ret == NULL)
26489     return NULL;
26490   g_object_unref (ret);
26491   return FOO_IGEN_INLINE_DOCS (ret);
26492 }
26493
26494 /**
26495  * foo_igen_object_peek_changing_interface_v1: (skip)
26496  * @object: A #FooiGenObject.
26497  *
26498  * Like foo_igen_object_get_changing_interface_v1() but doesn't increase the reference count on the returned object.
26499  *
26500  * <warning>It is not safe to use the returned object if you are on another thread than the one where the #GDBusObjectManagerClient or #GDBusObjectManagerServer for @object is running.</warning>
26501  *
26502  * Returns: (transfer none): A #FooiGenChangingInterfaceV1 or %NULL if @object does not implement the interface. Do not free the returned object, it is owned by @object.
26503  */
26504 FooiGenChangingInterfaceV1 *foo_igen_object_peek_changing_interface_v1 (FooiGenObject *object)
26505 {
26506   GDBusInterface *ret;
26507   ret = g_dbus_object_get_interface (G_DBUS_OBJECT (object), "ChangingInterfaceV1");
26508   if (ret == NULL)
26509     return NULL;
26510   g_object_unref (ret);
26511   return FOO_IGEN_CHANGING_INTERFACE_V1 (ret);
26512 }
26513
26514 /**
26515  * foo_igen_object_peek_changing_interface_v2: (skip)
26516  * @object: A #FooiGenObject.
26517  *
26518  * Like foo_igen_object_get_changing_interface_v2() but doesn't increase the reference count on the returned object.
26519  *
26520  * <warning>It is not safe to use the returned object if you are on another thread than the one where the #GDBusObjectManagerClient or #GDBusObjectManagerServer for @object is running.</warning>
26521  *
26522  * Returns: (transfer none): A #FooiGenChangingInterfaceV2 or %NULL if @object does not implement the interface. Do not free the returned object, it is owned by @object.
26523  *
26524  * Since: 2.0
26525  */
26526 FooiGenChangingInterfaceV2 *foo_igen_object_peek_changing_interface_v2 (FooiGenObject *object)
26527 {
26528   GDBusInterface *ret;
26529   ret = g_dbus_object_get_interface (G_DBUS_OBJECT (object), "ChangingInterfaceV2");
26530   if (ret == NULL)
26531     return NULL;
26532   g_object_unref (ret);
26533   return FOO_IGEN_CHANGING_INTERFACE_V2 (ret);
26534 }
26535
26536 /**
26537  * foo_igen_object_peek_changing_interface_v10: (skip)
26538  * @object: A #FooiGenObject.
26539  *
26540  * Like foo_igen_object_get_changing_interface_v10() but doesn't increase the reference count on the returned object.
26541  *
26542  * <warning>It is not safe to use the returned object if you are on another thread than the one where the #GDBusObjectManagerClient or #GDBusObjectManagerServer for @object is running.</warning>
26543  *
26544  * Returns: (transfer none): A #FooiGenChangingInterfaceV10 or %NULL if @object does not implement the interface. Do not free the returned object, it is owned by @object.
26545  *
26546  * Since: 10.0
26547  */
26548 FooiGenChangingInterfaceV10 *foo_igen_object_peek_changing_interface_v10 (FooiGenObject *object)
26549 {
26550   GDBusInterface *ret;
26551   ret = g_dbus_object_get_interface (G_DBUS_OBJECT (object), "ChangingInterfaceV10");
26552   if (ret == NULL)
26553     return NULL;
26554   g_object_unref (ret);
26555   return FOO_IGEN_CHANGING_INTERFACE_V10 (ret);
26556 }
26557
26558 /**
26559  * foo_igen_object_peek_test_ugly_case_interface: (skip)
26560  * @object: A #FooiGenObject.
26561  *
26562  * Like foo_igen_object_get_test_ugly_case_interface() but doesn't increase the reference count on the returned object.
26563  *
26564  * <warning>It is not safe to use the returned object if you are on another thread than the one where the #GDBusObjectManagerClient or #GDBusObjectManagerServer for @object is running.</warning>
26565  *
26566  * Returns: (transfer none): A #FooiGenTesTuglyCASEInterface or %NULL if @object does not implement the interface. Do not free the returned object, it is owned by @object.
26567  */
26568 FooiGenTesTuglyCASEInterface *foo_igen_object_peek_test_ugly_case_interface (FooiGenObject *object)
26569 {
26570   GDBusInterface *ret;
26571   ret = g_dbus_object_get_interface (G_DBUS_OBJECT (object), "TestUglyCaseInterface");
26572   if (ret == NULL)
26573     return NULL;
26574   g_object_unref (ret);
26575   return FOO_IGEN_TEST_UGLY_CASE_INTERFACE (ret);
26576 }
26577
26578 /**
26579  * foo_igen_object_peek_oldie_interface: (skip)
26580  * @object: A #FooiGenObject.
26581  *
26582  * Like foo_igen_object_get_oldie_interface() but doesn't increase the reference count on the returned object.
26583  *
26584  * <warning>It is not safe to use the returned object if you are on another thread than the one where the #GDBusObjectManagerClient or #GDBusObjectManagerServer for @object is running.</warning>
26585  *
26586  * Returns: (transfer none): A #FooiGenOldieInterface or %NULL if @object does not implement the interface. Do not free the returned object, it is owned by @object.
26587  *
26588  * Deprecated: The D-Bus interface has been deprecated.
26589  */
26590 FooiGenOldieInterface *foo_igen_object_peek_oldie_interface (FooiGenObject *object)
26591 {
26592   GDBusInterface *ret;
26593   ret = g_dbus_object_get_interface (G_DBUS_OBJECT (object), "OldieInterface");
26594   if (ret == NULL)
26595     return NULL;
26596   g_object_unref (ret);
26597   return FOO_IGEN_OLDIE_INTERFACE (ret);
26598 }
26599
26600 /**
26601  * foo_igen_object_peek_unknown_xml_tags: (skip)
26602  * @object: A #FooiGenObject.
26603  *
26604  * Like foo_igen_object_get_unknown_xml_tags() but doesn't increase the reference count on the returned object.
26605  *
26606  * <warning>It is not safe to use the returned object if you are on another thread than the one where the #GDBusObjectManagerClient or #GDBusObjectManagerServer for @object is running.</warning>
26607  *
26608  * Returns: (transfer none): A #FooiGenUnknownXmlTags or %NULL if @object does not implement the interface. Do not free the returned object, it is owned by @object.
26609  */
26610 FooiGenUnknownXmlTags *foo_igen_object_peek_unknown_xml_tags (FooiGenObject *object)
26611 {
26612   GDBusInterface *ret;
26613   ret = g_dbus_object_get_interface (G_DBUS_OBJECT (object), "UnknownXmlTags");
26614   if (ret == NULL)
26615     return NULL;
26616   g_object_unref (ret);
26617   return FOO_IGEN_UNKNOWN_XML_TAGS (ret);
26618 }
26619
26620 /**
26621  * foo_igen_object_peek_fdpassing: (skip)
26622  * @object: A #FooiGenObject.
26623  *
26624  * Like foo_igen_object_get_fdpassing() but doesn't increase the reference count on the returned object.
26625  *
26626  * <warning>It is not safe to use the returned object if you are on another thread than the one where the #GDBusObjectManagerClient or #GDBusObjectManagerServer for @object is running.</warning>
26627  *
26628  * Returns: (transfer none): A #FooiGenFDPassing or %NULL if @object does not implement the interface. Do not free the returned object, it is owned by @object.
26629  */
26630 FooiGenFDPassing *foo_igen_object_peek_fdpassing (FooiGenObject *object)
26631 {
26632   GDBusInterface *ret;
26633   ret = g_dbus_object_get_interface (G_DBUS_OBJECT (object), "FDPassing");
26634   if (ret == NULL)
26635     return NULL;
26636   g_object_unref (ret);
26637   return FOO_IGEN_FDPASSING (ret);
26638 }
26639
26640
26641 static void
26642 foo_igen_object_notify (GDBusObject *object, GDBusInterface *interface)
26643 {
26644   g_object_notify (G_OBJECT (object), ((_ExtendedGDBusInterfaceInfo *) g_dbus_interface_get_info (interface))->hyphen_name);
26645 }
26646
26647 /**
26648  * FooiGenObjectProxy:
26649  *
26650  * The #FooiGenObjectProxy structure contains only private data and should only be accessed using the provided API.
26651  */
26652
26653 /**
26654  * FooiGenObjectProxyClass:
26655  * @parent_class: The parent class.
26656  *
26657  * Class structure for #FooiGenObjectProxy.
26658  */
26659
26660 static void
26661 foo_igen_object_proxy__foo_igen_object_iface_init (FooiGenObjectIface *iface)
26662 {
26663 }
26664
26665 static void
26666 foo_igen_object_proxy__g_dbus_object_iface_init (GDBusObjectIface *iface)
26667 {
26668   iface->interface_added = foo_igen_object_notify;
26669   iface->interface_removed = foo_igen_object_notify;
26670 }
26671
26672
26673 G_DEFINE_TYPE_WITH_CODE (FooiGenObjectProxy, foo_igen_object_proxy, G_TYPE_DBUS_OBJECT_PROXY,
26674                          G_IMPLEMENT_INTERFACE (FOO_IGEN_TYPE_OBJECT, foo_igen_object_proxy__foo_igen_object_iface_init)
26675                          G_IMPLEMENT_INTERFACE (G_TYPE_DBUS_OBJECT, foo_igen_object_proxy__g_dbus_object_iface_init));
26676
26677 static void
26678 foo_igen_object_proxy_init (FooiGenObjectProxy *object)
26679 {
26680 }
26681
26682 static void
26683 foo_igen_object_proxy_set_property (GObject      *gobject,
26684   guint         prop_id,
26685   const GValue *value,
26686   GParamSpec   *pspec)
26687 {
26688   G_OBJECT_WARN_INVALID_PROPERTY_ID (gobject, prop_id, pspec);
26689 }
26690
26691 static void
26692 foo_igen_object_proxy_get_property (GObject      *gobject,
26693   guint         prop_id,
26694   GValue       *value,
26695   GParamSpec   *pspec)
26696 {
26697   FooiGenObjectProxy *object = FOO_IGEN_OBJECT_PROXY (gobject);
26698   GDBusInterface *interface;
26699
26700   switch (prop_id)
26701     {
26702     case 1:
26703       interface = g_dbus_object_get_interface (G_DBUS_OBJECT (object), "org.project.Bar");
26704       g_value_take_object (value, interface);
26705       break;
26706
26707     case 2:
26708       interface = g_dbus_object_get_interface (G_DBUS_OBJECT (object), "org.project.Bar.Frobnicator");
26709       g_value_take_object (value, interface);
26710       break;
26711
26712     case 3:
26713       interface = g_dbus_object_get_interface (G_DBUS_OBJECT (object), "org.project.Baz");
26714       g_value_take_object (value, interface);
26715       break;
26716
26717     case 4:
26718       interface = g_dbus_object_get_interface (G_DBUS_OBJECT (object), "com.acme.Coyote");
26719       g_value_take_object (value, interface);
26720       break;
26721
26722     case 5:
26723       interface = g_dbus_object_get_interface (G_DBUS_OBJECT (object), "com.acme.Rocket");
26724       g_value_take_object (value, interface);
26725       break;
26726
26727     case 6:
26728       interface = g_dbus_object_get_interface (G_DBUS_OBJECT (object), "org.project.Bat");
26729       g_value_take_object (value, interface);
26730       break;
26731
26732     case 7:
26733       interface = g_dbus_object_get_interface (G_DBUS_OBJECT (object), "org.project.Authorize");
26734       g_value_take_object (value, interface);
26735       break;
26736
26737     case 8:
26738       interface = g_dbus_object_get_interface (G_DBUS_OBJECT (object), "org.project.MethodThreads");
26739       g_value_take_object (value, interface);
26740       break;
26741
26742     case 9:
26743       interface = g_dbus_object_get_interface (G_DBUS_OBJECT (object), "org.project.InlineDocs");
26744       g_value_take_object (value, interface);
26745       break;
26746
26747     case 10:
26748       interface = g_dbus_object_get_interface (G_DBUS_OBJECT (object), "ChangingInterfaceV1");
26749       g_value_take_object (value, interface);
26750       break;
26751
26752     case 11:
26753       interface = g_dbus_object_get_interface (G_DBUS_OBJECT (object), "ChangingInterfaceV2");
26754       g_value_take_object (value, interface);
26755       break;
26756
26757     case 12:
26758       interface = g_dbus_object_get_interface (G_DBUS_OBJECT (object), "ChangingInterfaceV10");
26759       g_value_take_object (value, interface);
26760       break;
26761
26762     case 13:
26763       interface = g_dbus_object_get_interface (G_DBUS_OBJECT (object), "TestUglyCaseInterface");
26764       g_value_take_object (value, interface);
26765       break;
26766
26767     case 14:
26768       interface = g_dbus_object_get_interface (G_DBUS_OBJECT (object), "OldieInterface");
26769       g_value_take_object (value, interface);
26770       break;
26771
26772     case 15:
26773       interface = g_dbus_object_get_interface (G_DBUS_OBJECT (object), "UnknownXmlTags");
26774       g_value_take_object (value, interface);
26775       break;
26776
26777     case 16:
26778       interface = g_dbus_object_get_interface (G_DBUS_OBJECT (object), "FDPassing");
26779       g_value_take_object (value, interface);
26780       break;
26781
26782     default:
26783       G_OBJECT_WARN_INVALID_PROPERTY_ID (gobject, prop_id, pspec);
26784       break;
26785   }
26786 }
26787
26788 static void
26789 foo_igen_object_proxy_class_init (FooiGenObjectProxyClass *klass)
26790 {
26791   GObjectClass *gobject_class = G_OBJECT_CLASS (klass);
26792
26793   gobject_class->set_property = foo_igen_object_proxy_set_property;
26794   gobject_class->get_property = foo_igen_object_proxy_get_property;
26795
26796   g_object_class_override_property (gobject_class, 1, "bar");
26797   g_object_class_override_property (gobject_class, 2, "bar-frobnicator");
26798   g_object_class_override_property (gobject_class, 3, "baz");
26799   g_object_class_override_property (gobject_class, 4, "com-acme-coyote");
26800   g_object_class_override_property (gobject_class, 5, "rocket123");
26801   g_object_class_override_property (gobject_class, 6, "bat");
26802   g_object_class_override_property (gobject_class, 7, "authorize");
26803   g_object_class_override_property (gobject_class, 8, "method-threads");
26804   g_object_class_override_property (gobject_class, 9, "inline-docs");
26805   g_object_class_override_property (gobject_class, 10, "changing-interface-v1");
26806   g_object_class_override_property (gobject_class, 11, "changing-interface-v2");
26807   g_object_class_override_property (gobject_class, 12, "changing-interface-v10");
26808   g_object_class_override_property (gobject_class, 13, "test-ugly-case-interface");
26809   g_object_class_override_property (gobject_class, 14, "oldie-interface");
26810   g_object_class_override_property (gobject_class, 15, "unknown-xml-tags");
26811   g_object_class_override_property (gobject_class, 16, "fdpassing");
26812 }
26813
26814 /**
26815  * foo_igen_object_proxy_new:
26816  * @connection: A #GDBusConnection.
26817  * @object_path: An object path.
26818  *
26819  * Creates a new proxy object.
26820  *
26821  * Returns: (transfer full): The proxy object.
26822  */
26823 FooiGenObjectProxy *
26824 foo_igen_object_proxy_new (GDBusConnection *connection,
26825   const gchar *object_path)
26826 {
26827   g_return_val_if_fail (G_IS_DBUS_CONNECTION (connection), NULL);
26828   g_return_val_if_fail (g_variant_is_object_path (object_path), NULL);
26829   return FOO_IGEN_OBJECT_PROXY (g_object_new (FOO_IGEN_TYPE_OBJECT_PROXY, "g-connection", connection, "g-object-path", object_path, NULL));
26830 }
26831
26832 /**
26833  * FooiGenObjectSkeleton:
26834  *
26835  * The #FooiGenObjectSkeleton structure contains only private data and should only be accessed using the provided API.
26836  */
26837
26838 /**
26839  * FooiGenObjectSkeletonClass:
26840  * @parent_class: The parent class.
26841  *
26842  * Class structure for #FooiGenObjectSkeleton.
26843  */
26844
26845 static void
26846 foo_igen_object_skeleton__foo_igen_object_iface_init (FooiGenObjectIface *iface)
26847 {
26848 }
26849
26850
26851 static void
26852 foo_igen_object_skeleton__g_dbus_object_iface_init (GDBusObjectIface *iface)
26853 {
26854   iface->interface_added = foo_igen_object_notify;
26855   iface->interface_removed = foo_igen_object_notify;
26856 }
26857
26858 G_DEFINE_TYPE_WITH_CODE (FooiGenObjectSkeleton, foo_igen_object_skeleton, G_TYPE_DBUS_OBJECT_SKELETON,
26859                          G_IMPLEMENT_INTERFACE (FOO_IGEN_TYPE_OBJECT, foo_igen_object_skeleton__foo_igen_object_iface_init)
26860                          G_IMPLEMENT_INTERFACE (G_TYPE_DBUS_OBJECT, foo_igen_object_skeleton__g_dbus_object_iface_init));
26861
26862 static void
26863 foo_igen_object_skeleton_init (FooiGenObjectSkeleton *object)
26864 {
26865 }
26866
26867 static void
26868 foo_igen_object_skeleton_set_property (GObject      *gobject,
26869   guint         prop_id,
26870   const GValue *value,
26871   GParamSpec   *pspec)
26872 {
26873   FooiGenObjectSkeleton *object = FOO_IGEN_OBJECT_SKELETON (gobject);
26874   GDBusInterfaceSkeleton *interface;
26875
26876   switch (prop_id)
26877     {
26878     case 1:
26879       interface = g_value_get_object (value);
26880       if (interface != NULL)
26881         {
26882           g_warn_if_fail (FOO_IGEN_IS_BAR (interface));
26883           g_dbus_object_skeleton_add_interface (G_DBUS_OBJECT_SKELETON (object), interface);
26884         }
26885       else
26886         {
26887           g_dbus_object_skeleton_remove_interface_by_name (G_DBUS_OBJECT_SKELETON (object), "org.project.Bar");
26888         }
26889       break;
26890
26891     case 2:
26892       interface = g_value_get_object (value);
26893       if (interface != NULL)
26894         {
26895           g_warn_if_fail (FOO_IGEN_IS_BAR_FROBNICATOR (interface));
26896           g_dbus_object_skeleton_add_interface (G_DBUS_OBJECT_SKELETON (object), interface);
26897         }
26898       else
26899         {
26900           g_dbus_object_skeleton_remove_interface_by_name (G_DBUS_OBJECT_SKELETON (object), "org.project.Bar.Frobnicator");
26901         }
26902       break;
26903
26904     case 3:
26905       interface = g_value_get_object (value);
26906       if (interface != NULL)
26907         {
26908           g_warn_if_fail (FOO_IGEN_IS_BAZ (interface));
26909           g_dbus_object_skeleton_add_interface (G_DBUS_OBJECT_SKELETON (object), interface);
26910         }
26911       else
26912         {
26913           g_dbus_object_skeleton_remove_interface_by_name (G_DBUS_OBJECT_SKELETON (object), "org.project.Baz");
26914         }
26915       break;
26916
26917     case 4:
26918       interface = g_value_get_object (value);
26919       if (interface != NULL)
26920         {
26921           g_warn_if_fail (FOO_IGEN_IS_COM_ACME_COYOTE (interface));
26922           g_dbus_object_skeleton_add_interface (G_DBUS_OBJECT_SKELETON (object), interface);
26923         }
26924       else
26925         {
26926           g_dbus_object_skeleton_remove_interface_by_name (G_DBUS_OBJECT_SKELETON (object), "com.acme.Coyote");
26927         }
26928       break;
26929
26930     case 5:
26931       interface = g_value_get_object (value);
26932       if (interface != NULL)
26933         {
26934           g_warn_if_fail (FOO_IGEN_IS_ROCKET123 (interface));
26935           g_dbus_object_skeleton_add_interface (G_DBUS_OBJECT_SKELETON (object), interface);
26936         }
26937       else
26938         {
26939           g_dbus_object_skeleton_remove_interface_by_name (G_DBUS_OBJECT_SKELETON (object), "com.acme.Rocket");
26940         }
26941       break;
26942
26943     case 6:
26944       interface = g_value_get_object (value);
26945       if (interface != NULL)
26946         {
26947           g_warn_if_fail (FOO_IGEN_IS_BAT (interface));
26948           g_dbus_object_skeleton_add_interface (G_DBUS_OBJECT_SKELETON (object), interface);
26949         }
26950       else
26951         {
26952           g_dbus_object_skeleton_remove_interface_by_name (G_DBUS_OBJECT_SKELETON (object), "org.project.Bat");
26953         }
26954       break;
26955
26956     case 7:
26957       interface = g_value_get_object (value);
26958       if (interface != NULL)
26959         {
26960           g_warn_if_fail (FOO_IGEN_IS_AUTHORIZE (interface));
26961           g_dbus_object_skeleton_add_interface (G_DBUS_OBJECT_SKELETON (object), interface);
26962         }
26963       else
26964         {
26965           g_dbus_object_skeleton_remove_interface_by_name (G_DBUS_OBJECT_SKELETON (object), "org.project.Authorize");
26966         }
26967       break;
26968
26969     case 8:
26970       interface = g_value_get_object (value);
26971       if (interface != NULL)
26972         {
26973           g_warn_if_fail (FOO_IGEN_IS_METHOD_THREADS (interface));
26974           g_dbus_object_skeleton_add_interface (G_DBUS_OBJECT_SKELETON (object), interface);
26975         }
26976       else
26977         {
26978           g_dbus_object_skeleton_remove_interface_by_name (G_DBUS_OBJECT_SKELETON (object), "org.project.MethodThreads");
26979         }
26980       break;
26981
26982     case 9:
26983       interface = g_value_get_object (value);
26984       if (interface != NULL)
26985         {
26986           g_warn_if_fail (FOO_IGEN_IS_INLINE_DOCS (interface));
26987           g_dbus_object_skeleton_add_interface (G_DBUS_OBJECT_SKELETON (object), interface);
26988         }
26989       else
26990         {
26991           g_dbus_object_skeleton_remove_interface_by_name (G_DBUS_OBJECT_SKELETON (object), "org.project.InlineDocs");
26992         }
26993       break;
26994
26995     case 10:
26996       interface = g_value_get_object (value);
26997       if (interface != NULL)
26998         {
26999           g_warn_if_fail (FOO_IGEN_IS_CHANGING_INTERFACE_V1 (interface));
27000           g_dbus_object_skeleton_add_interface (G_DBUS_OBJECT_SKELETON (object), interface);
27001         }
27002       else
27003         {
27004           g_dbus_object_skeleton_remove_interface_by_name (G_DBUS_OBJECT_SKELETON (object), "ChangingInterfaceV1");
27005         }
27006       break;
27007
27008     case 11:
27009       interface = g_value_get_object (value);
27010       if (interface != NULL)
27011         {
27012           g_warn_if_fail (FOO_IGEN_IS_CHANGING_INTERFACE_V2 (interface));
27013           g_dbus_object_skeleton_add_interface (G_DBUS_OBJECT_SKELETON (object), interface);
27014         }
27015       else
27016         {
27017           g_dbus_object_skeleton_remove_interface_by_name (G_DBUS_OBJECT_SKELETON (object), "ChangingInterfaceV2");
27018         }
27019       break;
27020
27021     case 12:
27022       interface = g_value_get_object (value);
27023       if (interface != NULL)
27024         {
27025           g_warn_if_fail (FOO_IGEN_IS_CHANGING_INTERFACE_V10 (interface));
27026           g_dbus_object_skeleton_add_interface (G_DBUS_OBJECT_SKELETON (object), interface);
27027         }
27028       else
27029         {
27030           g_dbus_object_skeleton_remove_interface_by_name (G_DBUS_OBJECT_SKELETON (object), "ChangingInterfaceV10");
27031         }
27032       break;
27033
27034     case 13:
27035       interface = g_value_get_object (value);
27036       if (interface != NULL)
27037         {
27038           g_warn_if_fail (FOO_IGEN_IS_TEST_UGLY_CASE_INTERFACE (interface));
27039           g_dbus_object_skeleton_add_interface (G_DBUS_OBJECT_SKELETON (object), interface);
27040         }
27041       else
27042         {
27043           g_dbus_object_skeleton_remove_interface_by_name (G_DBUS_OBJECT_SKELETON (object), "TestUglyCaseInterface");
27044         }
27045       break;
27046
27047     case 14:
27048       interface = g_value_get_object (value);
27049       if (interface != NULL)
27050         {
27051           g_warn_if_fail (FOO_IGEN_IS_OLDIE_INTERFACE (interface));
27052           g_dbus_object_skeleton_add_interface (G_DBUS_OBJECT_SKELETON (object), interface);
27053         }
27054       else
27055         {
27056           g_dbus_object_skeleton_remove_interface_by_name (G_DBUS_OBJECT_SKELETON (object), "OldieInterface");
27057         }
27058       break;
27059
27060     case 15:
27061       interface = g_value_get_object (value);
27062       if (interface != NULL)
27063         {
27064           g_warn_if_fail (FOO_IGEN_IS_UNKNOWN_XML_TAGS (interface));
27065           g_dbus_object_skeleton_add_interface (G_DBUS_OBJECT_SKELETON (object), interface);
27066         }
27067       else
27068         {
27069           g_dbus_object_skeleton_remove_interface_by_name (G_DBUS_OBJECT_SKELETON (object), "UnknownXmlTags");
27070         }
27071       break;
27072
27073     case 16:
27074       interface = g_value_get_object (value);
27075       if (interface != NULL)
27076         {
27077           g_warn_if_fail (FOO_IGEN_IS_FDPASSING (interface));
27078           g_dbus_object_skeleton_add_interface (G_DBUS_OBJECT_SKELETON (object), interface);
27079         }
27080       else
27081         {
27082           g_dbus_object_skeleton_remove_interface_by_name (G_DBUS_OBJECT_SKELETON (object), "FDPassing");
27083         }
27084       break;
27085
27086     default:
27087       G_OBJECT_WARN_INVALID_PROPERTY_ID (gobject, prop_id, pspec);
27088       break;
27089   }
27090 }
27091
27092 static void
27093 foo_igen_object_skeleton_get_property (GObject      *gobject,
27094   guint         prop_id,
27095   GValue       *value,
27096   GParamSpec   *pspec)
27097 {
27098   FooiGenObjectSkeleton *object = FOO_IGEN_OBJECT_SKELETON (gobject);
27099   GDBusInterface *interface;
27100
27101   switch (prop_id)
27102     {
27103     case 1:
27104       interface = g_dbus_object_get_interface (G_DBUS_OBJECT (object), "org.project.Bar");
27105       g_value_take_object (value, interface);
27106       break;
27107
27108     case 2:
27109       interface = g_dbus_object_get_interface (G_DBUS_OBJECT (object), "org.project.Bar.Frobnicator");
27110       g_value_take_object (value, interface);
27111       break;
27112
27113     case 3:
27114       interface = g_dbus_object_get_interface (G_DBUS_OBJECT (object), "org.project.Baz");
27115       g_value_take_object (value, interface);
27116       break;
27117
27118     case 4:
27119       interface = g_dbus_object_get_interface (G_DBUS_OBJECT (object), "com.acme.Coyote");
27120       g_value_take_object (value, interface);
27121       break;
27122
27123     case 5:
27124       interface = g_dbus_object_get_interface (G_DBUS_OBJECT (object), "com.acme.Rocket");
27125       g_value_take_object (value, interface);
27126       break;
27127
27128     case 6:
27129       interface = g_dbus_object_get_interface (G_DBUS_OBJECT (object), "org.project.Bat");
27130       g_value_take_object (value, interface);
27131       break;
27132
27133     case 7:
27134       interface = g_dbus_object_get_interface (G_DBUS_OBJECT (object), "org.project.Authorize");
27135       g_value_take_object (value, interface);
27136       break;
27137
27138     case 8:
27139       interface = g_dbus_object_get_interface (G_DBUS_OBJECT (object), "org.project.MethodThreads");
27140       g_value_take_object (value, interface);
27141       break;
27142
27143     case 9:
27144       interface = g_dbus_object_get_interface (G_DBUS_OBJECT (object), "org.project.InlineDocs");
27145       g_value_take_object (value, interface);
27146       break;
27147
27148     case 10:
27149       interface = g_dbus_object_get_interface (G_DBUS_OBJECT (object), "ChangingInterfaceV1");
27150       g_value_take_object (value, interface);
27151       break;
27152
27153     case 11:
27154       interface = g_dbus_object_get_interface (G_DBUS_OBJECT (object), "ChangingInterfaceV2");
27155       g_value_take_object (value, interface);
27156       break;
27157
27158     case 12:
27159       interface = g_dbus_object_get_interface (G_DBUS_OBJECT (object), "ChangingInterfaceV10");
27160       g_value_take_object (value, interface);
27161       break;
27162
27163     case 13:
27164       interface = g_dbus_object_get_interface (G_DBUS_OBJECT (object), "TestUglyCaseInterface");
27165       g_value_take_object (value, interface);
27166       break;
27167
27168     case 14:
27169       interface = g_dbus_object_get_interface (G_DBUS_OBJECT (object), "OldieInterface");
27170       g_value_take_object (value, interface);
27171       break;
27172
27173     case 15:
27174       interface = g_dbus_object_get_interface (G_DBUS_OBJECT (object), "UnknownXmlTags");
27175       g_value_take_object (value, interface);
27176       break;
27177
27178     case 16:
27179       interface = g_dbus_object_get_interface (G_DBUS_OBJECT (object), "FDPassing");
27180       g_value_take_object (value, interface);
27181       break;
27182
27183     default:
27184       G_OBJECT_WARN_INVALID_PROPERTY_ID (gobject, prop_id, pspec);
27185       break;
27186   }
27187 }
27188
27189 static void
27190 foo_igen_object_skeleton_class_init (FooiGenObjectSkeletonClass *klass)
27191 {
27192   GObjectClass *gobject_class = G_OBJECT_CLASS (klass);
27193
27194   gobject_class->set_property = foo_igen_object_skeleton_set_property;
27195   gobject_class->get_property = foo_igen_object_skeleton_get_property;
27196
27197   g_object_class_override_property (gobject_class, 1, "bar");
27198   g_object_class_override_property (gobject_class, 2, "bar-frobnicator");
27199   g_object_class_override_property (gobject_class, 3, "baz");
27200   g_object_class_override_property (gobject_class, 4, "com-acme-coyote");
27201   g_object_class_override_property (gobject_class, 5, "rocket123");
27202   g_object_class_override_property (gobject_class, 6, "bat");
27203   g_object_class_override_property (gobject_class, 7, "authorize");
27204   g_object_class_override_property (gobject_class, 8, "method-threads");
27205   g_object_class_override_property (gobject_class, 9, "inline-docs");
27206   g_object_class_override_property (gobject_class, 10, "changing-interface-v1");
27207   g_object_class_override_property (gobject_class, 11, "changing-interface-v2");
27208   g_object_class_override_property (gobject_class, 12, "changing-interface-v10");
27209   g_object_class_override_property (gobject_class, 13, "test-ugly-case-interface");
27210   g_object_class_override_property (gobject_class, 14, "oldie-interface");
27211   g_object_class_override_property (gobject_class, 15, "unknown-xml-tags");
27212   g_object_class_override_property (gobject_class, 16, "fdpassing");
27213 }
27214
27215 /**
27216  * foo_igen_object_skeleton_new:
27217  * @object_path: An object path.
27218  *
27219  * Creates a new skeleton object.
27220  *
27221  * Returns: (transfer full): The skeleton object.
27222  */
27223 FooiGenObjectSkeleton *
27224 foo_igen_object_skeleton_new (const gchar *object_path)
27225 {
27226   g_return_val_if_fail (g_variant_is_object_path (object_path), NULL);
27227   return FOO_IGEN_OBJECT_SKELETON (g_object_new (FOO_IGEN_TYPE_OBJECT_SKELETON, "g-object-path", object_path, NULL));
27228 }
27229
27230 /**
27231  * foo_igen_object_skeleton_set_bar:
27232  * @object: A #FooiGenObjectSkeleton.
27233  * @interface_: (allow-none): A #FooiGenBar or %NULL to clear the interface.
27234  *
27235  * Sets the #FooiGenBar instance for the D-Bus interface <link linkend="gdbus-interface-org-project-Bar.top_of_page">org.project.Bar</link> on @object.
27236  */
27237 void foo_igen_object_skeleton_set_bar (FooiGenObjectSkeleton *object, FooiGenBar *interface_)
27238 {
27239   g_object_set (G_OBJECT (object), "bar", interface_, NULL);
27240 }
27241
27242 /**
27243  * foo_igen_object_skeleton_set_bar_frobnicator:
27244  * @object: A #FooiGenObjectSkeleton.
27245  * @interface_: (allow-none): A #FooiGenBarFrobnicator or %NULL to clear the interface.
27246  *
27247  * Sets the #FooiGenBarFrobnicator instance for the D-Bus interface <link linkend="gdbus-interface-org-project-Bar-Frobnicator.top_of_page">org.project.Bar.Frobnicator</link> on @object.
27248  */
27249 void foo_igen_object_skeleton_set_bar_frobnicator (FooiGenObjectSkeleton *object, FooiGenBarFrobnicator *interface_)
27250 {
27251   g_object_set (G_OBJECT (object), "bar-frobnicator", interface_, NULL);
27252 }
27253
27254 /**
27255  * foo_igen_object_skeleton_set_baz:
27256  * @object: A #FooiGenObjectSkeleton.
27257  * @interface_: (allow-none): A #FooiGenBaz or %NULL to clear the interface.
27258  *
27259  * Sets the #FooiGenBaz instance for the D-Bus interface <link linkend="gdbus-interface-org-project-Baz.top_of_page">org.project.Baz</link> on @object.
27260  */
27261 void foo_igen_object_skeleton_set_baz (FooiGenObjectSkeleton *object, FooiGenBaz *interface_)
27262 {
27263   g_object_set (G_OBJECT (object), "baz", interface_, NULL);
27264 }
27265
27266 /**
27267  * foo_igen_object_skeleton_set_com_acme_coyote:
27268  * @object: A #FooiGenObjectSkeleton.
27269  * @interface_: (allow-none): A #FooiGenComAcmeCoyote or %NULL to clear the interface.
27270  *
27271  * Sets the #FooiGenComAcmeCoyote instance for the D-Bus interface <link linkend="gdbus-interface-com-acme-Coyote.top_of_page">com.acme.Coyote</link> on @object.
27272  */
27273 void foo_igen_object_skeleton_set_com_acme_coyote (FooiGenObjectSkeleton *object, FooiGenComAcmeCoyote *interface_)
27274 {
27275   g_object_set (G_OBJECT (object), "com-acme-coyote", interface_, NULL);
27276 }
27277
27278 /**
27279  * foo_igen_object_skeleton_set_rocket123:
27280  * @object: A #FooiGenObjectSkeleton.
27281  * @interface_: (allow-none): A #FooiGenRocket123 or %NULL to clear the interface.
27282  *
27283  * Sets the #FooiGenRocket123 instance for the D-Bus interface <link linkend="gdbus-interface-com-acme-Rocket.top_of_page">com.acme.Rocket</link> on @object.
27284  */
27285 void foo_igen_object_skeleton_set_rocket123 (FooiGenObjectSkeleton *object, FooiGenRocket123 *interface_)
27286 {
27287   g_object_set (G_OBJECT (object), "rocket123", interface_, NULL);
27288 }
27289
27290 /**
27291  * foo_igen_object_skeleton_set_bat:
27292  * @object: A #FooiGenObjectSkeleton.
27293  * @interface_: (allow-none): A #FooiGenBat or %NULL to clear the interface.
27294  *
27295  * Sets the #FooiGenBat instance for the D-Bus interface <link linkend="gdbus-interface-org-project-Bat.top_of_page">org.project.Bat</link> on @object.
27296  */
27297 void foo_igen_object_skeleton_set_bat (FooiGenObjectSkeleton *object, FooiGenBat *interface_)
27298 {
27299   g_object_set (G_OBJECT (object), "bat", interface_, NULL);
27300 }
27301
27302 /**
27303  * foo_igen_object_skeleton_set_authorize:
27304  * @object: A #FooiGenObjectSkeleton.
27305  * @interface_: (allow-none): A #FooiGenAuthorize or %NULL to clear the interface.
27306  *
27307  * Sets the #FooiGenAuthorize instance for the D-Bus interface <link linkend="gdbus-interface-org-project-Authorize.top_of_page">org.project.Authorize</link> on @object.
27308  */
27309 void foo_igen_object_skeleton_set_authorize (FooiGenObjectSkeleton *object, FooiGenAuthorize *interface_)
27310 {
27311   g_object_set (G_OBJECT (object), "authorize", interface_, NULL);
27312 }
27313
27314 /**
27315  * foo_igen_object_skeleton_set_method_threads:
27316  * @object: A #FooiGenObjectSkeleton.
27317  * @interface_: (allow-none): A #FooiGenMethodThreads or %NULL to clear the interface.
27318  *
27319  * Sets the #FooiGenMethodThreads instance for the D-Bus interface <link linkend="gdbus-interface-org-project-MethodThreads.top_of_page">org.project.MethodThreads</link> on @object.
27320  */
27321 void foo_igen_object_skeleton_set_method_threads (FooiGenObjectSkeleton *object, FooiGenMethodThreads *interface_)
27322 {
27323   g_object_set (G_OBJECT (object), "method-threads", interface_, NULL);
27324 }
27325
27326 /**
27327  * foo_igen_object_skeleton_set_inline_docs:
27328  * @object: A #FooiGenObjectSkeleton.
27329  * @interface_: (allow-none): A #FooiGenInlineDocs or %NULL to clear the interface.
27330  *
27331  * Sets the #FooiGenInlineDocs instance for the D-Bus interface <link linkend="gdbus-interface-org-project-InlineDocs.top_of_page">org.project.InlineDocs</link> on @object.
27332  */
27333 void foo_igen_object_skeleton_set_inline_docs (FooiGenObjectSkeleton *object, FooiGenInlineDocs *interface_)
27334 {
27335   g_object_set (G_OBJECT (object), "inline-docs", interface_, NULL);
27336 }
27337
27338 /**
27339  * foo_igen_object_skeleton_set_changing_interface_v1:
27340  * @object: A #FooiGenObjectSkeleton.
27341  * @interface_: (allow-none): A #FooiGenChangingInterfaceV1 or %NULL to clear the interface.
27342  *
27343  * Sets the #FooiGenChangingInterfaceV1 instance for the D-Bus interface <link linkend="gdbus-interface-ChangingInterfaceV1.top_of_page">ChangingInterfaceV1</link> on @object.
27344  */
27345 void foo_igen_object_skeleton_set_changing_interface_v1 (FooiGenObjectSkeleton *object, FooiGenChangingInterfaceV1 *interface_)
27346 {
27347   g_object_set (G_OBJECT (object), "changing-interface-v1", interface_, NULL);
27348 }
27349
27350 /**
27351  * foo_igen_object_skeleton_set_changing_interface_v2:
27352  * @object: A #FooiGenObjectSkeleton.
27353  * @interface_: (allow-none): A #FooiGenChangingInterfaceV2 or %NULL to clear the interface.
27354  *
27355  * Sets the #FooiGenChangingInterfaceV2 instance for the D-Bus interface <link linkend="gdbus-interface-ChangingInterfaceV2.top_of_page">ChangingInterfaceV2</link> on @object.
27356  *
27357  * Since: 2.0
27358  */
27359 void foo_igen_object_skeleton_set_changing_interface_v2 (FooiGenObjectSkeleton *object, FooiGenChangingInterfaceV2 *interface_)
27360 {
27361   g_object_set (G_OBJECT (object), "changing-interface-v2", interface_, NULL);
27362 }
27363
27364 /**
27365  * foo_igen_object_skeleton_set_changing_interface_v10:
27366  * @object: A #FooiGenObjectSkeleton.
27367  * @interface_: (allow-none): A #FooiGenChangingInterfaceV10 or %NULL to clear the interface.
27368  *
27369  * Sets the #FooiGenChangingInterfaceV10 instance for the D-Bus interface <link linkend="gdbus-interface-ChangingInterfaceV10.top_of_page">ChangingInterfaceV10</link> on @object.
27370  *
27371  * Since: 10.0
27372  */
27373 void foo_igen_object_skeleton_set_changing_interface_v10 (FooiGenObjectSkeleton *object, FooiGenChangingInterfaceV10 *interface_)
27374 {
27375   g_object_set (G_OBJECT (object), "changing-interface-v10", interface_, NULL);
27376 }
27377
27378 /**
27379  * foo_igen_object_skeleton_set_test_ugly_case_interface:
27380  * @object: A #FooiGenObjectSkeleton.
27381  * @interface_: (allow-none): A #FooiGenTesTuglyCASEInterface or %NULL to clear the interface.
27382  *
27383  * Sets the #FooiGenTesTuglyCASEInterface instance for the D-Bus interface <link linkend="gdbus-interface-TestUglyCaseInterface.top_of_page">TestUglyCaseInterface</link> on @object.
27384  */
27385 void foo_igen_object_skeleton_set_test_ugly_case_interface (FooiGenObjectSkeleton *object, FooiGenTesTuglyCASEInterface *interface_)
27386 {
27387   g_object_set (G_OBJECT (object), "test-ugly-case-interface", interface_, NULL);
27388 }
27389
27390 /**
27391  * foo_igen_object_skeleton_set_oldie_interface:
27392  * @object: A #FooiGenObjectSkeleton.
27393  * @interface_: (allow-none): A #FooiGenOldieInterface or %NULL to clear the interface.
27394  *
27395  * Sets the #FooiGenOldieInterface instance for the D-Bus interface <link linkend="gdbus-interface-OldieInterface.top_of_page">OldieInterface</link> on @object.
27396  *
27397  * Deprecated: The D-Bus interface has been deprecated.
27398  */
27399 void foo_igen_object_skeleton_set_oldie_interface (FooiGenObjectSkeleton *object, FooiGenOldieInterface *interface_)
27400 {
27401   g_object_set (G_OBJECT (object), "oldie-interface", interface_, NULL);
27402 }
27403
27404 /**
27405  * foo_igen_object_skeleton_set_unknown_xml_tags:
27406  * @object: A #FooiGenObjectSkeleton.
27407  * @interface_: (allow-none): A #FooiGenUnknownXmlTags or %NULL to clear the interface.
27408  *
27409  * Sets the #FooiGenUnknownXmlTags instance for the D-Bus interface <link linkend="gdbus-interface-UnknownXmlTags.top_of_page">UnknownXmlTags</link> on @object.
27410  */
27411 void foo_igen_object_skeleton_set_unknown_xml_tags (FooiGenObjectSkeleton *object, FooiGenUnknownXmlTags *interface_)
27412 {
27413   g_object_set (G_OBJECT (object), "unknown-xml-tags", interface_, NULL);
27414 }
27415
27416 /**
27417  * foo_igen_object_skeleton_set_fdpassing:
27418  * @object: A #FooiGenObjectSkeleton.
27419  * @interface_: (allow-none): A #FooiGenFDPassing or %NULL to clear the interface.
27420  *
27421  * Sets the #FooiGenFDPassing instance for the D-Bus interface <link linkend="gdbus-interface-FDPassing.top_of_page">FDPassing</link> on @object.
27422  */
27423 void foo_igen_object_skeleton_set_fdpassing (FooiGenObjectSkeleton *object, FooiGenFDPassing *interface_)
27424 {
27425   g_object_set (G_OBJECT (object), "fdpassing", interface_, NULL);
27426 }
27427
27428
27429 /* ------------------------------------------------------------------------
27430  * Code for ObjectManager client
27431  * ------------------------------------------------------------------------
27432  */
27433
27434 /**
27435  * SECTION:FooiGenObjectManagerClient
27436  * @title: FooiGenObjectManagerClient
27437  * @short_description: Generated GDBusObjectManagerClient type
27438  *
27439  * This section contains a #GDBusObjectManagerClient that uses foo_igen_object_manager_client_get_proxy_type() as the #GDBusProxyTypeFunc.
27440  */
27441
27442 /**
27443  * FooiGenObjectManagerClient:
27444  *
27445  * The #FooiGenObjectManagerClient structure contains only private data and should only be accessed using the provided API.
27446  */
27447
27448 /**
27449  * FooiGenObjectManagerClientClass:
27450  * @parent_class: The parent class.
27451  *
27452  * Class structure for #FooiGenObjectManagerClient.
27453  */
27454
27455 G_DEFINE_TYPE (FooiGenObjectManagerClient, foo_igen_object_manager_client, G_TYPE_DBUS_OBJECT_MANAGER_CLIENT);
27456
27457 static void
27458 foo_igen_object_manager_client_init (FooiGenObjectManagerClient *manager)
27459 {
27460 }
27461
27462 static void
27463 foo_igen_object_manager_client_class_init (FooiGenObjectManagerClientClass *klass)
27464 {
27465 }
27466
27467 /**
27468  * foo_igen_object_manager_client_get_proxy_type:
27469  * @manager: A #GDBusObjectManagerClient.
27470  * @object_path: The object path of the remote object (unused).
27471  * @interface_name: (allow-none): Interface name of the remote object or %NULL to get the object proxy #GType.
27472  * @user_data: User data (unused).
27473  *
27474  * A #GDBusProxyTypeFunc that maps @interface_name to the generated #GDBusObjectProxy<!-- -->- and #GDBusProxy<!-- -->-derived types.
27475  *
27476  * Returns: A #GDBusProxy<!-- -->-derived #GType if @interface_name is not %NULL, otherwise the #GType for #FooiGenObjectProxy.
27477  */
27478 GType
27479 foo_igen_object_manager_client_get_proxy_type (GDBusObjectManagerClient *manager, const gchar *object_path, const gchar *interface_name, gpointer user_data)
27480 {
27481   static gsize once_init_value = 0;
27482   static GHashTable *lookup_hash;
27483   GType ret;
27484
27485   if (interface_name == NULL)
27486     return FOO_IGEN_TYPE_OBJECT_PROXY;
27487   if (g_once_init_enter (&once_init_value))
27488     {
27489       lookup_hash = g_hash_table_new (g_str_hash, g_str_equal);
27490       g_hash_table_insert (lookup_hash, "org.project.Bar", GSIZE_TO_POINTER (FOO_IGEN_TYPE_BAR_PROXY));
27491       g_hash_table_insert (lookup_hash, "org.project.Bar.Frobnicator", GSIZE_TO_POINTER (FOO_IGEN_TYPE_BAR_FROBNICATOR_PROXY));
27492       g_hash_table_insert (lookup_hash, "org.project.Baz", GSIZE_TO_POINTER (FOO_IGEN_TYPE_BAZ_PROXY));
27493       g_hash_table_insert (lookup_hash, "com.acme.Coyote", GSIZE_TO_POINTER (FOO_IGEN_TYPE_COM_ACME_COYOTE_PROXY));
27494       g_hash_table_insert (lookup_hash, "com.acme.Rocket", GSIZE_TO_POINTER (FOO_IGEN_TYPE_ROCKET123_PROXY));
27495       g_hash_table_insert (lookup_hash, "org.project.Bat", GSIZE_TO_POINTER (FOO_IGEN_TYPE_BAT_PROXY));
27496       g_hash_table_insert (lookup_hash, "org.project.Authorize", GSIZE_TO_POINTER (FOO_IGEN_TYPE_AUTHORIZE_PROXY));
27497       g_hash_table_insert (lookup_hash, "org.project.MethodThreads", GSIZE_TO_POINTER (FOO_IGEN_TYPE_METHOD_THREADS_PROXY));
27498       g_hash_table_insert (lookup_hash, "org.project.InlineDocs", GSIZE_TO_POINTER (FOO_IGEN_TYPE_INLINE_DOCS_PROXY));
27499       g_hash_table_insert (lookup_hash, "ChangingInterfaceV1", GSIZE_TO_POINTER (FOO_IGEN_TYPE_CHANGING_INTERFACE_V1_PROXY));
27500       g_hash_table_insert (lookup_hash, "ChangingInterfaceV2", GSIZE_TO_POINTER (FOO_IGEN_TYPE_CHANGING_INTERFACE_V2_PROXY));
27501       g_hash_table_insert (lookup_hash, "ChangingInterfaceV10", GSIZE_TO_POINTER (FOO_IGEN_TYPE_CHANGING_INTERFACE_V10_PROXY));
27502       g_hash_table_insert (lookup_hash, "TestUglyCaseInterface", GSIZE_TO_POINTER (FOO_IGEN_TYPE_TEST_UGLY_CASE_INTERFACE_PROXY));
27503       g_hash_table_insert (lookup_hash, "OldieInterface", GSIZE_TO_POINTER (FOO_IGEN_TYPE_OLDIE_INTERFACE_PROXY));
27504       g_hash_table_insert (lookup_hash, "UnknownXmlTags", GSIZE_TO_POINTER (FOO_IGEN_TYPE_UNKNOWN_XML_TAGS_PROXY));
27505       g_hash_table_insert (lookup_hash, "FDPassing", GSIZE_TO_POINTER (FOO_IGEN_TYPE_FDPASSING_PROXY));
27506       g_once_init_leave (&once_init_value, 1);
27507     }
27508   ret = (GType) GPOINTER_TO_SIZE (g_hash_table_lookup (lookup_hash, interface_name));
27509   if (ret == (GType) 0)
27510     ret = G_TYPE_DBUS_PROXY;
27511   return ret;
27512 }
27513
27514 /**
27515  * foo_igen_object_manager_client_new:
27516  * @connection: A #GDBusConnection.
27517  * @flags: Flags from the #GDBusObjectManagerClientFlags enumeration.
27518  * @name: (allow-none): A bus name (well-known or unique) or %NULL if @connection is not a message bus connection.
27519  * @object_path: An object path.
27520  * @cancellable: (allow-none): A #GCancellable or %NULL.
27521  * @callback: A #GAsyncReadyCallback to call when the request is satisfied.
27522  * @user_data: User data to pass to @callback.
27523  *
27524  * Asynchronously creates #GDBusObjectManagerClient using foo_igen_object_manager_client_get_proxy_type() as the #GDBusProxyTypeFunc. See g_dbus_object_manager_client_new() for more details.
27525  *
27526  * When the operation is finished, @callback will be invoked in the <link linkend="g-main-context-push-thread-default">thread-default main loop</link> of the thread you are calling this method from.
27527  * You can then call foo_igen_object_manager_client_new_finish() to get the result of the operation.
27528  *
27529  * See foo_igen_object_manager_client_new_sync() for the synchronous, blocking version of this constructor.
27530  */
27531 void
27532 foo_igen_object_manager_client_new (
27533     GDBusConnection        *connection,
27534     GDBusObjectManagerClientFlags  flags,
27535     const gchar            *name,
27536     const gchar            *object_path,
27537     GCancellable           *cancellable,
27538     GAsyncReadyCallback     callback,
27539     gpointer                user_data)
27540 {
27541   g_async_initable_new_async (FOO_IGEN_TYPE_OBJECT_MANAGER_CLIENT, G_PRIORITY_DEFAULT, cancellable, callback, user_data, "flags", flags, "name", name, "connection", connection, "object-path", object_path, "get-proxy-type-func", foo_igen_object_manager_client_get_proxy_type, NULL);
27542 }
27543
27544 /**
27545  * foo_igen_object_manager_client_new_finish:
27546  * @res: The #GAsyncResult obtained from the #GAsyncReadyCallback passed to foo_igen_object_manager_client_new().
27547  * @error: Return location for error or %NULL
27548  *
27549  * Finishes an operation started with foo_igen_object_manager_client_new().
27550  *
27551  * Returns: (transfer full) (type FooiGenObjectManagerClient): The constructed object manager client or %NULL if @error is set.
27552  */
27553 GDBusObjectManager *
27554 foo_igen_object_manager_client_new_finish (
27555     GAsyncResult        *res,
27556     GError             **error)
27557 {
27558   GObject *ret;
27559   GObject *source_object;
27560   source_object = g_async_result_get_source_object (res);
27561   ret = g_async_initable_new_finish (G_ASYNC_INITABLE (source_object), res, error);
27562   g_object_unref (source_object);
27563   if (ret != NULL)
27564     return G_DBUS_OBJECT_MANAGER (ret);
27565   else
27566     return NULL;
27567 }
27568
27569 /**
27570  * foo_igen_object_manager_client_new_sync:
27571  * @connection: A #GDBusConnection.
27572  * @flags: Flags from the #GDBusObjectManagerClientFlags enumeration.
27573  * @name: (allow-none): A bus name (well-known or unique) or %NULL if @connection is not a message bus connection.
27574  * @object_path: An object path.
27575  * @cancellable: (allow-none): A #GCancellable or %NULL.
27576  * @error: Return location for error or %NULL
27577  *
27578  * Synchronously creates #GDBusObjectManagerClient using foo_igen_object_manager_client_get_proxy_type() as the #GDBusProxyTypeFunc. See g_dbus_object_manager_client_new_sync() for more details.
27579  *
27580  * The calling thread is blocked until a reply is received.
27581  *
27582  * See foo_igen_object_manager_client_new() for the asynchronous version of this constructor.
27583  *
27584  * Returns: (transfer full) (type FooiGenObjectManagerClient): The constructed object manager client or %NULL if @error is set.
27585  */
27586 GDBusObjectManager *
27587 foo_igen_object_manager_client_new_sync (
27588     GDBusConnection        *connection,
27589     GDBusObjectManagerClientFlags  flags,
27590     const gchar            *name,
27591     const gchar            *object_path,
27592     GCancellable           *cancellable,
27593     GError                **error)
27594 {
27595   GInitable *ret;
27596   ret = g_initable_new (FOO_IGEN_TYPE_OBJECT_MANAGER_CLIENT, cancellable, error, "flags", flags, "name", name, "connection", connection, "object-path", object_path, "get-proxy-type-func", foo_igen_object_manager_client_get_proxy_type, NULL);
27597   if (ret != NULL)
27598     return G_DBUS_OBJECT_MANAGER (ret);
27599   else
27600     return NULL;
27601 }
27602
27603
27604 /**
27605  * foo_igen_object_manager_client_new_for_bus:
27606  * @bus_type: A #GBusType.
27607  * @flags: Flags from the #GDBusObjectManagerClientFlags enumeration.
27608  * @name: A bus name (well-known or unique).
27609  * @object_path: An object path.
27610  * @cancellable: (allow-none): A #GCancellable or %NULL.
27611  * @callback: A #GAsyncReadyCallback to call when the request is satisfied.
27612  * @user_data: User data to pass to @callback.
27613  *
27614  * Like foo_igen_object_manager_client_new() but takes a #GBusType instead of a #GDBusConnection.
27615  *
27616  * When the operation is finished, @callback will be invoked in the <link linkend="g-main-context-push-thread-default">thread-default main loop</link> of the thread you are calling this method from.
27617  * You can then call foo_igen_object_manager_client_new_for_bus_finish() to get the result of the operation.
27618  *
27619  * See foo_igen_object_manager_client_new_for_bus_sync() for the synchronous, blocking version of this constructor.
27620  */
27621 void
27622 foo_igen_object_manager_client_new_for_bus (
27623     GBusType                bus_type,
27624     GDBusObjectManagerClientFlags  flags,
27625     const gchar            *name,
27626     const gchar            *object_path,
27627     GCancellable           *cancellable,
27628     GAsyncReadyCallback     callback,
27629     gpointer                user_data)
27630 {
27631   g_async_initable_new_async (FOO_IGEN_TYPE_OBJECT_MANAGER_CLIENT, G_PRIORITY_DEFAULT, cancellable, callback, user_data, "flags", flags, "name", name, "bus-type", bus_type, "object-path", object_path, "get-proxy-type-func", foo_igen_object_manager_client_get_proxy_type, NULL);
27632 }
27633
27634 /**
27635  * foo_igen_object_manager_client_new_for_bus_finish:
27636  * @res: The #GAsyncResult obtained from the #GAsyncReadyCallback passed to foo_igen_object_manager_client_new_for_bus().
27637  * @error: Return location for error or %NULL
27638  *
27639  * Finishes an operation started with foo_igen_object_manager_client_new_for_bus().
27640  *
27641  * Returns: (transfer full) (type FooiGenObjectManagerClient): The constructed object manager client or %NULL if @error is set.
27642  */
27643 GDBusObjectManager *
27644 foo_igen_object_manager_client_new_for_bus_finish (
27645     GAsyncResult        *res,
27646     GError             **error)
27647 {
27648   GObject *ret;
27649   GObject *source_object;
27650   source_object = g_async_result_get_source_object (res);
27651   ret = g_async_initable_new_finish (G_ASYNC_INITABLE (source_object), res, error);
27652   g_object_unref (source_object);
27653   if (ret != NULL)
27654     return G_DBUS_OBJECT_MANAGER (ret);
27655   else
27656     return NULL;
27657 }
27658
27659 /**
27660  * foo_igen_object_manager_client_new_for_bus_sync:
27661  * @bus_type: A #GBusType.
27662  * @flags: Flags from the #GDBusObjectManagerClientFlags enumeration.
27663  * @name: A bus name (well-known or unique).
27664  * @object_path: An object path.
27665  * @cancellable: (allow-none): A #GCancellable or %NULL.
27666  * @error: Return location for error or %NULL
27667  *
27668  * Like foo_igen_object_manager_client_new_sync() but takes a #GBusType instead of a #GDBusConnection.
27669  *
27670  * The calling thread is blocked until a reply is received.
27671  *
27672  * See foo_igen_object_manager_client_new_for_bus() for the asynchronous version of this constructor.
27673  *
27674  * Returns: (transfer full) (type FooiGenObjectManagerClient): The constructed object manager client or %NULL if @error is set.
27675  */
27676 GDBusObjectManager *
27677 foo_igen_object_manager_client_new_for_bus_sync (
27678     GBusType                bus_type,
27679     GDBusObjectManagerClientFlags  flags,
27680     const gchar            *name,
27681     const gchar            *object_path,
27682     GCancellable           *cancellable,
27683     GError                **error)
27684 {
27685   GInitable *ret;
27686   ret = g_initable_new (FOO_IGEN_TYPE_OBJECT_MANAGER_CLIENT, cancellable, error, "flags", flags, "name", name, "bus-type", bus_type, "object-path", object_path, "get-proxy-type-func", foo_igen_object_manager_client_get_proxy_type, NULL);
27687   if (ret != NULL)
27688     return G_DBUS_OBJECT_MANAGER (ret);
27689   else
27690     return NULL;
27691 }
27692
27693