Blame gio/giotypes.h

Packit ae235b
/* GIO - GLib Input, Output and Streaming Library
Packit ae235b
 *
Packit ae235b
 * Copyright (C) 2006-2007 Red Hat, Inc.
Packit ae235b
 *
Packit ae235b
 * This library is free software; you can redistribute it and/or
Packit ae235b
 * modify it under the terms of the GNU Lesser General Public
Packit ae235b
 * License as published by the Free Software Foundation; either
Packit ae235b
 * version 2.1 of the License, or (at your option) any later version.
Packit ae235b
 *
Packit ae235b
 * This library is distributed in the hope that it will be useful,
Packit ae235b
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
Packit ae235b
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
Packit ae235b
 * Lesser General Public License for more details.
Packit ae235b
 *
Packit ae235b
 * You should have received a copy of the GNU Lesser General
Packit ae235b
 * Public License along with this library; if not, see <http://www.gnu.org/licenses/>.
Packit ae235b
 *
Packit ae235b
 * Author: Alexander Larsson <alexl@redhat.com>
Packit ae235b
 */
Packit ae235b
Packit ae235b
#ifndef __GIO_TYPES_H__
Packit ae235b
#define __GIO_TYPES_H__
Packit ae235b
Packit ae235b
#if !defined (__GIO_GIO_H_INSIDE__) && !defined (GIO_COMPILATION)
Packit ae235b
#error "Only <gio/gio.h> can be included directly."
Packit ae235b
#endif
Packit ae235b
Packit ae235b
#include <gio/gioenums.h>
Packit ae235b
Packit ae235b
G_BEGIN_DECLS
Packit ae235b
Packit ae235b
typedef struct _GAppLaunchContext             GAppLaunchContext;
Packit ae235b
typedef struct _GAppInfo                      GAppInfo; /* Dummy typedef */
Packit ae235b
typedef struct _GAsyncResult                  GAsyncResult; /* Dummy typedef */
Packit ae235b
typedef struct _GAsyncInitable                GAsyncInitable;
Packit ae235b
typedef struct _GBufferedInputStream          GBufferedInputStream;
Packit ae235b
typedef struct _GBufferedOutputStream         GBufferedOutputStream;
Packit ae235b
typedef struct _GCancellable                  GCancellable;
Packit ae235b
typedef struct _GCharsetConverter             GCharsetConverter;
Packit ae235b
typedef struct _GConverter                    GConverter;
Packit ae235b
typedef struct _GConverterInputStream         GConverterInputStream;
Packit ae235b
typedef struct _GConverterOutputStream        GConverterOutputStream;
Packit ae235b
typedef struct _GDatagramBased                GDatagramBased;
Packit ae235b
typedef struct _GDataInputStream              GDataInputStream;
Packit ae235b
typedef struct _GSimplePermission             GSimplePermission;
Packit ae235b
typedef struct _GZlibCompressor               GZlibCompressor;
Packit ae235b
typedef struct _GZlibDecompressor             GZlibDecompressor;
Packit ae235b
Packit ae235b
typedef struct _GSimpleActionGroup            GSimpleActionGroup;
Packit ae235b
typedef struct _GRemoteActionGroup            GRemoteActionGroup;
Packit ae235b
typedef struct _GDBusActionGroup              GDBusActionGroup;
Packit ae235b
typedef struct _GActionMap                    GActionMap;
Packit ae235b
typedef struct _GActionGroup                  GActionGroup;
Packit ae235b
typedef struct _GPropertyAction               GPropertyAction;
Packit ae235b
typedef struct _GSimpleAction                 GSimpleAction;
Packit ae235b
typedef struct _GAction                       GAction;
Packit ae235b
typedef struct _GApplication                  GApplication;
Packit ae235b
typedef struct _GApplicationCommandLine       GApplicationCommandLine;
Packit ae235b
typedef struct _GSettingsBackend              GSettingsBackend;
Packit ae235b
typedef struct _GSettings                     GSettings;
Packit ae235b
typedef struct _GPermission                   GPermission;
Packit ae235b
Packit ae235b
typedef struct _GMenuModel                    GMenuModel;
Packit ae235b
typedef struct _GNotification                 GNotification;
Packit ae235b
Packit ae235b
/**
Packit ae235b
 * GDrive:
Packit ae235b
 *
Packit ae235b
 * Opaque drive object.
Packit ae235b
 **/
