Blame gio/gdbusprivate.h

Packit ae235b
/* GDBus - GLib D-Bus Library
Packit ae235b
 *
Packit ae235b
 * Copyright (C) 2008-2010 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: David Zeuthen <davidz@redhat.com>
Packit ae235b
 */
Packit ae235b
Packit ae235b
#ifndef __G_DBUS_PRIVATE_H__
Packit ae235b
#define __G_DBUS_PRIVATE_H__
Packit ae235b
Packit ae235b
#if !defined (GIO_COMPILATION)
Packit ae235b
#error "gdbusprivate.h is a private header file."
Packit ae235b
#endif
Packit ae235b
Packit ae235b
#include <gio/giotypes.h>
Packit ae235b
Packit ae235b
G_BEGIN_DECLS
Packit ae235b
Packit ae235b
/* ---------------------------------------------------------------------------------------------------- */
Packit ae235b
Packit ae235b
typedef struct GDBusWorker GDBusWorker;
Packit ae235b
Packit ae235b
typedef void (*GDBusWorkerMessageReceivedCallback) (GDBusWorker   *worker,
Packit ae235b
                                                    GDBusMessage  *message,
Packit ae235b
                                                    gpointer       user_data);
Packit ae235b
Packit ae235b
typedef GDBusMessage *(*GDBusWorkerMessageAboutToBeSentCallback) (GDBusWorker   *worker,
Packit ae235b
                                                                  GDBusMessage  *message,
Packit ae235b
                                                                  gpointer       user_data);
Packit ae235b
Packit ae235b
typedef void (*GDBusWorkerDisconnectedCallback)    (GDBusWorker   *worker,
Packit ae235b
                                                    gboolean       remote_peer_vanished,
Packit ae235b
                                                    GError        *error,
Packit ae235b
                                                    gpointer       user_data);
Packit ae235b
Packit ae235b
/* This function may be called from any thread - callbacks will be in the shared private message thread
Packit ae235b
 * and must not block.
Packit ae235b
 */
Packit ae235b
GDBusWorker *_g_dbus_worker_new          (GIOStream                          *stream,
Packit ae235b
                                          GDBusCapabilityFlags                capabilities,
Packit ae235b
                                          gboolean                            initially_frozen,
Packit ae235b
                                          GDBusWorkerMessageReceivedCallback  message_received_callback,
Packit ae235b
                                          GDBusWorkerMessageAboutToBeSentCallback message_about_to_be_sent_callback,
Packit ae235b
                                          GDBusWorkerDisconnectedCallback     disconnected_callback,
Packit ae235b
                                          gpointer                            user_data);
Packit ae235b
Packit ae235b
/* can be called from any thread - steals blob */
Packit ae235b
void         _g_dbus_worker_send_message (GDBusWorker    *worker,
Packit ae235b
                                          GDBusMessage   *message,
Packit ae235b
                                          gchar          *blob,
Packit ae235b
                                          gsize           blob_len);
Packit ae235b
Packit ae235b
/* can be called from any thread */
Packit ae235b
void         _g_dbus_worker_stop         (GDBusWorker    *worker);
Packit ae235b
Packit ae235b
/* can be called from any thread */
Packit ae235b
void         _g_dbus_worker_unfreeze     (GDBusWorker    *worker);
Packit ae235b
Packit ae235b
/* can be called from any thread (except the worker thread) */
Packit ae235b
gboolean     _g_dbus_worker_flush_sync   (GDBusWorker    *worker,
Packit ae235b
                                          GCancellable   *cancellable,
Packit ae235b
                                          GError        **error);
Packit ae235b
Packit ae235b
/* can be called from any thread */
Packit ae235b
void         _g_dbus_worker_close        (GDBusWorker         *worker,
Packit ae235b
                                          GTask               *task);
