1 | /* GIO - GLib Input, Output and Streaming Library |
2 | * |
3 | * Copyright (C) 2006-2007 Red Hat, Inc. |
4 | * |
5 | * This library is free software; you can redistribute it and/or |
6 | * modify it under the terms of the GNU Lesser General Public |
7 | * License as published by the Free Software Foundation; either |
8 | * version 2.1 of the License, or (at your option) any later version. |
9 | * |
10 | * This library is distributed in the hope that it will be useful, |
11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of |
12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU |
13 | * Lesser General Public License for more details. |
14 | * |
15 | * You should have received a copy of the GNU Lesser General |
16 | * Public License along with this library; if not, see <http://www.gnu.org/licenses/>. |
17 | * |
18 | * Author: Alexander Larsson <alexl@redhat.com> |
19 | */ |
20 | |
21 | #ifndef __GIO_TYPES_H__ |
22 | #define __GIO_TYPES_H__ |
23 | |
24 | #if !defined (__GIO_GIO_H_INSIDE__) && !defined (GIO_COMPILATION) |
25 | #error "Only <gio/gio.h> can be included directly." |
26 | #endif |
27 | |
28 | #include <gio/gioenums.h> |
29 | |
30 | G_BEGIN_DECLS |
31 | |
32 | typedef struct _GAppLaunchContext GAppLaunchContext; |
33 | typedef struct _GAppInfo GAppInfo; /* Dummy typedef */ |
34 | typedef struct _GAsyncResult GAsyncResult; /* Dummy typedef */ |
35 | typedef struct _GAsyncInitable GAsyncInitable; |
36 | typedef struct _GBufferedInputStream GBufferedInputStream; |
37 | typedef struct _GBufferedOutputStream GBufferedOutputStream; |
38 | typedef struct _GCancellable GCancellable; |
39 | typedef struct _GCharsetConverter GCharsetConverter; |
40 | typedef struct _GConverter GConverter; |
41 | typedef struct _GConverterInputStream GConverterInputStream; |
42 | typedef struct _GConverterOutputStream GConverterOutputStream; |
43 | typedef struct _GDatagramBased GDatagramBased; |
44 | typedef struct _GDataInputStream GDataInputStream; |
45 | typedef struct _GSimplePermission GSimplePermission; |
46 | typedef struct _GZlibCompressor GZlibCompressor; |
47 | typedef struct _GZlibDecompressor GZlibDecompressor; |
48 | |
49 | typedef struct _GSimpleActionGroup GSimpleActionGroup; |
50 | typedef struct _GRemoteActionGroup GRemoteActionGroup; |
51 | typedef struct _GDBusActionGroup GDBusActionGroup; |
52 | typedef struct _GActionMap GActionMap; |
53 | typedef struct _GActionGroup GActionGroup; |
54 | typedef struct _GPropertyAction GPropertyAction; |
55 | typedef struct _GSimpleAction GSimpleAction; |
56 | typedef struct _GAction GAction; |
57 | typedef struct _GApplication GApplication; |
58 | typedef struct _GApplicationCommandLine GApplicationCommandLine; |
59 | typedef struct _GSettingsBackend GSettingsBackend; |
60 | typedef struct _GSettings GSettings; |
61 | typedef struct _GPermission GPermission; |
62 | |
63 | typedef struct _GMenuModel ; |
64 | typedef struct _GNotification GNotification; |
65 | |
66 | /** |
67 | * GDrive: |
68 | * |
69 | * Opaque drive object. |
70 | **/ |
71 | typedef struct _GDrive GDrive; /* Dummy typedef */ |
72 | typedef struct _GFileEnumerator GFileEnumerator; |
73 | typedef struct _GFileMonitor GFileMonitor; |
74 | typedef struct _GFilterInputStream GFilterInputStream; |
75 | typedef struct _GFilterOutputStream GFilterOutputStream; |
76 | |
77 | /** |
78 | * GFile: |
79 | * |
80 | * A handle to an object implementing the #GFileIface interface. |
81 | * Generally stores a location within the file system. Handles do not |
82 | * necessarily represent files or directories that currently exist. |
83 | **/ |
84 | typedef struct _GFile GFile; /* Dummy typedef */ |
85 | typedef struct _GFileInfo GFileInfo; |
86 | |
87 | /** |
88 | * GFileAttributeMatcher: |
89 | * |
90 | * Determines if a string matches a file attribute. |
91 | **/ |
92 | typedef struct _GFileAttributeMatcher GFileAttributeMatcher; |
93 | typedef struct _GFileAttributeInfo GFileAttributeInfo; |
94 | typedef struct _GFileAttributeInfoList GFileAttributeInfoList; |
95 | typedef struct _GFileDescriptorBased GFileDescriptorBased; |
96 | typedef struct _GFileInputStream GFileInputStream; |
97 | typedef struct _GFileOutputStream GFileOutputStream; |
98 | typedef struct _GFileIOStream GFileIOStream; |
99 | typedef struct _GFileIcon GFileIcon; |
100 | typedef struct _GFilenameCompleter GFilenameCompleter; |
101 | |
102 | |
103 | typedef struct _GIcon GIcon; /* Dummy typedef */ |
104 | typedef struct _GInetAddress GInetAddress; |
105 | typedef struct _GInetAddressMask GInetAddressMask; |
106 | typedef struct _GInetSocketAddress GInetSocketAddress; |
107 | typedef struct _GNativeSocketAddress GNativeSocketAddress; |
108 | typedef struct _GInputStream GInputStream; |
109 | typedef struct _GInitable GInitable; |
110 | typedef struct _GIOModule GIOModule; |
111 | typedef struct _GIOExtensionPoint GIOExtensionPoint; |
112 | typedef struct _GIOExtension GIOExtension; |
113 | |
114 | /** |
115 | * GIOSchedulerJob: |
116 | * |
117 | * Opaque class for defining and scheduling IO jobs. |
118 | **/ |
119 | typedef struct _GIOSchedulerJob GIOSchedulerJob; |
120 | typedef struct _GIOStreamAdapter GIOStreamAdapter; |
121 | typedef struct _GLoadableIcon GLoadableIcon; /* Dummy typedef */ |
122 | typedef struct _GBytesIcon GBytesIcon; |
123 | typedef struct _GMemoryInputStream GMemoryInputStream; |
124 | typedef struct _GMemoryOutputStream GMemoryOutputStream; |
125 | |
126 | /** |
127 | * GMount: |
128 | * |
129 | * A handle to an object implementing the #GMountIface interface. |
130 | **/ |
131 | typedef struct _GMount GMount; /* Dummy typedef */ |
132 | typedef struct _GMountOperation GMountOperation; |
133 | typedef struct _GNetworkAddress GNetworkAddress; |
134 | typedef struct _GNetworkMonitor GNetworkMonitor; |
135 | typedef struct _GNetworkService GNetworkService; |
136 | typedef struct _GOutputStream GOutputStream; |
137 | typedef struct _GIOStream GIOStream; |
138 | typedef struct _GSimpleIOStream GSimpleIOStream; |
139 | typedef struct _GPollableInputStream GPollableInputStream; /* Dummy typedef */ |
140 | typedef struct _GPollableOutputStream GPollableOutputStream; /* Dummy typedef */ |
141 | typedef struct _GResolver GResolver; |
142 | |
143 | /** |
144 | * GResource: |
145 | * |
146 | * A resource bundle. |
147 | * |
148 | * Since: 2.32 |
149 | */ |
150 | typedef struct _GResource GResource; |
151 | typedef struct _GSeekable GSeekable; |
152 | typedef struct _GSimpleAsyncResult GSimpleAsyncResult; |
153 | |
154 | /** |
155 | * GSocket: |
156 | * |
157 | * A lowlevel network socket object. |
158 | * |
159 | * Since: 2.22 |
160 | **/ |
161 | typedef struct _GSocket GSocket; |
162 | |
163 | /** |
164 | * GSocketControlMessage: |
165 | * |
166 | * Base class for socket-type specific control messages that can be sent and |
167 | * received over #GSocket. |
168 | **/ |
169 | typedef struct _GSocketControlMessage GSocketControlMessage; |
170 | /** |
171 | * GSocketClient: |
172 | * |
173 | * A helper class for network clients to make connections. |
174 | * |
175 | * Since: 2.22 |
176 | **/ |
177 | typedef struct _GSocketClient GSocketClient; |
178 | /** |
179 | * GSocketConnection: |
180 | * |
181 | * A socket connection GIOStream object for connection-oriented sockets. |
182 | * |
183 | * Since: 2.22 |
184 | **/ |
185 | typedef struct _GSocketConnection GSocketConnection; |
186 | /** |
187 | * GSocketListener: |
188 | * |
189 | * A helper class for network servers to listen for and accept connections. |
190 | * |
191 | * Since: 2.22 |
192 | **/ |
193 | typedef struct _GSocketListener GSocketListener; |
194 | /** |
195 | * GSocketService: |
196 | * |
197 | * A helper class for handling accepting incoming connections in the |
198 | * glib mainloop. |
199 | * |
200 | * Since: 2.22 |
201 | **/ |
202 | typedef struct _GSocketService GSocketService; |
203 | typedef struct _GSocketAddress GSocketAddress; |
204 | typedef struct _GSocketAddressEnumerator GSocketAddressEnumerator; |
205 | typedef struct _GSocketConnectable GSocketConnectable; |
206 | typedef struct _GSrvTarget GSrvTarget; |
207 | typedef struct _GTask GTask; |
208 | /** |
209 | * GTcpConnection: |
210 | * |
211 | * A #GSocketConnection for TCP/IP connections. |
212 | * |
213 | * Since: 2.22 |
214 | **/ |
215 | typedef struct _GTcpConnection GTcpConnection; |
216 | typedef struct _GTcpWrapperConnection GTcpWrapperConnection; |
217 | /** |
218 | * GThreadedSocketService: |
219 | * |
220 | * A helper class for handling accepting incoming connections in the |
221 | * glib mainloop and handling them in a thread. |
222 | * |
223 | * Since: 2.22 |
224 | **/ |
225 | typedef struct _GThreadedSocketService GThreadedSocketService; |
226 | typedef struct _GDtlsConnection GDtlsConnection; |
227 | typedef struct _GDtlsClientConnection GDtlsClientConnection; /* Dummy typedef */ |
228 | typedef struct _GDtlsServerConnection GDtlsServerConnection; /* Dummy typedef */ |
229 | typedef struct _GThemedIcon GThemedIcon; |
230 | typedef struct _GTlsCertificate GTlsCertificate; |
231 | typedef struct _GTlsClientConnection GTlsClientConnection; /* Dummy typedef */ |
232 | typedef struct _GTlsConnection GTlsConnection; |
233 | typedef struct _GTlsDatabase GTlsDatabase; |
234 | typedef struct _GTlsFileDatabase GTlsFileDatabase; |
235 | typedef struct _GTlsInteraction GTlsInteraction; |
236 | typedef struct _GTlsPassword GTlsPassword; |
237 | typedef struct _GTlsServerConnection GTlsServerConnection; /* Dummy typedef */ |
238 | typedef struct _GVfs GVfs; /* Dummy typedef */ |
239 | |
240 | /** |
241 | * GProxyResolver: |
242 | * |
243 | * A helper class to enumerate proxies base on URI. |
244 | * |
245 | * Since: 2.26 |
246 | **/ |
247 | typedef struct _GProxyResolver GProxyResolver; |
248 | typedef struct _GProxy GProxy; |
249 | typedef struct _GProxyAddress GProxyAddress; |
250 | typedef struct _GProxyAddressEnumerator GProxyAddressEnumerator; |
251 | |
252 | /** |
253 | * GVolume: |
254 | * |
255 | * Opaque mountable volume object. |
256 | **/ |
257 | typedef struct _GVolume GVolume; /* Dummy typedef */ |
258 | typedef struct _GVolumeMonitor GVolumeMonitor; |
259 | |
260 | /** |
261 | * GAsyncReadyCallback: |
262 | * @source_object: (nullable): the object the asynchronous operation was started with. |
263 | * @res: a #GAsyncResult. |
264 | * @user_data: user data passed to the callback. |
265 | * |
266 | * Type definition for a function that will be called back when an asynchronous |
267 | * operation within GIO has been completed. #GAsyncReadyCallback |
268 | * callbacks from #GTask are guaranteed to be invoked in a later |
269 | * iteration of the |
270 | * [thread-default main context][g-main-context-push-thread-default] |
271 | * where the #GTask was created. All other users of |
272 | * #GAsyncReadyCallback must likewise call it asynchronously in a |
273 | * later iteration of the main context. |
274 | * |
275 | * The asynchronous operation is guaranteed to have held a reference to |
276 | * @source_object from the time when the `*_async()` function was called, until |
277 | * after this callback returns. |
278 | **/ |
279 | typedef void (*GAsyncReadyCallback) (GObject *source_object, |
280 | GAsyncResult *res, |
281 | gpointer user_data); |
282 | |
283 | /** |
284 | * GFileProgressCallback: |
285 | * @current_num_bytes: the current number of bytes in the operation. |
286 | * @total_num_bytes: the total number of bytes in the operation. |
287 | * @user_data: user data passed to the callback. |
288 | * |
289 | * When doing file operations that may take a while, such as moving |
290 | * a file or copying a file, a progress callback is used to pass how |
291 | * far along that operation is to the application. |
292 | **/ |
293 | typedef void (*GFileProgressCallback) (goffset current_num_bytes, |
294 | goffset total_num_bytes, |
295 | gpointer user_data); |
296 | |
297 | /** |
298 | * GFileReadMoreCallback: |
299 | * @file_contents: the data as currently read. |
300 | * @file_size: the size of the data currently read. |
301 | * @callback_data: (closure): data passed to the callback. |
302 | * |
303 | * When loading the partial contents of a file with g_file_load_partial_contents_async(), |
304 | * it may become necessary to determine if any more data from the file should be loaded. |
305 | * A #GFileReadMoreCallback function facilitates this by returning %TRUE if more data |
306 | * should be read, or %FALSE otherwise. |
307 | * |
308 | * Returns: %TRUE if more data should be read back. %FALSE otherwise. |
309 | **/ |
310 | typedef gboolean (* GFileReadMoreCallback) (const char *file_contents, |
311 | goffset file_size, |
312 | gpointer callback_data); |
313 | |
314 | /** |
315 | * GFileMeasureProgressCallback: |
316 | * @reporting: %TRUE if more reports will come |
317 | * @current_size: the current cumulative size measurement |
318 | * @num_dirs: the number of directories visited so far |
319 | * @num_files: the number of non-directory files encountered |
320 | * @user_data: the data passed to the original request for this callback |
321 | * |
322 | * This callback type is used by g_file_measure_disk_usage() to make |
323 | * periodic progress reports when measuring the amount of disk spaced |
324 | * used by a directory. |
325 | * |
326 | * These calls are made on a best-effort basis and not all types of |
327 | * #GFile will support them. At the minimum, however, one call will |
328 | * always be made immediately. |
329 | * |
330 | * In the case that there is no support, @reporting will be set to |
331 | * %FALSE (and the other values undefined) and no further calls will be |
332 | * made. Otherwise, the @reporting will be %TRUE and the other values |
333 | * all-zeros during the first (immediate) call. In this way, you can |
334 | * know which type of progress UI to show without a delay. |
335 | * |
336 | * For g_file_measure_disk_usage() the callback is made directly. For |
337 | * g_file_measure_disk_usage_async() the callback is made via the |
338 | * default main context of the calling thread (ie: the same way that the |
339 | * final async result would be reported). |
340 | * |
341 | * @current_size is in the same units as requested by the operation (see |
342 | * %G_FILE_MEASURE_APPARENT_SIZE). |
343 | * |
344 | * The frequency of the updates is implementation defined, but is |
345 | * ideally about once every 200ms. |
346 | * |
347 | * The last progress callback may or may not be equal to the final |
348 | * result. Always check the async result to get the final value. |
349 | * |
350 | * Since: 2.38 |
351 | **/ |
352 | typedef void (* GFileMeasureProgressCallback) (gboolean reporting, |
353 | guint64 current_size, |
354 | guint64 num_dirs, |
355 | guint64 num_files, |
356 | gpointer user_data); |
357 | |
358 | /** |
359 | * GIOSchedulerJobFunc: |
360 | * @job: a #GIOSchedulerJob. |
361 | * @cancellable: optional #GCancellable object, %NULL to ignore. |
362 | * @user_data: the data to pass to callback function |
363 | * |
364 | * I/O Job function. |
365 | * |
366 | * Long-running jobs should periodically check the @cancellable |
367 | * to see if they have been cancelled. |
368 | * |
369 | * Returns: %TRUE if this function should be called again to |
370 | * complete the job, %FALSE if the job is complete (or cancelled) |
371 | **/ |
372 | typedef gboolean (*GIOSchedulerJobFunc) (GIOSchedulerJob *job, |
373 | GCancellable *cancellable, |
374 | gpointer user_data); |
375 | |
376 | /** |
377 | * GSimpleAsyncThreadFunc: |
378 | * @res: a #GSimpleAsyncResult. |
379 | * @object: a #GObject. |
380 | * @cancellable: optional #GCancellable object, %NULL to ignore. |
381 | * |
382 | * Simple thread function that runs an asynchronous operation and |
383 | * checks for cancellation. |
384 | **/ |
385 | typedef void (*GSimpleAsyncThreadFunc) (GSimpleAsyncResult *res, |
386 | GObject *object, |
387 | GCancellable *cancellable); |
388 | |
389 | /** |
390 | * GSocketSourceFunc: |
391 | * @socket: the #GSocket |
392 | * @condition: the current condition at the source fired. |
393 | * @user_data: data passed in by the user. |
394 | * |
395 | * This is the function type of the callback used for the #GSource |
396 | * returned by g_socket_create_source(). |
397 | * |
398 | * Returns: it should return %FALSE if the source should be removed. |
399 | * |
400 | * Since: 2.22 |
401 | */ |
402 | typedef gboolean (*GSocketSourceFunc) (GSocket *socket, |
403 | GIOCondition condition, |
404 | gpointer user_data); |
405 | |
406 | /** |
407 | * GDatagramBasedSourceFunc: |
408 | * @datagram_based: the #GDatagramBased |
409 | * @condition: the current condition at the source fired |
410 | * @user_data: data passed in by the user |
411 | * |
412 | * This is the function type of the callback used for the #GSource |
413 | * returned by g_datagram_based_create_source(). |
414 | * |
415 | * Returns: %G_SOURCE_REMOVE if the source should be removed, |
416 | * %G_SOURCE_CONTINUE otherwise |
417 | * |
418 | * Since: 2.48 |
419 | */ |
420 | typedef gboolean (*GDatagramBasedSourceFunc) (GDatagramBased *datagram_based, |
421 | GIOCondition condition, |
422 | gpointer user_data); |
423 | |
424 | /** |
425 | * GInputVector: |
426 | * @buffer: Pointer to a buffer where data will be written. |
427 | * @size: the available size in @buffer. |
428 | * |
429 | * Structure used for scatter/gather data input. |
430 | * You generally pass in an array of #GInputVectors |
431 | * and the operation will store the read data starting in the |
432 | * first buffer, switching to the next as needed. |
433 | * |
434 | * Since: 2.22 |
435 | */ |
436 | typedef struct _GInputVector GInputVector; |
437 | |
438 | struct _GInputVector { |
439 | gpointer buffer; |
440 | gsize size; |
441 | }; |
442 | |
443 | /** |
444 | * GInputMessage: |
445 | * @address: (optional) (out) (transfer full): return location |
446 | * for a #GSocketAddress, or %NULL |
447 | * @vectors: (array length=num_vectors) (out): pointer to an |
448 | * array of input vectors |
449 | * @num_vectors: the number of input vectors pointed to by @vectors |
450 | * @bytes_received: (out): will be set to the number of bytes that have been |
451 | * received |
452 | * @flags: (out): collection of #GSocketMsgFlags for the received message, |
453 | * outputted by the call |
454 | * @control_messages: (array length=num_control_messages) (optional) |
455 | * (out) (transfer full): return location for a |
456 | * caller-allocated array of #GSocketControlMessages, or %NULL |
457 | * @num_control_messages: (out) (optional): return location for the number of |
458 | * elements in @control_messages |
459 | * |
460 | * Structure used for scatter/gather data input when receiving multiple |
461 | * messages or packets in one go. You generally pass in an array of empty |
462 | * #GInputVectors and the operation will use all the buffers as if they |
463 | * were one buffer, and will set @bytes_received to the total number of bytes |
464 | * received across all #GInputVectors. |
465 | * |
466 | * This structure closely mirrors `struct mmsghdr` and `struct msghdr` from |
467 | * the POSIX sockets API (see `man 2 recvmmsg`). |
468 | * |
469 | * If @address is non-%NULL then it is set to the source address the message |
470 | * was received from, and the caller must free it afterwards. |
471 | * |
472 | * If @control_messages is non-%NULL then it is set to an array of control |
473 | * messages received with the message (if any), and the caller must free it |
474 | * afterwards. @num_control_messages is set to the number of elements in |
475 | * this array, which may be zero. |
476 | * |
477 | * Flags relevant to this message will be returned in @flags. For example, |
478 | * `MSG_EOR` or `MSG_TRUNC`. |
479 | * |
480 | * Since: 2.48 |
481 | */ |
482 | typedef struct _GInputMessage GInputMessage; |
483 | |
484 | struct _GInputMessage { |
485 | GSocketAddress **address; |
486 | |
487 | GInputVector *vectors; |
488 | guint num_vectors; |
489 | |
490 | gsize bytes_received; |
491 | gint flags; |
492 | |
493 | GSocketControlMessage ***control_messages; |
494 | guint *num_control_messages; |
495 | }; |
496 | |
497 | /** |
498 | * GOutputVector: |
499 | * @buffer: Pointer to a buffer of data to read. |
500 | * @size: the size of @buffer. |
501 | * |
502 | * Structure used for scatter/gather data output. |
503 | * You generally pass in an array of #GOutputVectors |
504 | * and the operation will use all the buffers as if they were |
505 | * one buffer. |
506 | * |
507 | * Since: 2.22 |
508 | */ |
509 | typedef struct _GOutputVector GOutputVector; |
510 | |
511 | struct _GOutputVector { |
512 | gconstpointer buffer; |
513 | gsize size; |
514 | }; |
515 | |
516 | /** |
517 | * GOutputMessage: |
518 | * @address: (nullable): a #GSocketAddress, or %NULL |
519 | * @vectors: pointer to an array of output vectors |
520 | * @num_vectors: the number of output vectors pointed to by @vectors. |
521 | * @bytes_sent: initialize to 0. Will be set to the number of bytes |
522 | * that have been sent |
523 | * @control_messages: (array length=num_control_messages) (nullable): a pointer |
524 | * to an array of #GSocketControlMessages, or %NULL. |
525 | * @num_control_messages: number of elements in @control_messages. |
526 | * |
527 | * Structure used for scatter/gather data output when sending multiple |
528 | * messages or packets in one go. You generally pass in an array of |
529 | * #GOutputVectors and the operation will use all the buffers as if they |
530 | * were one buffer. |
531 | * |
532 | * If @address is %NULL then the message is sent to the default receiver |
533 | * (as previously set by g_socket_connect()). |
534 | * |
535 | * Since: 2.44 |
536 | */ |
537 | typedef struct _GOutputMessage GOutputMessage; |
538 | |
539 | struct _GOutputMessage { |
540 | GSocketAddress *address; |
541 | |
542 | GOutputVector *vectors; |
543 | guint num_vectors; |
544 | |
545 | guint bytes_sent; |
546 | |
547 | GSocketControlMessage **control_messages; |
548 | guint num_control_messages; |
549 | }; |
550 | |
551 | typedef struct _GCredentials GCredentials; |
552 | typedef struct _GUnixCredentialsMessage GUnixCredentialsMessage; |
553 | typedef struct _GUnixFDList GUnixFDList; |
554 | typedef struct _GDBusMessage GDBusMessage; |
555 | typedef struct _GDBusConnection GDBusConnection; |
556 | typedef struct _GDBusProxy GDBusProxy; |
557 | typedef struct _GDBusMethodInvocation GDBusMethodInvocation; |
558 | typedef struct _GDBusServer GDBusServer; |
559 | typedef struct _GDBusAuthObserver GDBusAuthObserver; |
560 | typedef struct _GDBusErrorEntry GDBusErrorEntry; |
561 | typedef struct _GDBusInterfaceVTable GDBusInterfaceVTable; |
562 | typedef struct _GDBusSubtreeVTable GDBusSubtreeVTable; |
563 | typedef struct _GDBusAnnotationInfo GDBusAnnotationInfo; |
564 | typedef struct _GDBusArgInfo GDBusArgInfo; |
565 | typedef struct _GDBusMethodInfo GDBusMethodInfo; |
566 | typedef struct _GDBusSignalInfo GDBusSignalInfo; |
567 | typedef struct _GDBusPropertyInfo GDBusPropertyInfo; |
568 | typedef struct _GDBusInterfaceInfo GDBusInterfaceInfo; |
569 | typedef struct _GDBusNodeInfo GDBusNodeInfo; |
570 | |
571 | /** |
572 | * GCancellableSourceFunc: |
573 | * @cancellable: the #GCancellable |
574 | * @user_data: data passed in by the user. |
575 | * |
576 | * This is the function type of the callback used for the #GSource |
577 | * returned by g_cancellable_source_new(). |
578 | * |
579 | * Returns: it should return %FALSE if the source should be removed. |
580 | * |
581 | * Since: 2.28 |
582 | */ |
583 | typedef gboolean (*GCancellableSourceFunc) (GCancellable *cancellable, |
584 | gpointer user_data); |
585 | |
586 | /** |
587 | * GPollableSourceFunc: |
588 | * @pollable_stream: the #GPollableInputStream or #GPollableOutputStream |
589 | * @user_data: data passed in by the user. |
590 | * |
591 | * This is the function type of the callback used for the #GSource |
592 | * returned by g_pollable_input_stream_create_source() and |
593 | * g_pollable_output_stream_create_source(). |
594 | * |
595 | * Returns: it should return %FALSE if the source should be removed. |
596 | * |
597 | * Since: 2.28 |
598 | */ |
599 | typedef gboolean (*GPollableSourceFunc) (GObject *pollable_stream, |
600 | gpointer user_data); |
601 | |
602 | typedef struct _GDBusInterface GDBusInterface; /* Dummy typedef */ |
603 | typedef struct _GDBusInterfaceSkeleton GDBusInterfaceSkeleton; |
604 | typedef struct _GDBusObject GDBusObject; /* Dummy typedef */ |
605 | typedef struct _GDBusObjectSkeleton GDBusObjectSkeleton; |
606 | typedef struct _GDBusObjectProxy GDBusObjectProxy; |
607 | typedef struct _GDBusObjectManager GDBusObjectManager; /* Dummy typedef */ |
608 | typedef struct _GDBusObjectManagerClient GDBusObjectManagerClient; |
609 | typedef struct _GDBusObjectManagerServer GDBusObjectManagerServer; |
610 | |
611 | /** |
612 | * GDBusProxyTypeFunc: |
613 | * @manager: A #GDBusObjectManagerClient. |
614 | * @object_path: The object path of the remote object. |
615 | * @interface_name: (nullable): The interface name of the remote object or %NULL if a #GDBusObjectProxy #GType is requested. |
616 | * @user_data: User data. |
617 | * |
618 | * Function signature for a function used to determine the #GType to |
619 | * use for an interface proxy (if @interface_name is not %NULL) or |
620 | * object proxy (if @interface_name is %NULL). |
621 | * |
622 | * This function is called in the |
623 | * [thread-default main loop][g-main-context-push-thread-default] |
624 | * that @manager was constructed in. |
625 | * |
626 | * Returns: A #GType to use for the remote object. The returned type |
627 | * must be a #GDBusProxy or #GDBusObjectProxy -derived |
628 | * type. |
629 | * |
630 | * Since: 2.30 |
631 | */ |
632 | typedef GType (*GDBusProxyTypeFunc) (GDBusObjectManagerClient *manager, |
633 | const gchar *object_path, |
634 | const gchar *interface_name, |
635 | gpointer user_data); |
636 | |
637 | typedef struct _GTestDBus GTestDBus; |
638 | |
639 | /** |
640 | * GSubprocess: |
641 | * |
642 | * A child process. |
643 | * |
644 | * Since: 2.40 |
645 | */ |
646 | typedef struct _GSubprocess GSubprocess; |
647 | /** |
648 | * GSubprocessLauncher: |
649 | * |
650 | * Options for launching a child process. |
651 | * |
652 | * Since: 2.40 |
653 | */ |
654 | typedef struct _GSubprocessLauncher GSubprocessLauncher; |
655 | |
656 | G_END_DECLS |
657 | |
658 | #endif /* __GIO_TYPES_H__ */ |
659 | |