Packit ae235b
typedef struct _GDrive                        GDrive; /* Dummy typedef */
Packit ae235b
typedef struct _GFileEnumerator               GFileEnumerator;
Packit ae235b
typedef struct _GFileMonitor                  GFileMonitor;
Packit ae235b
typedef struct _GFilterInputStream            GFilterInputStream;
Packit ae235b
typedef struct _GFilterOutputStream           GFilterOutputStream;
Packit ae235b
Packit ae235b
/**
Packit ae235b
 * GFile:
Packit ae235b
 *
Packit ae235b
 * A handle to an object implementing the #GFileIface interface.
Packit ae235b
 * Generally stores a location within the file system. Handles do not
Packit ae235b
 * necessarily represent files or directories that currently exist.
Packit ae235b
 **/
Packit ae235b
typedef struct _GFile                         GFile; /* Dummy typedef */
Packit ae235b
typedef struct _GFileInfo                     GFileInfo;
Packit ae235b
Packit ae235b
/**
Packit ae235b
 * GFileAttributeMatcher:
Packit ae235b
 *
Packit ae235b
 * Determines if a string matches a file attribute.
Packit ae235b
 **/
Packit ae235b
typedef struct _GFileAttributeMatcher         GFileAttributeMatcher;
Packit ae235b
typedef struct _GFileAttributeInfo            GFileAttributeInfo;
Packit ae235b
typedef struct _GFileAttributeInfoList        GFileAttributeInfoList;
Packit ae235b
typedef struct _GFileDescriptorBased          GFileDescriptorBased;
Packit ae235b
typedef struct _GFileInputStream              GFileInputStream;
Packit ae235b
typedef struct _GFileOutputStream             GFileOutputStream;
Packit ae235b
typedef struct _GFileIOStream                 GFileIOStream;
Packit ae235b
typedef struct _GFileIcon                     GFileIcon;
Packit ae235b
typedef struct _GFilenameCompleter            GFilenameCompleter;
Packit ae235b
Packit ae235b
Packit ae235b
typedef struct _GIcon                         GIcon; /* Dummy typedef */
Packit ae235b
typedef struct _GInetAddress                  GInetAddress;
Packit ae235b
typedef struct _GInetAddressMask              GInetAddressMask;
Packit ae235b
typedef struct _GInetSocketAddress            GInetSocketAddress;
Packit ae235b
typedef struct _GNativeSocketAddress          GNativeSocketAddress;
Packit ae235b
typedef struct _GInputStream                  GInputStream;
Packit ae235b
typedef struct _GInitable                     GInitable;
Packit ae235b
typedef struct _GIOModule                     GIOModule;
Packit ae235b
typedef struct _GIOExtensionPoint             GIOExtensionPoint;
Packit ae235b
typedef struct _GIOExtension                  GIOExtension;
Packit ae235b
Packit ae235b
/**
Packit ae235b
 * GIOSchedulerJob:
Packit ae235b
 *
Packit ae235b
 * Opaque class for defining and scheduling IO jobs.
Packit ae235b
 **/
Packit ae235b
typedef struct _GIOSchedulerJob               GIOSchedulerJob;
Packit ae235b
typedef struct _GIOStreamAdapter              GIOStreamAdapter;
Packit ae235b
typedef struct _GLoadableIcon                 GLoadableIcon; /* Dummy typedef */
Packit ae235b
typedef struct _GBytesIcon                    GBytesIcon;
Packit ae235b
typedef struct _GMemoryInputStream            GMemoryInputStream;
Packit ae235b
typedef struct _GMemoryOutputStream           GMemoryOutputStream;
Packit ae235b
Packit ae235b
/**
Packit ae235b
 * GMount:
Packit ae235b
 *
Packit ae235b
 * A handle to an object implementing the #GMountIface interface.
Packit ae235b
 **/
Packit ae235b
typedef struct _GMount                        GMount; /* Dummy typedef */
Packit ae235b
typedef struct _GMountOperation               GMountOperation;
Packit ae235b
typedef struct _GNetworkAddress               GNetworkAddress;
Packit ae235b
typedef struct _GNetworkMonitor               GNetworkMonitor;
Packit ae235b
typedef struct _GNetworkService               GNetworkService;
Packit ae235b
typedef struct _GOutputStream                 GOutputStream;
Packit ae235b
typedef struct _GIOStream                     GIOStream;
Packit ae235b
typedef struct _GSimpleIOStream               GSimpleIOStream;
Packit ae235b
typedef struct _GPollableInputStream          GPollableInputStream; /* Dummy typedef */
Packit ae235b
typedef struct _GPollableOutputStream         GPollableOutputStream; /* Dummy typedef */
Packit ae235b
typedef struct _GResolver                     GResolver;
Packit ae235b
Packit ae235b
/**
Packit ae235b
 * GResource:
Packit ae235b
 *
Packit ae235b
 * A resource bundle.
Packit ae235b
 *
Packit ae235b
 * Since: 2.32
Packit ae235b
 */
