@girs/msg-0 0.0.0-4.0.0-beta.16

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/msg-0.d.ts ADDED
@@ -0,0 +1,2404 @@
1
+ /**
2
+ * Type Definitions for Gjs (https://gjs.guide/)
3
+ *
4
+ * These type definitions are automatically generated, do not edit them by hand.
5
+ * If you found a bug fix it in `ts-for-gir` or create a bug report on https://github.com/gjsify/ts-for-gir
6
+ *
7
+ * The based EJS template file is used for the generated .d.ts file of each GIR module like Gtk-4.0, GObject-2.0, ...
8
+ */
9
+
10
+ // Module dependencies
11
+ import type Soup from '@girs/soup-3.0';
12
+ import type Gio from '@girs/gio-2.0';
13
+ import type GObject from '@girs/gobject-2.0';
14
+ import type GLib from '@girs/glib-2.0';
15
+ import type GModule from '@girs/gmodule-2.0';
16
+ import type Json from '@girs/json-1.0';
17
+ import type Goa from '@girs/goa-1.0';
18
+
19
+ export namespace Msg {
20
+ /**
21
+ * Msg-0
22
+ */
23
+
24
+ /**
25
+ * The type of Drive
26
+ * <ulink url="https://docs.microsoft.com/en-us/graph/api/resources/drive?view=graph-rest-1.0">
27
+ * objects</ulink>.
28
+ */
29
+
30
+ /**
31
+ * The type of Drive
32
+ * <ulink url="https://docs.microsoft.com/en-us/graph/api/resources/drive?view=graph-rest-1.0">
33
+ * objects</ulink>.
34
+ */
35
+ export namespace DriveType {
36
+ export const $gtype: GObject.GType<DriveType>;
37
+ }
38
+
39
+ enum DriveType {
40
+ /**
41
+ * Personal OneDrive drive
42
+ */
43
+ PERSONAL,
44
+ /**
45
+ * OneDrive for Business drive
46
+ */
47
+ BUSINESS,
48
+ /**
49
+ * SharePoint document library
50
+ */
51
+ DOCUMENT_LIBRARY,
52
+ }
53
+ /**
54
+ * This enumeration can be expanded at a later date.
55
+ */
56
+ class Error extends GLib.Error {
57
+ static $gtype: GObject.GType<Error>;
58
+
59
+ // Static fields
60
+
61
+ /**
62
+ * An unrecoverable error occurred.
63
+ */
64
+ static FAILED: number;
65
+ static PROTOCOL_ERROR: number;
66
+
67
+ // Constructors
68
+
69
+ constructor(options: { message: string; code: number });
70
+ _init(...args: any[]): void;
71
+ }
72
+
73
+ export namespace MessageMailFolderType {
74
+ export const $gtype: GObject.GType<MessageMailFolderType>;
75
+ }
76
+
77
+ enum MessageMailFolderType {
78
+ INBOX,
79
+ DRAFTS,
80
+ SENT_ITEMS,
81
+ JUNK_EMAIL,
82
+ DELETED_ITEMS,
83
+ OUTBOX,
84
+ ARCHIVE,
85
+ }
86
+ const API_ENDPOINT: string;
87
+ function error_quark(): GLib.Quark;
88
+ function json_object_get_string(object: Json.Object, name: string): string;
89
+ module Contact {
90
+ // Constructor properties interface
91
+
92
+ interface ConstructorProps extends GObject.Object.ConstructorProps {}
93
+ }
94
+
95
+ /**
96
+ * Handling of contact specific functions.
97
+ *
98
+ * Details: https://learn.microsoft.com/en-us/graph/api/resources/contact?view=graph-rest-1.0
99
+ */
100
+ class Contact extends GObject.Object {
101
+ static $gtype: GObject.GType<Contact>;
102
+
103
+ // Constructors
104
+
105
+ constructor(properties?: Partial<Contact.ConstructorProps>, ...args: any[]);
106
+
107
+ _init(...args: any[]): void;
108
+
109
+ static ['new'](): Contact;
110
+
111
+ static new_from_json(json_object: Json.Object): Contact;
112
+
113
+ // Methods
114
+
115
+ /**
116
+ * Gets given name.
117
+ * @returns given name
118
+ */
119
+ get_given_name(): string;
120
+ /**
121
+ * Gets ID
122
+ * @returns identifier
123
+ */
124
+ get_id(): string;
125
+ get_name(): string;
126
+ /**
127
+ * Gets surname.
128
+ * @returns surname
129
+ */
130
+ get_surname(): string;
131
+ /**
132
+ * Sets contacts given name
133
+ * @param given_name new give name
134
+ */
135
+ set_given_name(given_name: string): void;
136
+ /**
137
+ * Sets contacts surname
138
+ * @param surname new sirname
139
+ */
140
+ set_surname(surname: string): void;
141
+ }
142
+
143
+ module ContactService {
144
+ // Constructor properties interface
145
+
146
+ interface ConstructorProps extends Service.ConstructorProps {}
147
+ }
148
+
149
+ class ContactService extends Service {
150
+ static $gtype: GObject.GType<ContactService>;
151
+
152
+ // Constructors
153
+
154
+ constructor(properties?: Partial<ContactService.ConstructorProps>, ...args: any[]);
155
+
156
+ _init(...args: any[]): void;
157
+
158
+ static ['new'](authorizer: Authorizer): ContactService;
159
+
160
+ // Methods
161
+
162
+ /**
163
+ * Create new contact #contact and return new contact object.
164
+ * @param contact a #MsgContact
165
+ * @param cancellable a #GCancellable
166
+ * @returns a new #MsgContact
167
+ */
168
+ create(contact: Contact, cancellable?: Gio.Cancellable | null): Contact;
169
+ /**
170
+ * Delets #contact.
171
+ * @param contact a #MsgContact
172
+ * @param cancellable a #GCancellable
173
+ * @returns %TRUE for succes, else %FALSE
174
+ */
175
+ ['delete'](contact: Contact, cancellable?: Gio.Cancellable | null): boolean;
176
+ /**
177
+ * Get all contacts accessed by contact service.
178
+ * @param cancellable a cancellable
179
+ * @returns all contacts
180
+ */
181
+ get_contacts(cancellable?: Gio.Cancellable | null): Contact[];
182
+ }
183
+
184
+ module Drive {
185
+ // Constructor properties interface
186
+
187
+ interface ConstructorProps extends GObject.Object.ConstructorProps {}
188
+ }
189
+
190
+ /**
191
+ * #MsgDriveService is a subclass of #MsgService for communicating with the MS Graph API.
192
+ *
193
+ * Details: https://learn.microsoft.com/en-us/graph/api/resources/drive?view=graph-rest-1.0
194
+ */
195
+ class Drive extends GObject.Object {
196
+ static $gtype: GObject.GType<Drive>;
197
+
198
+ // Constructors
199
+
200
+ constructor(properties?: Partial<Drive.ConstructorProps>, ...args: any[]);
201
+
202
+ _init(...args: any[]): void;
203
+
204
+ static ['new'](): Drive;
205
+
206
+ static new_from_json(object: Json.Object): Drive;
207
+
208
+ // Methods
209
+
210
+ /**
211
+ * Get created time of drive.
212
+ * @returns created time of drive
213
+ */
214
+ get_created(): GLib.DateTime;
215
+ /**
216
+ * Gets the drive type of the drive.
217
+ * @returns the drive type of drive
218
+ */
219
+ get_drive_type(): DriveType;
220
+ /**
221
+ * Gets the ID of the drive.
222
+ * @returns the id of the drive
223
+ */
224
+ get_id(): string;
225
+ /**
226
+ * Gets the modified time of the drive.
227
+ * @returns modified time of drive
228
+ */
229
+ get_modified(): GLib.DateTime;
230
+ /**
231
+ * Gets tthe name of the drive.
232
+ * @returns name of drive
233
+ */
234
+ get_name(): string;
235
+ /**
236
+ * Gets the remaining size of the drive.
237
+ * @returns remaining size of drive
238
+ */
239
+ get_remaining(): number;
240
+ /**
241
+ * Gets the total size of the drive.
242
+ * @returns total size of drive
243
+ */
244
+ get_total(): number;
245
+ /**
246
+ * Gets the used size of the drive.
247
+ * @returns used size of drive
248
+ */
249
+ get_used(): number;
250
+ }
251
+
252
+ module DriveItem {
253
+ // Constructor properties interface
254
+
255
+ interface ConstructorProps extends GObject.Object.ConstructorProps {}
256
+ }
257
+
258
+ class DriveItem extends GObject.Object {
259
+ static $gtype: GObject.GType<DriveItem>;
260
+
261
+ // Constructors
262
+
263
+ constructor(properties?: Partial<DriveItem.ConstructorProps>, ...args: any[]);
264
+
265
+ _init(...args: any[]): void;
266
+
267
+ static new_from_json(object: Json.Object): DriveItem;
268
+
269
+ // Methods
270
+
271
+ /**
272
+ * Get created time of drive item.
273
+ * @returns created date time of drive item
274
+ */
275
+ get_created(): number;
276
+ /**
277
+ * Gets drive id of drive item.
278
+ * @returns drive id of drive item
279
+ */
280
+ get_drive_id(): string;
281
+ /**
282
+ * Gets etag of drive item.
283
+ * @returns etag of drive item
284
+ */
285
+ get_etag(): string;
286
+ /**
287
+ * Get id of drive item.
288
+ * @returns id of drive item
289
+ */
290
+ get_id(): string;
291
+ /**
292
+ * Gets modified time of drive item.
293
+ * @returns modified date time of drive item
294
+ */
295
+ get_modified(): number;
296
+ /**
297
+ * Gets name of drive item.
298
+ * @returns name of drive item
299
+ */
300
+ get_name(): string;
301
+ /**
302
+ * Gets parent id of drive item.
303
+ * @returns parent id of drive item
304
+ */
305
+ get_parent_id(): string;
306
+ /**
307
+ * Gets size of drive item.
308
+ * @returns size of drive item
309
+ */
310
+ get_size(): number;
311
+ /**
312
+ * Gets user of drive item.
313
+ * @returns user of drive item
314
+ */
315
+ get_user(): string;
316
+ /**
317
+ * Gets whether item is shared.
318
+ * @returns %TRUE if item is shared, otherwise %FALSE
319
+ */
320
+ is_shared(): boolean;
321
+ /**
322
+ * Sets id of drive item.
323
+ * @param id new id of drive item
324
+ */
325
+ set_id(id: string): void;
326
+ /**
327
+ * Sets name of drive item.
328
+ * @param name new name of drive item
329
+ */
330
+ set_name(name: string): void;
331
+ /**
332
+ * Set parent id of drive item.
333
+ * @param parent_id parent id
334
+ */
335
+ set_parent_id(parent_id: string): void;
336
+ }
337
+
338
+ module DriveItemFile {
339
+ // Constructor properties interface
340
+
341
+ interface ConstructorProps extends DriveItem.ConstructorProps {}
342
+ }
343
+
344
+ class DriveItemFile extends DriveItem {
345
+ static $gtype: GObject.GType<DriveItemFile>;
346
+
347
+ // Constructors
348
+
349
+ constructor(properties?: Partial<DriveItemFile.ConstructorProps>, ...args: any[]);
350
+
351
+ _init(...args: any[]): void;
352
+
353
+ static ['new'](): DriveItemFile;
354
+
355
+ static new_from_json(object: Json.Object): DriveItemFile;
356
+
357
+ // Methods
358
+
359
+ /**
360
+ * Gets mime type of drive item file.
361
+ * @returns mime type of drive item file
362
+ */
363
+ get_mime_type(): string;
364
+ /**
365
+ * Gets thumbnail uri of drive item file.
366
+ * @returns thumbnail uri of drive item file
367
+ */
368
+ get_thumbnail_uri(): string;
369
+ }
370
+
371
+ module DriveItemFolder {
372
+ // Constructor properties interface
373
+
374
+ interface ConstructorProps extends DriveItem.ConstructorProps {}
375
+ }
376
+
377
+ class DriveItemFolder extends DriveItem {
378
+ static $gtype: GObject.GType<DriveItemFolder>;
379
+
380
+ // Constructors
381
+
382
+ constructor(properties?: Partial<DriveItemFolder.ConstructorProps>, ...args: any[]);
383
+
384
+ _init(...args: any[]): void;
385
+
386
+ static ['new'](): DriveItemFolder;
387
+
388
+ static new_from_json(object: Json.Object): DriveItemFolder;
389
+ }
390
+
391
+ module DriveService {
392
+ // Constructor properties interface
393
+
394
+ interface ConstructorProps extends Service.ConstructorProps {}
395
+ }
396
+
397
+ class DriveService extends Service {
398
+ static $gtype: GObject.GType<DriveService>;
399
+
400
+ // Constructors
401
+
402
+ constructor(properties?: Partial<DriveService.ConstructorProps>, ...args: any[]);
403
+
404
+ _init(...args: any[]): void;
405
+
406
+ static ['new'](authorizer: Authorizer): DriveService;
407
+
408
+ // Methods
409
+
410
+ /**
411
+ * Adds item to parent folder
412
+ * @param parent parent drive item
413
+ * @param item drive item to add
414
+ * @param cancellable a cancellable
415
+ * @returns a new drive item
416
+ */
417
+ add_item_to_folder(parent: DriveItem, item: DriveItem, cancellable?: Gio.Cancellable | null): DriveItem;
418
+ /**
419
+ * Copy a file async on remote server to a new directory.
420
+ * @param file source #MsgDriveItem
421
+ * @param destination destination directory #MsgDriveItem
422
+ * @param cancellable a #GCancellable
423
+ * @returns %TRUE if accepted, %FALSE on error
424
+ */
425
+ copy_file(file: DriveItem, destination: DriveItem, cancellable?: Gio.Cancellable | null): boolean;
426
+ /**
427
+ * Creates a new folder called name under parent.
428
+ * @param parent parent drive item
429
+ * @param name name of new folder
430
+ * @param cancellable a cancellable
431
+ * @returns a newly created `MsgDriveItem`
432
+ */
433
+ create_folder(parent: DriveItem, name: string, cancellable?: Gio.Cancellable | null): DriveItem;
434
+ /**
435
+ * Deletes item.
436
+ * @param item a #MsgDriveItem
437
+ * @param cancellable a cancellable
438
+ * @returns %TRUE when item has been deleted, otherwise %FALSE
439
+ */
440
+ ['delete'](item: DriveItem, cancellable?: Gio.Cancellable | null): boolean;
441
+ /**
442
+ * Download item
443
+ * @param item a #MsgDriveItem
444
+ * @param cancellable a #GCancellable
445
+ * @returns input stream of drive item
446
+ */
447
+ download_item(item: DriveItem, cancellable?: Gio.Cancellable | null): Gio.InputStream;
448
+ /**
449
+ * Download url
450
+ * @param url url to download
451
+ * @param cancellable a #GCancellable
452
+ * @returns a new `GInputStream` for url
453
+ */
454
+ download_url(url: string, cancellable?: Gio.Cancellable | null): Gio.InputStream;
455
+ /**
456
+ * Queries the Microsoft Graph API for all the drives of the currently logged in user
457
+ * @param cancellable a #GCancellable
458
+ * @returns all drives the user can access
459
+ */
460
+ get_drives(cancellable?: Gio.Cancellable | null): Drive[];
461
+ /**
462
+ * Get root item of selected drive
463
+ * @param drive a #MsgDrive
464
+ * @param cancellable a #GCancellable
465
+ * @returns root 'MsgDriveItem'
466
+ */
467
+ get_root(drive: Drive, cancellable?: Gio.Cancellable | null): DriveItem;
468
+ /**
469
+ * Requests all shared with me items
470
+ * @param cancellable a #GCancellable
471
+ * @returns shared with me list
472
+ */
473
+ get_shared_with_me(cancellable?: Gio.Cancellable | null): DriveItem[];
474
+ /**
475
+ * Get a list of all files in folder item
476
+ * @param item a #MsgDriveItem
477
+ * @param cancellable a #GCancellable
478
+ * @returns all items in folder
479
+ */
480
+ list_children(item: DriveItem, cancellable?: Gio.Cancellable | null): DriveItem[];
481
+ /**
482
+ * Move a file async on remote server to a new directory.
483
+ * @param file source #MsgDriveItem
484
+ * @param destination destination directory #MsgDriveItem
485
+ * @param cancellable a #GCancellable
486
+ * @returns moved #MsgDriveItem
487
+ */
488
+ move_file(file: DriveItem, destination: DriveItem, cancellable?: Gio.Cancellable | null): DriveItem;
489
+ /**
490
+ * Sets a new drive item name
491
+ * @param item a #MsgDriveItem
492
+ * @param new_name new name of item
493
+ * @param cancellable a #GCancellable
494
+ * @returns the renamed `MsgDriveItem`
495
+ */
496
+ rename(item: DriveItem, new_name: string, cancellable?: Gio.Cancellable | null): DriveItem;
497
+ /**
498
+ * Creates an update stream for drive item in order to update it's content.
499
+ * @param item a drive item
500
+ * @param cancellable a cancellable
501
+ * @returns an output stream
502
+ */
503
+ update(item: DriveItem, cancellable?: Gio.Cancellable | null): Gio.OutputStream;
504
+ /**
505
+ * Finish a update session of given #item.
506
+ * @param item a #MsgDriveItem
507
+ * @param stream stream where data is store and needs to be transfered
508
+ * @param cancellable a #GCancellable
509
+ * @returns a new #MsgDriveItem or %NULL on error.
510
+ */
511
+ update_finish(item: DriveItem, stream: Gio.OutputStream, cancellable?: Gio.Cancellable | null): DriveItem;
512
+ }
513
+
514
+ module GoaAuthorizer {
515
+ // Constructor properties interface
516
+
517
+ interface ConstructorProps extends GObject.Object.ConstructorProps, Authorizer.ConstructorProps {
518
+ goa_object: Goa.Object;
519
+ goaObject: Goa.Object;
520
+ }
521
+ }
522
+
523
+ /**
524
+ * The #MsgGoaAuthorizer structure contains only private data and
525
+ * should only be accessed using the provided API.
526
+ */
527
+ class GoaAuthorizer extends GObject.Object implements Authorizer {
528
+ static $gtype: GObject.GType<GoaAuthorizer>;
529
+
530
+ // Properties
531
+
532
+ get goa_object(): Goa.Object;
533
+ get goaObject(): Goa.Object;
534
+
535
+ // Constructors
536
+
537
+ constructor(properties?: Partial<GoaAuthorizer.ConstructorProps>, ...args: any[]);
538
+
539
+ _init(...args: any[]): void;
540
+
541
+ static ['new'](goa_object: Goa.Object): GoaAuthorizer;
542
+
543
+ // Methods
544
+
545
+ /**
546
+ * Gets the GOA account used by `self` for authorization.
547
+ * @returns A #GoaObject. The returned object is owned by #MsgGoaAuthorizer and should not be modified or freed.
548
+ */
549
+ get_goa_object(): Goa.Object;
550
+
551
+ // Inherited methods
552
+ /**
553
+ * Adds the necessary authorization to `message`. The type of `message`
554
+ * can be DELETE, GET and POST.
555
+ *
556
+ * This method modifies `message` in place and is thread safe.
557
+ * @param message A #SoupMessage.
558
+ */
559
+ process_request(message: Soup.Message): void;
560
+ /**
561
+ * Synchronously forces `iface` to refresh any authorization tokens
562
+ * held by it. See msg_authorizer_refresh_authorization_async() for the
563
+ * asynchronous version of this call.
564
+ *
565
+ * This method is thread safe.
566
+ * @param cancellable An optional #GCancellable object, or %NULL.
567
+ * @returns %TRUE if the authorizer now has a valid token.
568
+ */
569
+ refresh_authorization(cancellable?: Gio.Cancellable | null): boolean;
570
+ /**
571
+ * Adds the necessary authorization to `message`. The type of `message`
572
+ * can be DELETE, GET and POST.
573
+ *
574
+ * This method modifies `message` in place and is thread safe.
575
+ * @param message A #SoupMessage.
576
+ */
577
+ vfunc_process_request(message: Soup.Message): void;
578
+ /**
579
+ * Synchronously forces `iface` to refresh any authorization tokens
580
+ * held by it. See msg_authorizer_refresh_authorization_async() for the
581
+ * asynchronous version of this call.
582
+ *
583
+ * This method is thread safe.
584
+ * @param cancellable An optional #GCancellable object, or %NULL.
585
+ */
586
+ vfunc_refresh_authorization(cancellable?: Gio.Cancellable | null): boolean;
587
+ /**
588
+ * Creates a binding between `source_property` on `source` and `target_property`
589
+ * on `target`.
590
+ *
591
+ * Whenever the `source_property` is changed the `target_property` is
592
+ * updated using the same value. For instance:
593
+ *
594
+ *
595
+ * ```c
596
+ * g_object_bind_property (action, "active", widget, "sensitive", 0);
597
+ * ```
598
+ *
599
+ *
600
+ * Will result in the "sensitive" property of the widget #GObject instance to be
601
+ * updated with the same value of the "active" property of the action #GObject
602
+ * instance.
603
+ *
604
+ * If `flags` contains %G_BINDING_BIDIRECTIONAL then the binding will be mutual:
605
+ * if `target_property` on `target` changes then the `source_property` on `source`
606
+ * will be updated as well.
607
+ *
608
+ * The binding will automatically be removed when either the `source` or the
609
+ * `target` instances are finalized. To remove the binding without affecting the
610
+ * `source` and the `target` you can just call g_object_unref() on the returned
611
+ * #GBinding instance.
612
+ *
613
+ * Removing the binding by calling g_object_unref() on it must only be done if
614
+ * the binding, `source` and `target` are only used from a single thread and it
615
+ * is clear that both `source` and `target` outlive the binding. Especially it
616
+ * is not safe to rely on this if the binding, `source` or `target` can be
617
+ * finalized from different threads. Keep another reference to the binding and
618
+ * use g_binding_unbind() instead to be on the safe side.
619
+ *
620
+ * A #GObject can have multiple bindings.
621
+ * @param source_property the property on @source to bind
622
+ * @param target the target #GObject
623
+ * @param target_property the property on @target to bind
624
+ * @param flags flags to pass to #GBinding
625
+ * @returns the #GBinding instance representing the binding between the two #GObject instances. The binding is released whenever the #GBinding reference count reaches zero.
626
+ */
627
+ bind_property(
628
+ source_property: string,
629
+ target: GObject.Object,
630
+ target_property: string,
631
+ flags: GObject.BindingFlags,
632
+ ): GObject.Binding;
633
+ /**
634
+ * Complete version of g_object_bind_property().
635
+ *
636
+ * Creates a binding between `source_property` on `source` and `target_property`
637
+ * on `target,` allowing you to set the transformation functions to be used by
638
+ * the binding.
639
+ *
640
+ * If `flags` contains %G_BINDING_BIDIRECTIONAL then the binding will be mutual:
641
+ * if `target_property` on `target` changes then the `source_property` on `source`
642
+ * will be updated as well. The `transform_from` function is only used in case
643
+ * of bidirectional bindings, otherwise it will be ignored
644
+ *
645
+ * The binding will automatically be removed when either the `source` or the
646
+ * `target` instances are finalized. This will release the reference that is
647
+ * being held on the #GBinding instance; if you want to hold on to the
648
+ * #GBinding instance, you will need to hold a reference to it.
649
+ *
650
+ * To remove the binding, call g_binding_unbind().
651
+ *
652
+ * A #GObject can have multiple bindings.
653
+ *
654
+ * The same `user_data` parameter will be used for both `transform_to`
655
+ * and `transform_from` transformation functions; the `notify` function will
656
+ * be called once, when the binding is removed. If you need different data
657
+ * for each transformation function, please use
658
+ * g_object_bind_property_with_closures() instead.
659
+ * @param source_property the property on @source to bind
660
+ * @param target the target #GObject
661
+ * @param target_property the property on @target to bind
662
+ * @param flags flags to pass to #GBinding
663
+ * @param transform_to the transformation function from the @source to the @target, or %NULL to use the default
664
+ * @param transform_from the transformation function from the @target to the @source, or %NULL to use the default
665
+ * @param notify a function to call when disposing the binding, to free resources used by the transformation functions, or %NULL if not required
666
+ * @returns the #GBinding instance representing the binding between the two #GObject instances. The binding is released whenever the #GBinding reference count reaches zero.
667
+ */
668
+ bind_property_full(
669
+ source_property: string,
670
+ target: GObject.Object,
671
+ target_property: string,
672
+ flags: GObject.BindingFlags,
673
+ transform_to?: GObject.BindingTransformFunc | null,
674
+ transform_from?: GObject.BindingTransformFunc | null,
675
+ notify?: GLib.DestroyNotify | null,
676
+ ): GObject.Binding;
677
+ // Conflicted with GObject.Object.bind_property_full
678
+ bind_property_full(...args: never[]): any;
679
+ /**
680
+ * This function is intended for #GObject implementations to re-enforce
681
+ * a [floating][floating-ref] object reference. Doing this is seldom
682
+ * required: all #GInitiallyUnowneds are created with a floating reference
683
+ * which usually just needs to be sunken by calling g_object_ref_sink().
684
+ */
685
+ force_floating(): void;
686
+ /**
687
+ * Increases the freeze count on `object`. If the freeze count is
688
+ * non-zero, the emission of "notify" signals on `object` is
689
+ * stopped. The signals are queued until the freeze count is decreased
690
+ * to zero. Duplicate notifications are squashed so that at most one
691
+ * #GObject::notify signal is emitted for each property modified while the
692
+ * object is frozen.
693
+ *
694
+ * This is necessary for accessors that modify multiple properties to prevent
695
+ * premature notification while the object is still being modified.
696
+ */
697
+ freeze_notify(): void;
698
+ /**
699
+ * Gets a named field from the objects table of associations (see g_object_set_data()).
700
+ * @param key name of the key for that association
701
+ * @returns the data if found, or %NULL if no such data exists.
702
+ */
703
+ get_data(key: string): any | null;
704
+ get_property(property_name: string): any;
705
+ /**
706
+ * This function gets back user data pointers stored via
707
+ * g_object_set_qdata().
708
+ * @param quark A #GQuark, naming the user data pointer
709
+ * @returns The user data pointer set, or %NULL
710
+ */
711
+ get_qdata(quark: GLib.Quark): any | null;
712
+ /**
713
+ * Gets `n_properties` properties for an `object`.
714
+ * Obtained properties will be set to `values`. All properties must be valid.
715
+ * Warnings will be emitted and undefined behaviour may result if invalid
716
+ * properties are passed in.
717
+ * @param names the names of each property to get
718
+ * @param values the values of each property to get
719
+ */
720
+ getv(names: string[], values: (GObject.Value | any)[]): void;
721
+ /**
722
+ * Checks whether `object` has a [floating][floating-ref] reference.
723
+ * @returns %TRUE if @object has a floating reference
724
+ */
725
+ is_floating(): boolean;
726
+ /**
727
+ * Emits a "notify" signal for the property `property_name` on `object`.
728
+ *
729
+ * When possible, eg. when signaling a property change from within the class
730
+ * that registered the property, you should use g_object_notify_by_pspec()
731
+ * instead.
732
+ *
733
+ * Note that emission of the notify signal may be blocked with
734
+ * g_object_freeze_notify(). In this case, the signal emissions are queued
735
+ * and will be emitted (in reverse order) when g_object_thaw_notify() is
736
+ * called.
737
+ * @param property_name the name of a property installed on the class of @object.
738
+ */
739
+ notify(property_name: string): void;
740
+ /**
741
+ * Emits a "notify" signal for the property specified by `pspec` on `object`.
742
+ *
743
+ * This function omits the property name lookup, hence it is faster than
744
+ * g_object_notify().
745
+ *
746
+ * One way to avoid using g_object_notify() from within the
747
+ * class that registered the properties, and using g_object_notify_by_pspec()
748
+ * instead, is to store the GParamSpec used with
749
+ * g_object_class_install_property() inside a static array, e.g.:
750
+ *
751
+ *
752
+ * ```c
753
+ * typedef enum
754
+ * {
755
+ * PROP_FOO = 1,
756
+ * PROP_LAST
757
+ * } MyObjectProperty;
758
+ *
759
+ * static GParamSpec *properties[PROP_LAST];
760
+ *
761
+ * static void
762
+ * my_object_class_init (MyObjectClass *klass)
763
+ * {
764
+ * properties[PROP_FOO] = g_param_spec_int ("foo", NULL, NULL,
765
+ * 0, 100,
766
+ * 50,
767
+ * G_PARAM_READWRITE | G_PARAM_STATIC_STRINGS);
768
+ * g_object_class_install_property (gobject_class,
769
+ * PROP_FOO,
770
+ * properties[PROP_FOO]);
771
+ * }
772
+ * ```
773
+ *
774
+ *
775
+ * and then notify a change on the "foo" property with:
776
+ *
777
+ *
778
+ * ```c
779
+ * g_object_notify_by_pspec (self, properties[PROP_FOO]);
780
+ * ```
781
+ *
782
+ * @param pspec the #GParamSpec of a property installed on the class of @object.
783
+ */
784
+ notify_by_pspec(pspec: GObject.ParamSpec): void;
785
+ /**
786
+ * Increases the reference count of `object`.
787
+ *
788
+ * Since GLib 2.56, if `GLIB_VERSION_MAX_ALLOWED` is 2.56 or greater, the type
789
+ * of `object` will be propagated to the return type (using the GCC typeof()
790
+ * extension), so any casting the caller needs to do on the return type must be
791
+ * explicit.
792
+ * @returns the same @object
793
+ */
794
+ ref(): GObject.Object;
795
+ /**
796
+ * Increase the reference count of `object,` and possibly remove the
797
+ * [floating][floating-ref] reference, if `object` has a floating reference.
798
+ *
799
+ * In other words, if the object is floating, then this call "assumes
800
+ * ownership" of the floating reference, converting it to a normal
801
+ * reference by clearing the floating flag while leaving the reference
802
+ * count unchanged. If the object is not floating, then this call
803
+ * adds a new normal reference increasing the reference count by one.
804
+ *
805
+ * Since GLib 2.56, the type of `object` will be propagated to the return type
806
+ * under the same conditions as for g_object_ref().
807
+ * @returns @object
808
+ */
809
+ ref_sink(): GObject.Object;
810
+ /**
811
+ * Releases all references to other objects. This can be used to break
812
+ * reference cycles.
813
+ *
814
+ * This function should only be called from object system implementations.
815
+ */
816
+ run_dispose(): void;
817
+ /**
818
+ * Each object carries around a table of associations from
819
+ * strings to pointers. This function lets you set an association.
820
+ *
821
+ * If the object already had an association with that name,
822
+ * the old association will be destroyed.
823
+ *
824
+ * Internally, the `key` is converted to a #GQuark using g_quark_from_string().
825
+ * This means a copy of `key` is kept permanently (even after `object` has been
826
+ * finalized) — so it is recommended to only use a small, bounded set of values
827
+ * for `key` in your program, to avoid the #GQuark storage growing unbounded.
828
+ * @param key name of the key
829
+ * @param data data to associate with that key
830
+ */
831
+ set_data(key: string, data?: any | null): void;
832
+ set_property(property_name: string, value: any): void;
833
+ /**
834
+ * Remove a specified datum from the object's data associations,
835
+ * without invoking the association's destroy handler.
836
+ * @param key name of the key
837
+ * @returns the data if found, or %NULL if no such data exists.
838
+ */
839
+ steal_data(key: string): any | null;
840
+ /**
841
+ * This function gets back user data pointers stored via
842
+ * g_object_set_qdata() and removes the `data` from object
843
+ * without invoking its destroy() function (if any was
844
+ * set).
845
+ * Usually, calling this function is only required to update
846
+ * user data pointers with a destroy notifier, for example:
847
+ *
848
+ * ```c
849
+ * void
850
+ * object_add_to_user_list (GObject *object,
851
+ * const gchar *new_string)
852
+ * {
853
+ * // the quark, naming the object data
854
+ * GQuark quark_string_list = g_quark_from_static_string ("my-string-list");
855
+ * // retrieve the old string list
856
+ * GList *list = g_object_steal_qdata (object, quark_string_list);
857
+ *
858
+ * // prepend new string
859
+ * list = g_list_prepend (list, g_strdup (new_string));
860
+ * // this changed 'list', so we need to set it again
861
+ * g_object_set_qdata_full (object, quark_string_list, list, free_string_list);
862
+ * }
863
+ * static void
864
+ * free_string_list (gpointer data)
865
+ * {
866
+ * GList *node, *list = data;
867
+ *
868
+ * for (node = list; node; node = node->next)
869
+ * g_free (node->data);
870
+ * g_list_free (list);
871
+ * }
872
+ * ```
873
+ *
874
+ * Using g_object_get_qdata() in the above example, instead of
875
+ * g_object_steal_qdata() would have left the destroy function set,
876
+ * and thus the partial string list would have been freed upon
877
+ * g_object_set_qdata_full().
878
+ * @param quark A #GQuark, naming the user data pointer
879
+ * @returns The user data pointer set, or %NULL
880
+ */
881
+ steal_qdata(quark: GLib.Quark): any | null;
882
+ /**
883
+ * Reverts the effect of a previous call to
884
+ * g_object_freeze_notify(). The freeze count is decreased on `object`
885
+ * and when it reaches zero, queued "notify" signals are emitted.
886
+ *
887
+ * Duplicate notifications for each property are squashed so that at most one
888
+ * #GObject::notify signal is emitted for each property, in the reverse order
889
+ * in which they have been queued.
890
+ *
891
+ * It is an error to call this function when the freeze count is zero.
892
+ */
893
+ thaw_notify(): void;
894
+ /**
895
+ * Decreases the reference count of `object`. When its reference count
896
+ * drops to 0, the object is finalized (i.e. its memory is freed).
897
+ *
898
+ * If the pointer to the #GObject may be reused in future (for example, if it is
899
+ * an instance variable of another object), it is recommended to clear the
900
+ * pointer to %NULL rather than retain a dangling pointer to a potentially
901
+ * invalid #GObject instance. Use g_clear_object() for this.
902
+ */
903
+ unref(): void;
904
+ /**
905
+ * This function essentially limits the life time of the `closure` to
906
+ * the life time of the object. That is, when the object is finalized,
907
+ * the `closure` is invalidated by calling g_closure_invalidate() on
908
+ * it, in order to prevent invocations of the closure with a finalized
909
+ * (nonexisting) object. Also, g_object_ref() and g_object_unref() are
910
+ * added as marshal guards to the `closure,` to ensure that an extra
911
+ * reference count is held on `object` during invocation of the
912
+ * `closure`. Usually, this function will be called on closures that
913
+ * use this `object` as closure data.
914
+ * @param closure #GClosure to watch
915
+ */
916
+ watch_closure(closure: GObject.Closure): void;
917
+ /**
918
+ * the `constructed` function is called by g_object_new() as the
919
+ * final step of the object creation process. At the point of the call, all
920
+ * construction properties have been set on the object. The purpose of this
921
+ * call is to allow for object initialisation steps that can only be performed
922
+ * after construction properties have been set. `constructed` implementors
923
+ * should chain up to the `constructed` call of their parent class to allow it
924
+ * to complete its initialisation.
925
+ */
926
+ vfunc_constructed(): void;
927
+ /**
928
+ * emits property change notification for a bunch
929
+ * of properties. Overriding `dispatch_properties_changed` should be rarely
930
+ * needed.
931
+ * @param n_pspecs
932
+ * @param pspecs
933
+ */
934
+ vfunc_dispatch_properties_changed(n_pspecs: number, pspecs: GObject.ParamSpec): void;
935
+ /**
936
+ * the `dispose` function is supposed to drop all references to other
937
+ * objects, but keep the instance otherwise intact, so that client method
938
+ * invocations still work. It may be run multiple times (due to reference
939
+ * loops). Before returning, `dispose` should chain up to the `dispose` method
940
+ * of the parent class.
941
+ */
942
+ vfunc_dispose(): void;
943
+ /**
944
+ * instance finalization function, should finish the finalization of
945
+ * the instance begun in `dispose` and chain up to the `finalize` method of the
946
+ * parent class.
947
+ */
948
+ vfunc_finalize(): void;
949
+ /**
950
+ * the generic getter for all properties of this type. Should be
951
+ * overridden for every type with properties.
952
+ * @param property_id
953
+ * @param value
954
+ * @param pspec
955
+ */
956
+ vfunc_get_property(property_id: number, value: GObject.Value | any, pspec: GObject.ParamSpec): void;
957
+ /**
958
+ * Emits a "notify" signal for the property `property_name` on `object`.
959
+ *
960
+ * When possible, eg. when signaling a property change from within the class
961
+ * that registered the property, you should use g_object_notify_by_pspec()
962
+ * instead.
963
+ *
964
+ * Note that emission of the notify signal may be blocked with
965
+ * g_object_freeze_notify(). In this case, the signal emissions are queued
966
+ * and will be emitted (in reverse order) when g_object_thaw_notify() is
967
+ * called.
968
+ * @param pspec
969
+ */
970
+ vfunc_notify(pspec: GObject.ParamSpec): void;
971
+ /**
972
+ * the generic setter for all properties of this type. Should be
973
+ * overridden for every type with properties. If implementations of
974
+ * `set_property` don't emit property change notification explicitly, this will
975
+ * be done implicitly by the type system. However, if the notify signal is
976
+ * emitted explicitly, the type system will not emit it a second time.
977
+ * @param property_id
978
+ * @param value
979
+ * @param pspec
980
+ */
981
+ vfunc_set_property(property_id: number, value: GObject.Value | any, pspec: GObject.ParamSpec): void;
982
+ disconnect(id: number): void;
983
+ set(properties: { [key: string]: any }): void;
984
+ block_signal_handler(id: number): any;
985
+ unblock_signal_handler(id: number): any;
986
+ stop_emission_by_name(detailedName: string): any;
987
+ }
988
+
989
+ module InputStream {
990
+ // Constructor properties interface
991
+
992
+ interface ConstructorProps extends Gio.InputStream.ConstructorProps, Gio.Seekable.ConstructorProps {}
993
+ }
994
+
995
+ class InputStream extends Gio.InputStream implements Gio.Seekable {
996
+ static $gtype: GObject.GType<InputStream>;
997
+
998
+ // Constructors
999
+
1000
+ constructor(properties?: Partial<InputStream.ConstructorProps>, ...args: any[]);
1001
+
1002
+ _init(...args: any[]): void;
1003
+
1004
+ static ['new'](service: Service, uri: string): InputStream;
1005
+
1006
+ // Static methods
1007
+
1008
+ /**
1009
+ * Gets corresponding SoupMessage
1010
+ * @param stream a #GInputStream
1011
+ */
1012
+ static get_message(stream: Gio.InputStream): Soup.Message;
1013
+ static send_async(
1014
+ stream: Gio.InputStream,
1015
+ io_priority: number,
1016
+ cancellable?: Gio.Cancellable | null,
1017
+ callback?: Gio.AsyncReadyCallback<InputStream> | null,
1018
+ ): void;
1019
+ static send_finish(stream: Gio.InputStream, result: Gio.AsyncResult): boolean;
1020
+
1021
+ // Inherited methods
1022
+ /**
1023
+ * Tests if the stream supports the #GSeekableIface.
1024
+ * @returns %TRUE if @seekable can be seeked. %FALSE otherwise.
1025
+ */
1026
+ can_seek(): boolean;
1027
+ /**
1028
+ * Tests if the length of the stream can be adjusted with
1029
+ * g_seekable_truncate().
1030
+ * @returns %TRUE if the stream can be truncated, %FALSE otherwise.
1031
+ */
1032
+ can_truncate(): boolean;
1033
+ /**
1034
+ * Seeks in the stream by the given `offset,` modified by `type`.
1035
+ *
1036
+ * Attempting to seek past the end of the stream will have different
1037
+ * results depending on if the stream is fixed-sized or resizable. If
1038
+ * the stream is resizable then seeking past the end and then writing
1039
+ * will result in zeros filling the empty space. Seeking past the end
1040
+ * of a resizable stream and reading will result in EOF. Seeking past
1041
+ * the end of a fixed-sized stream will fail.
1042
+ *
1043
+ * Any operation that would result in a negative offset will fail.
1044
+ *
1045
+ * If `cancellable` is not %NULL, then the operation can be cancelled by
1046
+ * triggering the cancellable object from another thread. If the operation
1047
+ * was cancelled, the error %G_IO_ERROR_CANCELLED will be returned.
1048
+ * @param offset a #goffset.
1049
+ * @param type a #GSeekType.
1050
+ * @param cancellable optional #GCancellable object, %NULL to ignore.
1051
+ * @returns %TRUE if successful. If an error has occurred, this function will return %FALSE and set @error appropriately if present.
1052
+ */
1053
+ seek(offset: number, type: GLib.SeekType, cancellable?: Gio.Cancellable | null): boolean;
1054
+ /**
1055
+ * Tells the current position within the stream.
1056
+ * @returns the (positive or zero) offset from the beginning of the buffer, zero if the target is not seekable.
1057
+ */
1058
+ tell(): number;
1059
+ /**
1060
+ * Sets the length of the stream to `offset`. If the stream was previously
1061
+ * larger than `offset,` the extra data is discarded. If the stream was
1062
+ * previously shorter than `offset,` it is extended with NUL ('\0') bytes.
1063
+ *
1064
+ * If `cancellable` is not %NULL, then the operation can be cancelled by
1065
+ * triggering the cancellable object from another thread. If the operation
1066
+ * was cancelled, the error %G_IO_ERROR_CANCELLED will be returned. If an
1067
+ * operation was partially finished when the operation was cancelled the
1068
+ * partial result will be returned, without an error.
1069
+ * @param offset new length for @seekable, in bytes.
1070
+ * @param cancellable optional #GCancellable object, %NULL to ignore.
1071
+ * @returns %TRUE if successful. If an error has occurred, this function will return %FALSE and set @error appropriately if present.
1072
+ */
1073
+ truncate(offset: number, cancellable?: Gio.Cancellable | null): boolean;
1074
+ /**
1075
+ * Tests if the stream supports the #GSeekableIface.
1076
+ */
1077
+ vfunc_can_seek(): boolean;
1078
+ /**
1079
+ * Tests if the length of the stream can be adjusted with
1080
+ * g_seekable_truncate().
1081
+ */
1082
+ vfunc_can_truncate(): boolean;
1083
+ /**
1084
+ * Seeks in the stream by the given `offset,` modified by `type`.
1085
+ *
1086
+ * Attempting to seek past the end of the stream will have different
1087
+ * results depending on if the stream is fixed-sized or resizable. If
1088
+ * the stream is resizable then seeking past the end and then writing
1089
+ * will result in zeros filling the empty space. Seeking past the end
1090
+ * of a resizable stream and reading will result in EOF. Seeking past
1091
+ * the end of a fixed-sized stream will fail.
1092
+ *
1093
+ * Any operation that would result in a negative offset will fail.
1094
+ *
1095
+ * If `cancellable` is not %NULL, then the operation can be cancelled by
1096
+ * triggering the cancellable object from another thread. If the operation
1097
+ * was cancelled, the error %G_IO_ERROR_CANCELLED will be returned.
1098
+ * @param offset a #goffset.
1099
+ * @param type a #GSeekType.
1100
+ * @param cancellable optional #GCancellable object, %NULL to ignore.
1101
+ */
1102
+ vfunc_seek(offset: number, type: GLib.SeekType, cancellable?: Gio.Cancellable | null): boolean;
1103
+ /**
1104
+ * Tells the current position within the stream.
1105
+ */
1106
+ vfunc_tell(): number;
1107
+ /**
1108
+ * Sets the length of the stream to `offset`. If the stream was previously
1109
+ * larger than `offset,` the extra data is discarded. If the stream was
1110
+ * previously shorter than `offset,` it is extended with NUL ('\0') bytes.
1111
+ *
1112
+ * If `cancellable` is not %NULL, then the operation can be cancelled by
1113
+ * triggering the cancellable object from another thread. If the operation
1114
+ * was cancelled, the error %G_IO_ERROR_CANCELLED will be returned. If an
1115
+ * operation was partially finished when the operation was cancelled the
1116
+ * partial result will be returned, without an error.
1117
+ * @param offset new length for @seekable, in bytes.
1118
+ * @param cancellable optional #GCancellable object, %NULL to ignore.
1119
+ */
1120
+ vfunc_truncate_fn(offset: number, cancellable?: Gio.Cancellable | null): boolean;
1121
+ /**
1122
+ * Creates a binding between `source_property` on `source` and `target_property`
1123
+ * on `target`.
1124
+ *
1125
+ * Whenever the `source_property` is changed the `target_property` is
1126
+ * updated using the same value. For instance:
1127
+ *
1128
+ *
1129
+ * ```c
1130
+ * g_object_bind_property (action, "active", widget, "sensitive", 0);
1131
+ * ```
1132
+ *
1133
+ *
1134
+ * Will result in the "sensitive" property of the widget #GObject instance to be
1135
+ * updated with the same value of the "active" property of the action #GObject
1136
+ * instance.
1137
+ *
1138
+ * If `flags` contains %G_BINDING_BIDIRECTIONAL then the binding will be mutual:
1139
+ * if `target_property` on `target` changes then the `source_property` on `source`
1140
+ * will be updated as well.
1141
+ *
1142
+ * The binding will automatically be removed when either the `source` or the
1143
+ * `target` instances are finalized. To remove the binding without affecting the
1144
+ * `source` and the `target` you can just call g_object_unref() on the returned
1145
+ * #GBinding instance.
1146
+ *
1147
+ * Removing the binding by calling g_object_unref() on it must only be done if
1148
+ * the binding, `source` and `target` are only used from a single thread and it
1149
+ * is clear that both `source` and `target` outlive the binding. Especially it
1150
+ * is not safe to rely on this if the binding, `source` or `target` can be
1151
+ * finalized from different threads. Keep another reference to the binding and
1152
+ * use g_binding_unbind() instead to be on the safe side.
1153
+ *
1154
+ * A #GObject can have multiple bindings.
1155
+ * @param source_property the property on @source to bind
1156
+ * @param target the target #GObject
1157
+ * @param target_property the property on @target to bind
1158
+ * @param flags flags to pass to #GBinding
1159
+ * @returns the #GBinding instance representing the binding between the two #GObject instances. The binding is released whenever the #GBinding reference count reaches zero.
1160
+ */
1161
+ bind_property(
1162
+ source_property: string,
1163
+ target: GObject.Object,
1164
+ target_property: string,
1165
+ flags: GObject.BindingFlags,
1166
+ ): GObject.Binding;
1167
+ /**
1168
+ * Complete version of g_object_bind_property().
1169
+ *
1170
+ * Creates a binding between `source_property` on `source` and `target_property`
1171
+ * on `target,` allowing you to set the transformation functions to be used by
1172
+ * the binding.
1173
+ *
1174
+ * If `flags` contains %G_BINDING_BIDIRECTIONAL then the binding will be mutual:
1175
+ * if `target_property` on `target` changes then the `source_property` on `source`
1176
+ * will be updated as well. The `transform_from` function is only used in case
1177
+ * of bidirectional bindings, otherwise it will be ignored
1178
+ *
1179
+ * The binding will automatically be removed when either the `source` or the
1180
+ * `target` instances are finalized. This will release the reference that is
1181
+ * being held on the #GBinding instance; if you want to hold on to the
1182
+ * #GBinding instance, you will need to hold a reference to it.
1183
+ *
1184
+ * To remove the binding, call g_binding_unbind().
1185
+ *
1186
+ * A #GObject can have multiple bindings.
1187
+ *
1188
+ * The same `user_data` parameter will be used for both `transform_to`
1189
+ * and `transform_from` transformation functions; the `notify` function will
1190
+ * be called once, when the binding is removed. If you need different data
1191
+ * for each transformation function, please use
1192
+ * g_object_bind_property_with_closures() instead.
1193
+ * @param source_property the property on @source to bind
1194
+ * @param target the target #GObject
1195
+ * @param target_property the property on @target to bind
1196
+ * @param flags flags to pass to #GBinding
1197
+ * @param transform_to the transformation function from the @source to the @target, or %NULL to use the default
1198
+ * @param transform_from the transformation function from the @target to the @source, or %NULL to use the default
1199
+ * @param notify a function to call when disposing the binding, to free resources used by the transformation functions, or %NULL if not required
1200
+ * @returns the #GBinding instance representing the binding between the two #GObject instances. The binding is released whenever the #GBinding reference count reaches zero.
1201
+ */
1202
+ bind_property_full(
1203
+ source_property: string,
1204
+ target: GObject.Object,
1205
+ target_property: string,
1206
+ flags: GObject.BindingFlags,
1207
+ transform_to?: GObject.BindingTransformFunc | null,
1208
+ transform_from?: GObject.BindingTransformFunc | null,
1209
+ notify?: GLib.DestroyNotify | null,
1210
+ ): GObject.Binding;
1211
+ // Conflicted with GObject.Object.bind_property_full
1212
+ bind_property_full(...args: never[]): any;
1213
+ /**
1214
+ * This function is intended for #GObject implementations to re-enforce
1215
+ * a [floating][floating-ref] object reference. Doing this is seldom
1216
+ * required: all #GInitiallyUnowneds are created with a floating reference
1217
+ * which usually just needs to be sunken by calling g_object_ref_sink().
1218
+ */
1219
+ force_floating(): void;
1220
+ /**
1221
+ * Increases the freeze count on `object`. If the freeze count is
1222
+ * non-zero, the emission of "notify" signals on `object` is
1223
+ * stopped. The signals are queued until the freeze count is decreased
1224
+ * to zero. Duplicate notifications are squashed so that at most one
1225
+ * #GObject::notify signal is emitted for each property modified while the
1226
+ * object is frozen.
1227
+ *
1228
+ * This is necessary for accessors that modify multiple properties to prevent
1229
+ * premature notification while the object is still being modified.
1230
+ */
1231
+ freeze_notify(): void;
1232
+ /**
1233
+ * Gets a named field from the objects table of associations (see g_object_set_data()).
1234
+ * @param key name of the key for that association
1235
+ * @returns the data if found, or %NULL if no such data exists.
1236
+ */
1237
+ get_data(key: string): any | null;
1238
+ get_property(property_name: string): any;
1239
+ /**
1240
+ * This function gets back user data pointers stored via
1241
+ * g_object_set_qdata().
1242
+ * @param quark A #GQuark, naming the user data pointer
1243
+ * @returns The user data pointer set, or %NULL
1244
+ */
1245
+ get_qdata(quark: GLib.Quark): any | null;
1246
+ /**
1247
+ * Gets `n_properties` properties for an `object`.
1248
+ * Obtained properties will be set to `values`. All properties must be valid.
1249
+ * Warnings will be emitted and undefined behaviour may result if invalid
1250
+ * properties are passed in.
1251
+ * @param names the names of each property to get
1252
+ * @param values the values of each property to get
1253
+ */
1254
+ getv(names: string[], values: (GObject.Value | any)[]): void;
1255
+ /**
1256
+ * Checks whether `object` has a [floating][floating-ref] reference.
1257
+ * @returns %TRUE if @object has a floating reference
1258
+ */
1259
+ is_floating(): boolean;
1260
+ /**
1261
+ * Emits a "notify" signal for the property `property_name` on `object`.
1262
+ *
1263
+ * When possible, eg. when signaling a property change from within the class
1264
+ * that registered the property, you should use g_object_notify_by_pspec()
1265
+ * instead.
1266
+ *
1267
+ * Note that emission of the notify signal may be blocked with
1268
+ * g_object_freeze_notify(). In this case, the signal emissions are queued
1269
+ * and will be emitted (in reverse order) when g_object_thaw_notify() is
1270
+ * called.
1271
+ * @param property_name the name of a property installed on the class of @object.
1272
+ */
1273
+ notify(property_name: string): void;
1274
+ /**
1275
+ * Emits a "notify" signal for the property specified by `pspec` on `object`.
1276
+ *
1277
+ * This function omits the property name lookup, hence it is faster than
1278
+ * g_object_notify().
1279
+ *
1280
+ * One way to avoid using g_object_notify() from within the
1281
+ * class that registered the properties, and using g_object_notify_by_pspec()
1282
+ * instead, is to store the GParamSpec used with
1283
+ * g_object_class_install_property() inside a static array, e.g.:
1284
+ *
1285
+ *
1286
+ * ```c
1287
+ * typedef enum
1288
+ * {
1289
+ * PROP_FOO = 1,
1290
+ * PROP_LAST
1291
+ * } MyObjectProperty;
1292
+ *
1293
+ * static GParamSpec *properties[PROP_LAST];
1294
+ *
1295
+ * static void
1296
+ * my_object_class_init (MyObjectClass *klass)
1297
+ * {
1298
+ * properties[PROP_FOO] = g_param_spec_int ("foo", NULL, NULL,
1299
+ * 0, 100,
1300
+ * 50,
1301
+ * G_PARAM_READWRITE | G_PARAM_STATIC_STRINGS);
1302
+ * g_object_class_install_property (gobject_class,
1303
+ * PROP_FOO,
1304
+ * properties[PROP_FOO]);
1305
+ * }
1306
+ * ```
1307
+ *
1308
+ *
1309
+ * and then notify a change on the "foo" property with:
1310
+ *
1311
+ *
1312
+ * ```c
1313
+ * g_object_notify_by_pspec (self, properties[PROP_FOO]);
1314
+ * ```
1315
+ *
1316
+ * @param pspec the #GParamSpec of a property installed on the class of @object.
1317
+ */
1318
+ notify_by_pspec(pspec: GObject.ParamSpec): void;
1319
+ /**
1320
+ * Increases the reference count of `object`.
1321
+ *
1322
+ * Since GLib 2.56, if `GLIB_VERSION_MAX_ALLOWED` is 2.56 or greater, the type
1323
+ * of `object` will be propagated to the return type (using the GCC typeof()
1324
+ * extension), so any casting the caller needs to do on the return type must be
1325
+ * explicit.
1326
+ * @returns the same @object
1327
+ */
1328
+ ref(): GObject.Object;
1329
+ /**
1330
+ * Increase the reference count of `object,` and possibly remove the
1331
+ * [floating][floating-ref] reference, if `object` has a floating reference.
1332
+ *
1333
+ * In other words, if the object is floating, then this call "assumes
1334
+ * ownership" of the floating reference, converting it to a normal
1335
+ * reference by clearing the floating flag while leaving the reference
1336
+ * count unchanged. If the object is not floating, then this call
1337
+ * adds a new normal reference increasing the reference count by one.
1338
+ *
1339
+ * Since GLib 2.56, the type of `object` will be propagated to the return type
1340
+ * under the same conditions as for g_object_ref().
1341
+ * @returns @object
1342
+ */
1343
+ ref_sink(): GObject.Object;
1344
+ /**
1345
+ * Releases all references to other objects. This can be used to break
1346
+ * reference cycles.
1347
+ *
1348
+ * This function should only be called from object system implementations.
1349
+ */
1350
+ run_dispose(): void;
1351
+ /**
1352
+ * Each object carries around a table of associations from
1353
+ * strings to pointers. This function lets you set an association.
1354
+ *
1355
+ * If the object already had an association with that name,
1356
+ * the old association will be destroyed.
1357
+ *
1358
+ * Internally, the `key` is converted to a #GQuark using g_quark_from_string().
1359
+ * This means a copy of `key` is kept permanently (even after `object` has been
1360
+ * finalized) — so it is recommended to only use a small, bounded set of values
1361
+ * for `key` in your program, to avoid the #GQuark storage growing unbounded.
1362
+ * @param key name of the key
1363
+ * @param data data to associate with that key
1364
+ */
1365
+ set_data(key: string, data?: any | null): void;
1366
+ set_property(property_name: string, value: any): void;
1367
+ /**
1368
+ * Remove a specified datum from the object's data associations,
1369
+ * without invoking the association's destroy handler.
1370
+ * @param key name of the key
1371
+ * @returns the data if found, or %NULL if no such data exists.
1372
+ */
1373
+ steal_data(key: string): any | null;
1374
+ /**
1375
+ * This function gets back user data pointers stored via
1376
+ * g_object_set_qdata() and removes the `data` from object
1377
+ * without invoking its destroy() function (if any was
1378
+ * set).
1379
+ * Usually, calling this function is only required to update
1380
+ * user data pointers with a destroy notifier, for example:
1381
+ *
1382
+ * ```c
1383
+ * void
1384
+ * object_add_to_user_list (GObject *object,
1385
+ * const gchar *new_string)
1386
+ * {
1387
+ * // the quark, naming the object data
1388
+ * GQuark quark_string_list = g_quark_from_static_string ("my-string-list");
1389
+ * // retrieve the old string list
1390
+ * GList *list = g_object_steal_qdata (object, quark_string_list);
1391
+ *
1392
+ * // prepend new string
1393
+ * list = g_list_prepend (list, g_strdup (new_string));
1394
+ * // this changed 'list', so we need to set it again
1395
+ * g_object_set_qdata_full (object, quark_string_list, list, free_string_list);
1396
+ * }
1397
+ * static void
1398
+ * free_string_list (gpointer data)
1399
+ * {
1400
+ * GList *node, *list = data;
1401
+ *
1402
+ * for (node = list; node; node = node->next)
1403
+ * g_free (node->data);
1404
+ * g_list_free (list);
1405
+ * }
1406
+ * ```
1407
+ *
1408
+ * Using g_object_get_qdata() in the above example, instead of
1409
+ * g_object_steal_qdata() would have left the destroy function set,
1410
+ * and thus the partial string list would have been freed upon
1411
+ * g_object_set_qdata_full().
1412
+ * @param quark A #GQuark, naming the user data pointer
1413
+ * @returns The user data pointer set, or %NULL
1414
+ */
1415
+ steal_qdata(quark: GLib.Quark): any | null;
1416
+ /**
1417
+ * Reverts the effect of a previous call to
1418
+ * g_object_freeze_notify(). The freeze count is decreased on `object`
1419
+ * and when it reaches zero, queued "notify" signals are emitted.
1420
+ *
1421
+ * Duplicate notifications for each property are squashed so that at most one
1422
+ * #GObject::notify signal is emitted for each property, in the reverse order
1423
+ * in which they have been queued.
1424
+ *
1425
+ * It is an error to call this function when the freeze count is zero.
1426
+ */
1427
+ thaw_notify(): void;
1428
+ /**
1429
+ * Decreases the reference count of `object`. When its reference count
1430
+ * drops to 0, the object is finalized (i.e. its memory is freed).
1431
+ *
1432
+ * If the pointer to the #GObject may be reused in future (for example, if it is
1433
+ * an instance variable of another object), it is recommended to clear the
1434
+ * pointer to %NULL rather than retain a dangling pointer to a potentially
1435
+ * invalid #GObject instance. Use g_clear_object() for this.
1436
+ */
1437
+ unref(): void;
1438
+ /**
1439
+ * This function essentially limits the life time of the `closure` to
1440
+ * the life time of the object. That is, when the object is finalized,
1441
+ * the `closure` is invalidated by calling g_closure_invalidate() on
1442
+ * it, in order to prevent invocations of the closure with a finalized
1443
+ * (nonexisting) object. Also, g_object_ref() and g_object_unref() are
1444
+ * added as marshal guards to the `closure,` to ensure that an extra
1445
+ * reference count is held on `object` during invocation of the
1446
+ * `closure`. Usually, this function will be called on closures that
1447
+ * use this `object` as closure data.
1448
+ * @param closure #GClosure to watch
1449
+ */
1450
+ watch_closure(closure: GObject.Closure): void;
1451
+ /**
1452
+ * the `constructed` function is called by g_object_new() as the
1453
+ * final step of the object creation process. At the point of the call, all
1454
+ * construction properties have been set on the object. The purpose of this
1455
+ * call is to allow for object initialisation steps that can only be performed
1456
+ * after construction properties have been set. `constructed` implementors
1457
+ * should chain up to the `constructed` call of their parent class to allow it
1458
+ * to complete its initialisation.
1459
+ */
1460
+ vfunc_constructed(): void;
1461
+ /**
1462
+ * emits property change notification for a bunch
1463
+ * of properties. Overriding `dispatch_properties_changed` should be rarely
1464
+ * needed.
1465
+ * @param n_pspecs
1466
+ * @param pspecs
1467
+ */
1468
+ vfunc_dispatch_properties_changed(n_pspecs: number, pspecs: GObject.ParamSpec): void;
1469
+ /**
1470
+ * the `dispose` function is supposed to drop all references to other
1471
+ * objects, but keep the instance otherwise intact, so that client method
1472
+ * invocations still work. It may be run multiple times (due to reference
1473
+ * loops). Before returning, `dispose` should chain up to the `dispose` method
1474
+ * of the parent class.
1475
+ */
1476
+ vfunc_dispose(): void;
1477
+ /**
1478
+ * instance finalization function, should finish the finalization of
1479
+ * the instance begun in `dispose` and chain up to the `finalize` method of the
1480
+ * parent class.
1481
+ */
1482
+ vfunc_finalize(): void;
1483
+ /**
1484
+ * the generic getter for all properties of this type. Should be
1485
+ * overridden for every type with properties.
1486
+ * @param property_id
1487
+ * @param value
1488
+ * @param pspec
1489
+ */
1490
+ vfunc_get_property(property_id: number, value: GObject.Value | any, pspec: GObject.ParamSpec): void;
1491
+ /**
1492
+ * Emits a "notify" signal for the property `property_name` on `object`.
1493
+ *
1494
+ * When possible, eg. when signaling a property change from within the class
1495
+ * that registered the property, you should use g_object_notify_by_pspec()
1496
+ * instead.
1497
+ *
1498
+ * Note that emission of the notify signal may be blocked with
1499
+ * g_object_freeze_notify(). In this case, the signal emissions are queued
1500
+ * and will be emitted (in reverse order) when g_object_thaw_notify() is
1501
+ * called.
1502
+ * @param pspec
1503
+ */
1504
+ vfunc_notify(pspec: GObject.ParamSpec): void;
1505
+ /**
1506
+ * the generic setter for all properties of this type. Should be
1507
+ * overridden for every type with properties. If implementations of
1508
+ * `set_property` don't emit property change notification explicitly, this will
1509
+ * be done implicitly by the type system. However, if the notify signal is
1510
+ * emitted explicitly, the type system will not emit it a second time.
1511
+ * @param property_id
1512
+ * @param value
1513
+ * @param pspec
1514
+ */
1515
+ vfunc_set_property(property_id: number, value: GObject.Value | any, pspec: GObject.ParamSpec): void;
1516
+ disconnect(id: number): void;
1517
+ set(properties: { [key: string]: any }): void;
1518
+ block_signal_handler(id: number): any;
1519
+ unblock_signal_handler(id: number): any;
1520
+ stop_emission_by_name(detailedName: string): any;
1521
+ }
1522
+
1523
+ module MailFolder {
1524
+ // Constructor properties interface
1525
+
1526
+ interface ConstructorProps extends GObject.Object.ConstructorProps {}
1527
+ }
1528
+
1529
+ /**
1530
+ * Handling of mail folder specific functions.
1531
+ */
1532
+ class MailFolder extends GObject.Object {
1533
+ static $gtype: GObject.GType<MailFolder>;
1534
+
1535
+ // Constructors
1536
+
1537
+ constructor(properties?: Partial<MailFolder.ConstructorProps>, ...args: any[]);
1538
+
1539
+ _init(...args: any[]): void;
1540
+
1541
+ static ['new'](): MailFolder;
1542
+
1543
+ static new_from_json(json_object: Json.Object): MailFolder;
1544
+
1545
+ // Methods
1546
+
1547
+ get_display_name(): string;
1548
+ get_total_item_count(): number;
1549
+ get_unread_item_count(): number;
1550
+ }
1551
+
1552
+ module Message {
1553
+ // Constructor properties interface
1554
+
1555
+ interface ConstructorProps extends GObject.Object.ConstructorProps {}
1556
+ }
1557
+
1558
+ /**
1559
+ * Handling of message specific functions.
1560
+ *
1561
+ * Details: https://learn.microsoft.com/en-us/graph/api/resources/message?view=graph-rest-1.0
1562
+ */
1563
+ class Message extends GObject.Object {
1564
+ static $gtype: GObject.GType<Message>;
1565
+
1566
+ // Constructors
1567
+
1568
+ constructor(properties?: Partial<Message.ConstructorProps>, ...args: any[]);
1569
+
1570
+ _init(...args: any[]): void;
1571
+
1572
+ static ['new'](): Message;
1573
+
1574
+ static new_from_json(json_object: Json.Object): Message;
1575
+
1576
+ // Methods
1577
+
1578
+ get_body_preview(): string;
1579
+ get_id(): string;
1580
+ get_subject(): string;
1581
+ set_body(body: string): boolean;
1582
+ set_subject(subject: string): boolean;
1583
+ }
1584
+
1585
+ module MessageService {
1586
+ // Constructor properties interface
1587
+
1588
+ interface ConstructorProps extends Service.ConstructorProps {}
1589
+ }
1590
+
1591
+ class MessageService extends Service {
1592
+ static $gtype: GObject.GType<MessageService>;
1593
+
1594
+ // Constructors
1595
+
1596
+ constructor(properties?: Partial<MessageService.ConstructorProps>, ...args: any[]);
1597
+
1598
+ _init(...args: any[]): void;
1599
+
1600
+ static ['new'](authorizer: Authorizer): MessageService;
1601
+
1602
+ // Methods
1603
+
1604
+ /**
1605
+ * Create new draft message #message and return new message object.
1606
+ * @param message a #MsgMessage
1607
+ * @param cancellable a #GCancellable
1608
+ * @returns a new #MsgMessage
1609
+ */
1610
+ create_draft(message: Message, cancellable?: Gio.Cancellable | null): Message;
1611
+ /**
1612
+ * Delets #message.
1613
+ * @param message a #MsgMessage
1614
+ * @param cancellable a #GCancellable
1615
+ * @returns %TRUE for succes, else &FALSE
1616
+ */
1617
+ ['delete'](message: Message, cancellable?: Gio.Cancellable | null): boolean;
1618
+ /**
1619
+ * Get a specific mail folder for given service
1620
+ * @param type a #MsgMessageMailFolderType
1621
+ * @param cancellable a #GCancellable
1622
+ * @returns a #MsgMailFolder
1623
+ */
1624
+ get_mail_folder(type: MessageMailFolderType, cancellable?: Gio.Cancellable | null): MailFolder;
1625
+ /**
1626
+ * Get all folders for given service
1627
+ * @param cancellable a #GCancellable
1628
+ * @returns all mail folders the user can access
1629
+ */
1630
+ get_mail_folders(cancellable?: Gio.Cancellable | null): MailFolder[];
1631
+ /**
1632
+ * Get all messages for given service
1633
+ * @param cancellable a #GCancellable
1634
+ * @returns all messages the user can access
1635
+ */
1636
+ get_messages(cancellable?: Gio.Cancellable | null): Message[];
1637
+ }
1638
+
1639
+ module OAuth2Authorizer {
1640
+ // Constructor properties interface
1641
+
1642
+ interface ConstructorProps extends GObject.Object.ConstructorProps, Authorizer.ConstructorProps {
1643
+ client_id: string;
1644
+ clientId: string;
1645
+ redirect_uri: string;
1646
+ redirectUri: string;
1647
+ refresh_token: string;
1648
+ refreshToken: string;
1649
+ }
1650
+ }
1651
+
1652
+ class OAuth2Authorizer extends GObject.Object implements Authorizer {
1653
+ static $gtype: GObject.GType<OAuth2Authorizer>;
1654
+
1655
+ // Properties
1656
+
1657
+ get client_id(): string;
1658
+ get clientId(): string;
1659
+ get redirect_uri(): string;
1660
+ get redirectUri(): string;
1661
+ get refresh_token(): string;
1662
+ set refresh_token(val: string);
1663
+ get refreshToken(): string;
1664
+ set refreshToken(val: string);
1665
+
1666
+ // Constructors
1667
+
1668
+ constructor(properties?: Partial<OAuth2Authorizer.ConstructorProps>, ...args: any[]);
1669
+
1670
+ _init(...args: any[]): void;
1671
+
1672
+ static ['new'](client_id: string, redirect_uri: string): OAuth2Authorizer;
1673
+
1674
+ // Static methods
1675
+
1676
+ static test_load_credentials(self: Authorizer): boolean;
1677
+ static test_save_credentials(self: Authorizer): void;
1678
+
1679
+ // Methods
1680
+
1681
+ build_authentication_uri(): string;
1682
+ request_authorization(authorization_code: string, cancellable?: Gio.Cancellable | null): boolean;
1683
+
1684
+ // Inherited methods
1685
+ /**
1686
+ * Adds the necessary authorization to `message`. The type of `message`
1687
+ * can be DELETE, GET and POST.
1688
+ *
1689
+ * This method modifies `message` in place and is thread safe.
1690
+ * @param message A #SoupMessage.
1691
+ */
1692
+ process_request(message: Soup.Message): void;
1693
+ /**
1694
+ * Synchronously forces `iface` to refresh any authorization tokens
1695
+ * held by it. See msg_authorizer_refresh_authorization_async() for the
1696
+ * asynchronous version of this call.
1697
+ *
1698
+ * This method is thread safe.
1699
+ * @param cancellable An optional #GCancellable object, or %NULL.
1700
+ * @returns %TRUE if the authorizer now has a valid token.
1701
+ */
1702
+ refresh_authorization(cancellable?: Gio.Cancellable | null): boolean;
1703
+ /**
1704
+ * Adds the necessary authorization to `message`. The type of `message`
1705
+ * can be DELETE, GET and POST.
1706
+ *
1707
+ * This method modifies `message` in place and is thread safe.
1708
+ * @param message A #SoupMessage.
1709
+ */
1710
+ vfunc_process_request(message: Soup.Message): void;
1711
+ /**
1712
+ * Synchronously forces `iface` to refresh any authorization tokens
1713
+ * held by it. See msg_authorizer_refresh_authorization_async() for the
1714
+ * asynchronous version of this call.
1715
+ *
1716
+ * This method is thread safe.
1717
+ * @param cancellable An optional #GCancellable object, or %NULL.
1718
+ */
1719
+ vfunc_refresh_authorization(cancellable?: Gio.Cancellable | null): boolean;
1720
+ /**
1721
+ * Creates a binding between `source_property` on `source` and `target_property`
1722
+ * on `target`.
1723
+ *
1724
+ * Whenever the `source_property` is changed the `target_property` is
1725
+ * updated using the same value. For instance:
1726
+ *
1727
+ *
1728
+ * ```c
1729
+ * g_object_bind_property (action, "active", widget, "sensitive", 0);
1730
+ * ```
1731
+ *
1732
+ *
1733
+ * Will result in the "sensitive" property of the widget #GObject instance to be
1734
+ * updated with the same value of the "active" property of the action #GObject
1735
+ * instance.
1736
+ *
1737
+ * If `flags` contains %G_BINDING_BIDIRECTIONAL then the binding will be mutual:
1738
+ * if `target_property` on `target` changes then the `source_property` on `source`
1739
+ * will be updated as well.
1740
+ *
1741
+ * The binding will automatically be removed when either the `source` or the
1742
+ * `target` instances are finalized. To remove the binding without affecting the
1743
+ * `source` and the `target` you can just call g_object_unref() on the returned
1744
+ * #GBinding instance.
1745
+ *
1746
+ * Removing the binding by calling g_object_unref() on it must only be done if
1747
+ * the binding, `source` and `target` are only used from a single thread and it
1748
+ * is clear that both `source` and `target` outlive the binding. Especially it
1749
+ * is not safe to rely on this if the binding, `source` or `target` can be
1750
+ * finalized from different threads. Keep another reference to the binding and
1751
+ * use g_binding_unbind() instead to be on the safe side.
1752
+ *
1753
+ * A #GObject can have multiple bindings.
1754
+ * @param source_property the property on @source to bind
1755
+ * @param target the target #GObject
1756
+ * @param target_property the property on @target to bind
1757
+ * @param flags flags to pass to #GBinding
1758
+ * @returns the #GBinding instance representing the binding between the two #GObject instances. The binding is released whenever the #GBinding reference count reaches zero.
1759
+ */
1760
+ bind_property(
1761
+ source_property: string,
1762
+ target: GObject.Object,
1763
+ target_property: string,
1764
+ flags: GObject.BindingFlags,
1765
+ ): GObject.Binding;
1766
+ /**
1767
+ * Complete version of g_object_bind_property().
1768
+ *
1769
+ * Creates a binding between `source_property` on `source` and `target_property`
1770
+ * on `target,` allowing you to set the transformation functions to be used by
1771
+ * the binding.
1772
+ *
1773
+ * If `flags` contains %G_BINDING_BIDIRECTIONAL then the binding will be mutual:
1774
+ * if `target_property` on `target` changes then the `source_property` on `source`
1775
+ * will be updated as well. The `transform_from` function is only used in case
1776
+ * of bidirectional bindings, otherwise it will be ignored
1777
+ *
1778
+ * The binding will automatically be removed when either the `source` or the
1779
+ * `target` instances are finalized. This will release the reference that is
1780
+ * being held on the #GBinding instance; if you want to hold on to the
1781
+ * #GBinding instance, you will need to hold a reference to it.
1782
+ *
1783
+ * To remove the binding, call g_binding_unbind().
1784
+ *
1785
+ * A #GObject can have multiple bindings.
1786
+ *
1787
+ * The same `user_data` parameter will be used for both `transform_to`
1788
+ * and `transform_from` transformation functions; the `notify` function will
1789
+ * be called once, when the binding is removed. If you need different data
1790
+ * for each transformation function, please use
1791
+ * g_object_bind_property_with_closures() instead.
1792
+ * @param source_property the property on @source to bind
1793
+ * @param target the target #GObject
1794
+ * @param target_property the property on @target to bind
1795
+ * @param flags flags to pass to #GBinding
1796
+ * @param transform_to the transformation function from the @source to the @target, or %NULL to use the default
1797
+ * @param transform_from the transformation function from the @target to the @source, or %NULL to use the default
1798
+ * @param notify a function to call when disposing the binding, to free resources used by the transformation functions, or %NULL if not required
1799
+ * @returns the #GBinding instance representing the binding between the two #GObject instances. The binding is released whenever the #GBinding reference count reaches zero.
1800
+ */
1801
+ bind_property_full(
1802
+ source_property: string,
1803
+ target: GObject.Object,
1804
+ target_property: string,
1805
+ flags: GObject.BindingFlags,
1806
+ transform_to?: GObject.BindingTransformFunc | null,
1807
+ transform_from?: GObject.BindingTransformFunc | null,
1808
+ notify?: GLib.DestroyNotify | null,
1809
+ ): GObject.Binding;
1810
+ // Conflicted with GObject.Object.bind_property_full
1811
+ bind_property_full(...args: never[]): any;
1812
+ /**
1813
+ * This function is intended for #GObject implementations to re-enforce
1814
+ * a [floating][floating-ref] object reference. Doing this is seldom
1815
+ * required: all #GInitiallyUnowneds are created with a floating reference
1816
+ * which usually just needs to be sunken by calling g_object_ref_sink().
1817
+ */
1818
+ force_floating(): void;
1819
+ /**
1820
+ * Increases the freeze count on `object`. If the freeze count is
1821
+ * non-zero, the emission of "notify" signals on `object` is
1822
+ * stopped. The signals are queued until the freeze count is decreased
1823
+ * to zero. Duplicate notifications are squashed so that at most one
1824
+ * #GObject::notify signal is emitted for each property modified while the
1825
+ * object is frozen.
1826
+ *
1827
+ * This is necessary for accessors that modify multiple properties to prevent
1828
+ * premature notification while the object is still being modified.
1829
+ */
1830
+ freeze_notify(): void;
1831
+ /**
1832
+ * Gets a named field from the objects table of associations (see g_object_set_data()).
1833
+ * @param key name of the key for that association
1834
+ * @returns the data if found, or %NULL if no such data exists.
1835
+ */
1836
+ get_data(key: string): any | null;
1837
+ get_property(property_name: string): any;
1838
+ /**
1839
+ * This function gets back user data pointers stored via
1840
+ * g_object_set_qdata().
1841
+ * @param quark A #GQuark, naming the user data pointer
1842
+ * @returns The user data pointer set, or %NULL
1843
+ */
1844
+ get_qdata(quark: GLib.Quark): any | null;
1845
+ /**
1846
+ * Gets `n_properties` properties for an `object`.
1847
+ * Obtained properties will be set to `values`. All properties must be valid.
1848
+ * Warnings will be emitted and undefined behaviour may result if invalid
1849
+ * properties are passed in.
1850
+ * @param names the names of each property to get
1851
+ * @param values the values of each property to get
1852
+ */
1853
+ getv(names: string[], values: (GObject.Value | any)[]): void;
1854
+ /**
1855
+ * Checks whether `object` has a [floating][floating-ref] reference.
1856
+ * @returns %TRUE if @object has a floating reference
1857
+ */
1858
+ is_floating(): boolean;
1859
+ /**
1860
+ * Emits a "notify" signal for the property `property_name` on `object`.
1861
+ *
1862
+ * When possible, eg. when signaling a property change from within the class
1863
+ * that registered the property, you should use g_object_notify_by_pspec()
1864
+ * instead.
1865
+ *
1866
+ * Note that emission of the notify signal may be blocked with
1867
+ * g_object_freeze_notify(). In this case, the signal emissions are queued
1868
+ * and will be emitted (in reverse order) when g_object_thaw_notify() is
1869
+ * called.
1870
+ * @param property_name the name of a property installed on the class of @object.
1871
+ */
1872
+ notify(property_name: string): void;
1873
+ /**
1874
+ * Emits a "notify" signal for the property specified by `pspec` on `object`.
1875
+ *
1876
+ * This function omits the property name lookup, hence it is faster than
1877
+ * g_object_notify().
1878
+ *
1879
+ * One way to avoid using g_object_notify() from within the
1880
+ * class that registered the properties, and using g_object_notify_by_pspec()
1881
+ * instead, is to store the GParamSpec used with
1882
+ * g_object_class_install_property() inside a static array, e.g.:
1883
+ *
1884
+ *
1885
+ * ```c
1886
+ * typedef enum
1887
+ * {
1888
+ * PROP_FOO = 1,
1889
+ * PROP_LAST
1890
+ * } MyObjectProperty;
1891
+ *
1892
+ * static GParamSpec *properties[PROP_LAST];
1893
+ *
1894
+ * static void
1895
+ * my_object_class_init (MyObjectClass *klass)
1896
+ * {
1897
+ * properties[PROP_FOO] = g_param_spec_int ("foo", NULL, NULL,
1898
+ * 0, 100,
1899
+ * 50,
1900
+ * G_PARAM_READWRITE | G_PARAM_STATIC_STRINGS);
1901
+ * g_object_class_install_property (gobject_class,
1902
+ * PROP_FOO,
1903
+ * properties[PROP_FOO]);
1904
+ * }
1905
+ * ```
1906
+ *
1907
+ *
1908
+ * and then notify a change on the "foo" property with:
1909
+ *
1910
+ *
1911
+ * ```c
1912
+ * g_object_notify_by_pspec (self, properties[PROP_FOO]);
1913
+ * ```
1914
+ *
1915
+ * @param pspec the #GParamSpec of a property installed on the class of @object.
1916
+ */
1917
+ notify_by_pspec(pspec: GObject.ParamSpec): void;
1918
+ /**
1919
+ * Increases the reference count of `object`.
1920
+ *
1921
+ * Since GLib 2.56, if `GLIB_VERSION_MAX_ALLOWED` is 2.56 or greater, the type
1922
+ * of `object` will be propagated to the return type (using the GCC typeof()
1923
+ * extension), so any casting the caller needs to do on the return type must be
1924
+ * explicit.
1925
+ * @returns the same @object
1926
+ */
1927
+ ref(): GObject.Object;
1928
+ /**
1929
+ * Increase the reference count of `object,` and possibly remove the
1930
+ * [floating][floating-ref] reference, if `object` has a floating reference.
1931
+ *
1932
+ * In other words, if the object is floating, then this call "assumes
1933
+ * ownership" of the floating reference, converting it to a normal
1934
+ * reference by clearing the floating flag while leaving the reference
1935
+ * count unchanged. If the object is not floating, then this call
1936
+ * adds a new normal reference increasing the reference count by one.
1937
+ *
1938
+ * Since GLib 2.56, the type of `object` will be propagated to the return type
1939
+ * under the same conditions as for g_object_ref().
1940
+ * @returns @object
1941
+ */
1942
+ ref_sink(): GObject.Object;
1943
+ /**
1944
+ * Releases all references to other objects. This can be used to break
1945
+ * reference cycles.
1946
+ *
1947
+ * This function should only be called from object system implementations.
1948
+ */
1949
+ run_dispose(): void;
1950
+ /**
1951
+ * Each object carries around a table of associations from
1952
+ * strings to pointers. This function lets you set an association.
1953
+ *
1954
+ * If the object already had an association with that name,
1955
+ * the old association will be destroyed.
1956
+ *
1957
+ * Internally, the `key` is converted to a #GQuark using g_quark_from_string().
1958
+ * This means a copy of `key` is kept permanently (even after `object` has been
1959
+ * finalized) — so it is recommended to only use a small, bounded set of values
1960
+ * for `key` in your program, to avoid the #GQuark storage growing unbounded.
1961
+ * @param key name of the key
1962
+ * @param data data to associate with that key
1963
+ */
1964
+ set_data(key: string, data?: any | null): void;
1965
+ set_property(property_name: string, value: any): void;
1966
+ /**
1967
+ * Remove a specified datum from the object's data associations,
1968
+ * without invoking the association's destroy handler.
1969
+ * @param key name of the key
1970
+ * @returns the data if found, or %NULL if no such data exists.
1971
+ */
1972
+ steal_data(key: string): any | null;
1973
+ /**
1974
+ * This function gets back user data pointers stored via
1975
+ * g_object_set_qdata() and removes the `data` from object
1976
+ * without invoking its destroy() function (if any was
1977
+ * set).
1978
+ * Usually, calling this function is only required to update
1979
+ * user data pointers with a destroy notifier, for example:
1980
+ *
1981
+ * ```c
1982
+ * void
1983
+ * object_add_to_user_list (GObject *object,
1984
+ * const gchar *new_string)
1985
+ * {
1986
+ * // the quark, naming the object data
1987
+ * GQuark quark_string_list = g_quark_from_static_string ("my-string-list");
1988
+ * // retrieve the old string list
1989
+ * GList *list = g_object_steal_qdata (object, quark_string_list);
1990
+ *
1991
+ * // prepend new string
1992
+ * list = g_list_prepend (list, g_strdup (new_string));
1993
+ * // this changed 'list', so we need to set it again
1994
+ * g_object_set_qdata_full (object, quark_string_list, list, free_string_list);
1995
+ * }
1996
+ * static void
1997
+ * free_string_list (gpointer data)
1998
+ * {
1999
+ * GList *node, *list = data;
2000
+ *
2001
+ * for (node = list; node; node = node->next)
2002
+ * g_free (node->data);
2003
+ * g_list_free (list);
2004
+ * }
2005
+ * ```
2006
+ *
2007
+ * Using g_object_get_qdata() in the above example, instead of
2008
+ * g_object_steal_qdata() would have left the destroy function set,
2009
+ * and thus the partial string list would have been freed upon
2010
+ * g_object_set_qdata_full().
2011
+ * @param quark A #GQuark, naming the user data pointer
2012
+ * @returns The user data pointer set, or %NULL
2013
+ */
2014
+ steal_qdata(quark: GLib.Quark): any | null;
2015
+ /**
2016
+ * Reverts the effect of a previous call to
2017
+ * g_object_freeze_notify(). The freeze count is decreased on `object`
2018
+ * and when it reaches zero, queued "notify" signals are emitted.
2019
+ *
2020
+ * Duplicate notifications for each property are squashed so that at most one
2021
+ * #GObject::notify signal is emitted for each property, in the reverse order
2022
+ * in which they have been queued.
2023
+ *
2024
+ * It is an error to call this function when the freeze count is zero.
2025
+ */
2026
+ thaw_notify(): void;
2027
+ /**
2028
+ * Decreases the reference count of `object`. When its reference count
2029
+ * drops to 0, the object is finalized (i.e. its memory is freed).
2030
+ *
2031
+ * If the pointer to the #GObject may be reused in future (for example, if it is
2032
+ * an instance variable of another object), it is recommended to clear the
2033
+ * pointer to %NULL rather than retain a dangling pointer to a potentially
2034
+ * invalid #GObject instance. Use g_clear_object() for this.
2035
+ */
2036
+ unref(): void;
2037
+ /**
2038
+ * This function essentially limits the life time of the `closure` to
2039
+ * the life time of the object. That is, when the object is finalized,
2040
+ * the `closure` is invalidated by calling g_closure_invalidate() on
2041
+ * it, in order to prevent invocations of the closure with a finalized
2042
+ * (nonexisting) object. Also, g_object_ref() and g_object_unref() are
2043
+ * added as marshal guards to the `closure,` to ensure that an extra
2044
+ * reference count is held on `object` during invocation of the
2045
+ * `closure`. Usually, this function will be called on closures that
2046
+ * use this `object` as closure data.
2047
+ * @param closure #GClosure to watch
2048
+ */
2049
+ watch_closure(closure: GObject.Closure): void;
2050
+ /**
2051
+ * the `constructed` function is called by g_object_new() as the
2052
+ * final step of the object creation process. At the point of the call, all
2053
+ * construction properties have been set on the object. The purpose of this
2054
+ * call is to allow for object initialisation steps that can only be performed
2055
+ * after construction properties have been set. `constructed` implementors
2056
+ * should chain up to the `constructed` call of their parent class to allow it
2057
+ * to complete its initialisation.
2058
+ */
2059
+ vfunc_constructed(): void;
2060
+ /**
2061
+ * emits property change notification for a bunch
2062
+ * of properties. Overriding `dispatch_properties_changed` should be rarely
2063
+ * needed.
2064
+ * @param n_pspecs
2065
+ * @param pspecs
2066
+ */
2067
+ vfunc_dispatch_properties_changed(n_pspecs: number, pspecs: GObject.ParamSpec): void;
2068
+ /**
2069
+ * the `dispose` function is supposed to drop all references to other
2070
+ * objects, but keep the instance otherwise intact, so that client method
2071
+ * invocations still work. It may be run multiple times (due to reference
2072
+ * loops). Before returning, `dispose` should chain up to the `dispose` method
2073
+ * of the parent class.
2074
+ */
2075
+ vfunc_dispose(): void;
2076
+ /**
2077
+ * instance finalization function, should finish the finalization of
2078
+ * the instance begun in `dispose` and chain up to the `finalize` method of the
2079
+ * parent class.
2080
+ */
2081
+ vfunc_finalize(): void;
2082
+ /**
2083
+ * the generic getter for all properties of this type. Should be
2084
+ * overridden for every type with properties.
2085
+ * @param property_id
2086
+ * @param value
2087
+ * @param pspec
2088
+ */
2089
+ vfunc_get_property(property_id: number, value: GObject.Value | any, pspec: GObject.ParamSpec): void;
2090
+ /**
2091
+ * Emits a "notify" signal for the property `property_name` on `object`.
2092
+ *
2093
+ * When possible, eg. when signaling a property change from within the class
2094
+ * that registered the property, you should use g_object_notify_by_pspec()
2095
+ * instead.
2096
+ *
2097
+ * Note that emission of the notify signal may be blocked with
2098
+ * g_object_freeze_notify(). In this case, the signal emissions are queued
2099
+ * and will be emitted (in reverse order) when g_object_thaw_notify() is
2100
+ * called.
2101
+ * @param pspec
2102
+ */
2103
+ vfunc_notify(pspec: GObject.ParamSpec): void;
2104
+ /**
2105
+ * the generic setter for all properties of this type. Should be
2106
+ * overridden for every type with properties. If implementations of
2107
+ * `set_property` don't emit property change notification explicitly, this will
2108
+ * be done implicitly by the type system. However, if the notify signal is
2109
+ * emitted explicitly, the type system will not emit it a second time.
2110
+ * @param property_id
2111
+ * @param value
2112
+ * @param pspec
2113
+ */
2114
+ vfunc_set_property(property_id: number, value: GObject.Value | any, pspec: GObject.ParamSpec): void;
2115
+ disconnect(id: number): void;
2116
+ set(properties: { [key: string]: any }): void;
2117
+ block_signal_handler(id: number): any;
2118
+ unblock_signal_handler(id: number): any;
2119
+ stop_emission_by_name(detailedName: string): any;
2120
+ }
2121
+
2122
+ module Service {
2123
+ // Constructor properties interface
2124
+
2125
+ interface ConstructorProps extends GObject.Object.ConstructorProps {
2126
+ authorizer: Authorizer;
2127
+ }
2128
+ }
2129
+
2130
+ class Service extends GObject.Object {
2131
+ static $gtype: GObject.GType<Service>;
2132
+
2133
+ // Properties
2134
+
2135
+ set authorizer(val: Authorizer);
2136
+
2137
+ // Constructors
2138
+
2139
+ constructor(properties?: Partial<Service.ConstructorProps>, ...args: any[]);
2140
+
2141
+ _init(...args: any[]): void;
2142
+
2143
+ // Static methods
2144
+
2145
+ static accept_certificate_cb(
2146
+ msg: Soup.Message,
2147
+ tls_cert: Gio.TlsCertificate,
2148
+ tls_errors: Gio.TlsCertificateFlags,
2149
+ session?: any | null,
2150
+ ): boolean;
2151
+ static get_https_port(): number;
2152
+ /**
2153
+ * Get next link
2154
+ * @param object a #JsonObject
2155
+ */
2156
+ static get_next_link(object: Json.Object): string;
2157
+ /**
2158
+ * Parse response data and check for errors. In case
2159
+ * no errors are found, return json root object.
2160
+ * @param bytes input bytes containing response buffer
2161
+ * @param object a pointer to the returning root object
2162
+ */
2163
+ static parse_response(bytes: GLib.Bytes | Uint8Array, object: Json.Object): Json.Parser;
2164
+
2165
+ // Methods
2166
+
2167
+ /**
2168
+ * Construct and checks a #SoupMessage for transfer
2169
+ * @param method transfer method
2170
+ * @param uri uri to access
2171
+ * @param etag an optional etag
2172
+ * @param etag_if_match use etag if
2173
+ * @returns a #SoupMessage or NULL on error.
2174
+ */
2175
+ build_message(method: string, uri: string, etag: string, etag_if_match: boolean): Soup.Message;
2176
+ /**
2177
+ * Get related authorizer.
2178
+ * @returns a #MsgAuthorizer
2179
+ */
2180
+ get_authorizer(): Authorizer;
2181
+ /**
2182
+ * Get related soup session
2183
+ * @returns a #SoupSession
2184
+ */
2185
+ get_session(): Soup.Session;
2186
+ refresh_authorization(cancellable?: Gio.Cancellable | null): boolean;
2187
+ /**
2188
+ * Adds authorizer information to `message` and send it.
2189
+ * @param message a #SoupMessage
2190
+ * @param cancellable a #GCancellable
2191
+ * @returns a #GInputStream
2192
+ */
2193
+ send(message: Soup.Message, cancellable?: Gio.Cancellable | null): Gio.InputStream;
2194
+ /**
2195
+ * A combination of `msg_service_send_and_read` and `msg_service_parse_response`
2196
+ * @param message a #SoupMessage
2197
+ * @param object
2198
+ * @param cancellable a #GCancellable
2199
+ * @returns a #JsonParser or %NULL on error
2200
+ */
2201
+ send_and_parse_response(
2202
+ message: Soup.Message,
2203
+ object: Json.Object,
2204
+ cancellable?: Gio.Cancellable | null,
2205
+ ): Json.Parser;
2206
+ /**
2207
+ * Adds authorizer information to `message` and send it.
2208
+ * @param message a #SoupMessage
2209
+ * @param cancellable a #GCancellable
2210
+ * @returns a #GBytes or %NULL on error.
2211
+ */
2212
+ send_and_read(message: Soup.Message, cancellable?: Gio.Cancellable | null): GLib.Bytes;
2213
+ }
2214
+
2215
+ module User {
2216
+ // Constructor properties interface
2217
+
2218
+ interface ConstructorProps extends GObject.Object.ConstructorProps {}
2219
+ }
2220
+
2221
+ /**
2222
+ * Handling of user specific functions.
2223
+ */
2224
+ class User extends GObject.Object {
2225
+ static $gtype: GObject.GType<User>;
2226
+
2227
+ // Constructors
2228
+
2229
+ constructor(properties?: Partial<User.ConstructorProps>, ...args: any[]);
2230
+
2231
+ _init(...args: any[]): void;
2232
+
2233
+ static ['new'](): User;
2234
+
2235
+ static new_from_json(json_object: Json.Object): User;
2236
+
2237
+ // Methods
2238
+
2239
+ get_mail(): string;
2240
+ }
2241
+
2242
+ module UserService {
2243
+ // Constructor properties interface
2244
+
2245
+ interface ConstructorProps extends Service.ConstructorProps {}
2246
+ }
2247
+
2248
+ class UserService extends Service {
2249
+ static $gtype: GObject.GType<UserService>;
2250
+
2251
+ // Constructors
2252
+
2253
+ constructor(properties?: Partial<UserService.ConstructorProps>, ...args: any[]);
2254
+
2255
+ _init(...args: any[]): void;
2256
+
2257
+ static ['new'](authorizer: Authorizer): UserService;
2258
+
2259
+ // Methods
2260
+
2261
+ /**
2262
+ * Get user information
2263
+ * @param name user name (%NULL for me)
2264
+ * @param cancellable a #GCancellable
2265
+ * @returns request user
2266
+ */
2267
+ get_user(name: string, cancellable?: Gio.Cancellable | null): User;
2268
+ }
2269
+
2270
+ type AuthorizerInterface = typeof Authorizer;
2271
+ type ContactClass = typeof Contact;
2272
+ type ContactServiceClass = typeof ContactService;
2273
+ type DriveClass = typeof Drive;
2274
+ type DriveItemClass = typeof DriveItem;
2275
+ type DriveItemFileClass = typeof DriveItemFile;
2276
+ type DriveItemFolderClass = typeof DriveItemFolder;
2277
+ type DriveServiceClass = typeof DriveService;
2278
+ type GoaAuthorizerClass = typeof GoaAuthorizer;
2279
+ abstract class GoaAuthorizerPrivate {
2280
+ static $gtype: GObject.GType<GoaAuthorizerPrivate>;
2281
+
2282
+ // Constructors
2283
+
2284
+ _init(...args: any[]): void;
2285
+ }
2286
+
2287
+ type InputStreamClass = typeof InputStream;
2288
+ abstract class InputStreamPrivate {
2289
+ static $gtype: GObject.GType<InputStreamPrivate>;
2290
+
2291
+ // Constructors
2292
+
2293
+ _init(...args: any[]): void;
2294
+ }
2295
+
2296
+ type MailFolderClass = typeof MailFolder;
2297
+ type MessageClass = typeof Message;
2298
+ type MessageServiceClass = typeof MessageService;
2299
+ type OAuth2AuthorizerClass = typeof OAuth2Authorizer;
2300
+ abstract class OAuth2AuthorizerPrivate {
2301
+ static $gtype: GObject.GType<OAuth2AuthorizerPrivate>;
2302
+
2303
+ // Constructors
2304
+
2305
+ _init(...args: any[]): void;
2306
+ }
2307
+
2308
+ type ServiceClass = typeof Service;
2309
+ type UserClass = typeof User;
2310
+ type UserServiceClass = typeof UserService;
2311
+ abstract class _DriveItemFileClass {
2312
+ static $gtype: GObject.GType<_DriveItemFileClass>;
2313
+
2314
+ // Fields
2315
+
2316
+ padding: any[];
2317
+
2318
+ // Constructors
2319
+
2320
+ _init(...args: any[]): void;
2321
+ }
2322
+
2323
+ abstract class _DriveItemFolderClass {
2324
+ static $gtype: GObject.GType<_DriveItemFolderClass>;
2325
+
2326
+ // Fields
2327
+
2328
+ padding: any[];
2329
+
2330
+ // Constructors
2331
+
2332
+ _init(...args: any[]): void;
2333
+ }
2334
+
2335
+ module Authorizer {
2336
+ // Constructor properties interface
2337
+
2338
+ interface ConstructorProps extends GObject.Object.ConstructorProps {}
2339
+ }
2340
+
2341
+ export interface AuthorizerNamespace {
2342
+ $gtype: GObject.GType<Authorizer>;
2343
+ prototype: Authorizer;
2344
+ }
2345
+ interface Authorizer extends GObject.Object {
2346
+ // Methods
2347
+
2348
+ /**
2349
+ * Adds the necessary authorization to `message`. The type of `message`
2350
+ * can be DELETE, GET and POST.
2351
+ *
2352
+ * This method modifies `message` in place and is thread safe.
2353
+ * @param message A #SoupMessage.
2354
+ */
2355
+ process_request(message: Soup.Message): void;
2356
+ /**
2357
+ * Synchronously forces `iface` to refresh any authorization tokens
2358
+ * held by it. See msg_authorizer_refresh_authorization_async() for the
2359
+ * asynchronous version of this call.
2360
+ *
2361
+ * This method is thread safe.
2362
+ * @param cancellable An optional #GCancellable object, or %NULL.
2363
+ * @returns %TRUE if the authorizer now has a valid token.
2364
+ */
2365
+ refresh_authorization(cancellable?: Gio.Cancellable | null): boolean;
2366
+
2367
+ // Virtual methods
2368
+
2369
+ /**
2370
+ * Adds the necessary authorization to `message`. The type of `message`
2371
+ * can be DELETE, GET and POST.
2372
+ *
2373
+ * This method modifies `message` in place and is thread safe.
2374
+ * @param message A #SoupMessage.
2375
+ */
2376
+ vfunc_process_request(message: Soup.Message): void;
2377
+ /**
2378
+ * Synchronously forces `iface` to refresh any authorization tokens
2379
+ * held by it. See msg_authorizer_refresh_authorization_async() for the
2380
+ * asynchronous version of this call.
2381
+ *
2382
+ * This method is thread safe.
2383
+ * @param cancellable An optional #GCancellable object, or %NULL.
2384
+ */
2385
+ vfunc_refresh_authorization(cancellable?: Gio.Cancellable | null): boolean;
2386
+ }
2387
+
2388
+ export const Authorizer: AuthorizerNamespace;
2389
+
2390
+ /**
2391
+ * Name of the imported GIR library
2392
+ * `see` https://gitlab.gnome.org/GNOME/gjs/-/blob/master/gi/ns.cpp#L188
2393
+ */
2394
+ const __name__: string;
2395
+ /**
2396
+ * Version of the imported GIR library
2397
+ * `see` https://gitlab.gnome.org/GNOME/gjs/-/blob/master/gi/ns.cpp#L189
2398
+ */
2399
+ const __version__: string;
2400
+ }
2401
+
2402
+ export default Msg;
2403
+
2404
+ // END