Packit ae235b
Packit ae235b
/* ---------------------------------------------------------------------------------------------------- */
Packit ae235b
Packit ae235b
void _g_dbus_initialize (void);
Packit ae235b
gboolean _g_dbus_debug_authentication (void);
Packit ae235b
gboolean _g_dbus_debug_transport (void);
Packit ae235b
gboolean _g_dbus_debug_message (void);
Packit ae235b
gboolean _g_dbus_debug_payload (void);
Packit ae235b
gboolean _g_dbus_debug_call    (void);
Packit ae235b
gboolean _g_dbus_debug_signal  (void);
Packit ae235b
gboolean _g_dbus_debug_incoming (void);
Packit ae235b
gboolean _g_dbus_debug_return (void);
Packit ae235b
gboolean _g_dbus_debug_emission (void);
Packit ae235b
gboolean _g_dbus_debug_address (void);
Packit ae235b
Packit ae235b
void     _g_dbus_debug_print_lock (void);
Packit ae235b
void     _g_dbus_debug_print_unlock (void);
Packit ae235b
Packit ae235b
gboolean _g_dbus_address_parse_entry (const gchar  *address_entry,
Packit ae235b
                                      gchar       **out_transport_name,
Packit ae235b
                                      GHashTable  **out_key_value_pairs,
Packit ae235b
                                      GError      **error);
Packit ae235b
Packit ae235b
GVariantType * _g_dbus_compute_complete_signature (GDBusArgInfo **args);
Packit ae235b
Packit ae235b
gchar *_g_dbus_hexdump (const gchar *data, gsize len, guint indent);
Packit ae235b
Packit ae235b
/* ---------------------------------------------------------------------------------------------------- */
Packit ae235b
Packit ae235b
#ifdef G_OS_WIN32
Packit ae235b
gchar *_g_dbus_win32_get_user_sid (void);
Packit ae235b
#endif
Packit ae235b
Packit ae235b
gchar *_g_dbus_get_machine_id (GError **error);
Packit ae235b
Packit ae235b
gchar *_g_dbus_enum_to_string (GType enum_type, gint value);
Packit ae235b
Packit ae235b
/* ---------------------------------------------------------------------------------------------------- */
Packit ae235b
Packit ae235b
GDBusMethodInvocation *_g_dbus_method_invocation_new (const gchar             *sender,
Packit ae235b
                                                      const gchar             *object_path,
Packit ae235b
                                                      const gchar             *interface_name,
Packit ae235b
                                                      const gchar             *method_name,
Packit ae235b
                                                      const GDBusMethodInfo   *method_info,
Packit ae235b
                                                      const GDBusPropertyInfo *property_info,
Packit ae235b
                                                      GDBusConnection         *connection,
Packit ae235b
                                                      GDBusMessage            *message,
Packit ae235b
                                                      GVariant                *parameters,
Packit ae235b
                                                      gpointer                 user_data);
Packit ae235b
Packit ae235b
/* ---------------------------------------------------------------------------------------------------- */
Packit ae235b
Packit ae235b
gboolean _g_signal_accumulator_false_handled (GSignalInvocationHint *ihint,
Packit ae235b
                                              GValue                *return_accu,
Packit ae235b
                                              const GValue          *handler_return,
Packit ae235b
                                              gpointer               dummy);
Packit ae235b
Packit ae235b
gboolean _g_dbus_object_skeleton_has_authorize_method_handlers (GDBusObjectSkeleton *object);
Packit ae235b
Packit ae235b
void _g_dbus_object_proxy_add_interface (GDBusObjectProxy *proxy,
Packit ae235b
                                         GDBusProxy       *interface_proxy);
Packit ae235b
void _g_dbus_object_proxy_remove_interface (GDBusObjectProxy *proxy,
Packit ae235b
                                            const gchar      *interface_name);
Packit ae235b
Packit ae235b
/* Implemented in gdbusconnection.c */
Packit ae235b
GDBusConnection *_g_bus_get_singleton_if_exists (GBusType bus_type);
Packit ae235b
Packit ae235b
G_END_DECLS
Packit ae235b
Packit ae235b
#endif /* __G_DBUS_PRIVATE_H__ */