Packit ae235b
typedef struct _GResource                     GResource;
Packit ae235b
typedef struct _GSeekable                     GSeekable;
Packit ae235b
typedef struct _GSimpleAsyncResult            GSimpleAsyncResult;
Packit ae235b
Packit ae235b
/**
Packit ae235b
 * GSocket:
Packit ae235b
 *
Packit ae235b
 * A lowlevel network socket object.
Packit ae235b
 *
Packit ae235b
 * Since: 2.22
Packit ae235b
 **/
Packit ae235b
typedef struct _GSocket                       GSocket;
Packit ae235b
Packit ae235b
/**
Packit ae235b
 * GSocketControlMessage:
Packit ae235b
 *
Packit ae235b
 * Base class for socket-type specific control messages that can be sent and
Packit ae235b
 * received over #GSocket.
Packit ae235b
 **/
Packit ae235b
typedef struct _GSocketControlMessage         GSocketControlMessage;
Packit ae235b
/**
Packit ae235b
 * GSocketClient:
Packit ae235b
 *
Packit ae235b
 * A helper class for network clients to make connections.
Packit ae235b
 *
Packit ae235b
 * Since: 2.22
Packit ae235b
 **/
Packit ae235b
typedef struct _GSocketClient                               GSocketClient;
Packit ae235b
/**
Packit ae235b
 * GSocketConnection:
Packit ae235b
 *
Packit ae235b
 * A socket connection GIOStream object for connection-oriented sockets.
Packit ae235b
 *
Packit ae235b
 * Since: 2.22
Packit ae235b
 **/
Packit ae235b
typedef struct _GSocketConnection                           GSocketConnection;
Packit ae235b
/**
Packit ae235b
 * GSocketListener:
Packit ae235b
 *
Packit ae235b
 * A helper class for network servers to listen for and accept connections.
Packit ae235b
 *
Packit ae235b
 * Since: 2.22
Packit ae235b
 **/
Packit ae235b
typedef struct _GSocketListener                             GSocketListener;
Packit ae235b
/**
Packit ae235b
 * GSocketService:
Packit ae235b
 *
Packit ae235b
 * A helper class for handling accepting incomming connections in the
Packit ae235b
 * glib mainloop.
Packit ae235b
 *
Packit ae235b
 * Since: 2.22
Packit ae235b
 **/
Packit ae235b
typedef struct _GSocketService                              GSocketService;
Packit ae235b
typedef struct _GSocketAddress                GSocketAddress;
Packit ae235b
typedef struct _GSocketAddressEnumerator      GSocketAddressEnumerator;
Packit ae235b
typedef struct _GSocketConnectable            GSocketConnectable;
Packit ae235b
typedef struct _GSrvTarget                    GSrvTarget;
Packit ae235b
typedef struct _GTask                         GTask;
Packit ae235b
/**
Packit ae235b
 * GTcpConnection:
Packit ae235b
 *
Packit ae235b
 * A #GSocketConnection for TCP/IP connections.
Packit ae235b
 *
Packit ae235b
 * Since: 2.22
Packit ae235b
 **/
Packit ae235b
typedef struct _GTcpConnection                              GTcpConnection;
Packit ae235b
typedef struct _GTcpWrapperConnection                       GTcpWrapperConnection;
Packit ae235b
/**
Packit ae235b
 * GThreadedSocketService:
Packit ae235b
 *
Packit ae235b
 * A helper class for handling accepting incoming connections in the
Packit ae235b
 * glib mainloop and handling them in a thread.
Packit ae235b
 *
Packit ae235b
 * Since: 2.22
Packit ae235b
 **/
Packit ae235b
typedef struct _GThreadedSocketService                      GThreadedSocketService;
Packit ae235b
typedef struct _GDtlsConnection               GDtlsConnection;
Packit ae235b
typedef struct _GDtlsClientConnection         GDtlsClientConnection; /* Dummy typedef */
Packit ae235b
typedef struct _GDtlsServerConnection         GDtlsServerConnection; /* Dummy typedef */
Packit ae235b
typedef struct _GThemedIcon                   GThemedIcon;
Packit ae235b
typedef struct _GTlsCertificate               GTlsCertificate;
Packit ae235b
typedef struct _GTlsClientConnection          GTlsClientConnection; /* Dummy typedef */
Packit ae235b
typedef struct _GTlsConnection                GTlsConnection;
Packit ae235b
typedef struct _GTlsDatabase                  GTlsDatabase;
Packit ae235b
typedef struct _GTlsFileDatabase              GTlsFileDatabase;
Packit ae235b
typedef struct _GTlsInteraction               GTlsInteraction;
Packit ae235b
typedef struct _GTlsPassword                  GTlsPassword;
Packit ae235b
typedef struct _GTlsServerConnection          GTlsServerConnection; /* Dummy typedef */
Packit ae235b
typedef struct _GVfs                          GVfs; /* Dummy typedef */
Packit ae235b
Packit ae235b
/**
Packit ae235b
 * GProxyResolver:
Packit ae235b
 *
Packit ae235b
 * A helper class to enumerate proxies base on URI.
Packit ae235b
 *
Packit ae235b
 * Since: 2.26
Packit ae235b
 **/
Packit ae235b
typedef struct _GProxyResolver                GProxyResolver;
Packit ae235b
typedef struct _GProxy			      GProxy;
Packit ae235b
typedef struct _GProxyAddress		      GProxyAddress;
Packit ae235b
typedef struct _GProxyAddressEnumerator	      GProxyAddressEnumerator;
Packit ae235b
Packit ae235b
/**
Packit ae235b
 * GVolume:
Packit ae235b
 *
Packit ae235b
 * Opaque mountable volume object.
Packit ae235b
 **/
Packit ae235b
typedef struct _GVolume                       GVolume; /* Dummy typedef */
Packit ae235b
typedef struct _GVolumeMonitor                GVolumeMonitor;
Packit ae235b
Packit ae235b
/**
Packit ae235b
 * GAsyncReadyCallback:
Packit ae235b
 * @source_object: (nullable): the object the asynchronous operation was started with.
Packit ae235b
 * @res: a #GAsyncResult.
Packit ae235b
 * @user_data: user data passed to the callback.
Packit ae235b
 *
Packit ae235b
 * Type definition for a function that will be called back when an asynchronous
Packit ae235b
 * operation within GIO has been completed. #GAsyncReadyCallback
Packit ae235b
 * callbacks from #GTask are guaranteed to be invoked in a later
Packit ae235b
 * iteration of the
Packit ae235b
 * [thread-default main context][g-main-context-push-thread-default]
Packit ae235b
 * where the #GTask was created. All other users of
Packit ae235b
 * #GAsyncReadyCallback must likewise call it asynchronously in a
Packit ae235b
 * later iteration of the main context.
Packit ae235b
 **/
Packit ae235b
typedef void (*GAsyncReadyCallback) (GObject *source_object,
Packit ae235b
				     GAsyncResult *res,
Packit ae235b
				     gpointer user_data);
Packit ae235b
Packit ae235b
/**
Packit ae235b
 * GFileProgressCallback:
Packit ae235b
 * @current_num_bytes: the current number of bytes in the operation.
Packit ae235b
 * @total_num_bytes: the total number of bytes in the operation.
Packit ae235b
 * @user_data: user data passed to the callback.
Packit ae235b
 *
Packit ae235b
 * When doing file operations that may take a while, such as moving
Packit ae235b
 * a file or copying a file, a progress callback is used to pass how
Packit ae235b
 * far along that operation is to the application.
Packit ae235b
 **/
Packit ae235b
typedef void (*GFileProgressCallback) (goffset current_num_bytes,
Packit ae235b
                                       goffset total_num_bytes,
Packit ae235b
                                       gpointer user_data);
Packit ae235b
Packit ae235b
/**
Packit ae235b
 * GFileReadMoreCallback:
Packit ae235b
 * @file_contents: the data as currently read.
Packit ae235b
 * @file_size: the size of the data currently read.
Packit ae235b
 * @callback_data: (closure): data passed to the callback.
Packit ae235b
 *
Packit ae235b
 * When loading the partial contents of a file with g_file_load_partial_contents_async(),
Packit ae235b
 * it may become necessary to determine if any more data from the file should be loaded.
Packit ae235b
 * A #GFileReadMoreCallback function facilitates this by returning %TRUE if more data
Packit ae235b
 * should be read, or %FALSE otherwise.
Packit ae235b
 *
Packit ae235b
 * Returns: %TRUE if more data should be read back. %FALSE otherwise.
Packit ae235b
 **/
Packit ae235b
typedef gboolean (* GFileReadMoreCallback) (const char *file_contents,
Packit ae235b
                                            goffset file_size,
Packit ae235b
                                            gpointer callback_data);
Packit ae235b
Packit ae235b
/**
Packit ae235b
 * GFileMeasureProgressCallback:
Packit ae235b
 * @reporting: %TRUE if more reports will come
Packit ae235b
 * @current_size: the current cumulative size measurement
Packit ae235b
 * @num_dirs: the number of directories visited so far
Packit ae235b
 * @num_files: the number of non-directory files encountered
Packit ae235b
 * @user_data: the data passed to the original request for this callback
Packit ae235b
 *
Packit ae235b
 * This callback type is used by g_file_measure_disk_usage() to make
Packit ae235b
 * periodic progress reports when measuring the amount of disk spaced
Packit ae235b
 * used by a directory.
Packit ae235b
 *
Packit ae235b
 * These calls are made on a best-effort basis and not all types of
Packit ae235b
 * #GFile will support them.  At the minimum, however, one call will
Packit ae235b
 * always be made immediately.
Packit ae235b
 *
Packit ae235b
 * In the case that there is no support, @reporting will be set to
Packit ae235b
 * %FALSE (and the other values undefined) and no further calls will be
Packit ae235b
 * made.  Otherwise, the @reporting will be %TRUE and the other values
Packit ae235b
 * all-zeros during the first (immediate) call.  In this way, you can
Packit ae235b
 * know which type of progress UI to show without a delay.
Packit ae235b
 *
Packit ae235b
 * For g_file_measure_disk_usage() the callback is made directly.  For
Packit ae235b
 * g_file_measure_disk_usage_async() the callback is made via the
Packit ae235b
 * default main context of the calling thread (ie: the same way that the
Packit ae235b
 * final async result would be reported).
Packit ae235b
 *
Packit ae235b
 * @current_size is in the same units as requested by the operation (see
Packit ae235b
 * %G_FILE_DISK_USAGE_APPARENT_SIZE).
Packit ae235b
 *
Packit ae235b
 * The frequency of the updates is implementation defined, but is
Packit ae235b
 * ideally about once every 200ms.
Packit ae235b
 *
Packit ae235b
 * The last progress callback may or may not be equal to the final
Packit ae235b
 * result.  Always check the async result to get the final value.
Packit ae235b
 *
Packit ae235b
 * Since: 2.38
Packit ae235b
 **/
Packit ae235b
typedef void (* GFileMeasureProgressCallback) (gboolean reporting,
Packit ae235b
                                               guint64  current_size,
Packit ae235b
                                               guint64  num_dirs,
Packit ae235b
                                               guint64  num_files,
Packit ae235b
                                               gpointer user_data);
Packit ae235b
Packit ae235b
/**
Packit ae235b
 * GIOSchedulerJobFunc:
Packit ae235b
 * @job: a #GIOSchedulerJob.
Packit ae235b
 * @cancellable: optional #GCancellable object, %NULL to ignore.
Packit ae235b
 * @user_data: the data to pass to callback function
Packit ae235b
 *
Packit ae235b
 * I/O Job function.
Packit ae235b
 *
Packit ae235b
 * Long-running jobs should periodically check the @cancellable
Packit ae235b
 * to see if they have been cancelled.
Packit ae235b
 *
Packit ae235b
 * Returns: %TRUE if this function should be called again to
Packit ae235b
 *    complete the job, %FALSE if the job is complete (or cancelled)
Packit ae235b
 **/
Packit ae235b
typedef gboolean (*GIOSchedulerJobFunc) (GIOSchedulerJob *job,
Packit ae235b
					 GCancellable    *cancellable,
Packit ae235b
					 gpointer         user_data);
Packit ae235b
Packit ae235b
/**
Packit ae235b
 * GSimpleAsyncThreadFunc:
Packit ae235b
 * @res: a #GSimpleAsyncResult.
Packit ae235b
 * @object: a #GObject.
Packit ae235b
 * @cancellable: optional #GCancellable object, %NULL to ignore.
Packit ae235b
 *
Packit ae235b
 * Simple thread function that runs an asynchronous operation and
Packit ae235b
 * checks for cancellation.
Packit ae235b
 **/
Packit ae235b
typedef void (*GSimpleAsyncThreadFunc) (GSimpleAsyncResult *res,
Packit ae235b
                                        GObject *object,
Packit ae235b
                                        GCancellable *cancellable);
Packit ae235b
Packit ae235b
/**
Packit ae235b
 * GSocketSourceFunc:
Packit ae235b
 * @socket: the #GSocket
Packit ae235b
 * @condition: the current condition at the source fired.
Packit ae235b
 * @user_data: data passed in by the user.
Packit ae235b
 *
Packit ae235b
 * This is the function type of the callback used for the #GSource
Packit ae235b
 * returned by g_socket_create_source().
Packit ae235b
 *
Packit ae235b
 * Returns: it should return %FALSE if the source should be removed.
Packit ae235b
 *
Packit ae235b
 * Since: 2.22
Packit ae235b
 */
Packit ae235b
typedef gboolean (*GSocketSourceFunc) (GSocket *socket,
Packit ae235b
				       GIOCondition condition,
Packit ae235b
				       gpointer user_data);
Packit ae235b
Packit ae235b
/**
Packit ae235b
 * GDatagramBasedSourceFunc:
Packit ae235b
 * @datagram_based: the #GDatagramBased
Packit ae235b
 * @condition: the current condition at the source fired
Packit ae235b
 * @user_data: data passed in by the user
Packit ae235b
 *
Packit ae235b
 * This is the function type of the callback used for the #GSource
Packit ae235b
 * returned by g_datagram_based_create_source().
Packit ae235b
 *
Packit ae235b
 * Returns: %G_SOURCE_REMOVE if the source should be removed,
Packit ae235b
 *   %G_SOURCE_CONTINUE otherwise
Packit ae235b
 *
Packit ae235b
 * Since: 2.48
Packit ae235b
 */
Packit ae235b
typedef gboolean (*GDatagramBasedSourceFunc) (GDatagramBased *datagram_based,
Packit ae235b
                                              GIOCondition    condition,
Packit ae235b
                                              gpointer        user_data);
Packit ae235b
Packit ae235b
/**
Packit ae235b
 * GInputVector:
Packit ae235b
 * @buffer: Pointer to a buffer where data will be written.
Packit ae235b
 * @size: the available size in @buffer.
Packit ae235b
 *
Packit ae235b
 * Structure used for scatter/gather data input.
Packit ae235b
 * You generally pass in an array of #GInputVectors
Packit ae235b
 * and the operation will store the read data starting in the
Packit ae235b
 * first buffer, switching to the next as needed.
Packit ae235b
 *
Packit ae235b
 * Since: 2.22
Packit ae235b
 */
Packit ae235b
typedef struct _GInputVector GInputVector;
Packit ae235b
Packit ae235b
struct _GInputVector {
Packit ae235b
  gpointer buffer;
Packit ae235b
  gsize size;
Packit ae235b
};
Packit ae235b
Packit ae235b
/**
Packit ae235b
 * GInputMessage:
Packit ae235b
 * @address: (optional) (out) (transfer full): return location
Packit ae235b
 *   for a #GSocketAddress, or %NULL
Packit ae235b
 * @vectors: (array length=num_vectors) (out): pointer to an
Packit ae235b
 *   array of input vectors
Packit ae235b
 * @num_vectors: the number of input vectors pointed to by @vectors
Packit ae235b
 * @bytes_received: (out): will be set to the number of bytes that have been
Packit ae235b
 *   received
Packit ae235b
 * @flags: (out): collection of #GSocketMsgFlags for the received message,
Packit ae235b
 *   outputted by the call
Packit ae235b
 * @control_messages: (array length=num_control_messages) (optional)
Packit ae235b
 *   (out) (transfer full): return location for a
Packit ae235b
 *   caller-allocated array of #GSocketControlMessages, or %NULL
Packit ae235b
 * @num_control_messages: (out) (optional): return location for the number of
Packit ae235b
 *   elements in @control_messages
Packit ae235b
 *
Packit ae235b
 * Structure used for scatter/gather data input when receiving multiple
Packit ae235b
 * messages or packets in one go. You generally pass in an array of empty
Packit ae235b
 * #GInputVectors and the operation will use all the buffers as if they
Packit ae235b
 * were one buffer, and will set @bytes_received to the total number of bytes
Packit ae235b
 * received across all #GInputVectors.
Packit ae235b
 *
Packit ae235b
 * This structure closely mirrors `struct mmsghdr` and `struct msghdr` from
Packit ae235b
 * the POSIX sockets API (see `man 2 recvmmsg`).
Packit ae235b
 *
Packit ae235b
 * If @address is non-%NULL then it is set to the source address the message
Packit ae235b
 * was received from, and the caller must free it afterwards.
Packit ae235b
 *
Packit ae235b
 * If @control_messages is non-%NULL then it is set to an array of control
Packit ae235b
 * messages received with the message (if any), and the caller must free it
Packit ae235b
 * afterwards. @num_control_messages is set to the number of elements in
Packit ae235b
 * this array, which may be zero.
Packit ae235b
 *
Packit ae235b
 * Flags relevant to this message will be returned in @flags. For example,
Packit ae235b
 * `MSG_EOR` or `MSG_TRUNC`.
Packit ae235b
 *
Packit ae235b
 * Since: 2.48
Packit ae235b
 */
Packit ae235b
typedef struct _GInputMessage GInputMessage;
Packit ae235b
Packit ae235b
struct _GInputMessage {
Packit ae235b
  GSocketAddress         **address;
Packit ae235b
Packit ae235b
  GInputVector            *vectors;
Packit ae235b
  guint                    num_vectors;
Packit ae235b
Packit ae235b
  gsize                    bytes_received;
Packit ae235b
  gint                     flags;
Packit ae235b
Packit ae235b
  GSocketControlMessage ***control_messages;
Packit ae235b
  guint                   *num_control_messages;
Packit ae235b
};
Packit ae235b
Packit ae235b
/**
Packit ae235b
 * GOutputVector:
Packit ae235b
 * @buffer: Pointer to a buffer of data to read.
Packit ae235b
 * @size: the size of @buffer.
Packit ae235b
 *
Packit ae235b
 * Structure used for scatter/gather data output.
Packit ae235b
 * You generally pass in an array of #GOutputVectors
Packit ae235b
 * and the operation will use all the buffers as if they were
Packit ae235b
 * one buffer.
Packit ae235b
 *
Packit ae235b
 * Since: 2.22
Packit ae235b
 */
Packit ae235b
typedef struct _GOutputVector GOutputVector;
Packit ae235b
Packit ae235b
struct _GOutputVector {
Packit ae235b
  gconstpointer buffer;
Packit ae235b
  gsize size;
Packit ae235b
};
Packit ae235b
Packit ae235b
/**
Packit ae235b
 * GOutputMessage:
Packit ae235b
 * @address: (nullable): a #GSocketAddress, or %NULL
Packit ae235b
 * @vectors: pointer to an array of output vectors
Packit ae235b
 * @num_vectors: the number of output vectors pointed to by @vectors.
Packit ae235b
 * @bytes_sent: initialize to 0. Will be set to the number of bytes
Packit ae235b
 *     that have been sent
Packit ae235b
 * @control_messages: (array length=num_control_messages) (nullable): a pointer
Packit ae235b
 *   to an array of #GSocketControlMessages, or %NULL.
Packit ae235b
 * @num_control_messages: number of elements in @control_messages.
Packit ae235b
 *
Packit ae235b
 * Structure used for scatter/gather data output when sending multiple
Packit ae235b
 * messages or packets in one go. You generally pass in an array of
Packit ae235b
 * #GOutputVectors and the operation will use all the buffers as if they
Packit ae235b
 * were one buffer.
Packit ae235b
 *
Packit ae235b
 * If @address is %NULL then the message is sent to the default receiver
Packit ae235b
 * (as previously set by g_socket_connect()).
Packit ae235b
 *
Packit ae235b
 * Since: 2.44
Packit ae235b
 */
Packit ae235b
typedef struct _GOutputMessage GOutputMessage;
Packit ae235b
Packit ae235b
struct _GOutputMessage {
Packit ae235b
  GSocketAddress         *address;
Packit ae235b
Packit ae235b
  GOutputVector          *vectors;
Packit ae235b
  guint                   num_vectors;
Packit ae235b
Packit ae235b
  guint                   bytes_sent;
Packit ae235b
Packit ae235b
  GSocketControlMessage **control_messages;
Packit ae235b
  guint                   num_control_messages;
Packit ae235b
};
Packit ae235b
Packit ae235b
typedef struct _GCredentials                  GCredentials;
Packit ae235b
typedef struct _GUnixCredentialsMessage       GUnixCredentialsMessage;
Packit ae235b
typedef struct _GUnixFDList                   GUnixFDList;
Packit ae235b
typedef struct _GDBusMessage                  GDBusMessage;
Packit ae235b
typedef struct _GDBusConnection               GDBusConnection;
Packit ae235b
typedef struct _GDBusProxy                    GDBusProxy;
Packit ae235b
typedef struct _GDBusMethodInvocation         GDBusMethodInvocation;
Packit ae235b
typedef struct _GDBusServer                   GDBusServer;
Packit ae235b
typedef struct _GDBusAuthObserver             GDBusAuthObserver;
Packit ae235b
typedef struct _GDBusErrorEntry               GDBusErrorEntry;
Packit ae235b
typedef struct _GDBusInterfaceVTable          GDBusInterfaceVTable;
Packit ae235b
typedef struct _GDBusSubtreeVTable            GDBusSubtreeVTable;
Packit ae235b
typedef struct _GDBusAnnotationInfo           GDBusAnnotationInfo;
Packit ae235b
typedef struct _GDBusArgInfo                  GDBusArgInfo;
Packit ae235b
typedef struct _GDBusMethodInfo               GDBusMethodInfo;
Packit ae235b
typedef struct _GDBusSignalInfo               GDBusSignalInfo;
Packit ae235b
typedef struct _GDBusPropertyInfo             GDBusPropertyInfo;
Packit ae235b
typedef struct _GDBusInterfaceInfo            GDBusInterfaceInfo;
Packit ae235b
typedef struct _GDBusNodeInfo                 GDBusNodeInfo;
Packit ae235b
Packit ae235b
/**
Packit ae235b
 * GCancellableSourceFunc:
Packit ae235b
 * @cancellable: the #GCancellable
Packit ae235b
 * @user_data: data passed in by the user.
Packit ae235b
 *
Packit ae235b
 * This is the function type of the callback used for the #GSource
Packit ae235b
 * returned by g_cancellable_source_new().
Packit ae235b
 *
Packit ae235b
 * Returns: it should return %FALSE if the source should be removed.
Packit ae235b
 *
Packit ae235b
 * Since: 2.28
Packit ae235b
 */
Packit ae235b
typedef gboolean (*GCancellableSourceFunc) (GCancellable *cancellable,
Packit ae235b
					    gpointer      user_data);
Packit ae235b
Packit ae235b
/**
Packit ae235b
 * GPollableSourceFunc:
Packit ae235b
 * @pollable_stream: the #GPollableInputStream or #GPollableOutputStream
Packit ae235b
 * @user_data: data passed in by the user.
Packit ae235b
 *
Packit ae235b
 * This is the function type of the callback used for the #GSource
Packit ae235b
 * returned by g_pollable_input_stream_create_source() and
Packit ae235b
 * g_pollable_output_stream_create_source().
Packit ae235b
 *
Packit ae235b
 * Returns: it should return %FALSE if the source should be removed.
Packit ae235b
 *
Packit ae235b
 * Since: 2.28
Packit ae235b
 */
Packit ae235b
typedef gboolean (*GPollableSourceFunc) (GObject  *pollable_stream,
Packit ae235b
					 gpointer  user_data);
Packit ae235b
Packit ae235b
typedef struct _GDBusInterface              GDBusInterface; /* Dummy typedef */
Packit ae235b
typedef struct _GDBusInterfaceSkeleton      GDBusInterfaceSkeleton;
Packit ae235b
typedef struct _GDBusObject                 GDBusObject;  /* Dummy typedef */
Packit ae235b
typedef struct _GDBusObjectSkeleton         GDBusObjectSkeleton;
Packit ae235b
typedef struct _GDBusObjectProxy            GDBusObjectProxy;
Packit ae235b
typedef struct _GDBusObjectManager          GDBusObjectManager;  /* Dummy typedef */
Packit ae235b
typedef struct _GDBusObjectManagerClient    GDBusObjectManagerClient;
Packit ae235b
typedef struct _GDBusObjectManagerServer    GDBusObjectManagerServer;
Packit ae235b
Packit ae235b
/**
Packit ae235b
 * GDBusProxyTypeFunc:
Packit ae235b
 * @manager: A #GDBusObjectManagerClient.
Packit ae235b
 * @object_path: The object path of the remote object.
Packit ae235b
 * @interface_name: (nullable): The interface name of the remote object or %NULL if a #GDBusObjectProxy #GType is requested.
Packit ae235b
 * @user_data: User data.
Packit ae235b
 *
Packit ae235b
 * Function signature for a function used to determine the #GType to
Packit ae235b
 * use for an interface proxy (if @interface_name is not %NULL) or
Packit ae235b
 * object proxy (if @interface_name is %NULL).
Packit ae235b
 *
Packit ae235b
 * This function is called in the
Packit ae235b
 * [thread-default main loop][g-main-context-push-thread-default]
Packit ae235b
 * that @manager was constructed in.
Packit ae235b
 *
Packit ae235b
 * Returns: A #GType to use for the remote object. The returned type
Packit ae235b
 *   must be a #GDBusProxy or #GDBusObjectProxy -derived
Packit ae235b
 *   type.
Packit ae235b
 *
Packit ae235b
 * Since: 2.30
Packit ae235b
 */
Packit ae235b
typedef GType (*GDBusProxyTypeFunc) (GDBusObjectManagerClient   *manager,
Packit ae235b
                                     const gchar                *object_path,
Packit ae235b
                                     const gchar                *interface_name,
Packit ae235b
                                     gpointer                    user_data);
Packit ae235b
Packit ae235b
typedef struct _GTestDBus GTestDBus;
Packit ae235b
Packit ae235b
/**
Packit ae235b
 * GSubprocess:
Packit ae235b
 *
Packit ae235b
 * A child process.
Packit ae235b
 *
Packit ae235b
 * Since: 2.40
Packit ae235b
 */
Packit ae235b
typedef struct _GSubprocess                   GSubprocess;
Packit ae235b
/**
Packit ae235b
 * GSubprocessLauncher:
Packit ae235b
 *
Packit ae235b
 * Options for launching a child process.
Packit ae235b
 *
Packit ae235b
 * Since: 2.40
Packit ae235b
 */
Packit ae235b
typedef struct _GSubprocessLauncher           GSubprocessLauncher;
Packit ae235b
Packit ae235b
G_END_DECLS
Packit ae235b
Packit ae235b
#endif /* __GIO_TYPES_H__ */