/*
 * This file is generated by gdbus-codegen, do not modify it.
 *
 * The license of this code is the same as for the D-Bus interface description
 * it was derived from. Note that it links to GLib, so must comply with the
 * LGPL linking clauses.
 */

#ifdef HAVE_CONFIG_H
#  include "config.h"
#endif

#include "ms-dbus-systemd-sysupdated.h"

#include <string.h>
#ifdef G_OS_UNIX
#  include <gio/gunixfdlist.h>
#endif

#ifdef G_ENABLE_DEBUG
#define g_marshal_value_peek_boolean(v)  g_value_get_boolean (v)
#define g_marshal_value_peek_char(v)     g_value_get_schar (v)
#define g_marshal_value_peek_uchar(v)    g_value_get_uchar (v)
#define g_marshal_value_peek_int(v)      g_value_get_int (v)
#define g_marshal_value_peek_uint(v)     g_value_get_uint (v)
#define g_marshal_value_peek_long(v)     g_value_get_long (v)
#define g_marshal_value_peek_ulong(v)    g_value_get_ulong (v)
#define g_marshal_value_peek_int64(v)    g_value_get_int64 (v)
#define g_marshal_value_peek_uint64(v)   g_value_get_uint64 (v)
#define g_marshal_value_peek_enum(v)     g_value_get_enum (v)
#define g_marshal_value_peek_flags(v)    g_value_get_flags (v)
#define g_marshal_value_peek_float(v)    g_value_get_float (v)
#define g_marshal_value_peek_double(v)   g_value_get_double (v)
#define g_marshal_value_peek_string(v)   (char*) g_value_get_string (v)
#define g_marshal_value_peek_param(v)    g_value_get_param (v)
#define g_marshal_value_peek_boxed(v)    g_value_get_boxed (v)
#define g_marshal_value_peek_pointer(v)  g_value_get_pointer (v)
#define g_marshal_value_peek_object(v)   g_value_get_object (v)
#define g_marshal_value_peek_variant(v)  g_value_get_variant (v)
#else /* !G_ENABLE_DEBUG */
/* WARNING: This code accesses GValues directly, which is UNSUPPORTED API.
 *          Do not access GValues directly in your code. Instead, use the
 *          g_value_get_*() functions
 */
#define g_marshal_value_peek_boolean(v)  (v)->data[0].v_int
#define g_marshal_value_peek_char(v)     (v)->data[0].v_int
#define g_marshal_value_peek_uchar(v)    (v)->data[0].v_uint
#define g_marshal_value_peek_int(v)      (v)->data[0].v_int
#define g_marshal_value_peek_uint(v)     (v)->data[0].v_uint
#define g_marshal_value_peek_long(v)     (v)->data[0].v_long
#define g_marshal_value_peek_ulong(v)    (v)->data[0].v_ulong
#define g_marshal_value_peek_int64(v)    (v)->data[0].v_int64
#define g_marshal_value_peek_uint64(v)   (v)->data[0].v_uint64
#define g_marshal_value_peek_enum(v)     (v)->data[0].v_long
#define g_marshal_value_peek_flags(v)    (v)->data[0].v_ulong
#define g_marshal_value_peek_float(v)    (v)->data[0].v_float
#define g_marshal_value_peek_double(v)   (v)->data[0].v_double
#define g_marshal_value_peek_string(v)   (v)->data[0].v_pointer
#define g_marshal_value_peek_param(v)    (v)->data[0].v_pointer
#define g_marshal_value_peek_boxed(v)    (v)->data[0].v_pointer
#define g_marshal_value_peek_pointer(v)  (v)->data[0].v_pointer
#define g_marshal_value_peek_object(v)   (v)->data[0].v_pointer
#define g_marshal_value_peek_variant(v)  (v)->data[0].v_pointer
#endif /* !G_ENABLE_DEBUG */

typedef struct
{
  GDBusArgInfo parent_struct;
  gboolean use_gvariant;
} _ExtendedGDBusArgInfo;

typedef struct
{
  GDBusMethodInfo parent_struct;
  const gchar *signal_name;
  gboolean pass_fdlist;
} _ExtendedGDBusMethodInfo;

typedef struct
{
  GDBusSignalInfo parent_struct;
  const gchar *signal_name;
} _ExtendedGDBusSignalInfo;

typedef struct
{
  GDBusPropertyInfo parent_struct;
  const gchar *hyphen_name;
  guint use_gvariant : 1;
  guint emits_changed_signal : 1;
} _ExtendedGDBusPropertyInfo;

typedef struct
{
  GDBusInterfaceInfo parent_struct;
  const gchar *hyphen_name;
} _ExtendedGDBusInterfaceInfo;

typedef struct
{
  const _ExtendedGDBusPropertyInfo *info;
  guint prop_id;
  GValue orig_value; /* the value before the change */
} ChangedProperty;

static void
_changed_property_free (ChangedProperty *data)
{
  g_value_unset (&data->orig_value);
  g_free (data);
}

static gboolean
_g_strv_equal0 (gchar **a, gchar **b)
{
  gboolean ret = FALSE;
  guint n;
  if (a == NULL && b == NULL)
    {
      ret = TRUE;
      goto out;
    }
  if (a == NULL || b == NULL)
    goto out;
  if (g_strv_length (a) != g_strv_length (b))
    goto out;
  for (n = 0; a[n] != NULL; n++)
    if (g_strcmp0 (a[n], b[n]) != 0)
      goto out;
  ret = TRUE;
out:
  return ret;
}

static gboolean
_g_variant_equal0 (GVariant *a, GVariant *b)
{
  gboolean ret = FALSE;
  if (a == NULL && b == NULL)
    {
      ret = TRUE;
      goto out;
    }
  if (a == NULL || b == NULL)
    goto out;
  ret = g_variant_equal (a, b);
out:
  return ret;
}

G_GNUC_UNUSED static gboolean
_g_value_equal (const GValue *a, const GValue *b)
{
  gboolean ret = FALSE;
  g_assert (G_VALUE_TYPE (a) == G_VALUE_TYPE (b));
  switch (G_VALUE_TYPE (a))
    {
      case G_TYPE_BOOLEAN:
        ret = (g_value_get_boolean (a) == g_value_get_boolean (b));
        break;
      case G_TYPE_UCHAR:
        ret = (g_value_get_uchar (a) == g_value_get_uchar (b));
        break;
      case G_TYPE_INT:
        ret = (g_value_get_int (a) == g_value_get_int (b));
        break;
      case G_TYPE_UINT:
        ret = (g_value_get_uint (a) == g_value_get_uint (b));
        break;
      case G_TYPE_INT64:
        ret = (g_value_get_int64 (a) == g_value_get_int64 (b));
        break;
      case G_TYPE_UINT64:
        ret = (g_value_get_uint64 (a) == g_value_get_uint64 (b));
        break;
      case G_TYPE_DOUBLE:
        {
          /* Avoid -Wfloat-equal warnings by doing a direct bit compare */
          gdouble da = g_value_get_double (a);
          gdouble db = g_value_get_double (b);
          ret = memcmp (&da, &db, sizeof (gdouble)) == 0;
        }
        break;
      case G_TYPE_STRING:
        ret = (g_strcmp0 (g_value_get_string (a), g_value_get_string (b)) == 0);
        break;
      case G_TYPE_VARIANT:
        ret = _g_variant_equal0 (g_value_get_variant (a), g_value_get_variant (b));
        break;
      default:
        if (G_VALUE_TYPE (a) == G_TYPE_STRV)
          ret = _g_strv_equal0 (g_value_get_boxed (a), g_value_get_boxed (b));
        else
          g_critical ("_g_value_equal() does not handle type %s", g_type_name (G_VALUE_TYPE (a)));
        break;
    }
  return ret;
}

static void
_g_dbus_codegen_marshal_VOID__UINT64_STRING_INT (
    GClosure     *closure,
    GValue       *return_value G_GNUC_UNUSED,
    unsigned int  n_param_values,
    const GValue *param_values,
    void         *invocation_hint G_GNUC_UNUSED,
    void         *marshal_data)
{
  typedef void (*_GDbusCodegenMarshalVoid_Uint64StringIntFunc)
       (void *data1,
        guint64 arg_id,
        const gchar *arg_path,
        gint arg_status,
        void *data2);
  _GDbusCodegenMarshalVoid_Uint64StringIntFunc callback;
  GCClosure *cc = (GCClosure*) closure;
  void *data1, *data2;

  g_return_if_fail (n_param_values == 4);

  if (G_CCLOSURE_SWAP_DATA (closure))
    {
      data1 = closure->data;
      data2 = g_value_peek_pointer (param_values + 0);
    }
  else
    {
      data1 = g_value_peek_pointer (param_values + 0);
      data2 = closure->data;
    }

  callback = (_GDbusCodegenMarshalVoid_Uint64StringIntFunc)
    (marshal_data ? marshal_data : cc->callback);

  callback (data1,
            g_marshal_value_peek_uint64 (param_values + 1),
            g_marshal_value_peek_string (param_values + 2),
            g_marshal_value_peek_int (param_values + 3),
            data2);
}

static void
_g_dbus_codegen_marshal_BOOLEAN__OBJECT (
    GClosure     *closure,
    GValue       *return_value,
    unsigned int  n_param_values,
    const GValue *param_values,
    void         *invocation_hint G_GNUC_UNUSED,
    void         *marshal_data)
{
  typedef gboolean (*_GDbusCodegenMarshalBoolean_ObjectFunc)
       (void *data1,
        GDBusMethodInvocation *arg_method_invocation,
        void *data2);
  _GDbusCodegenMarshalBoolean_ObjectFunc callback;
  GCClosure *cc = (GCClosure*) closure;
  void *data1, *data2;
  gboolean v_return;

  g_return_if_fail (return_value != NULL);
  g_return_if_fail (n_param_values == 2);

  if (G_CCLOSURE_SWAP_DATA (closure))
    {
      data1 = closure->data;
      data2 = g_value_peek_pointer (param_values + 0);
    }
  else
    {
      data1 = g_value_peek_pointer (param_values + 0);
      data2 = closure->data;
    }

  callback = (_GDbusCodegenMarshalBoolean_ObjectFunc)
    (marshal_data ? marshal_data : cc->callback);

  v_return =
    callback (data1,
              g_marshal_value_peek_object (param_values + 1),
              data2);

  g_value_set_boolean (return_value, v_return);
}

static void
_g_dbus_codegen_marshal_BOOLEAN__OBJECT_UINT64 (
    GClosure     *closure,
    GValue       *return_value,
    unsigned int  n_param_values,
    const GValue *param_values,
    void         *invocation_hint G_GNUC_UNUSED,
    void         *marshal_data)
{
  typedef gboolean (*_GDbusCodegenMarshalBoolean_ObjectUint64Func)
       (void *data1,
        GDBusMethodInvocation *arg_method_invocation,
        guint64 arg_flags,
        void *data2);
  _GDbusCodegenMarshalBoolean_ObjectUint64Func callback;
  GCClosure *cc = (GCClosure*) closure;
  void *data1, *data2;
  gboolean v_return;

  g_return_if_fail (return_value != NULL);
  g_return_if_fail (n_param_values == 3);

  if (G_CCLOSURE_SWAP_DATA (closure))
    {
      data1 = closure->data;
      data2 = g_value_peek_pointer (param_values + 0);
    }
  else
    {
      data1 = g_value_peek_pointer (param_values + 0);
      data2 = closure->data;
    }

  callback = (_GDbusCodegenMarshalBoolean_ObjectUint64Func)
    (marshal_data ? marshal_data : cc->callback);

  v_return =
    callback (data1,
              g_marshal_value_peek_object (param_values + 1),
              g_marshal_value_peek_uint64 (param_values + 2),
              data2);

  g_value_set_boolean (return_value, v_return);
}

static void
_g_dbus_codegen_marshal_BOOLEAN__OBJECT_STRING_UINT64 (
    GClosure     *closure,
    GValue       *return_value,
    unsigned int  n_param_values,
    const GValue *param_values,
    void         *invocation_hint G_GNUC_UNUSED,
    void         *marshal_data)
{
  typedef gboolean (*_GDbusCodegenMarshalBoolean_ObjectStringUint64Func)
       (void *data1,
        GDBusMethodInvocation *arg_method_invocation,
        const gchar *arg_version,
        guint64 arg_flags,
        void *data2);
  _GDbusCodegenMarshalBoolean_ObjectStringUint64Func callback;
  GCClosure *cc = (GCClosure*) closure;
  void *data1, *data2;
  gboolean v_return;

  g_return_if_fail (return_value != NULL);
  g_return_if_fail (n_param_values == 4);

  if (G_CCLOSURE_SWAP_DATA (closure))
    {
      data1 = closure->data;
      data2 = g_value_peek_pointer (param_values + 0);
    }
  else
    {
      data1 = g_value_peek_pointer (param_values + 0);
      data2 = closure->data;
    }

  callback = (_GDbusCodegenMarshalBoolean_ObjectStringUint64Func)
    (marshal_data ? marshal_data : cc->callback);

  v_return =
    callback (data1,
              g_marshal_value_peek_object (param_values + 1),
              g_marshal_value_peek_string (param_values + 2),
              g_marshal_value_peek_uint64 (param_values + 3),
              data2);

  g_value_set_boolean (return_value, v_return);
}

static void
_g_dbus_codegen_marshal_BOOLEAN__OBJECT_STRING_INT_UINT64 (
    GClosure     *closure,
    GValue       *return_value,
    unsigned int  n_param_values,
    const GValue *param_values,
    void         *invocation_hint G_GNUC_UNUSED,
    void         *marshal_data)
{
  typedef gboolean (*_GDbusCodegenMarshalBoolean_ObjectStringIntUint64Func)
       (void *data1,
        GDBusMethodInvocation *arg_method_invocation,
        const gchar *arg_feature,
        gint arg_enabled,
        guint64 arg_flags,
        void *data2);
  _GDbusCodegenMarshalBoolean_ObjectStringIntUint64Func callback;
  GCClosure *cc = (GCClosure*) closure;
  void *data1, *data2;
  gboolean v_return;

  g_return_if_fail (return_value != NULL);
  g_return_if_fail (n_param_values == 5);

  if (G_CCLOSURE_SWAP_DATA (closure))
    {
      data1 = closure->data;
      data2 = g_value_peek_pointer (param_values + 0);
    }
  else
    {
      data1 = g_value_peek_pointer (param_values + 0);
      data2 = closure->data;
    }

  callback = (_GDbusCodegenMarshalBoolean_ObjectStringIntUint64Func)
    (marshal_data ? marshal_data : cc->callback);

  v_return =
    callback (data1,
              g_marshal_value_peek_object (param_values + 1),
              g_marshal_value_peek_string (param_values + 2),
              g_marshal_value_peek_int (param_values + 3),
              g_marshal_value_peek_uint64 (param_values + 4),
              data2);

  g_value_set_boolean (return_value, v_return);
}

/* ------------------------------------------------------------------------
 * Code for interface org.freedesktop.sysupdate1.Manager
 * ------------------------------------------------------------------------
 */

/**
 * SECTION:MsDBusSysupdateManager
 * @title: MsDBusSysupdateManager
 * @short_description: Generated C code for the org.freedesktop.sysupdate1.Manager D-Bus interface
 *
 * This section contains code for working with the <link linkend="gdbus-interface-org-freedesktop-sysupdate1-Manager.top_of_page">org.freedesktop.sysupdate1.Manager</link> D-Bus interface in C.
 */

enum
{
  MS_DBUS_SYSUPDATE__MANAGER_JOB_REMOVED,
};

static unsigned MS_DBUS_SYSUPDATE__MANAGER_SIGNALS[1] = { 0 };

/* ---- Introspection data for org.freedesktop.sysupdate1.Manager ---- */

static const _ExtendedGDBusArgInfo _ms_dbus_sysupdate_manager_method_info_list_targets_OUT_ARG_targets =
{
  {
    -1,
    (gchar *) "targets",
    (gchar *) "a(sso)",
    NULL
  },
  FALSE
};

static const GDBusArgInfo * const _ms_dbus_sysupdate_manager_method_info_list_targets_OUT_ARG_pointers[] =
{
  &_ms_dbus_sysupdate_manager_method_info_list_targets_OUT_ARG_targets.parent_struct,
  NULL
};

static const _ExtendedGDBusMethodInfo _ms_dbus_sysupdate_manager_method_info_list_targets =
{
  {
    -1,
    (gchar *) "ListTargets",
    NULL,
    (GDBusArgInfo **) &_ms_dbus_sysupdate_manager_method_info_list_targets_OUT_ARG_pointers,
    NULL
  },
  "handle-list-targets",
  FALSE
};

static const _ExtendedGDBusArgInfo _ms_dbus_sysupdate_manager_method_info_list_jobs_OUT_ARG_jobs =
{
  {
    -1,
    (gchar *) "jobs",
    (gchar *) "a(tsuo)",
    NULL
  },
  FALSE
};

static const GDBusArgInfo * const _ms_dbus_sysupdate_manager_method_info_list_jobs_OUT_ARG_pointers[] =
{
  &_ms_dbus_sysupdate_manager_method_info_list_jobs_OUT_ARG_jobs.parent_struct,
  NULL
};

static const _ExtendedGDBusMethodInfo _ms_dbus_sysupdate_manager_method_info_list_jobs =
{
  {
    -1,
    (gchar *) "ListJobs",
    NULL,
    (GDBusArgInfo **) &_ms_dbus_sysupdate_manager_method_info_list_jobs_OUT_ARG_pointers,
    NULL
  },
  "handle-list-jobs",
  FALSE
};

static const _ExtendedGDBusArgInfo _ms_dbus_sysupdate_manager_method_info_list_app_stream_OUT_ARG_urls =
{
  {
    -1,
    (gchar *) "urls",
    (gchar *) "as",
    NULL
  },
  FALSE
};

static const GDBusArgInfo * const _ms_dbus_sysupdate_manager_method_info_list_app_stream_OUT_ARG_pointers[] =
{
  &_ms_dbus_sysupdate_manager_method_info_list_app_stream_OUT_ARG_urls.parent_struct,
  NULL
};

static const _ExtendedGDBusMethodInfo _ms_dbus_sysupdate_manager_method_info_list_app_stream =
{
  {
    -1,
    (gchar *) "ListAppStream",
    NULL,
    (GDBusArgInfo **) &_ms_dbus_sysupdate_manager_method_info_list_app_stream_OUT_ARG_pointers,
    NULL
  },
  "handle-list-app-stream",
  FALSE
};

static const GDBusMethodInfo * const _ms_dbus_sysupdate_manager_method_info_pointers[] =
{
  &_ms_dbus_sysupdate_manager_method_info_list_targets.parent_struct,
  &_ms_dbus_sysupdate_manager_method_info_list_jobs.parent_struct,
  &_ms_dbus_sysupdate_manager_method_info_list_app_stream.parent_struct,
  NULL
};

static const _ExtendedGDBusArgInfo _ms_dbus_sysupdate_manager_signal_info_job_removed_ARG_id =
{
  {
    -1,
    (gchar *) "id",
    (gchar *) "t",
    NULL
  },
  FALSE
};

static const _ExtendedGDBusArgInfo _ms_dbus_sysupdate_manager_signal_info_job_removed_ARG_path =
{
  {
    -1,
    (gchar *) "path",
    (gchar *) "o",
    NULL
  },
  FALSE
};

static const _ExtendedGDBusArgInfo _ms_dbus_sysupdate_manager_signal_info_job_removed_ARG_status =
{
  {
    -1,
    (gchar *) "status",
    (gchar *) "i",
    NULL
  },
  FALSE
};

static const GDBusArgInfo * const _ms_dbus_sysupdate_manager_signal_info_job_removed_ARG_pointers[] =
{
  &_ms_dbus_sysupdate_manager_signal_info_job_removed_ARG_id.parent_struct,
  &_ms_dbus_sysupdate_manager_signal_info_job_removed_ARG_path.parent_struct,
  &_ms_dbus_sysupdate_manager_signal_info_job_removed_ARG_status.parent_struct,
  NULL
};

static const _ExtendedGDBusSignalInfo _ms_dbus_sysupdate_manager_signal_info_job_removed =
{
  {
    -1,
    (gchar *) "JobRemoved",
    (GDBusArgInfo **) &_ms_dbus_sysupdate_manager_signal_info_job_removed_ARG_pointers,
    NULL
  },
  "job-removed"
};

static const GDBusSignalInfo * const _ms_dbus_sysupdate_manager_signal_info_pointers[] =
{
  &_ms_dbus_sysupdate_manager_signal_info_job_removed.parent_struct,
  NULL
};

static const _ExtendedGDBusInterfaceInfo _ms_dbus_sysupdate_manager_interface_info =
{
  {
    -1,
    (gchar *) "org.freedesktop.sysupdate1.Manager",
    (GDBusMethodInfo **) &_ms_dbus_sysupdate_manager_method_info_pointers,
    (GDBusSignalInfo **) &_ms_dbus_sysupdate_manager_signal_info_pointers,
    NULL,
    NULL
  },
  "manager",
};


/**
 * ms_dbus_sysupdate_manager_interface_info:
 *
 * Gets a machine-readable description of the <link linkend="gdbus-interface-org-freedesktop-sysupdate1-Manager.top_of_page">org.freedesktop.sysupdate1.Manager</link> D-Bus interface.
 *
 * Returns: (transfer none): A #GDBusInterfaceInfo. Do not free.
 */
GDBusInterfaceInfo *
ms_dbus_sysupdate_manager_interface_info (void)
{
  return (GDBusInterfaceInfo *) &_ms_dbus_sysupdate_manager_interface_info.parent_struct;
}

/**
 * ms_dbus_sysupdate_manager_override_properties:
 * @klass: The class structure for a #GObject derived class.
 * @property_id_begin: The property id to assign to the first overridden property.
 *
 * Overrides all #GObject properties in the #MsDBusSysupdateManager interface for a concrete class.
 * The properties are overridden in the order they are defined.
 *
 * Returns: The last property id.
 */
guint
ms_dbus_sysupdate_manager_override_properties (GObjectClass *klass G_GNUC_UNUSED, guint property_id_begin)
{
  return property_id_begin - 1;
}


inline static void
ms_dbus_sysupdate_manager_signal_marshal_job_removed (
    GClosure     *closure,
    GValue       *return_value,
    unsigned int  n_param_values,
    const GValue *param_values,
    void         *invocation_hint,
    void         *marshal_data)
{
  _g_dbus_codegen_marshal_VOID__UINT64_STRING_INT (closure,
    return_value, n_param_values, param_values, invocation_hint, marshal_data);
}

inline static void
ms_dbus_sysupdate_manager_method_marshal_list_targets (
    GClosure     *closure,
    GValue       *return_value,
    unsigned int  n_param_values,
    const GValue *param_values,
    void         *invocation_hint,
    void         *marshal_data)
{
  _g_dbus_codegen_marshal_BOOLEAN__OBJECT (closure,
    return_value, n_param_values, param_values, invocation_hint, marshal_data);
}

inline static void
ms_dbus_sysupdate_manager_method_marshal_list_jobs (
    GClosure     *closure,
    GValue       *return_value,
    unsigned int  n_param_values,
    const GValue *param_values,
    void         *invocation_hint,
    void         *marshal_data)
{
  _g_dbus_codegen_marshal_BOOLEAN__OBJECT (closure,
    return_value, n_param_values, param_values, invocation_hint, marshal_data);
}

inline static void
ms_dbus_sysupdate_manager_method_marshal_list_app_stream (
    GClosure     *closure,
    GValue       *return_value,
    unsigned int  n_param_values,
    const GValue *param_values,
    void         *invocation_hint,
    void         *marshal_data)
{
  _g_dbus_codegen_marshal_BOOLEAN__OBJECT (closure,
    return_value, n_param_values, param_values, invocation_hint, marshal_data);
}


/**
 * MsDBusSysupdateManager:
 *
 * Abstract interface type for the D-Bus interface <link linkend="gdbus-interface-org-freedesktop-sysupdate1-Manager.top_of_page">org.freedesktop.sysupdate1.Manager</link>.
 */

/**
 * MsDBusSysupdateManagerIface:
 * @parent_iface: The parent interface.
 * @handle_list_app_stream: Handler for the #MsDBusSysupdateManager::handle-list-app-stream signal.
 * @handle_list_jobs: Handler for the #MsDBusSysupdateManager::handle-list-jobs signal.
 * @handle_list_targets: Handler for the #MsDBusSysupdateManager::handle-list-targets signal.
 * @job_removed: Handler for the #MsDBusSysupdateManager::job-removed signal.
 *
 * Virtual table for the D-Bus interface <link linkend="gdbus-interface-org-freedesktop-sysupdate1-Manager.top_of_page">org.freedesktop.sysupdate1.Manager</link>.
 */

typedef MsDBusSysupdateManagerIface MsDBusSysupdateManagerInterface;
G_DEFINE_INTERFACE (MsDBusSysupdateManager, ms_dbus_sysupdate_manager, G_TYPE_OBJECT)

static void
ms_dbus_sysupdate_manager_default_init (MsDBusSysupdateManagerIface *iface)
{
  /* GObject signals for incoming D-Bus method calls: */
  /**
   * MsDBusSysupdateManager::handle-list-targets:
   * @object: A #MsDBusSysupdateManager.
   * @invocation: A #GDBusMethodInvocation.
   *
   * Signal emitted when a remote caller is invoking the <link linkend="gdbus-method-org-freedesktop-sysupdate1-Manager.ListTargets">ListTargets()</link> D-Bus method.
   *
   * If a signal handler returns %TRUE, it means the signal handler will handle the invocation (e.g. take a reference to @invocation and eventually call ms_dbus_sysupdate_manager_complete_list_targets() or e.g. g_dbus_method_invocation_return_error() on it) and no other signal handlers will run. If no signal handler handles the invocation, the %G_DBUS_ERROR_UNKNOWN_METHOD error is returned.
   *
   * Returns: %G_DBUS_METHOD_INVOCATION_HANDLED or %TRUE if the invocation was handled, %G_DBUS_METHOD_INVOCATION_UNHANDLED or %FALSE to let other signal handlers run.
   */
  g_signal_new ("handle-list-targets",
    G_TYPE_FROM_INTERFACE (iface),
    G_SIGNAL_RUN_LAST,
    G_STRUCT_OFFSET (MsDBusSysupdateManagerIface, handle_list_targets),
    g_signal_accumulator_true_handled,
    NULL,
      ms_dbus_sysupdate_manager_method_marshal_list_targets,
    G_TYPE_BOOLEAN,
    1,
    G_TYPE_DBUS_METHOD_INVOCATION);

  /**
   * MsDBusSysupdateManager::handle-list-jobs:
   * @object: A #MsDBusSysupdateManager.
   * @invocation: A #GDBusMethodInvocation.
   *
   * Signal emitted when a remote caller is invoking the <link linkend="gdbus-method-org-freedesktop-sysupdate1-Manager.ListJobs">ListJobs()</link> D-Bus method.
   *
   * If a signal handler returns %TRUE, it means the signal handler will handle the invocation (e.g. take a reference to @invocation and eventually call ms_dbus_sysupdate_manager_complete_list_jobs() or e.g. g_dbus_method_invocation_return_error() on it) and no other signal handlers will run. If no signal handler handles the invocation, the %G_DBUS_ERROR_UNKNOWN_METHOD error is returned.
   *
   * Returns: %G_DBUS_METHOD_INVOCATION_HANDLED or %TRUE if the invocation was handled, %G_DBUS_METHOD_INVOCATION_UNHANDLED or %FALSE to let other signal handlers run.
   */
  g_signal_new ("handle-list-jobs",
    G_TYPE_FROM_INTERFACE (iface),
    G_SIGNAL_RUN_LAST,
    G_STRUCT_OFFSET (MsDBusSysupdateManagerIface, handle_list_jobs),
    g_signal_accumulator_true_handled,
    NULL,
      ms_dbus_sysupdate_manager_method_marshal_list_jobs,
    G_TYPE_BOOLEAN,
    1,
    G_TYPE_DBUS_METHOD_INVOCATION);

  /**
   * MsDBusSysupdateManager::handle-list-app-stream:
   * @object: A #MsDBusSysupdateManager.
   * @invocation: A #GDBusMethodInvocation.
   *
   * Signal emitted when a remote caller is invoking the <link linkend="gdbus-method-org-freedesktop-sysupdate1-Manager.ListAppStream">ListAppStream()</link> D-Bus method.
   *
   * If a signal handler returns %TRUE, it means the signal handler will handle the invocation (e.g. take a reference to @invocation and eventually call ms_dbus_sysupdate_manager_complete_list_app_stream() or e.g. g_dbus_method_invocation_return_error() on it) and no other signal handlers will run. If no signal handler handles the invocation, the %G_DBUS_ERROR_UNKNOWN_METHOD error is returned.
   *
   * Returns: %G_DBUS_METHOD_INVOCATION_HANDLED or %TRUE if the invocation was handled, %G_DBUS_METHOD_INVOCATION_UNHANDLED or %FALSE to let other signal handlers run.
   */
  g_signal_new ("handle-list-app-stream",
    G_TYPE_FROM_INTERFACE (iface),
    G_SIGNAL_RUN_LAST,
    G_STRUCT_OFFSET (MsDBusSysupdateManagerIface, handle_list_app_stream),
    g_signal_accumulator_true_handled,
    NULL,
      ms_dbus_sysupdate_manager_method_marshal_list_app_stream,
    G_TYPE_BOOLEAN,
    1,
    G_TYPE_DBUS_METHOD_INVOCATION);

  /* GObject signals for received D-Bus signals: */
  /**
   * MsDBusSysupdateManager::job-removed:
   * @object: A #MsDBusSysupdateManager.
   * @arg_id: Argument.
   * @arg_path: Argument.
   * @arg_status: Argument.
   *
   * On the client-side, this signal is emitted whenever the D-Bus signal <link linkend="gdbus-signal-org-freedesktop-sysupdate1-Manager.JobRemoved">"JobRemoved"</link> is received.
   *
   * On the service-side, this signal can be used with e.g. g_signal_emit_by_name() to make the object emit the D-Bus signal.
   */
  MS_DBUS_SYSUPDATE__MANAGER_SIGNALS[MS_DBUS_SYSUPDATE__MANAGER_JOB_REMOVED] =
    g_signal_new ("job-removed",
      G_TYPE_FROM_INTERFACE (iface),
      G_SIGNAL_RUN_LAST,
      G_STRUCT_OFFSET (MsDBusSysupdateManagerIface, job_removed),
      NULL,
      NULL,
      ms_dbus_sysupdate_manager_signal_marshal_job_removed,
      G_TYPE_NONE,
      3, G_TYPE_UINT64, G_TYPE_STRING, G_TYPE_INT);

}

/**
 * ms_dbus_sysupdate_manager_emit_job_removed:
 * @object: A #MsDBusSysupdateManager.
 * @arg_id: Argument to pass with the signal.
 * @arg_path: Argument to pass with the signal.
 * @arg_status: Argument to pass with the signal.
 *
 * Emits the <link linkend="gdbus-signal-org-freedesktop-sysupdate1-Manager.JobRemoved">"JobRemoved"</link> D-Bus signal.
 */
void
ms_dbus_sysupdate_manager_emit_job_removed (
    MsDBusSysupdateManager *object,
    guint64 arg_id,
    const gchar *arg_path,
    gint arg_status)
{
  g_signal_emit (object, MS_DBUS_SYSUPDATE__MANAGER_SIGNALS[MS_DBUS_SYSUPDATE__MANAGER_JOB_REMOVED], 0, arg_id, arg_path, arg_status);
}

/**
 * ms_dbus_sysupdate_manager_call_list_targets:
 * @proxy: A #MsDBusSysupdateManagerProxy.
 * @call_flags: Flags from the #GDBusCallFlags enumeration. If you want to allow interactive
       authorization be sure to set %G_DBUS_CALL_FLAGS_ALLOW_INTERACTIVE_AUTHORIZATION.
 * @timeout_msec: The timeout in milliseconds (with %G_MAXINT meaning "infinite") or
       -1 to use the proxy default timeout.
 * @cancellable: (nullable): A #GCancellable or %NULL.
 * @callback: A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
 * @user_data: User data to pass to @callback.
 *
 * Asynchronously invokes the <link linkend="gdbus-method-org-freedesktop-sysupdate1-Manager.ListTargets">ListTargets()</link> D-Bus method on @proxy.
 * When the operation is finished, @callback will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
 * You can then call ms_dbus_sysupdate_manager_call_list_targets_finish() to get the result of the operation.
 *
 * See ms_dbus_sysupdate_manager_call_list_targets_sync() for the synchronous, blocking version of this method.
 */
void
ms_dbus_sysupdate_manager_call_list_targets (
    MsDBusSysupdateManager *proxy,
    GDBusCallFlags call_flags,
    gint timeout_msec,
    GCancellable *cancellable,
    GAsyncReadyCallback callback,
    gpointer user_data)
{
  g_dbus_proxy_call (G_DBUS_PROXY (proxy),
    "ListTargets",
    g_variant_new ("()"),
    call_flags,
    timeout_msec,
    cancellable,
    callback,
    user_data);
}

/**
 * ms_dbus_sysupdate_manager_call_list_targets_finish:
 * @proxy: A #MsDBusSysupdateManagerProxy.
 * @out_targets: (out) (optional): Return location for return parameter or %NULL to ignore.
 * @res: The #GAsyncResult obtained from the #GAsyncReadyCallback passed to ms_dbus_sysupdate_manager_call_list_targets().
 * @error: Return location for error or %NULL.
 *
 * Finishes an operation started with ms_dbus_sysupdate_manager_call_list_targets().
 *
 * Returns: (skip): %TRUE if the call succeeded, %FALSE if @error is set.
 */
gboolean
ms_dbus_sysupdate_manager_call_list_targets_finish (
    MsDBusSysupdateManager *proxy,
    GVariant ** out_targets,
    GAsyncResult *res,
    GError **error)
{
  GVariant *_ret;
  _ret = g_dbus_proxy_call_finish (G_DBUS_PROXY (proxy), res, error);
  if (_ret == NULL)
    goto _out;
  g_variant_get (_ret,
                 "(@a(sso))",
                 out_targets);
  g_variant_unref (_ret);
_out:
  return _ret != NULL;
}

/**
 * ms_dbus_sysupdate_manager_call_list_targets_sync:
 * @proxy: A #MsDBusSysupdateManagerProxy.
 * @call_flags: Flags from the #GDBusCallFlags enumeration. If you want to allow interactive
       authorization be sure to set %G_DBUS_CALL_FLAGS_ALLOW_INTERACTIVE_AUTHORIZATION.
 * @timeout_msec: The timeout in milliseconds (with %G_MAXINT meaning "infinite") or
       -1 to use the proxy default timeout.
 * @out_targets: (out) (optional): Return location for return parameter or %NULL to ignore.
 * @cancellable: (nullable): A #GCancellable or %NULL.
 * @error: Return location for error or %NULL.
 *
 * Synchronously invokes the <link linkend="gdbus-method-org-freedesktop-sysupdate1-Manager.ListTargets">ListTargets()</link> D-Bus method on @proxy. The calling thread is blocked until a reply is received.
 *
 * See ms_dbus_sysupdate_manager_call_list_targets() for the asynchronous version of this method.
 *
 * Returns: (skip): %TRUE if the call succeeded, %FALSE if @error is set.
 */
gboolean
ms_dbus_sysupdate_manager_call_list_targets_sync (
    MsDBusSysupdateManager *proxy,
    GDBusCallFlags call_flags,
    gint timeout_msec,
    GVariant ** out_targets,
    GCancellable *cancellable,
    GError **error)
{
  GVariant *_ret;
  _ret = g_dbus_proxy_call_sync (G_DBUS_PROXY (proxy),
    "ListTargets",
    g_variant_new ("()"),
    call_flags,
    timeout_msec,
    cancellable,
    error);
  if (_ret == NULL)
    goto _out;
  g_variant_get (_ret,
                 "(@a(sso))",
                 out_targets);
  g_variant_unref (_ret);
_out:
  return _ret != NULL;
}

/**
 * ms_dbus_sysupdate_manager_call_list_jobs:
 * @proxy: A #MsDBusSysupdateManagerProxy.
 * @call_flags: Flags from the #GDBusCallFlags enumeration. If you want to allow interactive
       authorization be sure to set %G_DBUS_CALL_FLAGS_ALLOW_INTERACTIVE_AUTHORIZATION.
 * @timeout_msec: The timeout in milliseconds (with %G_MAXINT meaning "infinite") or
       -1 to use the proxy default timeout.
 * @cancellable: (nullable): A #GCancellable or %NULL.
 * @callback: A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
 * @user_data: User data to pass to @callback.
 *
 * Asynchronously invokes the <link linkend="gdbus-method-org-freedesktop-sysupdate1-Manager.ListJobs">ListJobs()</link> D-Bus method on @proxy.
 * When the operation is finished, @callback will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
 * You can then call ms_dbus_sysupdate_manager_call_list_jobs_finish() to get the result of the operation.
 *
 * See ms_dbus_sysupdate_manager_call_list_jobs_sync() for the synchronous, blocking version of this method.
 */
void
ms_dbus_sysupdate_manager_call_list_jobs (
    MsDBusSysupdateManager *proxy,
    GDBusCallFlags call_flags,
    gint timeout_msec,
    GCancellable *cancellable,
    GAsyncReadyCallback callback,
    gpointer user_data)
{
  g_dbus_proxy_call (G_DBUS_PROXY (proxy),
    "ListJobs",
    g_variant_new ("()"),
    call_flags,
    timeout_msec,
    cancellable,
    callback,
    user_data);
}

/**
 * ms_dbus_sysupdate_manager_call_list_jobs_finish:
 * @proxy: A #MsDBusSysupdateManagerProxy.
 * @out_jobs: (out) (optional): Return location for return parameter or %NULL to ignore.
 * @res: The #GAsyncResult obtained from the #GAsyncReadyCallback passed to ms_dbus_sysupdate_manager_call_list_jobs().
 * @error: Return location for error or %NULL.
 *
 * Finishes an operation started with ms_dbus_sysupdate_manager_call_list_jobs().
 *
 * Returns: (skip): %TRUE if the call succeeded, %FALSE if @error is set.
 */
gboolean
ms_dbus_sysupdate_manager_call_list_jobs_finish (
    MsDBusSysupdateManager *proxy,
    GVariant ** out_jobs,
    GAsyncResult *res,
    GError **error)
{
  GVariant *_ret;
  _ret = g_dbus_proxy_call_finish (G_DBUS_PROXY (proxy), res, error);
  if (_ret == NULL)
    goto _out;
  g_variant_get (_ret,
                 "(@a(tsuo))",
                 out_jobs);
  g_variant_unref (_ret);
_out:
  return _ret != NULL;
}

/**
 * ms_dbus_sysupdate_manager_call_list_jobs_sync:
 * @proxy: A #MsDBusSysupdateManagerProxy.
 * @call_flags: Flags from the #GDBusCallFlags enumeration. If you want to allow interactive
       authorization be sure to set %G_DBUS_CALL_FLAGS_ALLOW_INTERACTIVE_AUTHORIZATION.
 * @timeout_msec: The timeout in milliseconds (with %G_MAXINT meaning "infinite") or
       -1 to use the proxy default timeout.
 * @out_jobs: (out) (optional): Return location for return parameter or %NULL to ignore.
 * @cancellable: (nullable): A #GCancellable or %NULL.
 * @error: Return location for error or %NULL.
 *
 * Synchronously invokes the <link linkend="gdbus-method-org-freedesktop-sysupdate1-Manager.ListJobs">ListJobs()</link> D-Bus method on @proxy. The calling thread is blocked until a reply is received.
 *
 * See ms_dbus_sysupdate_manager_call_list_jobs() for the asynchronous version of this method.
 *
 * Returns: (skip): %TRUE if the call succeeded, %FALSE if @error is set.
 */
gboolean
ms_dbus_sysupdate_manager_call_list_jobs_sync (
    MsDBusSysupdateManager *proxy,
    GDBusCallFlags call_flags,
    gint timeout_msec,
    GVariant ** out_jobs,
    GCancellable *cancellable,
    GError **error)
{
  GVariant *_ret;
  _ret = g_dbus_proxy_call_sync (G_DBUS_PROXY (proxy),
    "ListJobs",
    g_variant_new ("()"),
    call_flags,
    timeout_msec,
    cancellable,
    error);
  if (_ret == NULL)
    goto _out;
  g_variant_get (_ret,
                 "(@a(tsuo))",
                 out_jobs);
  g_variant_unref (_ret);
_out:
  return _ret != NULL;
}

/**
 * ms_dbus_sysupdate_manager_call_list_app_stream:
 * @proxy: A #MsDBusSysupdateManagerProxy.
 * @call_flags: Flags from the #GDBusCallFlags enumeration. If you want to allow interactive
       authorization be sure to set %G_DBUS_CALL_FLAGS_ALLOW_INTERACTIVE_AUTHORIZATION.
 * @timeout_msec: The timeout in milliseconds (with %G_MAXINT meaning "infinite") or
       -1 to use the proxy default timeout.
 * @cancellable: (nullable): A #GCancellable or %NULL.
 * @callback: A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
 * @user_data: User data to pass to @callback.
 *
 * Asynchronously invokes the <link linkend="gdbus-method-org-freedesktop-sysupdate1-Manager.ListAppStream">ListAppStream()</link> D-Bus method on @proxy.
 * When the operation is finished, @callback will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
 * You can then call ms_dbus_sysupdate_manager_call_list_app_stream_finish() to get the result of the operation.
 *
 * See ms_dbus_sysupdate_manager_call_list_app_stream_sync() for the synchronous, blocking version of this method.
 */
void
ms_dbus_sysupdate_manager_call_list_app_stream (
    MsDBusSysupdateManager *proxy,
    GDBusCallFlags call_flags,
    gint timeout_msec,
    GCancellable *cancellable,
    GAsyncReadyCallback callback,
    gpointer user_data)
{
  g_dbus_proxy_call (G_DBUS_PROXY (proxy),
    "ListAppStream",
    g_variant_new ("()"),
    call_flags,
    timeout_msec,
    cancellable,
    callback,
    user_data);
}

/**
 * ms_dbus_sysupdate_manager_call_list_app_stream_finish:
 * @proxy: A #MsDBusSysupdateManagerProxy.
 * @out_urls: (out) (optional) (array zero-terminated=1): Return location for return parameter or %NULL to ignore.
 * @res: The #GAsyncResult obtained from the #GAsyncReadyCallback passed to ms_dbus_sysupdate_manager_call_list_app_stream().
 * @error: Return location for error or %NULL.
 *
 * Finishes an operation started with ms_dbus_sysupdate_manager_call_list_app_stream().
 *
 * Returns: (skip): %TRUE if the call succeeded, %FALSE if @error is set.
 */
gboolean
ms_dbus_sysupdate_manager_call_list_app_stream_finish (
    MsDBusSysupdateManager *proxy,
    gchar *** out_urls,
    GAsyncResult *res,
    GError **error)
{
  GVariant *_ret;
  _ret = g_dbus_proxy_call_finish (G_DBUS_PROXY (proxy), res, error);
  if (_ret == NULL)
    goto _out;
  g_variant_get (_ret,
                 "(^as)",
                 out_urls);
  g_variant_unref (_ret);
_out:
  return _ret != NULL;
}

/**
 * ms_dbus_sysupdate_manager_call_list_app_stream_sync:
 * @proxy: A #MsDBusSysupdateManagerProxy.
 * @call_flags: Flags from the #GDBusCallFlags enumeration. If you want to allow interactive
       authorization be sure to set %G_DBUS_CALL_FLAGS_ALLOW_INTERACTIVE_AUTHORIZATION.
 * @timeout_msec: The timeout in milliseconds (with %G_MAXINT meaning "infinite") or
       -1 to use the proxy default timeout.
 * @out_urls: (out) (optional) (array zero-terminated=1): Return location for return parameter or %NULL to ignore.
 * @cancellable: (nullable): A #GCancellable or %NULL.
 * @error: Return location for error or %NULL.
 *
 * Synchronously invokes the <link linkend="gdbus-method-org-freedesktop-sysupdate1-Manager.ListAppStream">ListAppStream()</link> D-Bus method on @proxy. The calling thread is blocked until a reply is received.
 *
 * See ms_dbus_sysupdate_manager_call_list_app_stream() for the asynchronous version of this method.
 *
 * Returns: (skip): %TRUE if the call succeeded, %FALSE if @error is set.
 */
gboolean
ms_dbus_sysupdate_manager_call_list_app_stream_sync (
    MsDBusSysupdateManager *proxy,
    GDBusCallFlags call_flags,
    gint timeout_msec,
    gchar *** out_urls,
    GCancellable *cancellable,
    GError **error)
{
  GVariant *_ret;
  _ret = g_dbus_proxy_call_sync (G_DBUS_PROXY (proxy),
    "ListAppStream",
    g_variant_new ("()"),
    call_flags,
    timeout_msec,
    cancellable,
    error);
  if (_ret == NULL)
    goto _out;
  g_variant_get (_ret,
                 "(^as)",
                 out_urls);
  g_variant_unref (_ret);
_out:
  return _ret != NULL;
}

/**
 * ms_dbus_sysupdate_manager_complete_list_targets:
 * @object: A #MsDBusSysupdateManager.
 * @invocation: (transfer full): A #GDBusMethodInvocation.
 * @targets: Parameter to return.
 *
 * Helper function used in service implementations to finish handling invocations of the <link linkend="gdbus-method-org-freedesktop-sysupdate1-Manager.ListTargets">ListTargets()</link> D-Bus method. If you instead want to finish handling an invocation by returning an error, use g_dbus_method_invocation_return_error() or similar.
 *
 * This method will free @invocation, you cannot use it afterwards.
 */
void
ms_dbus_sysupdate_manager_complete_list_targets (
    MsDBusSysupdateManager *object G_GNUC_UNUSED,
    GDBusMethodInvocation *invocation,
    GVariant *targets)
{
  g_dbus_method_invocation_return_value (invocation,
    g_variant_new ("(@a(sso))",
                   targets));
}

/**
 * ms_dbus_sysupdate_manager_complete_list_jobs:
 * @object: A #MsDBusSysupdateManager.
 * @invocation: (transfer full): A #GDBusMethodInvocation.
 * @jobs: Parameter to return.
 *
 * Helper function used in service implementations to finish handling invocations of the <link linkend="gdbus-method-org-freedesktop-sysupdate1-Manager.ListJobs">ListJobs()</link> D-Bus method. If you instead want to finish handling an invocation by returning an error, use g_dbus_method_invocation_return_error() or similar.
 *
 * This method will free @invocation, you cannot use it afterwards.
 */
void
ms_dbus_sysupdate_manager_complete_list_jobs (
    MsDBusSysupdateManager *object G_GNUC_UNUSED,
    GDBusMethodInvocation *invocation,
    GVariant *jobs)
{
  g_dbus_method_invocation_return_value (invocation,
    g_variant_new ("(@a(tsuo))",
                   jobs));
}

/**
 * ms_dbus_sysupdate_manager_complete_list_app_stream:
 * @object: A #MsDBusSysupdateManager.
 * @invocation: (transfer full): A #GDBusMethodInvocation.
 * @urls: Parameter to return.
 *
 * Helper function used in service implementations to finish handling invocations of the <link linkend="gdbus-method-org-freedesktop-sysupdate1-Manager.ListAppStream">ListAppStream()</link> D-Bus method. If you instead want to finish handling an invocation by returning an error, use g_dbus_method_invocation_return_error() or similar.
 *
 * This method will free @invocation, you cannot use it afterwards.
 */
void
ms_dbus_sysupdate_manager_complete_list_app_stream (
    MsDBusSysupdateManager *object G_GNUC_UNUSED,
    GDBusMethodInvocation *invocation,
    const gchar *const *urls)
{
  g_dbus_method_invocation_return_value (invocation,
    g_variant_new ("(^as)",
                   urls));
}

/* ------------------------------------------------------------------------ */

/**
 * MsDBusSysupdateManagerProxy:
 *
 * The #MsDBusSysupdateManagerProxy structure contains only private data and should only be accessed using the provided API.
 */

/**
 * MsDBusSysupdateManagerProxyClass:
 * @parent_class: The parent class.
 *
 * Class structure for #MsDBusSysupdateManagerProxy.
 */

struct _MsDBusSysupdateManagerProxyPrivate
{
  GData *qdata;
};

static void ms_dbus_sysupdate_manager_proxy_iface_init (MsDBusSysupdateManagerIface *iface);

#if GLIB_VERSION_MAX_ALLOWED >= GLIB_VERSION_2_38
G_DEFINE_TYPE_WITH_CODE (MsDBusSysupdateManagerProxy, ms_dbus_sysupdate_manager_proxy, G_TYPE_DBUS_PROXY,
                         G_ADD_PRIVATE (MsDBusSysupdateManagerProxy)
                         G_IMPLEMENT_INTERFACE (MS_DBUS_SYSUPDATE_TYPE_MANAGER, ms_dbus_sysupdate_manager_proxy_iface_init))

#else
G_DEFINE_TYPE_WITH_CODE (MsDBusSysupdateManagerProxy, ms_dbus_sysupdate_manager_proxy, G_TYPE_DBUS_PROXY,
                         G_IMPLEMENT_INTERFACE (MS_DBUS_SYSUPDATE_TYPE_MANAGER, ms_dbus_sysupdate_manager_proxy_iface_init))

#endif
static void
ms_dbus_sysupdate_manager_proxy_finalize (GObject *object)
{
  MsDBusSysupdateManagerProxy *proxy = MS_DBUS_SYSUPDATE_MANAGER_PROXY (object);
  g_datalist_clear (&proxy->priv->qdata);
  G_OBJECT_CLASS (ms_dbus_sysupdate_manager_proxy_parent_class)->finalize (object);
}

static void
ms_dbus_sysupdate_manager_proxy_get_property (GObject      *object G_GNUC_UNUSED,
  guint         prop_id G_GNUC_UNUSED,
  GValue       *value G_GNUC_UNUSED,
  GParamSpec   *pspec G_GNUC_UNUSED)
{
}

static void
ms_dbus_sysupdate_manager_proxy_set_property (GObject      *object G_GNUC_UNUSED,
  guint         prop_id G_GNUC_UNUSED,
  const GValue *value G_GNUC_UNUSED,
  GParamSpec   *pspec G_GNUC_UNUSED)
{
}

static void
ms_dbus_sysupdate_manager_proxy_g_signal (GDBusProxy *proxy,
  const gchar *sender_name G_GNUC_UNUSED,
  const gchar *signal_name,
  GVariant *parameters)
{
  _ExtendedGDBusSignalInfo *info;
  GVariantIter iter;
  GVariant *child;
  GValue *paramv;
  gsize num_params;
  gsize n;
  guint signal_id;
  info = (_ExtendedGDBusSignalInfo *) g_dbus_interface_info_lookup_signal ((GDBusInterfaceInfo *) &_ms_dbus_sysupdate_manager_interface_info.parent_struct, signal_name);
  if (info == NULL)
    return;
  num_params = g_variant_n_children (parameters);
  paramv = g_new0 (GValue, num_params + 1);
  g_value_init (&paramv[0], MS_DBUS_SYSUPDATE_TYPE_MANAGER);
  g_value_set_object (&paramv[0], proxy);
  g_variant_iter_init (&iter, parameters);
  n = 1;
  while ((child = g_variant_iter_next_value (&iter)) != NULL)
    {
      _ExtendedGDBusArgInfo *arg_info = (_ExtendedGDBusArgInfo *) info->parent_struct.args[n - 1];
      if (arg_info->use_gvariant)
        {
          g_value_init (&paramv[n], G_TYPE_VARIANT);
          g_value_set_variant (&paramv[n], child);
          n++;
        }
      else
        g_dbus_gvariant_to_gvalue (child, &paramv[n++]);
      g_variant_unref (child);
    }
  signal_id = g_signal_lookup (info->signal_name, MS_DBUS_SYSUPDATE_TYPE_MANAGER);
  g_signal_emitv (paramv, signal_id, 0, NULL);
  for (n = 0; n < num_params + 1; n++)
    g_value_unset (&paramv[n]);
  g_free (paramv);
}

static void
ms_dbus_sysupdate_manager_proxy_g_properties_changed (GDBusProxy *_proxy,
  GVariant *changed_properties,
  const gchar *const *invalidated_properties)
{
  MsDBusSysupdateManagerProxy *proxy = MS_DBUS_SYSUPDATE_MANAGER_PROXY (_proxy);
  guint n;
  const gchar *key;
  GVariantIter *iter;
  _ExtendedGDBusPropertyInfo *info;
  g_variant_get (changed_properties, "a{sv}", &iter);
  while (g_variant_iter_next (iter, "{&sv}", &key, NULL))
    {
      info = (_ExtendedGDBusPropertyInfo *) g_dbus_interface_info_lookup_property ((GDBusInterfaceInfo *) &_ms_dbus_sysupdate_manager_interface_info.parent_struct, key);
      g_datalist_remove_data (&proxy->priv->qdata, key);
      if (info != NULL)
        g_object_notify (G_OBJECT (proxy), info->hyphen_name);
    }
  g_variant_iter_free (iter);
  for (n = 0; invalidated_properties[n] != NULL; n++)
    {
      info = (_ExtendedGDBusPropertyInfo *) g_dbus_interface_info_lookup_property ((GDBusInterfaceInfo *) &_ms_dbus_sysupdate_manager_interface_info.parent_struct, invalidated_properties[n]);
      g_datalist_remove_data (&proxy->priv->qdata, invalidated_properties[n]);
      if (info != NULL)
        g_object_notify (G_OBJECT (proxy), info->hyphen_name);
    }
}

static void
ms_dbus_sysupdate_manager_proxy_init (MsDBusSysupdateManagerProxy *proxy)
{
#if GLIB_VERSION_MAX_ALLOWED >= GLIB_VERSION_2_38
  proxy->priv = ms_dbus_sysupdate_manager_proxy_get_instance_private (proxy);
#else
  proxy->priv = G_TYPE_INSTANCE_GET_PRIVATE (proxy, MS_DBUS_SYSUPDATE_TYPE_MANAGER_PROXY, MsDBusSysupdateManagerProxyPrivate);
#endif

  g_dbus_proxy_set_interface_info (G_DBUS_PROXY (proxy), ms_dbus_sysupdate_manager_interface_info ());
}

static void
ms_dbus_sysupdate_manager_proxy_class_init (MsDBusSysupdateManagerProxyClass *klass)
{
  GObjectClass *gobject_class;
  GDBusProxyClass *proxy_class;

  gobject_class = G_OBJECT_CLASS (klass);
  gobject_class->finalize     = ms_dbus_sysupdate_manager_proxy_finalize;
  gobject_class->get_property = ms_dbus_sysupdate_manager_proxy_get_property;
  gobject_class->set_property = ms_dbus_sysupdate_manager_proxy_set_property;

  proxy_class = G_DBUS_PROXY_CLASS (klass);
  proxy_class->g_signal = ms_dbus_sysupdate_manager_proxy_g_signal;
  proxy_class->g_properties_changed = ms_dbus_sysupdate_manager_proxy_g_properties_changed;

#if GLIB_VERSION_MAX_ALLOWED < GLIB_VERSION_2_38
  g_type_class_add_private (klass, sizeof (MsDBusSysupdateManagerProxyPrivate));
#endif
}

static void
ms_dbus_sysupdate_manager_proxy_iface_init (MsDBusSysupdateManagerIface *iface G_GNUC_UNUSED)
{
}

/**
 * ms_dbus_sysupdate_manager_proxy_new:
 * @connection: A #GDBusConnection.
 * @flags: Flags from the #GDBusProxyFlags enumeration.
 * @name: (nullable): A bus name (well-known or unique) or %NULL if @connection is not a message bus connection.
 * @object_path: An object path.
 * @cancellable: (nullable): A #GCancellable or %NULL.
 * @callback: A #GAsyncReadyCallback to call when the request is satisfied.
 * @user_data: User data to pass to @callback.
 *
 * Asynchronously creates a proxy for the D-Bus interface <link linkend="gdbus-interface-org-freedesktop-sysupdate1-Manager.top_of_page">org.freedesktop.sysupdate1.Manager</link>. See g_dbus_proxy_new() for more details.
 *
 * When the operation is finished, @callback will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
 * You can then call ms_dbus_sysupdate_manager_proxy_new_finish() to get the result of the operation.
 *
 * See ms_dbus_sysupdate_manager_proxy_new_sync() for the synchronous, blocking version of this constructor.
 */
void
ms_dbus_sysupdate_manager_proxy_new (
    GDBusConnection     *connection,
    GDBusProxyFlags      flags,
    const gchar         *name,
    const gchar         *object_path,
    GCancellable        *cancellable,
    GAsyncReadyCallback  callback,
    gpointer             user_data)
{
  g_async_initable_new_async (MS_DBUS_SYSUPDATE_TYPE_MANAGER_PROXY, G_PRIORITY_DEFAULT, cancellable, callback, user_data, "g-flags", flags, "g-name", name, "g-connection", connection, "g-object-path", object_path, "g-interface-name", "org.freedesktop.sysupdate1.Manager", NULL);
}

/**
 * ms_dbus_sysupdate_manager_proxy_new_finish:
 * @res: The #GAsyncResult obtained from the #GAsyncReadyCallback passed to ms_dbus_sysupdate_manager_proxy_new().
 * @error: Return location for error or %NULL
 *
 * Finishes an operation started with ms_dbus_sysupdate_manager_proxy_new().
 *
 * Returns: (transfer full) (type MsDBusSysupdateManagerProxy): The constructed proxy object or %NULL if @error is set.
 */
MsDBusSysupdateManager *
ms_dbus_sysupdate_manager_proxy_new_finish (
    GAsyncResult        *res,
    GError             **error)
{
  GObject *ret;
  GObject *source_object;
  source_object = g_async_result_get_source_object (res);
  ret = g_async_initable_new_finish (G_ASYNC_INITABLE (source_object), res, error);
  g_object_unref (source_object);
  if (ret != NULL)
    return MS_DBUS_SYSUPDATE_MANAGER (ret);
  else
    return NULL;
}

/**
 * ms_dbus_sysupdate_manager_proxy_new_sync:
 * @connection: A #GDBusConnection.
 * @flags: Flags from the #GDBusProxyFlags enumeration.
 * @name: (nullable): A bus name (well-known or unique) or %NULL if @connection is not a message bus connection.
 * @object_path: An object path.
 * @cancellable: (nullable): A #GCancellable or %NULL.
 * @error: Return location for error or %NULL
 *
 * Synchronously creates a proxy for the D-Bus interface <link linkend="gdbus-interface-org-freedesktop-sysupdate1-Manager.top_of_page">org.freedesktop.sysupdate1.Manager</link>. See g_dbus_proxy_new_sync() for more details.
 *
 * The calling thread is blocked until a reply is received.
 *
 * See ms_dbus_sysupdate_manager_proxy_new() for the asynchronous version of this constructor.
 *
 * Returns: (transfer full) (type MsDBusSysupdateManagerProxy): The constructed proxy object or %NULL if @error is set.
 */
MsDBusSysupdateManager *
ms_dbus_sysupdate_manager_proxy_new_sync (
    GDBusConnection     *connection,
    GDBusProxyFlags      flags,
    const gchar         *name,
    const gchar         *object_path,
    GCancellable        *cancellable,
    GError             **error)
{
  GInitable *ret;
  ret = g_initable_new (MS_DBUS_SYSUPDATE_TYPE_MANAGER_PROXY, cancellable, error, "g-flags", flags, "g-name", name, "g-connection", connection, "g-object-path", object_path, "g-interface-name", "org.freedesktop.sysupdate1.Manager", NULL);
  if (ret != NULL)
    return MS_DBUS_SYSUPDATE_MANAGER (ret);
  else
    return NULL;
}


/**
 * ms_dbus_sysupdate_manager_proxy_new_for_bus:
 * @bus_type: A #GBusType.
 * @flags: Flags from the #GDBusProxyFlags enumeration.
 * @name: A bus name (well-known or unique).
 * @object_path: An object path.
 * @cancellable: (nullable): A #GCancellable or %NULL.
 * @callback: A #GAsyncReadyCallback to call when the request is satisfied.
 * @user_data: User data to pass to @callback.
 *
 * Like ms_dbus_sysupdate_manager_proxy_new() but takes a #GBusType instead of a #GDBusConnection.
 *
 * When the operation is finished, @callback will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
 * You can then call ms_dbus_sysupdate_manager_proxy_new_for_bus_finish() to get the result of the operation.
 *
 * See ms_dbus_sysupdate_manager_proxy_new_for_bus_sync() for the synchronous, blocking version of this constructor.
 */
void
ms_dbus_sysupdate_manager_proxy_new_for_bus (
    GBusType             bus_type,
    GDBusProxyFlags      flags,
    const gchar         *name,
    const gchar         *object_path,
    GCancellable        *cancellable,
    GAsyncReadyCallback  callback,
    gpointer             user_data)
{
  g_async_initable_new_async (MS_DBUS_SYSUPDATE_TYPE_MANAGER_PROXY, G_PRIORITY_DEFAULT, cancellable, callback, user_data, "g-flags", flags, "g-name", name, "g-bus-type", bus_type, "g-object-path", object_path, "g-interface-name", "org.freedesktop.sysupdate1.Manager", NULL);
}

/**
 * ms_dbus_sysupdate_manager_proxy_new_for_bus_finish:
 * @res: The #GAsyncResult obtained from the #GAsyncReadyCallback passed to ms_dbus_sysupdate_manager_proxy_new_for_bus().
 * @error: Return location for error or %NULL
 *
 * Finishes an operation started with ms_dbus_sysupdate_manager_proxy_new_for_bus().
 *
 * Returns: (transfer full) (type MsDBusSysupdateManagerProxy): The constructed proxy object or %NULL if @error is set.
 */
MsDBusSysupdateManager *
ms_dbus_sysupdate_manager_proxy_new_for_bus_finish (
    GAsyncResult        *res,
    GError             **error)
{
  GObject *ret;
  GObject *source_object;
  source_object = g_async_result_get_source_object (res);
  ret = g_async_initable_new_finish (G_ASYNC_INITABLE (source_object), res, error);
  g_object_unref (source_object);
  if (ret != NULL)
    return MS_DBUS_SYSUPDATE_MANAGER (ret);
  else
    return NULL;
}

/**
 * ms_dbus_sysupdate_manager_proxy_new_for_bus_sync:
 * @bus_type: A #GBusType.
 * @flags: Flags from the #GDBusProxyFlags enumeration.
 * @name: A bus name (well-known or unique).
 * @object_path: An object path.
 * @cancellable: (nullable): A #GCancellable or %NULL.
 * @error: Return location for error or %NULL
 *
 * Like ms_dbus_sysupdate_manager_proxy_new_sync() but takes a #GBusType instead of a #GDBusConnection.
 *
 * The calling thread is blocked until a reply is received.
 *
 * See ms_dbus_sysupdate_manager_proxy_new_for_bus() for the asynchronous version of this constructor.
 *
 * Returns: (transfer full) (type MsDBusSysupdateManagerProxy): The constructed proxy object or %NULL if @error is set.
 */
MsDBusSysupdateManager *
ms_dbus_sysupdate_manager_proxy_new_for_bus_sync (
    GBusType             bus_type,
    GDBusProxyFlags      flags,
    const gchar         *name,
    const gchar         *object_path,
    GCancellable        *cancellable,
    GError             **error)
{
  GInitable *ret;
  ret = g_initable_new (MS_DBUS_SYSUPDATE_TYPE_MANAGER_PROXY, cancellable, error, "g-flags", flags, "g-name", name, "g-bus-type", bus_type, "g-object-path", object_path, "g-interface-name", "org.freedesktop.sysupdate1.Manager", NULL);
  if (ret != NULL)
    return MS_DBUS_SYSUPDATE_MANAGER (ret);
  else
    return NULL;
}


/* ------------------------------------------------------------------------ */

/**
 * MsDBusSysupdateManagerSkeleton:
 *
 * The #MsDBusSysupdateManagerSkeleton structure contains only private data and should only be accessed using the provided API.
 */

/**
 * MsDBusSysupdateManagerSkeletonClass:
 * @parent_class: The parent class.
 *
 * Class structure for #MsDBusSysupdateManagerSkeleton.
 */

struct _MsDBusSysupdateManagerSkeletonPrivate
{
  GValue *properties;
  GList *changed_properties;
  GSource *changed_properties_idle_source;
  GMainContext *context;
  GMutex lock;
};

static void
_ms_dbus_sysupdate_manager_skeleton_handle_method_call (
  GDBusConnection *connection G_GNUC_UNUSED,
  const gchar *sender G_GNUC_UNUSED,
  const gchar *object_path G_GNUC_UNUSED,
  const gchar *interface_name,
  const gchar *method_name,
  GVariant *parameters,
  GDBusMethodInvocation *invocation,
  gpointer user_data)
{
  MsDBusSysupdateManagerSkeleton *skeleton = MS_DBUS_SYSUPDATE_MANAGER_SKELETON (user_data);
  _ExtendedGDBusMethodInfo *info;
  GVariantIter iter;
  GVariant *child;
  GValue *paramv;
  gsize num_params;
  guint num_extra;
  gsize n;
  guint signal_id;
  GValue return_value = G_VALUE_INIT;
  info = (_ExtendedGDBusMethodInfo *) g_dbus_method_invocation_get_method_info (invocation);
  g_assert (info != NULL);
  num_params = g_variant_n_children (parameters);
  num_extra = info->pass_fdlist ? 3 : 2;  paramv = g_new0 (GValue, num_params + num_extra);
  n = 0;
  g_value_init (&paramv[n], MS_DBUS_SYSUPDATE_TYPE_MANAGER);
  g_value_set_object (&paramv[n++], skeleton);
  g_value_init (&paramv[n], G_TYPE_DBUS_METHOD_INVOCATION);
  g_value_set_object (&paramv[n++], invocation);
  if (info->pass_fdlist)
    {
#ifdef G_OS_UNIX
      g_value_init (&paramv[n], G_TYPE_UNIX_FD_LIST);
      g_value_set_object (&paramv[n++], g_dbus_message_get_unix_fd_list (g_dbus_method_invocation_get_message (invocation)));
#else
      g_assert_not_reached ();
#endif
    }
  g_variant_iter_init (&iter, parameters);
  while ((child = g_variant_iter_next_value (&iter)) != NULL)
    {
      _ExtendedGDBusArgInfo *arg_info = (_ExtendedGDBusArgInfo *) info->parent_struct.in_args[n - num_extra];
      if (arg_info->use_gvariant)
        {
          g_value_init (&paramv[n], G_TYPE_VARIANT);
          g_value_set_variant (&paramv[n], child);
          n++;
        }
      else
        g_dbus_gvariant_to_gvalue (child, &paramv[n++]);
      g_variant_unref (child);
    }
  signal_id = g_signal_lookup (info->signal_name, MS_DBUS_SYSUPDATE_TYPE_MANAGER);
  g_value_init (&return_value, G_TYPE_BOOLEAN);
  g_signal_emitv (paramv, signal_id, 0, &return_value);
  if (!g_value_get_boolean (&return_value))
    g_dbus_method_invocation_return_error (invocation, G_DBUS_ERROR, G_DBUS_ERROR_UNKNOWN_METHOD, "Method %s is not implemented on interface %s", method_name, interface_name);
  g_value_unset (&return_value);
  for (n = 0; n < num_params + num_extra; n++)
    g_value_unset (&paramv[n]);
  g_free (paramv);
}

static GVariant *
_ms_dbus_sysupdate_manager_skeleton_handle_get_property (
  GDBusConnection *connection G_GNUC_UNUSED,
  const gchar *sender G_GNUC_UNUSED,
  const gchar *object_path G_GNUC_UNUSED,
  const gchar *interface_name G_GNUC_UNUSED,
  const gchar *property_name,
  GError **error,
  gpointer user_data)
{
  MsDBusSysupdateManagerSkeleton *skeleton = MS_DBUS_SYSUPDATE_MANAGER_SKELETON (user_data);
  GValue value = G_VALUE_INIT;
  GParamSpec *pspec;
  _ExtendedGDBusPropertyInfo *info;
  GVariant *ret;
  ret = NULL;
  info = (_ExtendedGDBusPropertyInfo *) g_dbus_interface_info_lookup_property ((GDBusInterfaceInfo *) &_ms_dbus_sysupdate_manager_interface_info.parent_struct, property_name);
  g_assert (info != NULL);
  pspec = g_object_class_find_property (G_OBJECT_GET_CLASS (skeleton), info->hyphen_name);
  if (pspec == NULL)
    {
      g_set_error (error, G_DBUS_ERROR, G_DBUS_ERROR_INVALID_ARGS, "No property with name %s", property_name);
    }
  else
    {
      g_value_init (&value, pspec->value_type);
      g_object_get_property (G_OBJECT (skeleton), info->hyphen_name, &value);
      ret = g_dbus_gvalue_to_gvariant (&value, G_VARIANT_TYPE (info->parent_struct.signature));
      g_value_unset (&value);
    }
  return ret;
}

static gboolean
_ms_dbus_sysupdate_manager_skeleton_handle_set_property (
  GDBusConnection *connection G_GNUC_UNUSED,
  const gchar *sender G_GNUC_UNUSED,
  const gchar *object_path G_GNUC_UNUSED,
  const gchar *interface_name G_GNUC_UNUSED,
  const gchar *property_name,
  GVariant *variant,
  GError **error,
  gpointer user_data)
{
  MsDBusSysupdateManagerSkeleton *skeleton = MS_DBUS_SYSUPDATE_MANAGER_SKELETON (user_data);
  GValue value = G_VALUE_INIT;
  GParamSpec *pspec;
  _ExtendedGDBusPropertyInfo *info;
  gboolean ret;
  ret = FALSE;
  info = (_ExtendedGDBusPropertyInfo *) g_dbus_interface_info_lookup_property ((GDBusInterfaceInfo *) &_ms_dbus_sysupdate_manager_interface_info.parent_struct, property_name);
  g_assert (info != NULL);
  pspec = g_object_class_find_property (G_OBJECT_GET_CLASS (skeleton), info->hyphen_name);
  if (pspec == NULL)
    {
      g_set_error (error, G_DBUS_ERROR, G_DBUS_ERROR_INVALID_ARGS, "No property with name %s", property_name);
    }
  else
    {
      if (info->use_gvariant)
        g_value_set_variant (&value, variant);
      else
        g_dbus_gvariant_to_gvalue (variant, &value);
      g_object_set_property (G_OBJECT (skeleton), info->hyphen_name, &value);
      g_value_unset (&value);
      ret = TRUE;
    }
  return ret;
}

static const GDBusInterfaceVTable _ms_dbus_sysupdate_manager_skeleton_vtable =
{
  _ms_dbus_sysupdate_manager_skeleton_handle_method_call,
  _ms_dbus_sysupdate_manager_skeleton_handle_get_property,
  _ms_dbus_sysupdate_manager_skeleton_handle_set_property,
  {NULL}
};

static GDBusInterfaceInfo *
ms_dbus_sysupdate_manager_skeleton_dbus_interface_get_info (GDBusInterfaceSkeleton *skeleton G_GNUC_UNUSED)
{
  return ms_dbus_sysupdate_manager_interface_info ();
}

static GDBusInterfaceVTable *
ms_dbus_sysupdate_manager_skeleton_dbus_interface_get_vtable (GDBusInterfaceSkeleton *skeleton G_GNUC_UNUSED)
{
  return (GDBusInterfaceVTable *) &_ms_dbus_sysupdate_manager_skeleton_vtable;
}

static GVariant *
ms_dbus_sysupdate_manager_skeleton_dbus_interface_get_properties (GDBusInterfaceSkeleton *_skeleton)
{
  MsDBusSysupdateManagerSkeleton *skeleton = MS_DBUS_SYSUPDATE_MANAGER_SKELETON (_skeleton);

  GVariantBuilder builder;
  guint n;
#if GLIB_VERSION_MAX_ALLOWED >= GLIB_VERSION_2_84
  g_variant_builder_init_static (&builder, G_VARIANT_TYPE ("a{sv}"));
#else
  g_variant_builder_init(&builder, G_VARIANT_TYPE ("a{sv}"));
#endif
  if (_ms_dbus_sysupdate_manager_interface_info.parent_struct.properties == NULL)
    goto out;
  for (n = 0; _ms_dbus_sysupdate_manager_interface_info.parent_struct.properties[n] != NULL; n++)
    {
      GDBusPropertyInfo *info = _ms_dbus_sysupdate_manager_interface_info.parent_struct.properties[n];
      if (info->flags & G_DBUS_PROPERTY_INFO_FLAGS_READABLE)
        {
          GVariant *value;
          value = _ms_dbus_sysupdate_manager_skeleton_handle_get_property (g_dbus_interface_skeleton_get_connection (G_DBUS_INTERFACE_SKELETON (skeleton)), NULL, g_dbus_interface_skeleton_get_object_path (G_DBUS_INTERFACE_SKELETON (skeleton)), "org.freedesktop.sysupdate1.Manager", info->name, NULL, skeleton);
          if (value != NULL)
            {
              g_variant_take_ref (value);
              g_variant_builder_add (&builder, "{sv}", info->name, value);
              g_variant_unref (value);
            }
        }
    }
out:
  return g_variant_builder_end (&builder);
}

static void
ms_dbus_sysupdate_manager_skeleton_dbus_interface_flush (GDBusInterfaceSkeleton *_skeleton G_GNUC_UNUSED)
{
}

static void
_ms_dbus_sysupdate_manager_on_signal_job_removed (
    MsDBusSysupdateManager *object,
    guint64 arg_id,
    const gchar *arg_path,
    gint arg_status)
{
  MsDBusSysupdateManagerSkeleton *skeleton = MS_DBUS_SYSUPDATE_MANAGER_SKELETON (object);

  GList      *connections, *l;
  GVariant   *signal_variant;
  connections = g_dbus_interface_skeleton_get_connections (G_DBUS_INTERFACE_SKELETON (skeleton));

  signal_variant = g_variant_ref_sink (g_variant_new ("(toi)",
                   arg_id,
                   arg_path,
                   arg_status));
  for (l = connections; l != NULL; l = l->next)
    {
      GDBusConnection *connection = l->data;
      g_dbus_connection_emit_signal (connection,
        NULL, g_dbus_interface_skeleton_get_object_path (G_DBUS_INTERFACE_SKELETON (skeleton)), "org.freedesktop.sysupdate1.Manager", "JobRemoved",
        signal_variant, NULL);
    }
  g_variant_unref (signal_variant);
  g_list_free_full (connections, g_object_unref);
}

static void ms_dbus_sysupdate_manager_skeleton_iface_init (MsDBusSysupdateManagerIface *iface);
#if GLIB_VERSION_MAX_ALLOWED >= GLIB_VERSION_2_38
G_DEFINE_TYPE_WITH_CODE (MsDBusSysupdateManagerSkeleton, ms_dbus_sysupdate_manager_skeleton, G_TYPE_DBUS_INTERFACE_SKELETON,
                         G_ADD_PRIVATE (MsDBusSysupdateManagerSkeleton)
                         G_IMPLEMENT_INTERFACE (MS_DBUS_SYSUPDATE_TYPE_MANAGER, ms_dbus_sysupdate_manager_skeleton_iface_init))

#else
G_DEFINE_TYPE_WITH_CODE (MsDBusSysupdateManagerSkeleton, ms_dbus_sysupdate_manager_skeleton, G_TYPE_DBUS_INTERFACE_SKELETON,
                         G_IMPLEMENT_INTERFACE (MS_DBUS_SYSUPDATE_TYPE_MANAGER, ms_dbus_sysupdate_manager_skeleton_iface_init))

#endif
static void
ms_dbus_sysupdate_manager_skeleton_finalize (GObject *object)
{
  MsDBusSysupdateManagerSkeleton *skeleton = MS_DBUS_SYSUPDATE_MANAGER_SKELETON (object);
  g_list_free_full (skeleton->priv->changed_properties, (GDestroyNotify) _changed_property_free);
#if GLIB_VERSION_MAX_ALLOWED >= GLIB_VERSION_2_38
  /* coverity[missing_lock : SUPPRESS] */
  g_clear_pointer (&skeleton->priv->changed_properties_idle_source, g_source_destroy);
#else
  if (skeleton->priv->changed_properties_idle_source != NULL)
    g_source_destroy (skeleton->priv->changed_properties_idle_source);
skeleton->priv->changed_properties_idle_source = NULL;
#endif
  g_main_context_unref (skeleton->priv->context);
  g_mutex_clear (&skeleton->priv->lock);
  G_OBJECT_CLASS (ms_dbus_sysupdate_manager_skeleton_parent_class)->finalize (object);
}

static void
ms_dbus_sysupdate_manager_skeleton_init (MsDBusSysupdateManagerSkeleton *skeleton)
{
#if GLIB_VERSION_MAX_ALLOWED >= GLIB_VERSION_2_38
  skeleton->priv = ms_dbus_sysupdate_manager_skeleton_get_instance_private (skeleton);
#else
  skeleton->priv = G_TYPE_INSTANCE_GET_PRIVATE (skeleton, MS_DBUS_SYSUPDATE_TYPE_MANAGER_SKELETON, MsDBusSysupdateManagerSkeletonPrivate);
#endif

  g_mutex_init (&skeleton->priv->lock);
  skeleton->priv->context = g_main_context_ref_thread_default ();
}

static void
ms_dbus_sysupdate_manager_skeleton_class_init (MsDBusSysupdateManagerSkeletonClass *klass)
{
  GObjectClass *gobject_class;
  GDBusInterfaceSkeletonClass *skeleton_class;

  gobject_class = G_OBJECT_CLASS (klass);
  gobject_class->finalize = ms_dbus_sysupdate_manager_skeleton_finalize;

  skeleton_class = G_DBUS_INTERFACE_SKELETON_CLASS (klass);
  skeleton_class->get_info = ms_dbus_sysupdate_manager_skeleton_dbus_interface_get_info;
  skeleton_class->get_properties = ms_dbus_sysupdate_manager_skeleton_dbus_interface_get_properties;
  skeleton_class->flush = ms_dbus_sysupdate_manager_skeleton_dbus_interface_flush;
  skeleton_class->get_vtable = ms_dbus_sysupdate_manager_skeleton_dbus_interface_get_vtable;

#if GLIB_VERSION_MAX_ALLOWED < GLIB_VERSION_2_38
  g_type_class_add_private (klass, sizeof (MsDBusSysupdateManagerSkeletonPrivate));
#endif
}

static void
ms_dbus_sysupdate_manager_skeleton_iface_init (MsDBusSysupdateManagerIface *iface)
{
  iface->job_removed = _ms_dbus_sysupdate_manager_on_signal_job_removed;
}

/**
 * ms_dbus_sysupdate_manager_skeleton_new:
 *
 * Creates a skeleton object for the D-Bus interface <link linkend="gdbus-interface-org-freedesktop-sysupdate1-Manager.top_of_page">org.freedesktop.sysupdate1.Manager</link>.
 *
 * Returns: (transfer full) (type MsDBusSysupdateManagerSkeleton): The skeleton object.
 */
MsDBusSysupdateManager *
ms_dbus_sysupdate_manager_skeleton_new (void)
{
  return MS_DBUS_SYSUPDATE_MANAGER (g_object_new (MS_DBUS_SYSUPDATE_TYPE_MANAGER_SKELETON, NULL));
}

/* ------------------------------------------------------------------------
 * Code for interface org.freedesktop.sysupdate1.Job
 * ------------------------------------------------------------------------
 */

/**
 * SECTION:MsDBusSysupdateJob
 * @title: MsDBusSysupdateJob
 * @short_description: Generated C code for the org.freedesktop.sysupdate1.Job D-Bus interface
 *
 * This section contains code for working with the <link linkend="gdbus-interface-org-freedesktop-sysupdate1-Job.top_of_page">org.freedesktop.sysupdate1.Job</link> D-Bus interface in C.
 */

/* ---- Introspection data for org.freedesktop.sysupdate1.Job ---- */

static const _ExtendedGDBusMethodInfo _ms_dbus_sysupdate_job_method_info_cancel =
{
  {
    -1,
    (gchar *) "Cancel",
    NULL,
    NULL,
    NULL
  },
  "handle-cancel",
  FALSE
};

static const GDBusMethodInfo * const _ms_dbus_sysupdate_job_method_info_pointers[] =
{
  &_ms_dbus_sysupdate_job_method_info_cancel.parent_struct,
  NULL
};

static const GDBusAnnotationInfo _ms_dbus_sysupdate_job_property_id_annotation_info_0 =
{
  -1,
  (gchar *) "org.freedesktop.DBus.Property.EmitsChangedSignal",
  (gchar *) "const",
  NULL
};

static const GDBusAnnotationInfo * const _ms_dbus_sysupdate_job_property_id_annotation_info_pointers[] =
{
  &_ms_dbus_sysupdate_job_property_id_annotation_info_0,
  NULL
};

static const _ExtendedGDBusPropertyInfo _ms_dbus_sysupdate_job_property_info_id =
{
  {
    -1,
    (gchar *) "Id",
    (gchar *) "t",
    G_DBUS_PROPERTY_INFO_FLAGS_READABLE,
    (GDBusAnnotationInfo **) &_ms_dbus_sysupdate_job_property_id_annotation_info_pointers
  },
  "id",
  FALSE,
  FALSE
};

static const GDBusAnnotationInfo _ms_dbus_sysupdate_job_property_type__annotation_info_0 =
{
  -1,
  (gchar *) "org.freedesktop.DBus.Property.EmitsChangedSignal",
  (gchar *) "const",
  NULL
};

static const GDBusAnnotationInfo * const _ms_dbus_sysupdate_job_property_type__annotation_info_pointers[] =
{
  &_ms_dbus_sysupdate_job_property_type__annotation_info_0,
  NULL
};

static const _ExtendedGDBusPropertyInfo _ms_dbus_sysupdate_job_property_info_type_ =
{
  {
    -1,
    (gchar *) "Type",
    (gchar *) "s",
    G_DBUS_PROPERTY_INFO_FLAGS_READABLE,
    (GDBusAnnotationInfo **) &_ms_dbus_sysupdate_job_property_type__annotation_info_pointers
  },
  "type",
  FALSE,
  FALSE
};

static const GDBusAnnotationInfo _ms_dbus_sysupdate_job_property_offline_annotation_info_0 =
{
  -1,
  (gchar *) "org.freedesktop.DBus.Property.EmitsChangedSignal",
  (gchar *) "const",
  NULL
};

static const GDBusAnnotationInfo * const _ms_dbus_sysupdate_job_property_offline_annotation_info_pointers[] =
{
  &_ms_dbus_sysupdate_job_property_offline_annotation_info_0,
  NULL
};

static const _ExtendedGDBusPropertyInfo _ms_dbus_sysupdate_job_property_info_offline =
{
  {
    -1,
    (gchar *) "Offline",
    (gchar *) "b",
    G_DBUS_PROPERTY_INFO_FLAGS_READABLE,
    (GDBusAnnotationInfo **) &_ms_dbus_sysupdate_job_property_offline_annotation_info_pointers
  },
  "offline",
  FALSE,
  FALSE
};

static const _ExtendedGDBusPropertyInfo _ms_dbus_sysupdate_job_property_info_progress =
{
  {
    -1,
    (gchar *) "Progress",
    (gchar *) "u",
    G_DBUS_PROPERTY_INFO_FLAGS_READABLE,
    NULL
  },
  "progress",
  FALSE,
  TRUE
};

static const GDBusPropertyInfo * const _ms_dbus_sysupdate_job_property_info_pointers[] =
{
  &_ms_dbus_sysupdate_job_property_info_id.parent_struct,
  &_ms_dbus_sysupdate_job_property_info_type_.parent_struct,
  &_ms_dbus_sysupdate_job_property_info_offline.parent_struct,
  &_ms_dbus_sysupdate_job_property_info_progress.parent_struct,
  NULL
};

static const _ExtendedGDBusInterfaceInfo _ms_dbus_sysupdate_job_interface_info =
{
  {
    -1,
    (gchar *) "org.freedesktop.sysupdate1.Job",
    (GDBusMethodInfo **) &_ms_dbus_sysupdate_job_method_info_pointers,
    NULL,
    (GDBusPropertyInfo **) &_ms_dbus_sysupdate_job_property_info_pointers,
    NULL
  },
  "job",
};


/**
 * ms_dbus_sysupdate_job_interface_info:
 *
 * Gets a machine-readable description of the <link linkend="gdbus-interface-org-freedesktop-sysupdate1-Job.top_of_page">org.freedesktop.sysupdate1.Job</link> D-Bus interface.
 *
 * Returns: (transfer none): A #GDBusInterfaceInfo. Do not free.
 */
GDBusInterfaceInfo *
ms_dbus_sysupdate_job_interface_info (void)
{
  return (GDBusInterfaceInfo *) &_ms_dbus_sysupdate_job_interface_info.parent_struct;
}

/**
 * ms_dbus_sysupdate_job_override_properties:
 * @klass: The class structure for a #GObject derived class.
 * @property_id_begin: The property id to assign to the first overridden property.
 *
 * Overrides all #GObject properties in the #MsDBusSysupdateJob interface for a concrete class.
 * The properties are overridden in the order they are defined.
 *
 * Returns: The last property id.
 */
guint
ms_dbus_sysupdate_job_override_properties (GObjectClass *klass, guint property_id_begin)
{
  g_object_class_override_property (klass, property_id_begin++, "id");
  g_object_class_override_property (klass, property_id_begin++, "type");
  g_object_class_override_property (klass, property_id_begin++, "offline");
  g_object_class_override_property (klass, property_id_begin++, "progress");
  return property_id_begin - 1;
}


inline static void
ms_dbus_sysupdate_job_method_marshal_cancel (
    GClosure     *closure,
    GValue       *return_value,
    unsigned int  n_param_values,
    const GValue *param_values,
    void         *invocation_hint,
    void         *marshal_data)
{
  _g_dbus_codegen_marshal_BOOLEAN__OBJECT (closure,
    return_value, n_param_values, param_values, invocation_hint, marshal_data);
}


/**
 * MsDBusSysupdateJob:
 *
 * Abstract interface type for the D-Bus interface <link linkend="gdbus-interface-org-freedesktop-sysupdate1-Job.top_of_page">org.freedesktop.sysupdate1.Job</link>.
 */

/**
 * MsDBusSysupdateJobIface:
 * @parent_iface: The parent interface.
 * @handle_cancel: Handler for the #MsDBusSysupdateJob::handle-cancel signal.
 * @get_id: Getter for the #MsDBusSysupdateJob:id property.
 * @get_offline: Getter for the #MsDBusSysupdateJob:offline property.
 * @get_progress: Getter for the #MsDBusSysupdateJob:progress property.
 * @get_type_: Getter for the #MsDBusSysupdateJob:type property.
 *
 * Virtual table for the D-Bus interface <link linkend="gdbus-interface-org-freedesktop-sysupdate1-Job.top_of_page">org.freedesktop.sysupdate1.Job</link>.
 */

typedef MsDBusSysupdateJobIface MsDBusSysupdateJobInterface;
G_DEFINE_INTERFACE (MsDBusSysupdateJob, ms_dbus_sysupdate_job, G_TYPE_OBJECT)

static void
ms_dbus_sysupdate_job_default_init (MsDBusSysupdateJobIface *iface)
{
  /* GObject signals for incoming D-Bus method calls: */
  /**
   * MsDBusSysupdateJob::handle-cancel:
   * @object: A #MsDBusSysupdateJob.
   * @invocation: A #GDBusMethodInvocation.
   *
   * Signal emitted when a remote caller is invoking the <link linkend="gdbus-method-org-freedesktop-sysupdate1-Job.Cancel">Cancel()</link> D-Bus method.
   *
   * If a signal handler returns %TRUE, it means the signal handler will handle the invocation (e.g. take a reference to @invocation and eventually call ms_dbus_sysupdate_job_complete_cancel() or e.g. g_dbus_method_invocation_return_error() on it) and no other signal handlers will run. If no signal handler handles the invocation, the %G_DBUS_ERROR_UNKNOWN_METHOD error is returned.
   *
   * Returns: %G_DBUS_METHOD_INVOCATION_HANDLED or %TRUE if the invocation was handled, %G_DBUS_METHOD_INVOCATION_UNHANDLED or %FALSE to let other signal handlers run.
   */
  g_signal_new ("handle-cancel",
    G_TYPE_FROM_INTERFACE (iface),
    G_SIGNAL_RUN_LAST,
    G_STRUCT_OFFSET (MsDBusSysupdateJobIface, handle_cancel),
    g_signal_accumulator_true_handled,
    NULL,
      ms_dbus_sysupdate_job_method_marshal_cancel,
    G_TYPE_BOOLEAN,
    1,
    G_TYPE_DBUS_METHOD_INVOCATION);

  /* GObject properties for D-Bus properties: */
  /**
   * MsDBusSysupdateJob:id:
   *
   * Represents the D-Bus property <link linkend="gdbus-property-org-freedesktop-sysupdate1-Job.Id">"Id"</link>.
   *
   * Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
   */
  g_object_interface_install_property (iface,
    g_param_spec_uint64 ("id", "Id", "Id", 0, G_MAXUINT64, 0, G_PARAM_READWRITE | G_PARAM_STATIC_STRINGS));
  /**
   * MsDBusSysupdateJob:type:
   *
   * Represents the D-Bus property <link linkend="gdbus-property-org-freedesktop-sysupdate1-Job.Type">"Type"</link>.
   *
   * Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
   */
  g_object_interface_install_property (iface,
    g_param_spec_string ("type", "Type", "Type", NULL, G_PARAM_READWRITE | G_PARAM_STATIC_STRINGS));
  /**
   * MsDBusSysupdateJob:offline:
   *
   * Represents the D-Bus property <link linkend="gdbus-property-org-freedesktop-sysupdate1-Job.Offline">"Offline"</link>.
   *
   * Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
   */
  g_object_interface_install_property (iface,
    g_param_spec_boolean ("offline", "Offline", "Offline", FALSE, G_PARAM_READWRITE | G_PARAM_STATIC_STRINGS));
  /**
   * MsDBusSysupdateJob:progress:
   *
   * Represents the D-Bus property <link linkend="gdbus-property-org-freedesktop-sysupdate1-Job.Progress">"Progress"</link>.
   *
   * Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
   */
  g_object_interface_install_property (iface,
    g_param_spec_uint ("progress", "Progress", "Progress", 0, G_MAXUINT32, 0, G_PARAM_READWRITE | G_PARAM_STATIC_STRINGS));
}

/**
 * ms_dbus_sysupdate_job_get_id: (skip)
 * @object: A #MsDBusSysupdateJob.
 *
 * Gets the value of the <link linkend="gdbus-property-org-freedesktop-sysupdate1-Job.Id">"Id"</link> D-Bus property.
 *
 * Since this D-Bus property is readable, it is meaningful to use this function on both the client- and service-side.
 *
 * Returns: The property value.
 */
guint64 
ms_dbus_sysupdate_job_get_id (MsDBusSysupdateJob *object)
{
  g_return_val_if_fail (MS_DBUS_SYSUPDATE_IS_JOB (object), 0);

  return MS_DBUS_SYSUPDATE_JOB_GET_IFACE (object)->get_id (object);
}

/**
 * ms_dbus_sysupdate_job_set_id: (skip)
 * @object: A #MsDBusSysupdateJob.
 * @value: The value to set.
 *
 * Sets the <link linkend="gdbus-property-org-freedesktop-sysupdate1-Job.Id">"Id"</link> D-Bus property to @value.
 *
 * Since this D-Bus property is not writable, it is only meaningful to use this function on the service-side.
 */
void
ms_dbus_sysupdate_job_set_id (MsDBusSysupdateJob *object, guint64 value)
{
  g_object_set (G_OBJECT (object), "id", value, NULL);
}

/**
 * ms_dbus_sysupdate_job_get_type_: (skip)
 * @object: A #MsDBusSysupdateJob.
 *
 * Gets the value of the <link linkend="gdbus-property-org-freedesktop-sysupdate1-Job.Type">"Type"</link> D-Bus property.
 *
 * Since this D-Bus property is readable, it is meaningful to use this function on both the client- and service-side.
 *
 * The returned value is only valid until the property changes so on the client-side it is only safe to use this function on the thread where @object was constructed. Use ms_dbus_sysupdate_job_dup_type_() if on another thread.
 *
 * Returns: (transfer none) (nullable): The property value or %NULL if the property is not set. Do not free the returned value, it belongs to @object.
 */
const gchar *
ms_dbus_sysupdate_job_get_type_ (MsDBusSysupdateJob *object)
{
  g_return_val_if_fail (MS_DBUS_SYSUPDATE_IS_JOB (object), NULL);

  return MS_DBUS_SYSUPDATE_JOB_GET_IFACE (object)->get_type_ (object);
}

/**
 * ms_dbus_sysupdate_job_dup_type_: (skip)
 * @object: A #MsDBusSysupdateJob.
 *
 * Gets a copy of the <link linkend="gdbus-property-org-freedesktop-sysupdate1-Job.Type">"Type"</link> D-Bus property.
 *
 * Since this D-Bus property is readable, it is meaningful to use this function on both the client- and service-side.
 *
 * Returns: (transfer full) (nullable): The property value or %NULL if the property is not set. The returned value should be freed with g_free().
 */
gchar *
ms_dbus_sysupdate_job_dup_type_ (MsDBusSysupdateJob *object)
{
  gchar *value;
  g_object_get (G_OBJECT (object), "type", &value, NULL);
  return value;
}

/**
 * ms_dbus_sysupdate_job_set_type_: (skip)
 * @object: A #MsDBusSysupdateJob.
 * @value: The value to set.
 *
 * Sets the <link linkend="gdbus-property-org-freedesktop-sysupdate1-Job.Type">"Type"</link> D-Bus property to @value.
 *
 * Since this D-Bus property is not writable, it is only meaningful to use this function on the service-side.
 */
void
ms_dbus_sysupdate_job_set_type_ (MsDBusSysupdateJob *object, const gchar *value)
{
  g_object_set (G_OBJECT (object), "type", value, NULL);
}

/**
 * ms_dbus_sysupdate_job_get_offline: (skip)
 * @object: A #MsDBusSysupdateJob.
 *
 * Gets the value of the <link linkend="gdbus-property-org-freedesktop-sysupdate1-Job.Offline">"Offline"</link> D-Bus property.
 *
 * Since this D-Bus property is readable, it is meaningful to use this function on both the client- and service-side.
 *
 * Returns: The property value.
 */
gboolean 
ms_dbus_sysupdate_job_get_offline (MsDBusSysupdateJob *object)
{
  g_return_val_if_fail (MS_DBUS_SYSUPDATE_IS_JOB (object), FALSE);

  return MS_DBUS_SYSUPDATE_JOB_GET_IFACE (object)->get_offline (object);
}

/**
 * ms_dbus_sysupdate_job_set_offline: (skip)
 * @object: A #MsDBusSysupdateJob.
 * @value: The value to set.
 *
 * Sets the <link linkend="gdbus-property-org-freedesktop-sysupdate1-Job.Offline">"Offline"</link> D-Bus property to @value.
 *
 * Since this D-Bus property is not writable, it is only meaningful to use this function on the service-side.
 */
void
ms_dbus_sysupdate_job_set_offline (MsDBusSysupdateJob *object, gboolean value)
{
  g_object_set (G_OBJECT (object), "offline", value, NULL);
}

/**
 * ms_dbus_sysupdate_job_get_progress: (skip)
 * @object: A #MsDBusSysupdateJob.
 *
 * Gets the value of the <link linkend="gdbus-property-org-freedesktop-sysupdate1-Job.Progress">"Progress"</link> D-Bus property.
 *
 * Since this D-Bus property is readable, it is meaningful to use this function on both the client- and service-side.
 *
 * Returns: The property value.
 */
guint 
ms_dbus_sysupdate_job_get_progress (MsDBusSysupdateJob *object)
{
  g_return_val_if_fail (MS_DBUS_SYSUPDATE_IS_JOB (object), 0);

  return MS_DBUS_SYSUPDATE_JOB_GET_IFACE (object)->get_progress (object);
}

/**
 * ms_dbus_sysupdate_job_set_progress: (skip)
 * @object: A #MsDBusSysupdateJob.
 * @value: The value to set.
 *
 * Sets the <link linkend="gdbus-property-org-freedesktop-sysupdate1-Job.Progress">"Progress"</link> D-Bus property to @value.
 *
 * Since this D-Bus property is not writable, it is only meaningful to use this function on the service-side.
 */
void
ms_dbus_sysupdate_job_set_progress (MsDBusSysupdateJob *object, guint value)
{
  g_object_set (G_OBJECT (object), "progress", value, NULL);
}

/**
 * ms_dbus_sysupdate_job_call_cancel:
 * @proxy: A #MsDBusSysupdateJobProxy.
 * @call_flags: Flags from the #GDBusCallFlags enumeration. If you want to allow interactive
       authorization be sure to set %G_DBUS_CALL_FLAGS_ALLOW_INTERACTIVE_AUTHORIZATION.
 * @timeout_msec: The timeout in milliseconds (with %G_MAXINT meaning "infinite") or
       -1 to use the proxy default timeout.
 * @cancellable: (nullable): A #GCancellable or %NULL.
 * @callback: A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
 * @user_data: User data to pass to @callback.
 *
 * Asynchronously invokes the <link linkend="gdbus-method-org-freedesktop-sysupdate1-Job.Cancel">Cancel()</link> D-Bus method on @proxy.
 * When the operation is finished, @callback will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
 * You can then call ms_dbus_sysupdate_job_call_cancel_finish() to get the result of the operation.
 *
 * See ms_dbus_sysupdate_job_call_cancel_sync() for the synchronous, blocking version of this method.
 */
void
ms_dbus_sysupdate_job_call_cancel (
    MsDBusSysupdateJob *proxy,
    GDBusCallFlags call_flags,
    gint timeout_msec,
    GCancellable *cancellable,
    GAsyncReadyCallback callback,
    gpointer user_data)
{
  g_dbus_proxy_call (G_DBUS_PROXY (proxy),
    "Cancel",
    g_variant_new ("()"),
    call_flags,
    timeout_msec,
    cancellable,
    callback,
    user_data);
}

/**
 * ms_dbus_sysupdate_job_call_cancel_finish:
 * @proxy: A #MsDBusSysupdateJobProxy.
 * @res: The #GAsyncResult obtained from the #GAsyncReadyCallback passed to ms_dbus_sysupdate_job_call_cancel().
 * @error: Return location for error or %NULL.
 *
 * Finishes an operation started with ms_dbus_sysupdate_job_call_cancel().
 *
 * Returns: (skip): %TRUE if the call succeeded, %FALSE if @error is set.
 */
gboolean
ms_dbus_sysupdate_job_call_cancel_finish (
    MsDBusSysupdateJob *proxy,
    GAsyncResult *res,
    GError **error)
{
  GVariant *_ret;
  _ret = g_dbus_proxy_call_finish (G_DBUS_PROXY (proxy), res, error);
  if (_ret == NULL)
    goto _out;
  g_variant_get (_ret,
                 "()");
  g_variant_unref (_ret);
_out:
  return _ret != NULL;
}

/**
 * ms_dbus_sysupdate_job_call_cancel_sync:
 * @proxy: A #MsDBusSysupdateJobProxy.
 * @call_flags: Flags from the #GDBusCallFlags enumeration. If you want to allow interactive
       authorization be sure to set %G_DBUS_CALL_FLAGS_ALLOW_INTERACTIVE_AUTHORIZATION.
 * @timeout_msec: The timeout in milliseconds (with %G_MAXINT meaning "infinite") or
       -1 to use the proxy default timeout.
 * @cancellable: (nullable): A #GCancellable or %NULL.
 * @error: Return location for error or %NULL.
 *
 * Synchronously invokes the <link linkend="gdbus-method-org-freedesktop-sysupdate1-Job.Cancel">Cancel()</link> D-Bus method on @proxy. The calling thread is blocked until a reply is received.
 *
 * See ms_dbus_sysupdate_job_call_cancel() for the asynchronous version of this method.
 *
 * Returns: (skip): %TRUE if the call succeeded, %FALSE if @error is set.
 */
gboolean
ms_dbus_sysupdate_job_call_cancel_sync (
    MsDBusSysupdateJob *proxy,
    GDBusCallFlags call_flags,
    gint timeout_msec,
    GCancellable *cancellable,
    GError **error)
{
  GVariant *_ret;
  _ret = g_dbus_proxy_call_sync (G_DBUS_PROXY (proxy),
    "Cancel",
    g_variant_new ("()"),
    call_flags,
    timeout_msec,
    cancellable,
    error);
  if (_ret == NULL)
    goto _out;
  g_variant_get (_ret,
                 "()");
  g_variant_unref (_ret);
_out:
  return _ret != NULL;
}

/**
 * ms_dbus_sysupdate_job_complete_cancel:
 * @object: A #MsDBusSysupdateJob.
 * @invocation: (transfer full): A #GDBusMethodInvocation.
 *
 * Helper function used in service implementations to finish handling invocations of the <link linkend="gdbus-method-org-freedesktop-sysupdate1-Job.Cancel">Cancel()</link> D-Bus method. If you instead want to finish handling an invocation by returning an error, use g_dbus_method_invocation_return_error() or similar.
 *
 * This method will free @invocation, you cannot use it afterwards.
 */
void
ms_dbus_sysupdate_job_complete_cancel (
    MsDBusSysupdateJob *object G_GNUC_UNUSED,
    GDBusMethodInvocation *invocation)
{
  g_dbus_method_invocation_return_value (invocation,
    g_variant_new ("()"));
}

/* ------------------------------------------------------------------------ */

/**
 * MsDBusSysupdateJobProxy:
 *
 * The #MsDBusSysupdateJobProxy structure contains only private data and should only be accessed using the provided API.
 */

/**
 * MsDBusSysupdateJobProxyClass:
 * @parent_class: The parent class.
 *
 * Class structure for #MsDBusSysupdateJobProxy.
 */

struct _MsDBusSysupdateJobProxyPrivate
{
  GData *qdata;
};

static void ms_dbus_sysupdate_job_proxy_iface_init (MsDBusSysupdateJobIface *iface);

#if GLIB_VERSION_MAX_ALLOWED >= GLIB_VERSION_2_38
G_DEFINE_TYPE_WITH_CODE (MsDBusSysupdateJobProxy, ms_dbus_sysupdate_job_proxy, G_TYPE_DBUS_PROXY,
                         G_ADD_PRIVATE (MsDBusSysupdateJobProxy)
                         G_IMPLEMENT_INTERFACE (MS_DBUS_SYSUPDATE_TYPE_JOB, ms_dbus_sysupdate_job_proxy_iface_init))

#else
G_DEFINE_TYPE_WITH_CODE (MsDBusSysupdateJobProxy, ms_dbus_sysupdate_job_proxy, G_TYPE_DBUS_PROXY,
                         G_IMPLEMENT_INTERFACE (MS_DBUS_SYSUPDATE_TYPE_JOB, ms_dbus_sysupdate_job_proxy_iface_init))

#endif
static void
ms_dbus_sysupdate_job_proxy_finalize (GObject *object)
{
  MsDBusSysupdateJobProxy *proxy = MS_DBUS_SYSUPDATE_JOB_PROXY (object);
  g_datalist_clear (&proxy->priv->qdata);
  G_OBJECT_CLASS (ms_dbus_sysupdate_job_proxy_parent_class)->finalize (object);
}

static void
ms_dbus_sysupdate_job_proxy_get_property (GObject      *object,
  guint         prop_id,
  GValue       *value,
  GParamSpec   *pspec G_GNUC_UNUSED)
{
  const _ExtendedGDBusPropertyInfo *info;
  GVariant *variant;
  g_assert (prop_id != 0 && prop_id - 1 < 4);
  info = (const _ExtendedGDBusPropertyInfo *) _ms_dbus_sysupdate_job_property_info_pointers[prop_id - 1];
  variant = g_dbus_proxy_get_cached_property (G_DBUS_PROXY (object), info->parent_struct.name);
  if (info->use_gvariant)
    {
      g_value_set_variant (value, variant);
    }
  else
    {
      if (variant != NULL)
        g_dbus_gvariant_to_gvalue (variant, value);
    }
  if (variant != NULL)
    g_variant_unref (variant);
}

static void
ms_dbus_sysupdate_job_proxy_set_property_cb (GDBusProxy *proxy,
  GAsyncResult *res,
  gpointer      user_data)
{
  const _ExtendedGDBusPropertyInfo *info = user_data;
  GError *error;
  GVariant *_ret;
  error = NULL;
  _ret = g_dbus_proxy_call_finish (proxy, res, &error);
  if (!_ret)
    {
      g_warning ("Error setting property '%s' on interface org.freedesktop.sysupdate1.Job: %s (%s, %d)",
                 info->parent_struct.name, 
                 error->message, g_quark_to_string (error->domain), error->code);
      g_error_free (error);
    }
  else
    {
      g_variant_unref (_ret);
    }
}

static void
ms_dbus_sysupdate_job_proxy_set_property (GObject      *object,
  guint         prop_id,
  const GValue *value,
  GParamSpec   *pspec G_GNUC_UNUSED)
{
  const _ExtendedGDBusPropertyInfo *info;
  GVariant *variant;
  g_assert (prop_id != 0 && prop_id - 1 < 4);
  info = (const _ExtendedGDBusPropertyInfo *) _ms_dbus_sysupdate_job_property_info_pointers[prop_id - 1];
  variant = g_dbus_gvalue_to_gvariant (value, G_VARIANT_TYPE (info->parent_struct.signature));
  g_dbus_proxy_call (G_DBUS_PROXY (object),
    "org.freedesktop.DBus.Properties.Set",
    g_variant_new ("(ssv)", "org.freedesktop.sysupdate1.Job", info->parent_struct.name, variant),
    G_DBUS_CALL_FLAGS_NONE,
    -1,
    NULL, (GAsyncReadyCallback) ms_dbus_sysupdate_job_proxy_set_property_cb, (GDBusPropertyInfo *) &info->parent_struct);
  g_variant_unref (variant);
}

static void
ms_dbus_sysupdate_job_proxy_g_signal (GDBusProxy *proxy,
  const gchar *sender_name G_GNUC_UNUSED,
  const gchar *signal_name,
  GVariant *parameters)
{
  _ExtendedGDBusSignalInfo *info;
  GVariantIter iter;
  GVariant *child;
  GValue *paramv;
  gsize num_params;
  gsize n;
  guint signal_id;
  info = (_ExtendedGDBusSignalInfo *) g_dbus_interface_info_lookup_signal ((GDBusInterfaceInfo *) &_ms_dbus_sysupdate_job_interface_info.parent_struct, signal_name);
  if (info == NULL)
    return;
  num_params = g_variant_n_children (parameters);
  paramv = g_new0 (GValue, num_params + 1);
  g_value_init (&paramv[0], MS_DBUS_SYSUPDATE_TYPE_JOB);
  g_value_set_object (&paramv[0], proxy);
  g_variant_iter_init (&iter, parameters);
  n = 1;
  while ((child = g_variant_iter_next_value (&iter)) != NULL)
    {
      _ExtendedGDBusArgInfo *arg_info = (_ExtendedGDBusArgInfo *) info->parent_struct.args[n - 1];
      if (arg_info->use_gvariant)
        {
          g_value_init (&paramv[n], G_TYPE_VARIANT);
          g_value_set_variant (&paramv[n], child);
          n++;
        }
      else
        g_dbus_gvariant_to_gvalue (child, &paramv[n++]);
      g_variant_unref (child);
    }
  signal_id = g_signal_lookup (info->signal_name, MS_DBUS_SYSUPDATE_TYPE_JOB);
  g_signal_emitv (paramv, signal_id, 0, NULL);
  for (n = 0; n < num_params + 1; n++)
    g_value_unset (&paramv[n]);
  g_free (paramv);
}

static void
ms_dbus_sysupdate_job_proxy_g_properties_changed (GDBusProxy *_proxy,
  GVariant *changed_properties,
  const gchar *const *invalidated_properties)
{
  MsDBusSysupdateJobProxy *proxy = MS_DBUS_SYSUPDATE_JOB_PROXY (_proxy);
  guint n;
  const gchar *key;
  GVariantIter *iter;
  _ExtendedGDBusPropertyInfo *info;
  g_variant_get (changed_properties, "a{sv}", &iter);
  while (g_variant_iter_next (iter, "{&sv}", &key, NULL))
    {
      info = (_ExtendedGDBusPropertyInfo *) g_dbus_interface_info_lookup_property ((GDBusInterfaceInfo *) &_ms_dbus_sysupdate_job_interface_info.parent_struct, key);
      g_datalist_remove_data (&proxy->priv->qdata, key);
      if (info != NULL)
        g_object_notify (G_OBJECT (proxy), info->hyphen_name);
    }
  g_variant_iter_free (iter);
  for (n = 0; invalidated_properties[n] != NULL; n++)
    {
      info = (_ExtendedGDBusPropertyInfo *) g_dbus_interface_info_lookup_property ((GDBusInterfaceInfo *) &_ms_dbus_sysupdate_job_interface_info.parent_struct, invalidated_properties[n]);
      g_datalist_remove_data (&proxy->priv->qdata, invalidated_properties[n]);
      if (info != NULL)
        g_object_notify (G_OBJECT (proxy), info->hyphen_name);
    }
}

static guint64 
ms_dbus_sysupdate_job_proxy_get_id (MsDBusSysupdateJob *object)
{
  MsDBusSysupdateJobProxy *proxy = MS_DBUS_SYSUPDATE_JOB_PROXY (object);
  GVariant *variant;
  guint64 value = 0;
  variant = g_dbus_proxy_get_cached_property (G_DBUS_PROXY (proxy), "Id");
  if (variant != NULL)
    {
      value = g_variant_get_uint64 (variant);
      g_variant_unref (variant);
    }
  return value;
}

static const gchar *
ms_dbus_sysupdate_job_proxy_get_type_ (MsDBusSysupdateJob *object)
{
  MsDBusSysupdateJobProxy *proxy = MS_DBUS_SYSUPDATE_JOB_PROXY (object);
  GVariant *variant;
  const gchar *value = NULL;
  variant = g_dbus_proxy_get_cached_property (G_DBUS_PROXY (proxy), "Type");
  if (variant != NULL)
    {
      value = g_variant_get_string (variant, NULL);
      g_variant_unref (variant);
    }
  return value;
}

static gboolean 
ms_dbus_sysupdate_job_proxy_get_offline (MsDBusSysupdateJob *object)
{
  MsDBusSysupdateJobProxy *proxy = MS_DBUS_SYSUPDATE_JOB_PROXY (object);
  GVariant *variant;
  gboolean value = FALSE;
  variant = g_dbus_proxy_get_cached_property (G_DBUS_PROXY (proxy), "Offline");
  if (variant != NULL)
    {
      value = g_variant_get_boolean (variant);
      g_variant_unref (variant);
    }
  return value;
}

static guint 
ms_dbus_sysupdate_job_proxy_get_progress (MsDBusSysupdateJob *object)
{
  MsDBusSysupdateJobProxy *proxy = MS_DBUS_SYSUPDATE_JOB_PROXY (object);
  GVariant *variant;
  guint value = 0;
  variant = g_dbus_proxy_get_cached_property (G_DBUS_PROXY (proxy), "Progress");
  if (variant != NULL)
    {
      value = g_variant_get_uint32 (variant);
      g_variant_unref (variant);
    }
  return value;
}

static void
ms_dbus_sysupdate_job_proxy_init (MsDBusSysupdateJobProxy *proxy)
{
#if GLIB_VERSION_MAX_ALLOWED >= GLIB_VERSION_2_38
  proxy->priv = ms_dbus_sysupdate_job_proxy_get_instance_private (proxy);
#else
  proxy->priv = G_TYPE_INSTANCE_GET_PRIVATE (proxy, MS_DBUS_SYSUPDATE_TYPE_JOB_PROXY, MsDBusSysupdateJobProxyPrivate);
#endif

  g_dbus_proxy_set_interface_info (G_DBUS_PROXY (proxy), ms_dbus_sysupdate_job_interface_info ());
}

static void
ms_dbus_sysupdate_job_proxy_class_init (MsDBusSysupdateJobProxyClass *klass)
{
  GObjectClass *gobject_class;
  GDBusProxyClass *proxy_class;

  gobject_class = G_OBJECT_CLASS (klass);
  gobject_class->finalize     = ms_dbus_sysupdate_job_proxy_finalize;
  gobject_class->get_property = ms_dbus_sysupdate_job_proxy_get_property;
  gobject_class->set_property = ms_dbus_sysupdate_job_proxy_set_property;

  proxy_class = G_DBUS_PROXY_CLASS (klass);
  proxy_class->g_signal = ms_dbus_sysupdate_job_proxy_g_signal;
  proxy_class->g_properties_changed = ms_dbus_sysupdate_job_proxy_g_properties_changed;

  ms_dbus_sysupdate_job_override_properties (gobject_class, 1);

#if GLIB_VERSION_MAX_ALLOWED < GLIB_VERSION_2_38
  g_type_class_add_private (klass, sizeof (MsDBusSysupdateJobProxyPrivate));
#endif
}

static void
ms_dbus_sysupdate_job_proxy_iface_init (MsDBusSysupdateJobIface *iface)
{
  iface->get_id = ms_dbus_sysupdate_job_proxy_get_id;
  iface->get_type_ = ms_dbus_sysupdate_job_proxy_get_type_;
  iface->get_offline = ms_dbus_sysupdate_job_proxy_get_offline;
  iface->get_progress = ms_dbus_sysupdate_job_proxy_get_progress;
}

/**
 * ms_dbus_sysupdate_job_proxy_new:
 * @connection: A #GDBusConnection.
 * @flags: Flags from the #GDBusProxyFlags enumeration.
 * @name: (nullable): A bus name (well-known or unique) or %NULL if @connection is not a message bus connection.
 * @object_path: An object path.
 * @cancellable: (nullable): A #GCancellable or %NULL.
 * @callback: A #GAsyncReadyCallback to call when the request is satisfied.
 * @user_data: User data to pass to @callback.
 *
 * Asynchronously creates a proxy for the D-Bus interface <link linkend="gdbus-interface-org-freedesktop-sysupdate1-Job.top_of_page">org.freedesktop.sysupdate1.Job</link>. See g_dbus_proxy_new() for more details.
 *
 * When the operation is finished, @callback will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
 * You can then call ms_dbus_sysupdate_job_proxy_new_finish() to get the result of the operation.
 *
 * See ms_dbus_sysupdate_job_proxy_new_sync() for the synchronous, blocking version of this constructor.
 */
void
ms_dbus_sysupdate_job_proxy_new (
    GDBusConnection     *connection,
    GDBusProxyFlags      flags,
    const gchar         *name,
    const gchar         *object_path,
    GCancellable        *cancellable,
    GAsyncReadyCallback  callback,
    gpointer             user_data)
{
  g_async_initable_new_async (MS_DBUS_SYSUPDATE_TYPE_JOB_PROXY, G_PRIORITY_DEFAULT, cancellable, callback, user_data, "g-flags", flags, "g-name", name, "g-connection", connection, "g-object-path", object_path, "g-interface-name", "org.freedesktop.sysupdate1.Job", NULL);
}

/**
 * ms_dbus_sysupdate_job_proxy_new_finish:
 * @res: The #GAsyncResult obtained from the #GAsyncReadyCallback passed to ms_dbus_sysupdate_job_proxy_new().
 * @error: Return location for error or %NULL
 *
 * Finishes an operation started with ms_dbus_sysupdate_job_proxy_new().
 *
 * Returns: (transfer full) (type MsDBusSysupdateJobProxy): The constructed proxy object or %NULL if @error is set.
 */
MsDBusSysupdateJob *
ms_dbus_sysupdate_job_proxy_new_finish (
    GAsyncResult        *res,
    GError             **error)
{
  GObject *ret;
  GObject *source_object;
  source_object = g_async_result_get_source_object (res);
  ret = g_async_initable_new_finish (G_ASYNC_INITABLE (source_object), res, error);
  g_object_unref (source_object);
  if (ret != NULL)
    return MS_DBUS_SYSUPDATE_JOB (ret);
  else
    return NULL;
}

/**
 * ms_dbus_sysupdate_job_proxy_new_sync:
 * @connection: A #GDBusConnection.
 * @flags: Flags from the #GDBusProxyFlags enumeration.
 * @name: (nullable): A bus name (well-known or unique) or %NULL if @connection is not a message bus connection.
 * @object_path: An object path.
 * @cancellable: (nullable): A #GCancellable or %NULL.
 * @error: Return location for error or %NULL
 *
 * Synchronously creates a proxy for the D-Bus interface <link linkend="gdbus-interface-org-freedesktop-sysupdate1-Job.top_of_page">org.freedesktop.sysupdate1.Job</link>. See g_dbus_proxy_new_sync() for more details.
 *
 * The calling thread is blocked until a reply is received.
 *
 * See ms_dbus_sysupdate_job_proxy_new() for the asynchronous version of this constructor.
 *
 * Returns: (transfer full) (type MsDBusSysupdateJobProxy): The constructed proxy object or %NULL if @error is set.
 */
MsDBusSysupdateJob *
ms_dbus_sysupdate_job_proxy_new_sync (
    GDBusConnection     *connection,
    GDBusProxyFlags      flags,
    const gchar         *name,
    const gchar         *object_path,
    GCancellable        *cancellable,
    GError             **error)
{
  GInitable *ret;
  ret = g_initable_new (MS_DBUS_SYSUPDATE_TYPE_JOB_PROXY, cancellable, error, "g-flags", flags, "g-name", name, "g-connection", connection, "g-object-path", object_path, "g-interface-name", "org.freedesktop.sysupdate1.Job", NULL);
  if (ret != NULL)
    return MS_DBUS_SYSUPDATE_JOB (ret);
  else
    return NULL;
}


/**
 * ms_dbus_sysupdate_job_proxy_new_for_bus:
 * @bus_type: A #GBusType.
 * @flags: Flags from the #GDBusProxyFlags enumeration.
 * @name: A bus name (well-known or unique).
 * @object_path: An object path.
 * @cancellable: (nullable): A #GCancellable or %NULL.
 * @callback: A #GAsyncReadyCallback to call when the request is satisfied.
 * @user_data: User data to pass to @callback.
 *
 * Like ms_dbus_sysupdate_job_proxy_new() but takes a #GBusType instead of a #GDBusConnection.
 *
 * When the operation is finished, @callback will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
 * You can then call ms_dbus_sysupdate_job_proxy_new_for_bus_finish() to get the result of the operation.
 *
 * See ms_dbus_sysupdate_job_proxy_new_for_bus_sync() for the synchronous, blocking version of this constructor.
 */
void
ms_dbus_sysupdate_job_proxy_new_for_bus (
    GBusType             bus_type,
    GDBusProxyFlags      flags,
    const gchar         *name,
    const gchar         *object_path,
    GCancellable        *cancellable,
    GAsyncReadyCallback  callback,
    gpointer             user_data)
{
  g_async_initable_new_async (MS_DBUS_SYSUPDATE_TYPE_JOB_PROXY, G_PRIORITY_DEFAULT, cancellable, callback, user_data, "g-flags", flags, "g-name", name, "g-bus-type", bus_type, "g-object-path", object_path, "g-interface-name", "org.freedesktop.sysupdate1.Job", NULL);
}

/**
 * ms_dbus_sysupdate_job_proxy_new_for_bus_finish:
 * @res: The #GAsyncResult obtained from the #GAsyncReadyCallback passed to ms_dbus_sysupdate_job_proxy_new_for_bus().
 * @error: Return location for error or %NULL
 *
 * Finishes an operation started with ms_dbus_sysupdate_job_proxy_new_for_bus().
 *
 * Returns: (transfer full) (type MsDBusSysupdateJobProxy): The constructed proxy object or %NULL if @error is set.
 */
MsDBusSysupdateJob *
ms_dbus_sysupdate_job_proxy_new_for_bus_finish (
    GAsyncResult        *res,
    GError             **error)
{
  GObject *ret;
  GObject *source_object;
  source_object = g_async_result_get_source_object (res);
  ret = g_async_initable_new_finish (G_ASYNC_INITABLE (source_object), res, error);
  g_object_unref (source_object);
  if (ret != NULL)
    return MS_DBUS_SYSUPDATE_JOB (ret);
  else
    return NULL;
}

/**
 * ms_dbus_sysupdate_job_proxy_new_for_bus_sync:
 * @bus_type: A #GBusType.
 * @flags: Flags from the #GDBusProxyFlags enumeration.
 * @name: A bus name (well-known or unique).
 * @object_path: An object path.
 * @cancellable: (nullable): A #GCancellable or %NULL.
 * @error: Return location for error or %NULL
 *
 * Like ms_dbus_sysupdate_job_proxy_new_sync() but takes a #GBusType instead of a #GDBusConnection.
 *
 * The calling thread is blocked until a reply is received.
 *
 * See ms_dbus_sysupdate_job_proxy_new_for_bus() for the asynchronous version of this constructor.
 *
 * Returns: (transfer full) (type MsDBusSysupdateJobProxy): The constructed proxy object or %NULL if @error is set.
 */
MsDBusSysupdateJob *
ms_dbus_sysupdate_job_proxy_new_for_bus_sync (
    GBusType             bus_type,
    GDBusProxyFlags      flags,
    const gchar         *name,
    const gchar         *object_path,
    GCancellable        *cancellable,
    GError             **error)
{
  GInitable *ret;
  ret = g_initable_new (MS_DBUS_SYSUPDATE_TYPE_JOB_PROXY, cancellable, error, "g-flags", flags, "g-name", name, "g-bus-type", bus_type, "g-object-path", object_path, "g-interface-name", "org.freedesktop.sysupdate1.Job", NULL);
  if (ret != NULL)
    return MS_DBUS_SYSUPDATE_JOB (ret);
  else
    return NULL;
}


/* ------------------------------------------------------------------------ */

/**
 * MsDBusSysupdateJobSkeleton:
 *
 * The #MsDBusSysupdateJobSkeleton structure contains only private data and should only be accessed using the provided API.
 */

/**
 * MsDBusSysupdateJobSkeletonClass:
 * @parent_class: The parent class.
 *
 * Class structure for #MsDBusSysupdateJobSkeleton.
 */

struct _MsDBusSysupdateJobSkeletonPrivate
{
  GValue *properties;
  GList *changed_properties;
  GSource *changed_properties_idle_source;
  GMainContext *context;
  GMutex lock;
};

static void
_ms_dbus_sysupdate_job_skeleton_handle_method_call (
  GDBusConnection *connection G_GNUC_UNUSED,
  const gchar *sender G_GNUC_UNUSED,
  const gchar *object_path G_GNUC_UNUSED,
  const gchar *interface_name,
  const gchar *method_name,
  GVariant *parameters,
  GDBusMethodInvocation *invocation,
  gpointer user_data)
{
  MsDBusSysupdateJobSkeleton *skeleton = MS_DBUS_SYSUPDATE_JOB_SKELETON (user_data);
  _ExtendedGDBusMethodInfo *info;
  GVariantIter iter;
  GVariant *child;
  GValue *paramv;
  gsize num_params;
  guint num_extra;
  gsize n;
  guint signal_id;
  GValue return_value = G_VALUE_INIT;
  info = (_ExtendedGDBusMethodInfo *) g_dbus_method_invocation_get_method_info (invocation);
  g_assert (info != NULL);
  num_params = g_variant_n_children (parameters);
  num_extra = info->pass_fdlist ? 3 : 2;  paramv = g_new0 (GValue, num_params + num_extra);
  n = 0;
  g_value_init (&paramv[n], MS_DBUS_SYSUPDATE_TYPE_JOB);
  g_value_set_object (&paramv[n++], skeleton);
  g_value_init (&paramv[n], G_TYPE_DBUS_METHOD_INVOCATION);
  g_value_set_object (&paramv[n++], invocation);
  if (info->pass_fdlist)
    {
#ifdef G_OS_UNIX
      g_value_init (&paramv[n], G_TYPE_UNIX_FD_LIST);
      g_value_set_object (&paramv[n++], g_dbus_message_get_unix_fd_list (g_dbus_method_invocation_get_message (invocation)));
#else
      g_assert_not_reached ();
#endif
    }
  g_variant_iter_init (&iter, parameters);
  while ((child = g_variant_iter_next_value (&iter)) != NULL)
    {
      _ExtendedGDBusArgInfo *arg_info = (_ExtendedGDBusArgInfo *) info->parent_struct.in_args[n - num_extra];
      if (arg_info->use_gvariant)
        {
          g_value_init (&paramv[n], G_TYPE_VARIANT);
          g_value_set_variant (&paramv[n], child);
          n++;
        }
      else
        g_dbus_gvariant_to_gvalue (child, &paramv[n++]);
      g_variant_unref (child);
    }
  signal_id = g_signal_lookup (info->signal_name, MS_DBUS_SYSUPDATE_TYPE_JOB);
  g_value_init (&return_value, G_TYPE_BOOLEAN);
  g_signal_emitv (paramv, signal_id, 0, &return_value);
  if (!g_value_get_boolean (&return_value))
    g_dbus_method_invocation_return_error (invocation, G_DBUS_ERROR, G_DBUS_ERROR_UNKNOWN_METHOD, "Method %s is not implemented on interface %s", method_name, interface_name);
  g_value_unset (&return_value);
  for (n = 0; n < num_params + num_extra; n++)
    g_value_unset (&paramv[n]);
  g_free (paramv);
}

static GVariant *
_ms_dbus_sysupdate_job_skeleton_handle_get_property (
  GDBusConnection *connection G_GNUC_UNUSED,
  const gchar *sender G_GNUC_UNUSED,
  const gchar *object_path G_GNUC_UNUSED,
  const gchar *interface_name G_GNUC_UNUSED,
  const gchar *property_name,
  GError **error,
  gpointer user_data)
{
  MsDBusSysupdateJobSkeleton *skeleton = MS_DBUS_SYSUPDATE_JOB_SKELETON (user_data);
  GValue value = G_VALUE_INIT;
  GParamSpec *pspec;
  _ExtendedGDBusPropertyInfo *info;
  GVariant *ret;
  ret = NULL;
  info = (_ExtendedGDBusPropertyInfo *) g_dbus_interface_info_lookup_property ((GDBusInterfaceInfo *) &_ms_dbus_sysupdate_job_interface_info.parent_struct, property_name);
  g_assert (info != NULL);
  pspec = g_object_class_find_property (G_OBJECT_GET_CLASS (skeleton), info->hyphen_name);
  if (pspec == NULL)
    {
      g_set_error (error, G_DBUS_ERROR, G_DBUS_ERROR_INVALID_ARGS, "No property with name %s", property_name);
    }
  else
    {
      g_value_init (&value, pspec->value_type);
      g_object_get_property (G_OBJECT (skeleton), info->hyphen_name, &value);
      ret = g_dbus_gvalue_to_gvariant (&value, G_VARIANT_TYPE (info->parent_struct.signature));
      g_value_unset (&value);
    }
  return ret;
}

static gboolean
_ms_dbus_sysupdate_job_skeleton_handle_set_property (
  GDBusConnection *connection G_GNUC_UNUSED,
  const gchar *sender G_GNUC_UNUSED,
  const gchar *object_path G_GNUC_UNUSED,
  const gchar *interface_name G_GNUC_UNUSED,
  const gchar *property_name,
  GVariant *variant,
  GError **error,
  gpointer user_data)
{
  MsDBusSysupdateJobSkeleton *skeleton = MS_DBUS_SYSUPDATE_JOB_SKELETON (user_data);
  GValue value = G_VALUE_INIT;
  GParamSpec *pspec;
  _ExtendedGDBusPropertyInfo *info;
  gboolean ret;
  ret = FALSE;
  info = (_ExtendedGDBusPropertyInfo *) g_dbus_interface_info_lookup_property ((GDBusInterfaceInfo *) &_ms_dbus_sysupdate_job_interface_info.parent_struct, property_name);
  g_assert (info != NULL);
  pspec = g_object_class_find_property (G_OBJECT_GET_CLASS (skeleton), info->hyphen_name);
  if (pspec == NULL)
    {
      g_set_error (error, G_DBUS_ERROR, G_DBUS_ERROR_INVALID_ARGS, "No property with name %s", property_name);
    }
  else
    {
      if (info->use_gvariant)
        g_value_set_variant (&value, variant);
      else
        g_dbus_gvariant_to_gvalue (variant, &value);
      g_object_set_property (G_OBJECT (skeleton), info->hyphen_name, &value);
      g_value_unset (&value);
      ret = TRUE;
    }
  return ret;
}

static const GDBusInterfaceVTable _ms_dbus_sysupdate_job_skeleton_vtable =
{
  _ms_dbus_sysupdate_job_skeleton_handle_method_call,
  _ms_dbus_sysupdate_job_skeleton_handle_get_property,
  _ms_dbus_sysupdate_job_skeleton_handle_set_property,
  {NULL}
};

static GDBusInterfaceInfo *
ms_dbus_sysupdate_job_skeleton_dbus_interface_get_info (GDBusInterfaceSkeleton *skeleton G_GNUC_UNUSED)
{
  return ms_dbus_sysupdate_job_interface_info ();
}

static GDBusInterfaceVTable *
ms_dbus_sysupdate_job_skeleton_dbus_interface_get_vtable (GDBusInterfaceSkeleton *skeleton G_GNUC_UNUSED)
{
  return (GDBusInterfaceVTable *) &_ms_dbus_sysupdate_job_skeleton_vtable;
}

static GVariant *
ms_dbus_sysupdate_job_skeleton_dbus_interface_get_properties (GDBusInterfaceSkeleton *_skeleton)
{
  MsDBusSysupdateJobSkeleton *skeleton = MS_DBUS_SYSUPDATE_JOB_SKELETON (_skeleton);

  GVariantBuilder builder;
  guint n;
#if GLIB_VERSION_MAX_ALLOWED >= GLIB_VERSION_2_84
  g_variant_builder_init_static (&builder, G_VARIANT_TYPE ("a{sv}"));
#else
  g_variant_builder_init(&builder, G_VARIANT_TYPE ("a{sv}"));
#endif
  if (_ms_dbus_sysupdate_job_interface_info.parent_struct.properties == NULL)
    goto out;
  for (n = 0; _ms_dbus_sysupdate_job_interface_info.parent_struct.properties[n] != NULL; n++)
    {
      GDBusPropertyInfo *info = _ms_dbus_sysupdate_job_interface_info.parent_struct.properties[n];
      if (info->flags & G_DBUS_PROPERTY_INFO_FLAGS_READABLE)
        {
          GVariant *value;
          value = _ms_dbus_sysupdate_job_skeleton_handle_get_property (g_dbus_interface_skeleton_get_connection (G_DBUS_INTERFACE_SKELETON (skeleton)), NULL, g_dbus_interface_skeleton_get_object_path (G_DBUS_INTERFACE_SKELETON (skeleton)), "org.freedesktop.sysupdate1.Job", info->name, NULL, skeleton);
          if (value != NULL)
            {
              g_variant_take_ref (value);
              g_variant_builder_add (&builder, "{sv}", info->name, value);
              g_variant_unref (value);
            }
        }
    }
out:
  return g_variant_builder_end (&builder);
}

static gboolean _ms_dbus_sysupdate_job_emit_changed (gpointer user_data);

static void
ms_dbus_sysupdate_job_skeleton_dbus_interface_flush (GDBusInterfaceSkeleton *_skeleton)
{
  MsDBusSysupdateJobSkeleton *skeleton = MS_DBUS_SYSUPDATE_JOB_SKELETON (_skeleton);
  gboolean emit_changed = FALSE;

  g_mutex_lock (&skeleton->priv->lock);
  if (skeleton->priv->changed_properties_idle_source != NULL)
    {
      g_source_destroy (skeleton->priv->changed_properties_idle_source);
      skeleton->priv->changed_properties_idle_source = NULL;
      emit_changed = TRUE;
    }
  g_mutex_unlock (&skeleton->priv->lock);

  if (emit_changed)
    _ms_dbus_sysupdate_job_emit_changed (skeleton);
}

static void ms_dbus_sysupdate_job_skeleton_iface_init (MsDBusSysupdateJobIface *iface);
#if GLIB_VERSION_MAX_ALLOWED >= GLIB_VERSION_2_38
G_DEFINE_TYPE_WITH_CODE (MsDBusSysupdateJobSkeleton, ms_dbus_sysupdate_job_skeleton, G_TYPE_DBUS_INTERFACE_SKELETON,
                         G_ADD_PRIVATE (MsDBusSysupdateJobSkeleton)
                         G_IMPLEMENT_INTERFACE (MS_DBUS_SYSUPDATE_TYPE_JOB, ms_dbus_sysupdate_job_skeleton_iface_init))

#else
G_DEFINE_TYPE_WITH_CODE (MsDBusSysupdateJobSkeleton, ms_dbus_sysupdate_job_skeleton, G_TYPE_DBUS_INTERFACE_SKELETON,
                         G_IMPLEMENT_INTERFACE (MS_DBUS_SYSUPDATE_TYPE_JOB, ms_dbus_sysupdate_job_skeleton_iface_init))

#endif
static void
ms_dbus_sysupdate_job_skeleton_finalize (GObject *object)
{
  MsDBusSysupdateJobSkeleton *skeleton = MS_DBUS_SYSUPDATE_JOB_SKELETON (object);
  guint n;
  for (n = 0; n < 4; n++)
    g_value_unset (&skeleton->priv->properties[n]);
  g_free (skeleton->priv->properties);
  g_list_free_full (skeleton->priv->changed_properties, (GDestroyNotify) _changed_property_free);
#if GLIB_VERSION_MAX_ALLOWED >= GLIB_VERSION_2_38
  /* coverity[missing_lock : SUPPRESS] */
  g_clear_pointer (&skeleton->priv->changed_properties_idle_source, g_source_destroy);
#else
  if (skeleton->priv->changed_properties_idle_source != NULL)
    g_source_destroy (skeleton->priv->changed_properties_idle_source);
skeleton->priv->changed_properties_idle_source = NULL;
#endif
  g_main_context_unref (skeleton->priv->context);
  g_mutex_clear (&skeleton->priv->lock);
  G_OBJECT_CLASS (ms_dbus_sysupdate_job_skeleton_parent_class)->finalize (object);
}

static void
ms_dbus_sysupdate_job_skeleton_get_property (GObject      *object,
  guint         prop_id,
  GValue       *value,
  GParamSpec   *pspec G_GNUC_UNUSED)
{
  MsDBusSysupdateJobSkeleton *skeleton = MS_DBUS_SYSUPDATE_JOB_SKELETON (object);
  g_assert (prop_id != 0 && prop_id - 1 < 4);
  g_mutex_lock (&skeleton->priv->lock);
  g_value_copy (&skeleton->priv->properties[prop_id - 1], value);
  g_mutex_unlock (&skeleton->priv->lock);
}

static gboolean
_ms_dbus_sysupdate_job_emit_changed (gpointer user_data)
{
  MsDBusSysupdateJobSkeleton *skeleton = MS_DBUS_SYSUPDATE_JOB_SKELETON (user_data);
  GList *l;
  GVariantBuilder builder;
  GVariantBuilder invalidated_builder;
  guint num_changes;

  g_mutex_lock (&skeleton->priv->lock);
#if GLIB_VERSION_MAX_ALLOWED >= GLIB_VERSION_2_84
  g_variant_builder_init_static (&builder, G_VARIANT_TYPE ("a{sv}"));
  g_variant_builder_init_static (&invalidated_builder, G_VARIANT_TYPE ("as"));
#else
  g_variant_builder_init (&builder, G_VARIANT_TYPE ("a{sv}"));
  g_variant_builder_init (&invalidated_builder, G_VARIANT_TYPE ("as"));
#endif
  for (l = skeleton->priv->changed_properties, num_changes = 0; l != NULL; l = l->next)
    {
      ChangedProperty *cp = l->data;
      GVariant *variant;
      const GValue *cur_value;

      cur_value = &skeleton->priv->properties[cp->prop_id - 1];
      if (!_g_value_equal (cur_value, &cp->orig_value))
        {
          variant = g_dbus_gvalue_to_gvariant (cur_value, G_VARIANT_TYPE (cp->info->parent_struct.signature));
          g_variant_builder_add (&builder, "{sv}", cp->info->parent_struct.name, variant);
          g_variant_unref (variant);
          num_changes++;
        }
    }
  if (num_changes > 0)
    {
      GList *connections, *ll;
      GVariant *signal_variant;
      signal_variant = g_variant_ref_sink (g_variant_new ("(sa{sv}as)", "org.freedesktop.sysupdate1.Job",
                                           &builder, &invalidated_builder));
      connections = g_dbus_interface_skeleton_get_connections (G_DBUS_INTERFACE_SKELETON (skeleton));
      for (ll = connections; ll != NULL; ll = ll->next)
        {
          GDBusConnection *connection = ll->data;

          g_dbus_connection_emit_signal (connection,
                                         NULL, g_dbus_interface_skeleton_get_object_path (G_DBUS_INTERFACE_SKELETON (skeleton)),
                                         "org.freedesktop.DBus.Properties",
                                         "PropertiesChanged",
                                         signal_variant,
                                         NULL);
        }
      g_variant_unref (signal_variant);
      g_list_free_full (connections, g_object_unref);
    }
  else
    {
      g_variant_builder_clear (&builder);
      g_variant_builder_clear (&invalidated_builder);
    }
  g_list_free_full (skeleton->priv->changed_properties, (GDestroyNotify) _changed_property_free);
  skeleton->priv->changed_properties = NULL;
  skeleton->priv->changed_properties_idle_source = NULL;
  g_mutex_unlock (&skeleton->priv->lock);
  return FALSE;
}

static void
_ms_dbus_sysupdate_job_schedule_emit_changed (MsDBusSysupdateJobSkeleton *skeleton, const _ExtendedGDBusPropertyInfo *info, guint prop_id, const GValue *orig_value)
{
  ChangedProperty *cp;
  GList *l;
  cp = NULL;
  for (l = skeleton->priv->changed_properties; l != NULL; l = l->next)
    {
      ChangedProperty *i_cp = l->data;
      if (i_cp->info == info)
        {
          cp = i_cp;
          break;
        }
    }
  if (cp == NULL)
    {
      cp = g_new0 (ChangedProperty, 1);
      cp->prop_id = prop_id;
      cp->info = info;
      skeleton->priv->changed_properties = g_list_prepend (skeleton->priv->changed_properties, cp);
      g_value_init (&cp->orig_value, G_VALUE_TYPE (orig_value));
      g_value_copy (orig_value, &cp->orig_value);
    }
}

static void
ms_dbus_sysupdate_job_skeleton_notify (GObject      *object,
  GParamSpec *pspec G_GNUC_UNUSED)
{
  MsDBusSysupdateJobSkeleton *skeleton = MS_DBUS_SYSUPDATE_JOB_SKELETON (object);
  g_mutex_lock (&skeleton->priv->lock);
  if (skeleton->priv->changed_properties != NULL &&
      skeleton->priv->changed_properties_idle_source == NULL)
    {
      skeleton->priv->changed_properties_idle_source = g_idle_source_new ();
      g_source_set_priority (skeleton->priv->changed_properties_idle_source, G_PRIORITY_DEFAULT);
      g_source_set_callback (skeleton->priv->changed_properties_idle_source, _ms_dbus_sysupdate_job_emit_changed, g_object_ref (skeleton), (GDestroyNotify) g_object_unref);
      g_source_set_name (skeleton->priv->changed_properties_idle_source, "[generated] _ms_dbus_sysupdate_job_emit_changed");
      g_source_attach (skeleton->priv->changed_properties_idle_source, skeleton->priv->context);
      g_source_unref (skeleton->priv->changed_properties_idle_source);
    }
  g_mutex_unlock (&skeleton->priv->lock);
}

static void
ms_dbus_sysupdate_job_skeleton_set_property (GObject      *object,
  guint         prop_id,
  const GValue *value,
  GParamSpec   *pspec)
{
  const _ExtendedGDBusPropertyInfo *info;
  MsDBusSysupdateJobSkeleton *skeleton = MS_DBUS_SYSUPDATE_JOB_SKELETON (object);
  g_assert (prop_id != 0 && prop_id - 1 < 4);
  info = (const _ExtendedGDBusPropertyInfo *) _ms_dbus_sysupdate_job_property_info_pointers[prop_id - 1];
  g_mutex_lock (&skeleton->priv->lock);
  g_object_freeze_notify (object);
  if (!_g_value_equal (value, &skeleton->priv->properties[prop_id - 1]))
    {
      if (g_dbus_interface_skeleton_get_connection (G_DBUS_INTERFACE_SKELETON (skeleton)) != NULL &&
          info->emits_changed_signal)
        _ms_dbus_sysupdate_job_schedule_emit_changed (skeleton, info, prop_id, &skeleton->priv->properties[prop_id - 1]);
      g_value_copy (value, &skeleton->priv->properties[prop_id - 1]);
      g_object_notify_by_pspec (object, pspec);
    }
  g_mutex_unlock (&skeleton->priv->lock);
  g_object_thaw_notify (object);
}

static void
ms_dbus_sysupdate_job_skeleton_init (MsDBusSysupdateJobSkeleton *skeleton)
{
#if GLIB_VERSION_MAX_ALLOWED >= GLIB_VERSION_2_38
  skeleton->priv = ms_dbus_sysupdate_job_skeleton_get_instance_private (skeleton);
#else
  skeleton->priv = G_TYPE_INSTANCE_GET_PRIVATE (skeleton, MS_DBUS_SYSUPDATE_TYPE_JOB_SKELETON, MsDBusSysupdateJobSkeletonPrivate);
#endif

  g_mutex_init (&skeleton->priv->lock);
  skeleton->priv->context = g_main_context_ref_thread_default ();
  skeleton->priv->properties = g_new0 (GValue, 4);
  g_value_init (&skeleton->priv->properties[0], G_TYPE_UINT64);
  g_value_init (&skeleton->priv->properties[1], G_TYPE_STRING);
  g_value_init (&skeleton->priv->properties[2], G_TYPE_BOOLEAN);
  g_value_init (&skeleton->priv->properties[3], G_TYPE_UINT);
}

static guint64 
ms_dbus_sysupdate_job_skeleton_get_id (MsDBusSysupdateJob *object)
{
  MsDBusSysupdateJobSkeleton *skeleton = MS_DBUS_SYSUPDATE_JOB_SKELETON (object);
  guint64 value;
  g_mutex_lock (&skeleton->priv->lock);
  value = g_marshal_value_peek_uint64 (&(skeleton->priv->properties[0]));
  g_mutex_unlock (&skeleton->priv->lock);
  return value;
}

static const gchar *
ms_dbus_sysupdate_job_skeleton_get_type_ (MsDBusSysupdateJob *object)
{
  MsDBusSysupdateJobSkeleton *skeleton = MS_DBUS_SYSUPDATE_JOB_SKELETON (object);
  const gchar *value;
  g_mutex_lock (&skeleton->priv->lock);
  value = g_marshal_value_peek_string (&(skeleton->priv->properties[1]));
  g_mutex_unlock (&skeleton->priv->lock);
  return value;
}

static gboolean 
ms_dbus_sysupdate_job_skeleton_get_offline (MsDBusSysupdateJob *object)
{
  MsDBusSysupdateJobSkeleton *skeleton = MS_DBUS_SYSUPDATE_JOB_SKELETON (object);
  gboolean value;
  g_mutex_lock (&skeleton->priv->lock);
  value = g_marshal_value_peek_boolean (&(skeleton->priv->properties[2]));
  g_mutex_unlock (&skeleton->priv->lock);
  return value;
}

static guint 
ms_dbus_sysupdate_job_skeleton_get_progress (MsDBusSysupdateJob *object)
{
  MsDBusSysupdateJobSkeleton *skeleton = MS_DBUS_SYSUPDATE_JOB_SKELETON (object);
  guint value;
  g_mutex_lock (&skeleton->priv->lock);
  value = g_marshal_value_peek_uint (&(skeleton->priv->properties[3]));
  g_mutex_unlock (&skeleton->priv->lock);
  return value;
}

static void
ms_dbus_sysupdate_job_skeleton_class_init (MsDBusSysupdateJobSkeletonClass *klass)
{
  GObjectClass *gobject_class;
  GDBusInterfaceSkeletonClass *skeleton_class;

  gobject_class = G_OBJECT_CLASS (klass);
  gobject_class->finalize = ms_dbus_sysupdate_job_skeleton_finalize;
  gobject_class->get_property = ms_dbus_sysupdate_job_skeleton_get_property;
  gobject_class->set_property = ms_dbus_sysupdate_job_skeleton_set_property;
  gobject_class->notify       = ms_dbus_sysupdate_job_skeleton_notify;


  ms_dbus_sysupdate_job_override_properties (gobject_class, 1);

  skeleton_class = G_DBUS_INTERFACE_SKELETON_CLASS (klass);
  skeleton_class->get_info = ms_dbus_sysupdate_job_skeleton_dbus_interface_get_info;
  skeleton_class->get_properties = ms_dbus_sysupdate_job_skeleton_dbus_interface_get_properties;
  skeleton_class->flush = ms_dbus_sysupdate_job_skeleton_dbus_interface_flush;
  skeleton_class->get_vtable = ms_dbus_sysupdate_job_skeleton_dbus_interface_get_vtable;

#if GLIB_VERSION_MAX_ALLOWED < GLIB_VERSION_2_38
  g_type_class_add_private (klass, sizeof (MsDBusSysupdateJobSkeletonPrivate));
#endif
}

static void
ms_dbus_sysupdate_job_skeleton_iface_init (MsDBusSysupdateJobIface *iface)
{
  iface->get_id = ms_dbus_sysupdate_job_skeleton_get_id;
  iface->get_type_ = ms_dbus_sysupdate_job_skeleton_get_type_;
  iface->get_offline = ms_dbus_sysupdate_job_skeleton_get_offline;
  iface->get_progress = ms_dbus_sysupdate_job_skeleton_get_progress;
}

/**
 * ms_dbus_sysupdate_job_skeleton_new:
 *
 * Creates a skeleton object for the D-Bus interface <link linkend="gdbus-interface-org-freedesktop-sysupdate1-Job.top_of_page">org.freedesktop.sysupdate1.Job</link>.
 *
 * Returns: (transfer full) (type MsDBusSysupdateJobSkeleton): The skeleton object.
 */
MsDBusSysupdateJob *
ms_dbus_sysupdate_job_skeleton_new (void)
{
  return MS_DBUS_SYSUPDATE_JOB (g_object_new (MS_DBUS_SYSUPDATE_TYPE_JOB_SKELETON, NULL));
}

/* ------------------------------------------------------------------------
 * Code for interface org.freedesktop.sysupdate1.Target
 * ------------------------------------------------------------------------
 */

/**
 * SECTION:MsDBusSysupdateTarget
 * @title: MsDBusSysupdateTarget
 * @short_description: Generated C code for the org.freedesktop.sysupdate1.Target D-Bus interface
 *
 * This section contains code for working with the <link linkend="gdbus-interface-org-freedesktop-sysupdate1-Target.top_of_page">org.freedesktop.sysupdate1.Target</link> D-Bus interface in C.
 */

/* ---- Introspection data for org.freedesktop.sysupdate1.Target ---- */

static const _ExtendedGDBusArgInfo _ms_dbus_sysupdate_target_method_info_list_IN_ARG_flags =
{
  {
    -1,
    (gchar *) "flags",
    (gchar *) "t",
    NULL
  },
  FALSE
};

static const GDBusArgInfo * const _ms_dbus_sysupdate_target_method_info_list_IN_ARG_pointers[] =
{
  &_ms_dbus_sysupdate_target_method_info_list_IN_ARG_flags.parent_struct,
  NULL
};

static const _ExtendedGDBusArgInfo _ms_dbus_sysupdate_target_method_info_list_OUT_ARG_versions =
{
  {
    -1,
    (gchar *) "versions",
    (gchar *) "as",
    NULL
  },
  FALSE
};

static const GDBusArgInfo * const _ms_dbus_sysupdate_target_method_info_list_OUT_ARG_pointers[] =
{
  &_ms_dbus_sysupdate_target_method_info_list_OUT_ARG_versions.parent_struct,
  NULL
};

static const _ExtendedGDBusMethodInfo _ms_dbus_sysupdate_target_method_info_list =
{
  {
    -1,
    (gchar *) "List",
    (GDBusArgInfo **) &_ms_dbus_sysupdate_target_method_info_list_IN_ARG_pointers,
    (GDBusArgInfo **) &_ms_dbus_sysupdate_target_method_info_list_OUT_ARG_pointers,
    NULL
  },
  "handle-list",
  FALSE
};

static const _ExtendedGDBusArgInfo _ms_dbus_sysupdate_target_method_info_describe_IN_ARG_version =
{
  {
    -1,
    (gchar *) "version",
    (gchar *) "s",
    NULL
  },
  FALSE
};

static const _ExtendedGDBusArgInfo _ms_dbus_sysupdate_target_method_info_describe_IN_ARG_flags =
{
  {
    -1,
    (gchar *) "flags",
    (gchar *) "t",
    NULL
  },
  FALSE
};

static const GDBusArgInfo * const _ms_dbus_sysupdate_target_method_info_describe_IN_ARG_pointers[] =
{
  &_ms_dbus_sysupdate_target_method_info_describe_IN_ARG_version.parent_struct,
  &_ms_dbus_sysupdate_target_method_info_describe_IN_ARG_flags.parent_struct,
  NULL
};

static const _ExtendedGDBusArgInfo _ms_dbus_sysupdate_target_method_info_describe_OUT_ARG_json =
{
  {
    -1,
    (gchar *) "json",
    (gchar *) "s",
    NULL
  },
  FALSE
};

static const GDBusArgInfo * const _ms_dbus_sysupdate_target_method_info_describe_OUT_ARG_pointers[] =
{
  &_ms_dbus_sysupdate_target_method_info_describe_OUT_ARG_json.parent_struct,
  NULL
};

static const _ExtendedGDBusMethodInfo _ms_dbus_sysupdate_target_method_info_describe =
{
  {
    -1,
    (gchar *) "Describe",
    (GDBusArgInfo **) &_ms_dbus_sysupdate_target_method_info_describe_IN_ARG_pointers,
    (GDBusArgInfo **) &_ms_dbus_sysupdate_target_method_info_describe_OUT_ARG_pointers,
    NULL
  },
  "handle-describe",
  FALSE
};

static const _ExtendedGDBusArgInfo _ms_dbus_sysupdate_target_method_info_check_new_OUT_ARG_new_version =
{
  {
    -1,
    (gchar *) "new_version",
    (gchar *) "s",
    NULL
  },
  FALSE
};

static const GDBusArgInfo * const _ms_dbus_sysupdate_target_method_info_check_new_OUT_ARG_pointers[] =
{
  &_ms_dbus_sysupdate_target_method_info_check_new_OUT_ARG_new_version.parent_struct,
  NULL
};

static const _ExtendedGDBusMethodInfo _ms_dbus_sysupdate_target_method_info_check_new =
{
  {
    -1,
    (gchar *) "CheckNew",
    NULL,
    (GDBusArgInfo **) &_ms_dbus_sysupdate_target_method_info_check_new_OUT_ARG_pointers,
    NULL
  },
  "handle-check-new",
  FALSE
};

static const _ExtendedGDBusArgInfo _ms_dbus_sysupdate_target_method_info_acquire_IN_ARG_new_version =
{
  {
    -1,
    (gchar *) "new_version",
    (gchar *) "s",
    NULL
  },
  FALSE
};

static const _ExtendedGDBusArgInfo _ms_dbus_sysupdate_target_method_info_acquire_IN_ARG_flags =
{
  {
    -1,
    (gchar *) "flags",
    (gchar *) "t",
    NULL
  },
  FALSE
};

static const GDBusArgInfo * const _ms_dbus_sysupdate_target_method_info_acquire_IN_ARG_pointers[] =
{
  &_ms_dbus_sysupdate_target_method_info_acquire_IN_ARG_new_version.parent_struct,
  &_ms_dbus_sysupdate_target_method_info_acquire_IN_ARG_flags.parent_struct,
  NULL
};

static const _ExtendedGDBusArgInfo _ms_dbus_sysupdate_target_method_info_acquire_OUT_ARG_new_version =
{
  {
    -1,
    (gchar *) "new_version",
    (gchar *) "s",
    NULL
  },
  FALSE
};

static const _ExtendedGDBusArgInfo _ms_dbus_sysupdate_target_method_info_acquire_OUT_ARG_job_id =
{
  {
    -1,
    (gchar *) "job_id",
    (gchar *) "t",
    NULL
  },
  FALSE
};

static const _ExtendedGDBusArgInfo _ms_dbus_sysupdate_target_method_info_acquire_OUT_ARG_job_path =
{
  {
    -1,
    (gchar *) "job_path",
    (gchar *) "o",
    NULL
  },
  FALSE
};

static const GDBusArgInfo * const _ms_dbus_sysupdate_target_method_info_acquire_OUT_ARG_pointers[] =
{
  &_ms_dbus_sysupdate_target_method_info_acquire_OUT_ARG_new_version.parent_struct,
  &_ms_dbus_sysupdate_target_method_info_acquire_OUT_ARG_job_id.parent_struct,
  &_ms_dbus_sysupdate_target_method_info_acquire_OUT_ARG_job_path.parent_struct,
  NULL
};

static const _ExtendedGDBusMethodInfo _ms_dbus_sysupdate_target_method_info_acquire =
{
  {
    -1,
    (gchar *) "Acquire",
    (GDBusArgInfo **) &_ms_dbus_sysupdate_target_method_info_acquire_IN_ARG_pointers,
    (GDBusArgInfo **) &_ms_dbus_sysupdate_target_method_info_acquire_OUT_ARG_pointers,
    NULL
  },
  "handle-acquire",
  FALSE
};

static const _ExtendedGDBusArgInfo _ms_dbus_sysupdate_target_method_info_install_IN_ARG_new_version =
{
  {
    -1,
    (gchar *) "new_version",
    (gchar *) "s",
    NULL
  },
  FALSE
};

static const _ExtendedGDBusArgInfo _ms_dbus_sysupdate_target_method_info_install_IN_ARG_flags =
{
  {
    -1,
    (gchar *) "flags",
    (gchar *) "t",
    NULL
  },
  FALSE
};

static const GDBusArgInfo * const _ms_dbus_sysupdate_target_method_info_install_IN_ARG_pointers[] =
{
  &_ms_dbus_sysupdate_target_method_info_install_IN_ARG_new_version.parent_struct,
  &_ms_dbus_sysupdate_target_method_info_install_IN_ARG_flags.parent_struct,
  NULL
};

static const _ExtendedGDBusArgInfo _ms_dbus_sysupdate_target_method_info_install_OUT_ARG_new_version =
{
  {
    -1,
    (gchar *) "new_version",
    (gchar *) "s",
    NULL
  },
  FALSE
};

static const _ExtendedGDBusArgInfo _ms_dbus_sysupdate_target_method_info_install_OUT_ARG_job_id =
{
  {
    -1,
    (gchar *) "job_id",
    (gchar *) "t",
    NULL
  },
  FALSE
};

static const _ExtendedGDBusArgInfo _ms_dbus_sysupdate_target_method_info_install_OUT_ARG_job_path =
{
  {
    -1,
    (gchar *) "job_path",
    (gchar *) "o",
    NULL
  },
  FALSE
};

static const GDBusArgInfo * const _ms_dbus_sysupdate_target_method_info_install_OUT_ARG_pointers[] =
{
  &_ms_dbus_sysupdate_target_method_info_install_OUT_ARG_new_version.parent_struct,
  &_ms_dbus_sysupdate_target_method_info_install_OUT_ARG_job_id.parent_struct,
  &_ms_dbus_sysupdate_target_method_info_install_OUT_ARG_job_path.parent_struct,
  NULL
};

static const _ExtendedGDBusMethodInfo _ms_dbus_sysupdate_target_method_info_install =
{
  {
    -1,
    (gchar *) "Install",
    (GDBusArgInfo **) &_ms_dbus_sysupdate_target_method_info_install_IN_ARG_pointers,
    (GDBusArgInfo **) &_ms_dbus_sysupdate_target_method_info_install_OUT_ARG_pointers,
    NULL
  },
  "handle-install",
  FALSE
};

static const _ExtendedGDBusArgInfo _ms_dbus_sysupdate_target_method_info_vacuum_OUT_ARG_instances =
{
  {
    -1,
    (gchar *) "instances",
    (gchar *) "u",
    NULL
  },
  FALSE
};

static const _ExtendedGDBusArgInfo _ms_dbus_sysupdate_target_method_info_vacuum_OUT_ARG_disabled_transfers =
{
  {
    -1,
    (gchar *) "disabled_transfers",
    (gchar *) "u",
    NULL
  },
  FALSE
};

static const GDBusArgInfo * const _ms_dbus_sysupdate_target_method_info_vacuum_OUT_ARG_pointers[] =
{
  &_ms_dbus_sysupdate_target_method_info_vacuum_OUT_ARG_instances.parent_struct,
  &_ms_dbus_sysupdate_target_method_info_vacuum_OUT_ARG_disabled_transfers.parent_struct,
  NULL
};

static const _ExtendedGDBusMethodInfo _ms_dbus_sysupdate_target_method_info_vacuum =
{
  {
    -1,
    (gchar *) "Vacuum",
    NULL,
    (GDBusArgInfo **) &_ms_dbus_sysupdate_target_method_info_vacuum_OUT_ARG_pointers,
    NULL
  },
  "handle-vacuum",
  FALSE
};

static const _ExtendedGDBusArgInfo _ms_dbus_sysupdate_target_method_info_get_app_stream_OUT_ARG_appstream =
{
  {
    -1,
    (gchar *) "appstream",
    (gchar *) "as",
    NULL
  },
  FALSE
};

static const GDBusArgInfo * const _ms_dbus_sysupdate_target_method_info_get_app_stream_OUT_ARG_pointers[] =
{
  &_ms_dbus_sysupdate_target_method_info_get_app_stream_OUT_ARG_appstream.parent_struct,
  NULL
};

static const _ExtendedGDBusMethodInfo _ms_dbus_sysupdate_target_method_info_get_app_stream =
{
  {
    -1,
    (gchar *) "GetAppStream",
    NULL,
    (GDBusArgInfo **) &_ms_dbus_sysupdate_target_method_info_get_app_stream_OUT_ARG_pointers,
    NULL
  },
  "handle-get-app-stream",
  FALSE
};

static const _ExtendedGDBusArgInfo _ms_dbus_sysupdate_target_method_info_get_version_OUT_ARG_version =
{
  {
    -1,
    (gchar *) "version",
    (gchar *) "s",
    NULL
  },
  FALSE
};

static const GDBusArgInfo * const _ms_dbus_sysupdate_target_method_info_get_version_OUT_ARG_pointers[] =
{
  &_ms_dbus_sysupdate_target_method_info_get_version_OUT_ARG_version.parent_struct,
  NULL
};

static const _ExtendedGDBusMethodInfo _ms_dbus_sysupdate_target_method_info_get_version =
{
  {
    -1,
    (gchar *) "GetVersion",
    NULL,
    (GDBusArgInfo **) &_ms_dbus_sysupdate_target_method_info_get_version_OUT_ARG_pointers,
    NULL
  },
  "handle-get-version",
  FALSE
};

static const _ExtendedGDBusArgInfo _ms_dbus_sysupdate_target_method_info_list_features_IN_ARG_flags =
{
  {
    -1,
    (gchar *) "flags",
    (gchar *) "t",
    NULL
  },
  FALSE
};

static const GDBusArgInfo * const _ms_dbus_sysupdate_target_method_info_list_features_IN_ARG_pointers[] =
{
  &_ms_dbus_sysupdate_target_method_info_list_features_IN_ARG_flags.parent_struct,
  NULL
};

static const _ExtendedGDBusArgInfo _ms_dbus_sysupdate_target_method_info_list_features_OUT_ARG_features =
{
  {
    -1,
    (gchar *) "features",
    (gchar *) "as",
    NULL
  },
  FALSE
};

static const GDBusArgInfo * const _ms_dbus_sysupdate_target_method_info_list_features_OUT_ARG_pointers[] =
{
  &_ms_dbus_sysupdate_target_method_info_list_features_OUT_ARG_features.parent_struct,
  NULL
};

static const _ExtendedGDBusMethodInfo _ms_dbus_sysupdate_target_method_info_list_features =
{
  {
    -1,
    (gchar *) "ListFeatures",
    (GDBusArgInfo **) &_ms_dbus_sysupdate_target_method_info_list_features_IN_ARG_pointers,
    (GDBusArgInfo **) &_ms_dbus_sysupdate_target_method_info_list_features_OUT_ARG_pointers,
    NULL
  },
  "handle-list-features",
  FALSE
};

static const _ExtendedGDBusArgInfo _ms_dbus_sysupdate_target_method_info_describe_feature_IN_ARG_feature =
{
  {
    -1,
    (gchar *) "feature",
    (gchar *) "s",
    NULL
  },
  FALSE
};

static const _ExtendedGDBusArgInfo _ms_dbus_sysupdate_target_method_info_describe_feature_IN_ARG_flags =
{
  {
    -1,
    (gchar *) "flags",
    (gchar *) "t",
    NULL
  },
  FALSE
};

static const GDBusArgInfo * const _ms_dbus_sysupdate_target_method_info_describe_feature_IN_ARG_pointers[] =
{
  &_ms_dbus_sysupdate_target_method_info_describe_feature_IN_ARG_feature.parent_struct,
  &_ms_dbus_sysupdate_target_method_info_describe_feature_IN_ARG_flags.parent_struct,
  NULL
};

static const _ExtendedGDBusArgInfo _ms_dbus_sysupdate_target_method_info_describe_feature_OUT_ARG_json =
{
  {
    -1,
    (gchar *) "json",
    (gchar *) "s",
    NULL
  },
  FALSE
};

static const GDBusArgInfo * const _ms_dbus_sysupdate_target_method_info_describe_feature_OUT_ARG_pointers[] =
{
  &_ms_dbus_sysupdate_target_method_info_describe_feature_OUT_ARG_json.parent_struct,
  NULL
};

static const _ExtendedGDBusMethodInfo _ms_dbus_sysupdate_target_method_info_describe_feature =
{
  {
    -1,
    (gchar *) "DescribeFeature",
    (GDBusArgInfo **) &_ms_dbus_sysupdate_target_method_info_describe_feature_IN_ARG_pointers,
    (GDBusArgInfo **) &_ms_dbus_sysupdate_target_method_info_describe_feature_OUT_ARG_pointers,
    NULL
  },
  "handle-describe-feature",
  FALSE
};

static const _ExtendedGDBusArgInfo _ms_dbus_sysupdate_target_method_info_set_feature_enabled_IN_ARG_feature =
{
  {
    -1,
    (gchar *) "feature",
    (gchar *) "s",
    NULL
  },
  FALSE
};

static const _ExtendedGDBusArgInfo _ms_dbus_sysupdate_target_method_info_set_feature_enabled_IN_ARG_enabled =
{
  {
    -1,
    (gchar *) "enabled",
    (gchar *) "i",
    NULL
  },
  FALSE
};

static const _ExtendedGDBusArgInfo _ms_dbus_sysupdate_target_method_info_set_feature_enabled_IN_ARG_flags =
{
  {
    -1,
    (gchar *) "flags",
    (gchar *) "t",
    NULL
  },
  FALSE
};

static const GDBusArgInfo * const _ms_dbus_sysupdate_target_method_info_set_feature_enabled_IN_ARG_pointers[] =
{
  &_ms_dbus_sysupdate_target_method_info_set_feature_enabled_IN_ARG_feature.parent_struct,
  &_ms_dbus_sysupdate_target_method_info_set_feature_enabled_IN_ARG_enabled.parent_struct,
  &_ms_dbus_sysupdate_target_method_info_set_feature_enabled_IN_ARG_flags.parent_struct,
  NULL
};

static const _ExtendedGDBusMethodInfo _ms_dbus_sysupdate_target_method_info_set_feature_enabled =
{
  {
    -1,
    (gchar *) "SetFeatureEnabled",
    (GDBusArgInfo **) &_ms_dbus_sysupdate_target_method_info_set_feature_enabled_IN_ARG_pointers,
    NULL,
    NULL
  },
  "handle-set-feature-enabled",
  FALSE
};

static const GDBusMethodInfo * const _ms_dbus_sysupdate_target_method_info_pointers[] =
{
  &_ms_dbus_sysupdate_target_method_info_list.parent_struct,
  &_ms_dbus_sysupdate_target_method_info_describe.parent_struct,
  &_ms_dbus_sysupdate_target_method_info_check_new.parent_struct,
  &_ms_dbus_sysupdate_target_method_info_acquire.parent_struct,
  &_ms_dbus_sysupdate_target_method_info_install.parent_struct,
  &_ms_dbus_sysupdate_target_method_info_vacuum.parent_struct,
  &_ms_dbus_sysupdate_target_method_info_get_app_stream.parent_struct,
  &_ms_dbus_sysupdate_target_method_info_get_version.parent_struct,
  &_ms_dbus_sysupdate_target_method_info_list_features.parent_struct,
  &_ms_dbus_sysupdate_target_method_info_describe_feature.parent_struct,
  &_ms_dbus_sysupdate_target_method_info_set_feature_enabled.parent_struct,
  NULL
};

static const GDBusAnnotationInfo _ms_dbus_sysupdate_target_property_class_annotation_info_0 =
{
  -1,
  (gchar *) "org.freedesktop.DBus.Property.EmitsChangedSignal",
  (gchar *) "const",
  NULL
};

static const GDBusAnnotationInfo * const _ms_dbus_sysupdate_target_property_class_annotation_info_pointers[] =
{
  &_ms_dbus_sysupdate_target_property_class_annotation_info_0,
  NULL
};

static const _ExtendedGDBusPropertyInfo _ms_dbus_sysupdate_target_property_info_class =
{
  {
    -1,
    (gchar *) "Class",
    (gchar *) "s",
    G_DBUS_PROPERTY_INFO_FLAGS_READABLE,
    (GDBusAnnotationInfo **) &_ms_dbus_sysupdate_target_property_class_annotation_info_pointers
  },
  "class",
  FALSE,
  FALSE
};

static const GDBusAnnotationInfo _ms_dbus_sysupdate_target_property_name_annotation_info_0 =
{
  -1,
  (gchar *) "org.freedesktop.DBus.Property.EmitsChangedSignal",
  (gchar *) "const",
  NULL
};

static const GDBusAnnotationInfo * const _ms_dbus_sysupdate_target_property_name_annotation_info_pointers[] =
{
  &_ms_dbus_sysupdate_target_property_name_annotation_info_0,
  NULL
};

static const _ExtendedGDBusPropertyInfo _ms_dbus_sysupdate_target_property_info_name =
{
  {
    -1,
    (gchar *) "Name",
    (gchar *) "s",
    G_DBUS_PROPERTY_INFO_FLAGS_READABLE,
    (GDBusAnnotationInfo **) &_ms_dbus_sysupdate_target_property_name_annotation_info_pointers
  },
  "name",
  FALSE,
  FALSE
};

static const GDBusAnnotationInfo _ms_dbus_sysupdate_target_property_path_annotation_info_0 =
{
  -1,
  (gchar *) "org.freedesktop.DBus.Property.EmitsChangedSignal",
  (gchar *) "const",
  NULL
};

static const GDBusAnnotationInfo * const _ms_dbus_sysupdate_target_property_path_annotation_info_pointers[] =
{
  &_ms_dbus_sysupdate_target_property_path_annotation_info_0,
  NULL
};

static const _ExtendedGDBusPropertyInfo _ms_dbus_sysupdate_target_property_info_path =
{
  {
    -1,
    (gchar *) "Path",
    (gchar *) "s",
    G_DBUS_PROPERTY_INFO_FLAGS_READABLE,
    (GDBusAnnotationInfo **) &_ms_dbus_sysupdate_target_property_path_annotation_info_pointers
  },
  "path",
  FALSE,
  FALSE
};

static const GDBusPropertyInfo * const _ms_dbus_sysupdate_target_property_info_pointers[] =
{
  &_ms_dbus_sysupdate_target_property_info_class.parent_struct,
  &_ms_dbus_sysupdate_target_property_info_name.parent_struct,
  &_ms_dbus_sysupdate_target_property_info_path.parent_struct,
  NULL
};

static const _ExtendedGDBusInterfaceInfo _ms_dbus_sysupdate_target_interface_info =
{
  {
    -1,
    (gchar *) "org.freedesktop.sysupdate1.Target",
    (GDBusMethodInfo **) &_ms_dbus_sysupdate_target_method_info_pointers,
    NULL,
    (GDBusPropertyInfo **) &_ms_dbus_sysupdate_target_property_info_pointers,
    NULL
  },
  "target",
};


/**
 * ms_dbus_sysupdate_target_interface_info:
 *
 * Gets a machine-readable description of the <link linkend="gdbus-interface-org-freedesktop-sysupdate1-Target.top_of_page">org.freedesktop.sysupdate1.Target</link> D-Bus interface.
 *
 * Returns: (transfer none): A #GDBusInterfaceInfo. Do not free.
 */
GDBusInterfaceInfo *
ms_dbus_sysupdate_target_interface_info (void)
{
  return (GDBusInterfaceInfo *) &_ms_dbus_sysupdate_target_interface_info.parent_struct;
}

/**
 * ms_dbus_sysupdate_target_override_properties:
 * @klass: The class structure for a #GObject derived class.
 * @property_id_begin: The property id to assign to the first overridden property.
 *
 * Overrides all #GObject properties in the #MsDBusSysupdateTarget interface for a concrete class.
 * The properties are overridden in the order they are defined.
 *
 * Returns: The last property id.
 */
guint
ms_dbus_sysupdate_target_override_properties (GObjectClass *klass, guint property_id_begin)
{
  g_object_class_override_property (klass, property_id_begin++, "class");
  g_object_class_override_property (klass, property_id_begin++, "name");
  g_object_class_override_property (klass, property_id_begin++, "path");
  return property_id_begin - 1;
}


inline static void
ms_dbus_sysupdate_target_method_marshal_list (
    GClosure     *closure,
    GValue       *return_value,
    unsigned int  n_param_values,
    const GValue *param_values,
    void         *invocation_hint,
    void         *marshal_data)
{
  _g_dbus_codegen_marshal_BOOLEAN__OBJECT_UINT64 (closure,
    return_value, n_param_values, param_values, invocation_hint, marshal_data);
}

inline static void
ms_dbus_sysupdate_target_method_marshal_describe (
    GClosure     *closure,
    GValue       *return_value,
    unsigned int  n_param_values,
    const GValue *param_values,
    void         *invocation_hint,
    void         *marshal_data)
{
  _g_dbus_codegen_marshal_BOOLEAN__OBJECT_STRING_UINT64 (closure,
    return_value, n_param_values, param_values, invocation_hint, marshal_data);
}

inline static void
ms_dbus_sysupdate_target_method_marshal_check_new (
    GClosure     *closure,
    GValue       *return_value,
    unsigned int  n_param_values,
    const GValue *param_values,
    void         *invocation_hint,
    void         *marshal_data)
{
  _g_dbus_codegen_marshal_BOOLEAN__OBJECT (closure,
    return_value, n_param_values, param_values, invocation_hint, marshal_data);
}

inline static void
ms_dbus_sysupdate_target_method_marshal_acquire (
    GClosure     *closure,
    GValue       *return_value,
    unsigned int  n_param_values,
    const GValue *param_values,
    void         *invocation_hint,
    void         *marshal_data)
{
  _g_dbus_codegen_marshal_BOOLEAN__OBJECT_STRING_UINT64 (closure,
    return_value, n_param_values, param_values, invocation_hint, marshal_data);
}

inline static void
ms_dbus_sysupdate_target_method_marshal_install (
    GClosure     *closure,
    GValue       *return_value,
    unsigned int  n_param_values,
    const GValue *param_values,
    void         *invocation_hint,
    void         *marshal_data)
{
  _g_dbus_codegen_marshal_BOOLEAN__OBJECT_STRING_UINT64 (closure,
    return_value, n_param_values, param_values, invocation_hint, marshal_data);
}

inline static void
ms_dbus_sysupdate_target_method_marshal_vacuum (
    GClosure     *closure,
    GValue       *return_value,
    unsigned int  n_param_values,
    const GValue *param_values,
    void         *invocation_hint,
    void         *marshal_data)
{
  _g_dbus_codegen_marshal_BOOLEAN__OBJECT (closure,
    return_value, n_param_values, param_values, invocation_hint, marshal_data);
}

inline static void
ms_dbus_sysupdate_target_method_marshal_get_app_stream (
    GClosure     *closure,
    GValue       *return_value,
    unsigned int  n_param_values,
    const GValue *param_values,
    void         *invocation_hint,
    void         *marshal_data)
{
  _g_dbus_codegen_marshal_BOOLEAN__OBJECT (closure,
    return_value, n_param_values, param_values, invocation_hint, marshal_data);
}

inline static void
ms_dbus_sysupdate_target_method_marshal_get_version (
    GClosure     *closure,
    GValue       *return_value,
    unsigned int  n_param_values,
    const GValue *param_values,
    void         *invocation_hint,
    void         *marshal_data)
{
  _g_dbus_codegen_marshal_BOOLEAN__OBJECT (closure,
    return_value, n_param_values, param_values, invocation_hint, marshal_data);
}

inline static void
ms_dbus_sysupdate_target_method_marshal_list_features (
    GClosure     *closure,
    GValue       *return_value,
    unsigned int  n_param_values,
    const GValue *param_values,
    void         *invocation_hint,
    void         *marshal_data)
{
  _g_dbus_codegen_marshal_BOOLEAN__OBJECT_UINT64 (closure,
    return_value, n_param_values, param_values, invocation_hint, marshal_data);
}

inline static void
ms_dbus_sysupdate_target_method_marshal_describe_feature (
    GClosure     *closure,
    GValue       *return_value,
    unsigned int  n_param_values,
    const GValue *param_values,
    void         *invocation_hint,
    void         *marshal_data)
{
  _g_dbus_codegen_marshal_BOOLEAN__OBJECT_STRING_UINT64 (closure,
    return_value, n_param_values, param_values, invocation_hint, marshal_data);
}

inline static void
ms_dbus_sysupdate_target_method_marshal_set_feature_enabled (
    GClosure     *closure,
    GValue       *return_value,
    unsigned int  n_param_values,
    const GValue *param_values,
    void         *invocation_hint,
    void         *marshal_data)
{
  _g_dbus_codegen_marshal_BOOLEAN__OBJECT_STRING_INT_UINT64 (closure,
    return_value, n_param_values, param_values, invocation_hint, marshal_data);
}


/**
 * MsDBusSysupdateTarget:
 *
 * Abstract interface type for the D-Bus interface <link linkend="gdbus-interface-org-freedesktop-sysupdate1-Target.top_of_page">org.freedesktop.sysupdate1.Target</link>.
 */

/**
 * MsDBusSysupdateTargetIface:
 * @parent_iface: The parent interface.
 * @handle_acquire: Handler for the #MsDBusSysupdateTarget::handle-acquire signal.
 * @handle_check_new: Handler for the #MsDBusSysupdateTarget::handle-check-new signal.
 * @handle_describe: Handler for the #MsDBusSysupdateTarget::handle-describe signal.
 * @handle_describe_feature: Handler for the #MsDBusSysupdateTarget::handle-describe-feature signal.
 * @handle_get_app_stream: Handler for the #MsDBusSysupdateTarget::handle-get-app-stream signal.
 * @handle_get_version: Handler for the #MsDBusSysupdateTarget::handle-get-version signal.
 * @handle_install: Handler for the #MsDBusSysupdateTarget::handle-install signal.
 * @handle_list: Handler for the #MsDBusSysupdateTarget::handle-list signal.
 * @handle_list_features: Handler for the #MsDBusSysupdateTarget::handle-list-features signal.
 * @handle_set_feature_enabled: Handler for the #MsDBusSysupdateTarget::handle-set-feature-enabled signal.
 * @handle_vacuum: Handler for the #MsDBusSysupdateTarget::handle-vacuum signal.
 * @get_class: Getter for the #MsDBusSysupdateTarget:class property.
 * @get_name: Getter for the #MsDBusSysupdateTarget:name property.
 * @get_path: Getter for the #MsDBusSysupdateTarget:path property.
 *
 * Virtual table for the D-Bus interface <link linkend="gdbus-interface-org-freedesktop-sysupdate1-Target.top_of_page">org.freedesktop.sysupdate1.Target</link>.
 */

typedef MsDBusSysupdateTargetIface MsDBusSysupdateTargetInterface;
G_DEFINE_INTERFACE (MsDBusSysupdateTarget, ms_dbus_sysupdate_target, G_TYPE_OBJECT)

static void
ms_dbus_sysupdate_target_default_init (MsDBusSysupdateTargetIface *iface)
{
  /* GObject signals for incoming D-Bus method calls: */
  /**
   * MsDBusSysupdateTarget::handle-list:
   * @object: A #MsDBusSysupdateTarget.
   * @invocation: A #GDBusMethodInvocation.
   * @arg_flags: Argument passed by remote caller.
   *
   * Signal emitted when a remote caller is invoking the <link linkend="gdbus-method-org-freedesktop-sysupdate1-Target.List">List()</link> D-Bus method.
   *
   * If a signal handler returns %TRUE, it means the signal handler will handle the invocation (e.g. take a reference to @invocation and eventually call ms_dbus_sysupdate_target_complete_list() or e.g. g_dbus_method_invocation_return_error() on it) and no other signal handlers will run. If no signal handler handles the invocation, the %G_DBUS_ERROR_UNKNOWN_METHOD error is returned.
   *
   * Returns: %G_DBUS_METHOD_INVOCATION_HANDLED or %TRUE if the invocation was handled, %G_DBUS_METHOD_INVOCATION_UNHANDLED or %FALSE to let other signal handlers run.
   */
  g_signal_new ("handle-list",
    G_TYPE_FROM_INTERFACE (iface),
    G_SIGNAL_RUN_LAST,
    G_STRUCT_OFFSET (MsDBusSysupdateTargetIface, handle_list),
    g_signal_accumulator_true_handled,
    NULL,
      ms_dbus_sysupdate_target_method_marshal_list,
    G_TYPE_BOOLEAN,
    2,
    G_TYPE_DBUS_METHOD_INVOCATION, G_TYPE_UINT64);

  /**
   * MsDBusSysupdateTarget::handle-describe:
   * @object: A #MsDBusSysupdateTarget.
   * @invocation: A #GDBusMethodInvocation.
   * @arg_version: Argument passed by remote caller.
   * @arg_flags: Argument passed by remote caller.
   *
   * Signal emitted when a remote caller is invoking the <link linkend="gdbus-method-org-freedesktop-sysupdate1-Target.Describe">Describe()</link> D-Bus method.
   *
   * If a signal handler returns %TRUE, it means the signal handler will handle the invocation (e.g. take a reference to @invocation and eventually call ms_dbus_sysupdate_target_complete_describe() or e.g. g_dbus_method_invocation_return_error() on it) and no other signal handlers will run. If no signal handler handles the invocation, the %G_DBUS_ERROR_UNKNOWN_METHOD error is returned.
   *
   * Returns: %G_DBUS_METHOD_INVOCATION_HANDLED or %TRUE if the invocation was handled, %G_DBUS_METHOD_INVOCATION_UNHANDLED or %FALSE to let other signal handlers run.
   */
  g_signal_new ("handle-describe",
    G_TYPE_FROM_INTERFACE (iface),
    G_SIGNAL_RUN_LAST,
    G_STRUCT_OFFSET (MsDBusSysupdateTargetIface, handle_describe),
    g_signal_accumulator_true_handled,
    NULL,
      ms_dbus_sysupdate_target_method_marshal_describe,
    G_TYPE_BOOLEAN,
    3,
    G_TYPE_DBUS_METHOD_INVOCATION, G_TYPE_STRING, G_TYPE_UINT64);

  /**
   * MsDBusSysupdateTarget::handle-check-new:
   * @object: A #MsDBusSysupdateTarget.
   * @invocation: A #GDBusMethodInvocation.
   *
   * Signal emitted when a remote caller is invoking the <link linkend="gdbus-method-org-freedesktop-sysupdate1-Target.CheckNew">CheckNew()</link> D-Bus method.
   *
   * If a signal handler returns %TRUE, it means the signal handler will handle the invocation (e.g. take a reference to @invocation and eventually call ms_dbus_sysupdate_target_complete_check_new() or e.g. g_dbus_method_invocation_return_error() on it) and no other signal handlers will run. If no signal handler handles the invocation, the %G_DBUS_ERROR_UNKNOWN_METHOD error is returned.
   *
   * Returns: %G_DBUS_METHOD_INVOCATION_HANDLED or %TRUE if the invocation was handled, %G_DBUS_METHOD_INVOCATION_UNHANDLED or %FALSE to let other signal handlers run.
   */
  g_signal_new ("handle-check-new",
    G_TYPE_FROM_INTERFACE (iface),
    G_SIGNAL_RUN_LAST,
    G_STRUCT_OFFSET (MsDBusSysupdateTargetIface, handle_check_new),
    g_signal_accumulator_true_handled,
    NULL,
      ms_dbus_sysupdate_target_method_marshal_check_new,
    G_TYPE_BOOLEAN,
    1,
    G_TYPE_DBUS_METHOD_INVOCATION);

  /**
   * MsDBusSysupdateTarget::handle-acquire:
   * @object: A #MsDBusSysupdateTarget.
   * @invocation: A #GDBusMethodInvocation.
   * @arg_new_version: Argument passed by remote caller.
   * @arg_flags: Argument passed by remote caller.
   *
   * Signal emitted when a remote caller is invoking the <link linkend="gdbus-method-org-freedesktop-sysupdate1-Target.Acquire">Acquire()</link> D-Bus method.
   *
   * If a signal handler returns %TRUE, it means the signal handler will handle the invocation (e.g. take a reference to @invocation and eventually call ms_dbus_sysupdate_target_complete_acquire() or e.g. g_dbus_method_invocation_return_error() on it) and no other signal handlers will run. If no signal handler handles the invocation, the %G_DBUS_ERROR_UNKNOWN_METHOD error is returned.
   *
   * Returns: %G_DBUS_METHOD_INVOCATION_HANDLED or %TRUE if the invocation was handled, %G_DBUS_METHOD_INVOCATION_UNHANDLED or %FALSE to let other signal handlers run.
   */
  g_signal_new ("handle-acquire",
    G_TYPE_FROM_INTERFACE (iface),
    G_SIGNAL_RUN_LAST,
    G_STRUCT_OFFSET (MsDBusSysupdateTargetIface, handle_acquire),
    g_signal_accumulator_true_handled,
    NULL,
      ms_dbus_sysupdate_target_method_marshal_acquire,
    G_TYPE_BOOLEAN,
    3,
    G_TYPE_DBUS_METHOD_INVOCATION, G_TYPE_STRING, G_TYPE_UINT64);

  /**
   * MsDBusSysupdateTarget::handle-install:
   * @object: A #MsDBusSysupdateTarget.
   * @invocation: A #GDBusMethodInvocation.
   * @arg_new_version: Argument passed by remote caller.
   * @arg_flags: Argument passed by remote caller.
   *
   * Signal emitted when a remote caller is invoking the <link linkend="gdbus-method-org-freedesktop-sysupdate1-Target.Install">Install()</link> D-Bus method.
   *
   * If a signal handler returns %TRUE, it means the signal handler will handle the invocation (e.g. take a reference to @invocation and eventually call ms_dbus_sysupdate_target_complete_install() or e.g. g_dbus_method_invocation_return_error() on it) and no other signal handlers will run. If no signal handler handles the invocation, the %G_DBUS_ERROR_UNKNOWN_METHOD error is returned.
   *
   * Returns: %G_DBUS_METHOD_INVOCATION_HANDLED or %TRUE if the invocation was handled, %G_DBUS_METHOD_INVOCATION_UNHANDLED or %FALSE to let other signal handlers run.
   */
  g_signal_new ("handle-install",
    G_TYPE_FROM_INTERFACE (iface),
    G_SIGNAL_RUN_LAST,
    G_STRUCT_OFFSET (MsDBusSysupdateTargetIface, handle_install),
    g_signal_accumulator_true_handled,
    NULL,
      ms_dbus_sysupdate_target_method_marshal_install,
    G_TYPE_BOOLEAN,
    3,
    G_TYPE_DBUS_METHOD_INVOCATION, G_TYPE_STRING, G_TYPE_UINT64);

  /**
   * MsDBusSysupdateTarget::handle-vacuum:
   * @object: A #MsDBusSysupdateTarget.
   * @invocation: A #GDBusMethodInvocation.
   *
   * Signal emitted when a remote caller is invoking the <link linkend="gdbus-method-org-freedesktop-sysupdate1-Target.Vacuum">Vacuum()</link> D-Bus method.
   *
   * If a signal handler returns %TRUE, it means the signal handler will handle the invocation (e.g. take a reference to @invocation and eventually call ms_dbus_sysupdate_target_complete_vacuum() or e.g. g_dbus_method_invocation_return_error() on it) and no other signal handlers will run. If no signal handler handles the invocation, the %G_DBUS_ERROR_UNKNOWN_METHOD error is returned.
   *
   * Returns: %G_DBUS_METHOD_INVOCATION_HANDLED or %TRUE if the invocation was handled, %G_DBUS_METHOD_INVOCATION_UNHANDLED or %FALSE to let other signal handlers run.
   */
  g_signal_new ("handle-vacuum",
    G_TYPE_FROM_INTERFACE (iface),
    G_SIGNAL_RUN_LAST,
    G_STRUCT_OFFSET (MsDBusSysupdateTargetIface, handle_vacuum),
    g_signal_accumulator_true_handled,
    NULL,
      ms_dbus_sysupdate_target_method_marshal_vacuum,
    G_TYPE_BOOLEAN,
    1,
    G_TYPE_DBUS_METHOD_INVOCATION);

  /**
   * MsDBusSysupdateTarget::handle-get-app-stream:
   * @object: A #MsDBusSysupdateTarget.
   * @invocation: A #GDBusMethodInvocation.
   *
   * Signal emitted when a remote caller is invoking the <link linkend="gdbus-method-org-freedesktop-sysupdate1-Target.GetAppStream">GetAppStream()</link> D-Bus method.
   *
   * If a signal handler returns %TRUE, it means the signal handler will handle the invocation (e.g. take a reference to @invocation and eventually call ms_dbus_sysupdate_target_complete_get_app_stream() or e.g. g_dbus_method_invocation_return_error() on it) and no other signal handlers will run. If no signal handler handles the invocation, the %G_DBUS_ERROR_UNKNOWN_METHOD error is returned.
   *
   * Returns: %G_DBUS_METHOD_INVOCATION_HANDLED or %TRUE if the invocation was handled, %G_DBUS_METHOD_INVOCATION_UNHANDLED or %FALSE to let other signal handlers run.
   */
  g_signal_new ("handle-get-app-stream",
    G_TYPE_FROM_INTERFACE (iface),
    G_SIGNAL_RUN_LAST,
    G_STRUCT_OFFSET (MsDBusSysupdateTargetIface, handle_get_app_stream),
    g_signal_accumulator_true_handled,
    NULL,
      ms_dbus_sysupdate_target_method_marshal_get_app_stream,
    G_TYPE_BOOLEAN,
    1,
    G_TYPE_DBUS_METHOD_INVOCATION);

  /**
   * MsDBusSysupdateTarget::handle-get-version:
   * @object: A #MsDBusSysupdateTarget.
   * @invocation: A #GDBusMethodInvocation.
   *
   * Signal emitted when a remote caller is invoking the <link linkend="gdbus-method-org-freedesktop-sysupdate1-Target.GetVersion">GetVersion()</link> D-Bus method.
   *
   * If a signal handler returns %TRUE, it means the signal handler will handle the invocation (e.g. take a reference to @invocation and eventually call ms_dbus_sysupdate_target_complete_get_version() or e.g. g_dbus_method_invocation_return_error() on it) and no other signal handlers will run. If no signal handler handles the invocation, the %G_DBUS_ERROR_UNKNOWN_METHOD error is returned.
   *
   * Returns: %G_DBUS_METHOD_INVOCATION_HANDLED or %TRUE if the invocation was handled, %G_DBUS_METHOD_INVOCATION_UNHANDLED or %FALSE to let other signal handlers run.
   */
  g_signal_new ("handle-get-version",
    G_TYPE_FROM_INTERFACE (iface),
    G_SIGNAL_RUN_LAST,
    G_STRUCT_OFFSET (MsDBusSysupdateTargetIface, handle_get_version),
    g_signal_accumulator_true_handled,
    NULL,
      ms_dbus_sysupdate_target_method_marshal_get_version,
    G_TYPE_BOOLEAN,
    1,
    G_TYPE_DBUS_METHOD_INVOCATION);

  /**
   * MsDBusSysupdateTarget::handle-list-features:
   * @object: A #MsDBusSysupdateTarget.
   * @invocation: A #GDBusMethodInvocation.
   * @arg_flags: Argument passed by remote caller.
   *
   * Signal emitted when a remote caller is invoking the <link linkend="gdbus-method-org-freedesktop-sysupdate1-Target.ListFeatures">ListFeatures()</link> D-Bus method.
   *
   * If a signal handler returns %TRUE, it means the signal handler will handle the invocation (e.g. take a reference to @invocation and eventually call ms_dbus_sysupdate_target_complete_list_features() or e.g. g_dbus_method_invocation_return_error() on it) and no other signal handlers will run. If no signal handler handles the invocation, the %G_DBUS_ERROR_UNKNOWN_METHOD error is returned.
   *
   * Returns: %G_DBUS_METHOD_INVOCATION_HANDLED or %TRUE if the invocation was handled, %G_DBUS_METHOD_INVOCATION_UNHANDLED or %FALSE to let other signal handlers run.
   */
  g_signal_new ("handle-list-features",
    G_TYPE_FROM_INTERFACE (iface),
    G_SIGNAL_RUN_LAST,
    G_STRUCT_OFFSET (MsDBusSysupdateTargetIface, handle_list_features),
    g_signal_accumulator_true_handled,
    NULL,
      ms_dbus_sysupdate_target_method_marshal_list_features,
    G_TYPE_BOOLEAN,
    2,
    G_TYPE_DBUS_METHOD_INVOCATION, G_TYPE_UINT64);

  /**
   * MsDBusSysupdateTarget::handle-describe-feature:
   * @object: A #MsDBusSysupdateTarget.
   * @invocation: A #GDBusMethodInvocation.
   * @arg_feature: Argument passed by remote caller.
   * @arg_flags: Argument passed by remote caller.
   *
   * Signal emitted when a remote caller is invoking the <link linkend="gdbus-method-org-freedesktop-sysupdate1-Target.DescribeFeature">DescribeFeature()</link> D-Bus method.
   *
   * If a signal handler returns %TRUE, it means the signal handler will handle the invocation (e.g. take a reference to @invocation and eventually call ms_dbus_sysupdate_target_complete_describe_feature() or e.g. g_dbus_method_invocation_return_error() on it) and no other signal handlers will run. If no signal handler handles the invocation, the %G_DBUS_ERROR_UNKNOWN_METHOD error is returned.
   *
   * Returns: %G_DBUS_METHOD_INVOCATION_HANDLED or %TRUE if the invocation was handled, %G_DBUS_METHOD_INVOCATION_UNHANDLED or %FALSE to let other signal handlers run.
   */
  g_signal_new ("handle-describe-feature",
    G_TYPE_FROM_INTERFACE (iface),
    G_SIGNAL_RUN_LAST,
    G_STRUCT_OFFSET (MsDBusSysupdateTargetIface, handle_describe_feature),
    g_signal_accumulator_true_handled,
    NULL,
      ms_dbus_sysupdate_target_method_marshal_describe_feature,
    G_TYPE_BOOLEAN,
    3,
    G_TYPE_DBUS_METHOD_INVOCATION, G_TYPE_STRING, G_TYPE_UINT64);

  /**
   * MsDBusSysupdateTarget::handle-set-feature-enabled:
   * @object: A #MsDBusSysupdateTarget.
   * @invocation: A #GDBusMethodInvocation.
   * @arg_feature: Argument passed by remote caller.
   * @arg_enabled: Argument passed by remote caller.
   * @arg_flags: Argument passed by remote caller.
   *
   * Signal emitted when a remote caller is invoking the <link linkend="gdbus-method-org-freedesktop-sysupdate1-Target.SetFeatureEnabled">SetFeatureEnabled()</link> D-Bus method.
   *
   * If a signal handler returns %TRUE, it means the signal handler will handle the invocation (e.g. take a reference to @invocation and eventually call ms_dbus_sysupdate_target_complete_set_feature_enabled() or e.g. g_dbus_method_invocation_return_error() on it) and no other signal handlers will run. If no signal handler handles the invocation, the %G_DBUS_ERROR_UNKNOWN_METHOD error is returned.
   *
   * Returns: %G_DBUS_METHOD_INVOCATION_HANDLED or %TRUE if the invocation was handled, %G_DBUS_METHOD_INVOCATION_UNHANDLED or %FALSE to let other signal handlers run.
   */
  g_signal_new ("handle-set-feature-enabled",
    G_TYPE_FROM_INTERFACE (iface),
    G_SIGNAL_RUN_LAST,
    G_STRUCT_OFFSET (MsDBusSysupdateTargetIface, handle_set_feature_enabled),
    g_signal_accumulator_true_handled,
    NULL,
      ms_dbus_sysupdate_target_method_marshal_set_feature_enabled,
    G_TYPE_BOOLEAN,
    4,
    G_TYPE_DBUS_METHOD_INVOCATION, G_TYPE_STRING, G_TYPE_INT, G_TYPE_UINT64);

  /* GObject properties for D-Bus properties: */
  /**
   * MsDBusSysupdateTarget:class:
   *
   * Represents the D-Bus property <link linkend="gdbus-property-org-freedesktop-sysupdate1-Target.Class">"Class"</link>.
   *
   * Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
   */
  g_object_interface_install_property (iface,
    g_param_spec_string ("class", "Class", "Class", NULL, G_PARAM_READWRITE | G_PARAM_STATIC_STRINGS));
  /**
   * MsDBusSysupdateTarget:name:
   *
   * Represents the D-Bus property <link linkend="gdbus-property-org-freedesktop-sysupdate1-Target.Name">"Name"</link>.
   *
   * Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
   */
  g_object_interface_install_property (iface,
    g_param_spec_string ("name", "Name", "Name", NULL, G_PARAM_READWRITE | G_PARAM_STATIC_STRINGS));
  /**
   * MsDBusSysupdateTarget:path:
   *
   * Represents the D-Bus property <link linkend="gdbus-property-org-freedesktop-sysupdate1-Target.Path">"Path"</link>.
   *
   * Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side.
   */
  g_object_interface_install_property (iface,
    g_param_spec_string ("path", "Path", "Path", NULL, G_PARAM_READWRITE | G_PARAM_STATIC_STRINGS));
}

/**
 * ms_dbus_sysupdate_target_get_class: (skip)
 * @object: A #MsDBusSysupdateTarget.
 *
 * Gets the value of the <link linkend="gdbus-property-org-freedesktop-sysupdate1-Target.Class">"Class"</link> D-Bus property.
 *
 * Since this D-Bus property is readable, it is meaningful to use this function on both the client- and service-side.
 *
 * The returned value is only valid until the property changes so on the client-side it is only safe to use this function on the thread where @object was constructed. Use ms_dbus_sysupdate_target_dup_class() if on another thread.
 *
 * Returns: (transfer none) (nullable): The property value or %NULL if the property is not set. Do not free the returned value, it belongs to @object.
 */
const gchar *
ms_dbus_sysupdate_target_get_class (MsDBusSysupdateTarget *object)
{
  g_return_val_if_fail (MS_DBUS_SYSUPDATE_IS_TARGET (object), NULL);

  return MS_DBUS_SYSUPDATE_TARGET_GET_IFACE (object)->get_class (object);
}

/**
 * ms_dbus_sysupdate_target_dup_class: (skip)
 * @object: A #MsDBusSysupdateTarget.
 *
 * Gets a copy of the <link linkend="gdbus-property-org-freedesktop-sysupdate1-Target.Class">"Class"</link> D-Bus property.
 *
 * Since this D-Bus property is readable, it is meaningful to use this function on both the client- and service-side.
 *
 * Returns: (transfer full) (nullable): The property value or %NULL if the property is not set. The returned value should be freed with g_free().
 */
gchar *
ms_dbus_sysupdate_target_dup_class (MsDBusSysupdateTarget *object)
{
  gchar *value;
  g_object_get (G_OBJECT (object), "class", &value, NULL);
  return value;
}

/**
 * ms_dbus_sysupdate_target_set_class: (skip)
 * @object: A #MsDBusSysupdateTarget.
 * @value: The value to set.
 *
 * Sets the <link linkend="gdbus-property-org-freedesktop-sysupdate1-Target.Class">"Class"</link> D-Bus property to @value.
 *
 * Since this D-Bus property is not writable, it is only meaningful to use this function on the service-side.
 */
void
ms_dbus_sysupdate_target_set_class (MsDBusSysupdateTarget *object, const gchar *value)
{
  g_object_set (G_OBJECT (object), "class", value, NULL);
}

/**
 * ms_dbus_sysupdate_target_get_name: (skip)
 * @object: A #MsDBusSysupdateTarget.
 *
 * Gets the value of the <link linkend="gdbus-property-org-freedesktop-sysupdate1-Target.Name">"Name"</link> D-Bus property.
 *
 * Since this D-Bus property is readable, it is meaningful to use this function on both the client- and service-side.
 *
 * The returned value is only valid until the property changes so on the client-side it is only safe to use this function on the thread where @object was constructed. Use ms_dbus_sysupdate_target_dup_name() if on another thread.
 *
 * Returns: (transfer none) (nullable): The property value or %NULL if the property is not set. Do not free the returned value, it belongs to @object.
 */
const gchar *
ms_dbus_sysupdate_target_get_name (MsDBusSysupdateTarget *object)
{
  g_return_val_if_fail (MS_DBUS_SYSUPDATE_IS_TARGET (object), NULL);

  return MS_DBUS_SYSUPDATE_TARGET_GET_IFACE (object)->get_name (object);
}

/**
 * ms_dbus_sysupdate_target_dup_name: (skip)
 * @object: A #MsDBusSysupdateTarget.
 *
 * Gets a copy of the <link linkend="gdbus-property-org-freedesktop-sysupdate1-Target.Name">"Name"</link> D-Bus property.
 *
 * Since this D-Bus property is readable, it is meaningful to use this function on both the client- and service-side.
 *
 * Returns: (transfer full) (nullable): The property value or %NULL if the property is not set. The returned value should be freed with g_free().
 */
gchar *
ms_dbus_sysupdate_target_dup_name (MsDBusSysupdateTarget *object)
{
  gchar *value;
  g_object_get (G_OBJECT (object), "name", &value, NULL);
  return value;
}

/**
 * ms_dbus_sysupdate_target_set_name: (skip)
 * @object: A #MsDBusSysupdateTarget.
 * @value: The value to set.
 *
 * Sets the <link linkend="gdbus-property-org-freedesktop-sysupdate1-Target.Name">"Name"</link> D-Bus property to @value.
 *
 * Since this D-Bus property is not writable, it is only meaningful to use this function on the service-side.
 */
void
ms_dbus_sysupdate_target_set_name (MsDBusSysupdateTarget *object, const gchar *value)
{
  g_object_set (G_OBJECT (object), "name", value, NULL);
}

/**
 * ms_dbus_sysupdate_target_get_path: (skip)
 * @object: A #MsDBusSysupdateTarget.
 *
 * Gets the value of the <link linkend="gdbus-property-org-freedesktop-sysupdate1-Target.Path">"Path"</link> D-Bus property.
 *
 * Since this D-Bus property is readable, it is meaningful to use this function on both the client- and service-side.
 *
 * The returned value is only valid until the property changes so on the client-side it is only safe to use this function on the thread where @object was constructed. Use ms_dbus_sysupdate_target_dup_path() if on another thread.
 *
 * Returns: (transfer none) (nullable): The property value or %NULL if the property is not set. Do not free the returned value, it belongs to @object.
 */
const gchar *
ms_dbus_sysupdate_target_get_path (MsDBusSysupdateTarget *object)
{
  g_return_val_if_fail (MS_DBUS_SYSUPDATE_IS_TARGET (object), NULL);

  return MS_DBUS_SYSUPDATE_TARGET_GET_IFACE (object)->get_path (object);
}

/**
 * ms_dbus_sysupdate_target_dup_path: (skip)
 * @object: A #MsDBusSysupdateTarget.
 *
 * Gets a copy of the <link linkend="gdbus-property-org-freedesktop-sysupdate1-Target.Path">"Path"</link> D-Bus property.
 *
 * Since this D-Bus property is readable, it is meaningful to use this function on both the client- and service-side.
 *
 * Returns: (transfer full) (nullable): The property value or %NULL if the property is not set. The returned value should be freed with g_free().
 */
gchar *
ms_dbus_sysupdate_target_dup_path (MsDBusSysupdateTarget *object)
{
  gchar *value;
  g_object_get (G_OBJECT (object), "path", &value, NULL);
  return value;
}

/**
 * ms_dbus_sysupdate_target_set_path: (skip)
 * @object: A #MsDBusSysupdateTarget.
 * @value: The value to set.
 *
 * Sets the <link linkend="gdbus-property-org-freedesktop-sysupdate1-Target.Path">"Path"</link> D-Bus property to @value.
 *
 * Since this D-Bus property is not writable, it is only meaningful to use this function on the service-side.
 */
void
ms_dbus_sysupdate_target_set_path (MsDBusSysupdateTarget *object, const gchar *value)
{
  g_object_set (G_OBJECT (object), "path", value, NULL);
}

/**
 * ms_dbus_sysupdate_target_call_list:
 * @proxy: A #MsDBusSysupdateTargetProxy.
 * @arg_flags: Argument to pass with the method invocation.
 * @call_flags: Flags from the #GDBusCallFlags enumeration. If you want to allow interactive
       authorization be sure to set %G_DBUS_CALL_FLAGS_ALLOW_INTERACTIVE_AUTHORIZATION.
 * @timeout_msec: The timeout in milliseconds (with %G_MAXINT meaning "infinite") or
       -1 to use the proxy default timeout.
 * @cancellable: (nullable): A #GCancellable or %NULL.
 * @callback: A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
 * @user_data: User data to pass to @callback.
 *
 * Asynchronously invokes the <link linkend="gdbus-method-org-freedesktop-sysupdate1-Target.List">List()</link> D-Bus method on @proxy.
 * When the operation is finished, @callback will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
 * You can then call ms_dbus_sysupdate_target_call_list_finish() to get the result of the operation.
 *
 * See ms_dbus_sysupdate_target_call_list_sync() for the synchronous, blocking version of this method.
 */
void
ms_dbus_sysupdate_target_call_list (
    MsDBusSysupdateTarget *proxy,
    guint64 arg_flags,
    GDBusCallFlags call_flags,
    gint timeout_msec,
    GCancellable *cancellable,
    GAsyncReadyCallback callback,
    gpointer user_data)
{
  g_dbus_proxy_call (G_DBUS_PROXY (proxy),
    "List",
    g_variant_new ("(t)",
                   arg_flags),
    call_flags,
    timeout_msec,
    cancellable,
    callback,
    user_data);
}

/**
 * ms_dbus_sysupdate_target_call_list_finish:
 * @proxy: A #MsDBusSysupdateTargetProxy.
 * @out_versions: (out) (optional) (array zero-terminated=1): Return location for return parameter or %NULL to ignore.
 * @res: The #GAsyncResult obtained from the #GAsyncReadyCallback passed to ms_dbus_sysupdate_target_call_list().
 * @error: Return location for error or %NULL.
 *
 * Finishes an operation started with ms_dbus_sysupdate_target_call_list().
 *
 * Returns: (skip): %TRUE if the call succeeded, %FALSE if @error is set.
 */
gboolean
ms_dbus_sysupdate_target_call_list_finish (
    MsDBusSysupdateTarget *proxy,
    gchar *** out_versions,
    GAsyncResult *res,
    GError **error)
{
  GVariant *_ret;
  _ret = g_dbus_proxy_call_finish (G_DBUS_PROXY (proxy), res, error);
  if (_ret == NULL)
    goto _out;
  g_variant_get (_ret,
                 "(^as)",
                 out_versions);
  g_variant_unref (_ret);
_out:
  return _ret != NULL;
}

/**
 * ms_dbus_sysupdate_target_call_list_sync:
 * @proxy: A #MsDBusSysupdateTargetProxy.
 * @arg_flags: Argument to pass with the method invocation.
 * @call_flags: Flags from the #GDBusCallFlags enumeration. If you want to allow interactive
       authorization be sure to set %G_DBUS_CALL_FLAGS_ALLOW_INTERACTIVE_AUTHORIZATION.
 * @timeout_msec: The timeout in milliseconds (with %G_MAXINT meaning "infinite") or
       -1 to use the proxy default timeout.
 * @out_versions: (out) (optional) (array zero-terminated=1): Return location for return parameter or %NULL to ignore.
 * @cancellable: (nullable): A #GCancellable or %NULL.
 * @error: Return location for error or %NULL.
 *
 * Synchronously invokes the <link linkend="gdbus-method-org-freedesktop-sysupdate1-Target.List">List()</link> D-Bus method on @proxy. The calling thread is blocked until a reply is received.
 *
 * See ms_dbus_sysupdate_target_call_list() for the asynchronous version of this method.
 *
 * Returns: (skip): %TRUE if the call succeeded, %FALSE if @error is set.
 */
gboolean
ms_dbus_sysupdate_target_call_list_sync (
    MsDBusSysupdateTarget *proxy,
    guint64 arg_flags,
    GDBusCallFlags call_flags,
    gint timeout_msec,
    gchar *** out_versions,
    GCancellable *cancellable,
    GError **error)
{
  GVariant *_ret;
  _ret = g_dbus_proxy_call_sync (G_DBUS_PROXY (proxy),
    "List",
    g_variant_new ("(t)",
                   arg_flags),
    call_flags,
    timeout_msec,
    cancellable,
    error);
  if (_ret == NULL)
    goto _out;
  g_variant_get (_ret,
                 "(^as)",
                 out_versions);
  g_variant_unref (_ret);
_out:
  return _ret != NULL;
}

/**
 * ms_dbus_sysupdate_target_call_describe:
 * @proxy: A #MsDBusSysupdateTargetProxy.
 * @arg_version: Argument to pass with the method invocation.
 * @arg_flags: Argument to pass with the method invocation.
 * @call_flags: Flags from the #GDBusCallFlags enumeration. If you want to allow interactive
       authorization be sure to set %G_DBUS_CALL_FLAGS_ALLOW_INTERACTIVE_AUTHORIZATION.
 * @timeout_msec: The timeout in milliseconds (with %G_MAXINT meaning "infinite") or
       -1 to use the proxy default timeout.
 * @cancellable: (nullable): A #GCancellable or %NULL.
 * @callback: A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
 * @user_data: User data to pass to @callback.
 *
 * Asynchronously invokes the <link linkend="gdbus-method-org-freedesktop-sysupdate1-Target.Describe">Describe()</link> D-Bus method on @proxy.
 * When the operation is finished, @callback will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
 * You can then call ms_dbus_sysupdate_target_call_describe_finish() to get the result of the operation.
 *
 * See ms_dbus_sysupdate_target_call_describe_sync() for the synchronous, blocking version of this method.
 */
void
ms_dbus_sysupdate_target_call_describe (
    MsDBusSysupdateTarget *proxy,
    const gchar *arg_version,
    guint64 arg_flags,
    GDBusCallFlags call_flags,
    gint timeout_msec,
    GCancellable *cancellable,
    GAsyncReadyCallback callback,
    gpointer user_data)
{
  g_dbus_proxy_call (G_DBUS_PROXY (proxy),
    "Describe",
    g_variant_new ("(st)",
                   arg_version,
                   arg_flags),
    call_flags,
    timeout_msec,
    cancellable,
    callback,
    user_data);
}

/**
 * ms_dbus_sysupdate_target_call_describe_finish:
 * @proxy: A #MsDBusSysupdateTargetProxy.
 * @out_json: (out) (optional): Return location for return parameter or %NULL to ignore.
 * @res: The #GAsyncResult obtained from the #GAsyncReadyCallback passed to ms_dbus_sysupdate_target_call_describe().
 * @error: Return location for error or %NULL.
 *
 * Finishes an operation started with ms_dbus_sysupdate_target_call_describe().
 *
 * Returns: (skip): %TRUE if the call succeeded, %FALSE if @error is set.
 */
gboolean
ms_dbus_sysupdate_target_call_describe_finish (
    MsDBusSysupdateTarget *proxy,
    gchar ** out_json,
    GAsyncResult *res,
    GError **error)
{
  GVariant *_ret;
  _ret = g_dbus_proxy_call_finish (G_DBUS_PROXY (proxy), res, error);
  if (_ret == NULL)
    goto _out;
  g_variant_get (_ret,
                 "(s)",
                 out_json);
  g_variant_unref (_ret);
_out:
  return _ret != NULL;
}

/**
 * ms_dbus_sysupdate_target_call_describe_sync:
 * @proxy: A #MsDBusSysupdateTargetProxy.
 * @arg_version: Argument to pass with the method invocation.
 * @arg_flags: Argument to pass with the method invocation.
 * @call_flags: Flags from the #GDBusCallFlags enumeration. If you want to allow interactive
       authorization be sure to set %G_DBUS_CALL_FLAGS_ALLOW_INTERACTIVE_AUTHORIZATION.
 * @timeout_msec: The timeout in milliseconds (with %G_MAXINT meaning "infinite") or
       -1 to use the proxy default timeout.
 * @out_json: (out) (optional): Return location for return parameter or %NULL to ignore.
 * @cancellable: (nullable): A #GCancellable or %NULL.
 * @error: Return location for error or %NULL.
 *
 * Synchronously invokes the <link linkend="gdbus-method-org-freedesktop-sysupdate1-Target.Describe">Describe()</link> D-Bus method on @proxy. The calling thread is blocked until a reply is received.
 *
 * See ms_dbus_sysupdate_target_call_describe() for the asynchronous version of this method.
 *
 * Returns: (skip): %TRUE if the call succeeded, %FALSE if @error is set.
 */
gboolean
ms_dbus_sysupdate_target_call_describe_sync (
    MsDBusSysupdateTarget *proxy,
    const gchar *arg_version,
    guint64 arg_flags,
    GDBusCallFlags call_flags,
    gint timeout_msec,
    gchar ** out_json,
    GCancellable *cancellable,
    GError **error)
{
  GVariant *_ret;
  _ret = g_dbus_proxy_call_sync (G_DBUS_PROXY (proxy),
    "Describe",
    g_variant_new ("(st)",
                   arg_version,
                   arg_flags),
    call_flags,
    timeout_msec,
    cancellable,
    error);
  if (_ret == NULL)
    goto _out;
  g_variant_get (_ret,
                 "(s)",
                 out_json);
  g_variant_unref (_ret);
_out:
  return _ret != NULL;
}

/**
 * ms_dbus_sysupdate_target_call_check_new:
 * @proxy: A #MsDBusSysupdateTargetProxy.
 * @call_flags: Flags from the #GDBusCallFlags enumeration. If you want to allow interactive
       authorization be sure to set %G_DBUS_CALL_FLAGS_ALLOW_INTERACTIVE_AUTHORIZATION.
 * @timeout_msec: The timeout in milliseconds (with %G_MAXINT meaning "infinite") or
       -1 to use the proxy default timeout.
 * @cancellable: (nullable): A #GCancellable or %NULL.
 * @callback: A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
 * @user_data: User data to pass to @callback.
 *
 * Asynchronously invokes the <link linkend="gdbus-method-org-freedesktop-sysupdate1-Target.CheckNew">CheckNew()</link> D-Bus method on @proxy.
 * When the operation is finished, @callback will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
 * You can then call ms_dbus_sysupdate_target_call_check_new_finish() to get the result of the operation.
 *
 * See ms_dbus_sysupdate_target_call_check_new_sync() for the synchronous, blocking version of this method.
 */
void
ms_dbus_sysupdate_target_call_check_new (
    MsDBusSysupdateTarget *proxy,
    GDBusCallFlags call_flags,
    gint timeout_msec,
    GCancellable *cancellable,
    GAsyncReadyCallback callback,
    gpointer user_data)
{
  g_dbus_proxy_call (G_DBUS_PROXY (proxy),
    "CheckNew",
    g_variant_new ("()"),
    call_flags,
    timeout_msec,
    cancellable,
    callback,
    user_data);
}

/**
 * ms_dbus_sysupdate_target_call_check_new_finish:
 * @proxy: A #MsDBusSysupdateTargetProxy.
 * @out_new_version: (out) (optional): Return location for return parameter or %NULL to ignore.
 * @res: The #GAsyncResult obtained from the #GAsyncReadyCallback passed to ms_dbus_sysupdate_target_call_check_new().
 * @error: Return location for error or %NULL.
 *
 * Finishes an operation started with ms_dbus_sysupdate_target_call_check_new().
 *
 * Returns: (skip): %TRUE if the call succeeded, %FALSE if @error is set.
 */
gboolean
ms_dbus_sysupdate_target_call_check_new_finish (
    MsDBusSysupdateTarget *proxy,
    gchar ** out_new_version,
    GAsyncResult *res,
    GError **error)
{
  GVariant *_ret;
  _ret = g_dbus_proxy_call_finish (G_DBUS_PROXY (proxy), res, error);
  if (_ret == NULL)
    goto _out;
  g_variant_get (_ret,
                 "(s)",
                 out_new_version);
  g_variant_unref (_ret);
_out:
  return _ret != NULL;
}

/**
 * ms_dbus_sysupdate_target_call_check_new_sync:
 * @proxy: A #MsDBusSysupdateTargetProxy.
 * @call_flags: Flags from the #GDBusCallFlags enumeration. If you want to allow interactive
       authorization be sure to set %G_DBUS_CALL_FLAGS_ALLOW_INTERACTIVE_AUTHORIZATION.
 * @timeout_msec: The timeout in milliseconds (with %G_MAXINT meaning "infinite") or
       -1 to use the proxy default timeout.
 * @out_new_version: (out) (optional): Return location for return parameter or %NULL to ignore.
 * @cancellable: (nullable): A #GCancellable or %NULL.
 * @error: Return location for error or %NULL.
 *
 * Synchronously invokes the <link linkend="gdbus-method-org-freedesktop-sysupdate1-Target.CheckNew">CheckNew()</link> D-Bus method on @proxy. The calling thread is blocked until a reply is received.
 *
 * See ms_dbus_sysupdate_target_call_check_new() for the asynchronous version of this method.
 *
 * Returns: (skip): %TRUE if the call succeeded, %FALSE if @error is set.
 */
gboolean
ms_dbus_sysupdate_target_call_check_new_sync (
    MsDBusSysupdateTarget *proxy,
    GDBusCallFlags call_flags,
    gint timeout_msec,
    gchar ** out_new_version,
    GCancellable *cancellable,
    GError **error)
{
  GVariant *_ret;
  _ret = g_dbus_proxy_call_sync (G_DBUS_PROXY (proxy),
    "CheckNew",
    g_variant_new ("()"),
    call_flags,
    timeout_msec,
    cancellable,
    error);
  if (_ret == NULL)
    goto _out;
  g_variant_get (_ret,
                 "(s)",
                 out_new_version);
  g_variant_unref (_ret);
_out:
  return _ret != NULL;
}

/**
 * ms_dbus_sysupdate_target_call_acquire:
 * @proxy: A #MsDBusSysupdateTargetProxy.
 * @arg_new_version: Argument to pass with the method invocation.
 * @arg_flags: Argument to pass with the method invocation.
 * @call_flags: Flags from the #GDBusCallFlags enumeration. If you want to allow interactive
       authorization be sure to set %G_DBUS_CALL_FLAGS_ALLOW_INTERACTIVE_AUTHORIZATION.
 * @timeout_msec: The timeout in milliseconds (with %G_MAXINT meaning "infinite") or
       -1 to use the proxy default timeout.
 * @cancellable: (nullable): A #GCancellable or %NULL.
 * @callback: A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
 * @user_data: User data to pass to @callback.
 *
 * Asynchronously invokes the <link linkend="gdbus-method-org-freedesktop-sysupdate1-Target.Acquire">Acquire()</link> D-Bus method on @proxy.
 * When the operation is finished, @callback will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
 * You can then call ms_dbus_sysupdate_target_call_acquire_finish() to get the result of the operation.
 *
 * See ms_dbus_sysupdate_target_call_acquire_sync() for the synchronous, blocking version of this method.
 */
void
ms_dbus_sysupdate_target_call_acquire (
    MsDBusSysupdateTarget *proxy,
    const gchar *arg_new_version,
    guint64 arg_flags,
    GDBusCallFlags call_flags,
    gint timeout_msec,
    GCancellable *cancellable,
    GAsyncReadyCallback callback,
    gpointer user_data)
{
  g_dbus_proxy_call (G_DBUS_PROXY (proxy),
    "Acquire",
    g_variant_new ("(st)",
                   arg_new_version,
                   arg_flags),
    call_flags,
    timeout_msec,
    cancellable,
    callback,
    user_data);
}

/**
 * ms_dbus_sysupdate_target_call_acquire_finish:
 * @proxy: A #MsDBusSysupdateTargetProxy.
 * @out_new_version: (out) (optional): Return location for return parameter or %NULL to ignore.
 * @out_job_id: (out) (optional): Return location for return parameter or %NULL to ignore.
 * @out_job_path: (out) (optional): Return location for return parameter or %NULL to ignore.
 * @res: The #GAsyncResult obtained from the #GAsyncReadyCallback passed to ms_dbus_sysupdate_target_call_acquire().
 * @error: Return location for error or %NULL.
 *
 * Finishes an operation started with ms_dbus_sysupdate_target_call_acquire().
 *
 * Returns: (skip): %TRUE if the call succeeded, %FALSE if @error is set.
 */
gboolean
ms_dbus_sysupdate_target_call_acquire_finish (
    MsDBusSysupdateTarget *proxy,
    gchar ** out_new_version,
    guint64* out_job_id,
    gchar ** out_job_path,
    GAsyncResult *res,
    GError **error)
{
  GVariant *_ret;
  _ret = g_dbus_proxy_call_finish (G_DBUS_PROXY (proxy), res, error);
  if (_ret == NULL)
    goto _out;
  g_variant_get (_ret,
                 "(sto)",
                 out_new_version,
                 out_job_id,
                 out_job_path);
  g_variant_unref (_ret);
_out:
  return _ret != NULL;
}

/**
 * ms_dbus_sysupdate_target_call_acquire_sync:
 * @proxy: A #MsDBusSysupdateTargetProxy.
 * @arg_new_version: Argument to pass with the method invocation.
 * @arg_flags: Argument to pass with the method invocation.
 * @call_flags: Flags from the #GDBusCallFlags enumeration. If you want to allow interactive
       authorization be sure to set %G_DBUS_CALL_FLAGS_ALLOW_INTERACTIVE_AUTHORIZATION.
 * @timeout_msec: The timeout in milliseconds (with %G_MAXINT meaning "infinite") or
       -1 to use the proxy default timeout.
 * @out_new_version: (out) (optional): Return location for return parameter or %NULL to ignore.
 * @out_job_id: (out) (optional): Return location for return parameter or %NULL to ignore.
 * @out_job_path: (out) (optional): Return location for return parameter or %NULL to ignore.
 * @cancellable: (nullable): A #GCancellable or %NULL.
 * @error: Return location for error or %NULL.
 *
 * Synchronously invokes the <link linkend="gdbus-method-org-freedesktop-sysupdate1-Target.Acquire">Acquire()</link> D-Bus method on @proxy. The calling thread is blocked until a reply is received.
 *
 * See ms_dbus_sysupdate_target_call_acquire() for the asynchronous version of this method.
 *
 * Returns: (skip): %TRUE if the call succeeded, %FALSE if @error is set.
 */
gboolean
ms_dbus_sysupdate_target_call_acquire_sync (
    MsDBusSysupdateTarget *proxy,
    const gchar *arg_new_version,
    guint64 arg_flags,
    GDBusCallFlags call_flags,
    gint timeout_msec,
    gchar ** out_new_version,
    guint64* out_job_id,
    gchar ** out_job_path,
    GCancellable *cancellable,
    GError **error)
{
  GVariant *_ret;
  _ret = g_dbus_proxy_call_sync (G_DBUS_PROXY (proxy),
    "Acquire",
    g_variant_new ("(st)",
                   arg_new_version,
                   arg_flags),
    call_flags,
    timeout_msec,
    cancellable,
    error);
  if (_ret == NULL)
    goto _out;
  g_variant_get (_ret,
                 "(sto)",
                 out_new_version,
                 out_job_id,
                 out_job_path);
  g_variant_unref (_ret);
_out:
  return _ret != NULL;
}

/**
 * ms_dbus_sysupdate_target_call_install:
 * @proxy: A #MsDBusSysupdateTargetProxy.
 * @arg_new_version: Argument to pass with the method invocation.
 * @arg_flags: Argument to pass with the method invocation.
 * @call_flags: Flags from the #GDBusCallFlags enumeration. If you want to allow interactive
       authorization be sure to set %G_DBUS_CALL_FLAGS_ALLOW_INTERACTIVE_AUTHORIZATION.
 * @timeout_msec: The timeout in milliseconds (with %G_MAXINT meaning "infinite") or
       -1 to use the proxy default timeout.
 * @cancellable: (nullable): A #GCancellable or %NULL.
 * @callback: A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
 * @user_data: User data to pass to @callback.
 *
 * Asynchronously invokes the <link linkend="gdbus-method-org-freedesktop-sysupdate1-Target.Install">Install()</link> D-Bus method on @proxy.
 * When the operation is finished, @callback will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
 * You can then call ms_dbus_sysupdate_target_call_install_finish() to get the result of the operation.
 *
 * See ms_dbus_sysupdate_target_call_install_sync() for the synchronous, blocking version of this method.
 */
void
ms_dbus_sysupdate_target_call_install (
    MsDBusSysupdateTarget *proxy,
    const gchar *arg_new_version,
    guint64 arg_flags,
    GDBusCallFlags call_flags,
    gint timeout_msec,
    GCancellable *cancellable,
    GAsyncReadyCallback callback,
    gpointer user_data)
{
  g_dbus_proxy_call (G_DBUS_PROXY (proxy),
    "Install",
    g_variant_new ("(st)",
                   arg_new_version,
                   arg_flags),
    call_flags,
    timeout_msec,
    cancellable,
    callback,
    user_data);
}

/**
 * ms_dbus_sysupdate_target_call_install_finish:
 * @proxy: A #MsDBusSysupdateTargetProxy.
 * @out_new_version: (out) (optional): Return location for return parameter or %NULL to ignore.
 * @out_job_id: (out) (optional): Return location for return parameter or %NULL to ignore.
 * @out_job_path: (out) (optional): Return location for return parameter or %NULL to ignore.
 * @res: The #GAsyncResult obtained from the #GAsyncReadyCallback passed to ms_dbus_sysupdate_target_call_install().
 * @error: Return location for error or %NULL.
 *
 * Finishes an operation started with ms_dbus_sysupdate_target_call_install().
 *
 * Returns: (skip): %TRUE if the call succeeded, %FALSE if @error is set.
 */
gboolean
ms_dbus_sysupdate_target_call_install_finish (
    MsDBusSysupdateTarget *proxy,
    gchar ** out_new_version,
    guint64* out_job_id,
    gchar ** out_job_path,
    GAsyncResult *res,
    GError **error)
{
  GVariant *_ret;
  _ret = g_dbus_proxy_call_finish (G_DBUS_PROXY (proxy), res, error);
  if (_ret == NULL)
    goto _out;
  g_variant_get (_ret,
                 "(sto)",
                 out_new_version,
                 out_job_id,
                 out_job_path);
  g_variant_unref (_ret);
_out:
  return _ret != NULL;
}

/**
 * ms_dbus_sysupdate_target_call_install_sync:
 * @proxy: A #MsDBusSysupdateTargetProxy.
 * @arg_new_version: Argument to pass with the method invocation.
 * @arg_flags: Argument to pass with the method invocation.
 * @call_flags: Flags from the #GDBusCallFlags enumeration. If you want to allow interactive
       authorization be sure to set %G_DBUS_CALL_FLAGS_ALLOW_INTERACTIVE_AUTHORIZATION.
 * @timeout_msec: The timeout in milliseconds (with %G_MAXINT meaning "infinite") or
       -1 to use the proxy default timeout.
 * @out_new_version: (out) (optional): Return location for return parameter or %NULL to ignore.
 * @out_job_id: (out) (optional): Return location for return parameter or %NULL to ignore.
 * @out_job_path: (out) (optional): Return location for return parameter or %NULL to ignore.
 * @cancellable: (nullable): A #GCancellable or %NULL.
 * @error: Return location for error or %NULL.
 *
 * Synchronously invokes the <link linkend="gdbus-method-org-freedesktop-sysupdate1-Target.Install">Install()</link> D-Bus method on @proxy. The calling thread is blocked until a reply is received.
 *
 * See ms_dbus_sysupdate_target_call_install() for the asynchronous version of this method.
 *
 * Returns: (skip): %TRUE if the call succeeded, %FALSE if @error is set.
 */
gboolean
ms_dbus_sysupdate_target_call_install_sync (
    MsDBusSysupdateTarget *proxy,
    const gchar *arg_new_version,
    guint64 arg_flags,
    GDBusCallFlags call_flags,
    gint timeout_msec,
    gchar ** out_new_version,
    guint64* out_job_id,
    gchar ** out_job_path,
    GCancellable *cancellable,
    GError **error)
{
  GVariant *_ret;
  _ret = g_dbus_proxy_call_sync (G_DBUS_PROXY (proxy),
    "Install",
    g_variant_new ("(st)",
                   arg_new_version,
                   arg_flags),
    call_flags,
    timeout_msec,
    cancellable,
    error);
  if (_ret == NULL)
    goto _out;
  g_variant_get (_ret,
                 "(sto)",
                 out_new_version,
                 out_job_id,
                 out_job_path);
  g_variant_unref (_ret);
_out:
  return _ret != NULL;
}

/**
 * ms_dbus_sysupdate_target_call_vacuum:
 * @proxy: A #MsDBusSysupdateTargetProxy.
 * @call_flags: Flags from the #GDBusCallFlags enumeration. If you want to allow interactive
       authorization be sure to set %G_DBUS_CALL_FLAGS_ALLOW_INTERACTIVE_AUTHORIZATION.
 * @timeout_msec: The timeout in milliseconds (with %G_MAXINT meaning "infinite") or
       -1 to use the proxy default timeout.
 * @cancellable: (nullable): A #GCancellable or %NULL.
 * @callback: A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
 * @user_data: User data to pass to @callback.
 *
 * Asynchronously invokes the <link linkend="gdbus-method-org-freedesktop-sysupdate1-Target.Vacuum">Vacuum()</link> D-Bus method on @proxy.
 * When the operation is finished, @callback will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
 * You can then call ms_dbus_sysupdate_target_call_vacuum_finish() to get the result of the operation.
 *
 * See ms_dbus_sysupdate_target_call_vacuum_sync() for the synchronous, blocking version of this method.
 */
void
ms_dbus_sysupdate_target_call_vacuum (
    MsDBusSysupdateTarget *proxy,
    GDBusCallFlags call_flags,
    gint timeout_msec,
    GCancellable *cancellable,
    GAsyncReadyCallback callback,
    gpointer user_data)
{
  g_dbus_proxy_call (G_DBUS_PROXY (proxy),
    "Vacuum",
    g_variant_new ("()"),
    call_flags,
    timeout_msec,
    cancellable,
    callback,
    user_data);
}

/**
 * ms_dbus_sysupdate_target_call_vacuum_finish:
 * @proxy: A #MsDBusSysupdateTargetProxy.
 * @out_instances: (out) (optional): Return location for return parameter or %NULL to ignore.
 * @out_disabled_transfers: (out) (optional): Return location for return parameter or %NULL to ignore.
 * @res: The #GAsyncResult obtained from the #GAsyncReadyCallback passed to ms_dbus_sysupdate_target_call_vacuum().
 * @error: Return location for error or %NULL.
 *
 * Finishes an operation started with ms_dbus_sysupdate_target_call_vacuum().
 *
 * Returns: (skip): %TRUE if the call succeeded, %FALSE if @error is set.
 */
gboolean
ms_dbus_sysupdate_target_call_vacuum_finish (
    MsDBusSysupdateTarget *proxy,
    guint* out_instances,
    guint* out_disabled_transfers,
    GAsyncResult *res,
    GError **error)
{
  GVariant *_ret;
  _ret = g_dbus_proxy_call_finish (G_DBUS_PROXY (proxy), res, error);
  if (_ret == NULL)
    goto _out;
  g_variant_get (_ret,
                 "(uu)",
                 out_instances,
                 out_disabled_transfers);
  g_variant_unref (_ret);
_out:
  return _ret != NULL;
}

/**
 * ms_dbus_sysupdate_target_call_vacuum_sync:
 * @proxy: A #MsDBusSysupdateTargetProxy.
 * @call_flags: Flags from the #GDBusCallFlags enumeration. If you want to allow interactive
       authorization be sure to set %G_DBUS_CALL_FLAGS_ALLOW_INTERACTIVE_AUTHORIZATION.
 * @timeout_msec: The timeout in milliseconds (with %G_MAXINT meaning "infinite") or
       -1 to use the proxy default timeout.
 * @out_instances: (out) (optional): Return location for return parameter or %NULL to ignore.
 * @out_disabled_transfers: (out) (optional): Return location for return parameter or %NULL to ignore.
 * @cancellable: (nullable): A #GCancellable or %NULL.
 * @error: Return location for error or %NULL.
 *
 * Synchronously invokes the <link linkend="gdbus-method-org-freedesktop-sysupdate1-Target.Vacuum">Vacuum()</link> D-Bus method on @proxy. The calling thread is blocked until a reply is received.
 *
 * See ms_dbus_sysupdate_target_call_vacuum() for the asynchronous version of this method.
 *
 * Returns: (skip): %TRUE if the call succeeded, %FALSE if @error is set.
 */
gboolean
ms_dbus_sysupdate_target_call_vacuum_sync (
    MsDBusSysupdateTarget *proxy,
    GDBusCallFlags call_flags,
    gint timeout_msec,
    guint* out_instances,
    guint* out_disabled_transfers,
    GCancellable *cancellable,
    GError **error)
{
  GVariant *_ret;
  _ret = g_dbus_proxy_call_sync (G_DBUS_PROXY (proxy),
    "Vacuum",
    g_variant_new ("()"),
    call_flags,
    timeout_msec,
    cancellable,
    error);
  if (_ret == NULL)
    goto _out;
  g_variant_get (_ret,
                 "(uu)",
                 out_instances,
                 out_disabled_transfers);
  g_variant_unref (_ret);
_out:
  return _ret != NULL;
}

/**
 * ms_dbus_sysupdate_target_call_get_app_stream:
 * @proxy: A #MsDBusSysupdateTargetProxy.
 * @call_flags: Flags from the #GDBusCallFlags enumeration. If you want to allow interactive
       authorization be sure to set %G_DBUS_CALL_FLAGS_ALLOW_INTERACTIVE_AUTHORIZATION.
 * @timeout_msec: The timeout in milliseconds (with %G_MAXINT meaning "infinite") or
       -1 to use the proxy default timeout.
 * @cancellable: (nullable): A #GCancellable or %NULL.
 * @callback: A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
 * @user_data: User data to pass to @callback.
 *
 * Asynchronously invokes the <link linkend="gdbus-method-org-freedesktop-sysupdate1-Target.GetAppStream">GetAppStream()</link> D-Bus method on @proxy.
 * When the operation is finished, @callback will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
 * You can then call ms_dbus_sysupdate_target_call_get_app_stream_finish() to get the result of the operation.
 *
 * See ms_dbus_sysupdate_target_call_get_app_stream_sync() for the synchronous, blocking version of this method.
 */
void
ms_dbus_sysupdate_target_call_get_app_stream (
    MsDBusSysupdateTarget *proxy,
    GDBusCallFlags call_flags,
    gint timeout_msec,
    GCancellable *cancellable,
    GAsyncReadyCallback callback,
    gpointer user_data)
{
  g_dbus_proxy_call (G_DBUS_PROXY (proxy),
    "GetAppStream",
    g_variant_new ("()"),
    call_flags,
    timeout_msec,
    cancellable,
    callback,
    user_data);
}

/**
 * ms_dbus_sysupdate_target_call_get_app_stream_finish:
 * @proxy: A #MsDBusSysupdateTargetProxy.
 * @out_appstream: (out) (optional) (array zero-terminated=1): Return location for return parameter or %NULL to ignore.
 * @res: The #GAsyncResult obtained from the #GAsyncReadyCallback passed to ms_dbus_sysupdate_target_call_get_app_stream().
 * @error: Return location for error or %NULL.
 *
 * Finishes an operation started with ms_dbus_sysupdate_target_call_get_app_stream().
 *
 * Returns: (skip): %TRUE if the call succeeded, %FALSE if @error is set.
 */
gboolean
ms_dbus_sysupdate_target_call_get_app_stream_finish (
    MsDBusSysupdateTarget *proxy,
    gchar *** out_appstream,
    GAsyncResult *res,
    GError **error)
{
  GVariant *_ret;
  _ret = g_dbus_proxy_call_finish (G_DBUS_PROXY (proxy), res, error);
  if (_ret == NULL)
    goto _out;
  g_variant_get (_ret,
                 "(^as)",
                 out_appstream);
  g_variant_unref (_ret);
_out:
  return _ret != NULL;
}

/**
 * ms_dbus_sysupdate_target_call_get_app_stream_sync:
 * @proxy: A #MsDBusSysupdateTargetProxy.
 * @call_flags: Flags from the #GDBusCallFlags enumeration. If you want to allow interactive
       authorization be sure to set %G_DBUS_CALL_FLAGS_ALLOW_INTERACTIVE_AUTHORIZATION.
 * @timeout_msec: The timeout in milliseconds (with %G_MAXINT meaning "infinite") or
       -1 to use the proxy default timeout.
 * @out_appstream: (out) (optional) (array zero-terminated=1): Return location for return parameter or %NULL to ignore.
 * @cancellable: (nullable): A #GCancellable or %NULL.
 * @error: Return location for error or %NULL.
 *
 * Synchronously invokes the <link linkend="gdbus-method-org-freedesktop-sysupdate1-Target.GetAppStream">GetAppStream()</link> D-Bus method on @proxy. The calling thread is blocked until a reply is received.
 *
 * See ms_dbus_sysupdate_target_call_get_app_stream() for the asynchronous version of this method.
 *
 * Returns: (skip): %TRUE if the call succeeded, %FALSE if @error is set.
 */
gboolean
ms_dbus_sysupdate_target_call_get_app_stream_sync (
    MsDBusSysupdateTarget *proxy,
    GDBusCallFlags call_flags,
    gint timeout_msec,
    gchar *** out_appstream,
    GCancellable *cancellable,
    GError **error)
{
  GVariant *_ret;
  _ret = g_dbus_proxy_call_sync (G_DBUS_PROXY (proxy),
    "GetAppStream",
    g_variant_new ("()"),
    call_flags,
    timeout_msec,
    cancellable,
    error);
  if (_ret == NULL)
    goto _out;
  g_variant_get (_ret,
                 "(^as)",
                 out_appstream);
  g_variant_unref (_ret);
_out:
  return _ret != NULL;
}

/**
 * ms_dbus_sysupdate_target_call_get_version:
 * @proxy: A #MsDBusSysupdateTargetProxy.
 * @call_flags: Flags from the #GDBusCallFlags enumeration. If you want to allow interactive
       authorization be sure to set %G_DBUS_CALL_FLAGS_ALLOW_INTERACTIVE_AUTHORIZATION.
 * @timeout_msec: The timeout in milliseconds (with %G_MAXINT meaning "infinite") or
       -1 to use the proxy default timeout.
 * @cancellable: (nullable): A #GCancellable or %NULL.
 * @callback: A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
 * @user_data: User data to pass to @callback.
 *
 * Asynchronously invokes the <link linkend="gdbus-method-org-freedesktop-sysupdate1-Target.GetVersion">GetVersion()</link> D-Bus method on @proxy.
 * When the operation is finished, @callback will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
 * You can then call ms_dbus_sysupdate_target_call_get_version_finish() to get the result of the operation.
 *
 * See ms_dbus_sysupdate_target_call_get_version_sync() for the synchronous, blocking version of this method.
 */
void
ms_dbus_sysupdate_target_call_get_version (
    MsDBusSysupdateTarget *proxy,
    GDBusCallFlags call_flags,
    gint timeout_msec,
    GCancellable *cancellable,
    GAsyncReadyCallback callback,
    gpointer user_data)
{
  g_dbus_proxy_call (G_DBUS_PROXY (proxy),
    "GetVersion",
    g_variant_new ("()"),
    call_flags,
    timeout_msec,
    cancellable,
    callback,
    user_data);
}

/**
 * ms_dbus_sysupdate_target_call_get_version_finish:
 * @proxy: A #MsDBusSysupdateTargetProxy.
 * @out_version: (out) (optional): Return location for return parameter or %NULL to ignore.
 * @res: The #GAsyncResult obtained from the #GAsyncReadyCallback passed to ms_dbus_sysupdate_target_call_get_version().
 * @error: Return location for error or %NULL.
 *
 * Finishes an operation started with ms_dbus_sysupdate_target_call_get_version().
 *
 * Returns: (skip): %TRUE if the call succeeded, %FALSE if @error is set.
 */
gboolean
ms_dbus_sysupdate_target_call_get_version_finish (
    MsDBusSysupdateTarget *proxy,
    gchar ** out_version,
    GAsyncResult *res,
    GError **error)
{
  GVariant *_ret;
  _ret = g_dbus_proxy_call_finish (G_DBUS_PROXY (proxy), res, error);
  if (_ret == NULL)
    goto _out;
  g_variant_get (_ret,
                 "(s)",
                 out_version);
  g_variant_unref (_ret);
_out:
  return _ret != NULL;
}

/**
 * ms_dbus_sysupdate_target_call_get_version_sync:
 * @proxy: A #MsDBusSysupdateTargetProxy.
 * @call_flags: Flags from the #GDBusCallFlags enumeration. If you want to allow interactive
       authorization be sure to set %G_DBUS_CALL_FLAGS_ALLOW_INTERACTIVE_AUTHORIZATION.
 * @timeout_msec: The timeout in milliseconds (with %G_MAXINT meaning "infinite") or
       -1 to use the proxy default timeout.
 * @out_version: (out) (optional): Return location for return parameter or %NULL to ignore.
 * @cancellable: (nullable): A #GCancellable or %NULL.
 * @error: Return location for error or %NULL.
 *
 * Synchronously invokes the <link linkend="gdbus-method-org-freedesktop-sysupdate1-Target.GetVersion">GetVersion()</link> D-Bus method on @proxy. The calling thread is blocked until a reply is received.
 *
 * See ms_dbus_sysupdate_target_call_get_version() for the asynchronous version of this method.
 *
 * Returns: (skip): %TRUE if the call succeeded, %FALSE if @error is set.
 */
gboolean
ms_dbus_sysupdate_target_call_get_version_sync (
    MsDBusSysupdateTarget *proxy,
    GDBusCallFlags call_flags,
    gint timeout_msec,
    gchar ** out_version,
    GCancellable *cancellable,
    GError **error)
{
  GVariant *_ret;
  _ret = g_dbus_proxy_call_sync (G_DBUS_PROXY (proxy),
    "GetVersion",
    g_variant_new ("()"),
    call_flags,
    timeout_msec,
    cancellable,
    error);
  if (_ret == NULL)
    goto _out;
  g_variant_get (_ret,
                 "(s)",
                 out_version);
  g_variant_unref (_ret);
_out:
  return _ret != NULL;
}

/**
 * ms_dbus_sysupdate_target_call_list_features:
 * @proxy: A #MsDBusSysupdateTargetProxy.
 * @arg_flags: Argument to pass with the method invocation.
 * @call_flags: Flags from the #GDBusCallFlags enumeration. If you want to allow interactive
       authorization be sure to set %G_DBUS_CALL_FLAGS_ALLOW_INTERACTIVE_AUTHORIZATION.
 * @timeout_msec: The timeout in milliseconds (with %G_MAXINT meaning "infinite") or
       -1 to use the proxy default timeout.
 * @cancellable: (nullable): A #GCancellable or %NULL.
 * @callback: A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
 * @user_data: User data to pass to @callback.
 *
 * Asynchronously invokes the <link linkend="gdbus-method-org-freedesktop-sysupdate1-Target.ListFeatures">ListFeatures()</link> D-Bus method on @proxy.
 * When the operation is finished, @callback will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
 * You can then call ms_dbus_sysupdate_target_call_list_features_finish() to get the result of the operation.
 *
 * See ms_dbus_sysupdate_target_call_list_features_sync() for the synchronous, blocking version of this method.
 */
void
ms_dbus_sysupdate_target_call_list_features (
    MsDBusSysupdateTarget *proxy,
    guint64 arg_flags,
    GDBusCallFlags call_flags,
    gint timeout_msec,
    GCancellable *cancellable,
    GAsyncReadyCallback callback,
    gpointer user_data)
{
  g_dbus_proxy_call (G_DBUS_PROXY (proxy),
    "ListFeatures",
    g_variant_new ("(t)",
                   arg_flags),
    call_flags,
    timeout_msec,
    cancellable,
    callback,
    user_data);
}

/**
 * ms_dbus_sysupdate_target_call_list_features_finish:
 * @proxy: A #MsDBusSysupdateTargetProxy.
 * @out_features: (out) (optional) (array zero-terminated=1): Return location for return parameter or %NULL to ignore.
 * @res: The #GAsyncResult obtained from the #GAsyncReadyCallback passed to ms_dbus_sysupdate_target_call_list_features().
 * @error: Return location for error or %NULL.
 *
 * Finishes an operation started with ms_dbus_sysupdate_target_call_list_features().
 *
 * Returns: (skip): %TRUE if the call succeeded, %FALSE if @error is set.
 */
gboolean
ms_dbus_sysupdate_target_call_list_features_finish (
    MsDBusSysupdateTarget *proxy,
    gchar *** out_features,
    GAsyncResult *res,
    GError **error)
{
  GVariant *_ret;
  _ret = g_dbus_proxy_call_finish (G_DBUS_PROXY (proxy), res, error);
  if (_ret == NULL)
    goto _out;
  g_variant_get (_ret,
                 "(^as)",
                 out_features);
  g_variant_unref (_ret);
_out:
  return _ret != NULL;
}

/**
 * ms_dbus_sysupdate_target_call_list_features_sync:
 * @proxy: A #MsDBusSysupdateTargetProxy.
 * @arg_flags: Argument to pass with the method invocation.
 * @call_flags: Flags from the #GDBusCallFlags enumeration. If you want to allow interactive
       authorization be sure to set %G_DBUS_CALL_FLAGS_ALLOW_INTERACTIVE_AUTHORIZATION.
 * @timeout_msec: The timeout in milliseconds (with %G_MAXINT meaning "infinite") or
       -1 to use the proxy default timeout.
 * @out_features: (out) (optional) (array zero-terminated=1): Return location for return parameter or %NULL to ignore.
 * @cancellable: (nullable): A #GCancellable or %NULL.
 * @error: Return location for error or %NULL.
 *
 * Synchronously invokes the <link linkend="gdbus-method-org-freedesktop-sysupdate1-Target.ListFeatures">ListFeatures()</link> D-Bus method on @proxy. The calling thread is blocked until a reply is received.
 *
 * See ms_dbus_sysupdate_target_call_list_features() for the asynchronous version of this method.
 *
 * Returns: (skip): %TRUE if the call succeeded, %FALSE if @error is set.
 */
gboolean
ms_dbus_sysupdate_target_call_list_features_sync (
    MsDBusSysupdateTarget *proxy,
    guint64 arg_flags,
    GDBusCallFlags call_flags,
    gint timeout_msec,
    gchar *** out_features,
    GCancellable *cancellable,
    GError **error)
{
  GVariant *_ret;
  _ret = g_dbus_proxy_call_sync (G_DBUS_PROXY (proxy),
    "ListFeatures",
    g_variant_new ("(t)",
                   arg_flags),
    call_flags,
    timeout_msec,
    cancellable,
    error);
  if (_ret == NULL)
    goto _out;
  g_variant_get (_ret,
                 "(^as)",
                 out_features);
  g_variant_unref (_ret);
_out:
  return _ret != NULL;
}

/**
 * ms_dbus_sysupdate_target_call_describe_feature:
 * @proxy: A #MsDBusSysupdateTargetProxy.
 * @arg_feature: Argument to pass with the method invocation.
 * @arg_flags: Argument to pass with the method invocation.
 * @call_flags: Flags from the #GDBusCallFlags enumeration. If you want to allow interactive
       authorization be sure to set %G_DBUS_CALL_FLAGS_ALLOW_INTERACTIVE_AUTHORIZATION.
 * @timeout_msec: The timeout in milliseconds (with %G_MAXINT meaning "infinite") or
       -1 to use the proxy default timeout.
 * @cancellable: (nullable): A #GCancellable or %NULL.
 * @callback: A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
 * @user_data: User data to pass to @callback.
 *
 * Asynchronously invokes the <link linkend="gdbus-method-org-freedesktop-sysupdate1-Target.DescribeFeature">DescribeFeature()</link> D-Bus method on @proxy.
 * When the operation is finished, @callback will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
 * You can then call ms_dbus_sysupdate_target_call_describe_feature_finish() to get the result of the operation.
 *
 * See ms_dbus_sysupdate_target_call_describe_feature_sync() for the synchronous, blocking version of this method.
 */
void
ms_dbus_sysupdate_target_call_describe_feature (
    MsDBusSysupdateTarget *proxy,
    const gchar *arg_feature,
    guint64 arg_flags,
    GDBusCallFlags call_flags,
    gint timeout_msec,
    GCancellable *cancellable,
    GAsyncReadyCallback callback,
    gpointer user_data)
{
  g_dbus_proxy_call (G_DBUS_PROXY (proxy),
    "DescribeFeature",
    g_variant_new ("(st)",
                   arg_feature,
                   arg_flags),
    call_flags,
    timeout_msec,
    cancellable,
    callback,
    user_data);
}

/**
 * ms_dbus_sysupdate_target_call_describe_feature_finish:
 * @proxy: A #MsDBusSysupdateTargetProxy.
 * @out_json: (out) (optional): Return location for return parameter or %NULL to ignore.
 * @res: The #GAsyncResult obtained from the #GAsyncReadyCallback passed to ms_dbus_sysupdate_target_call_describe_feature().
 * @error: Return location for error or %NULL.
 *
 * Finishes an operation started with ms_dbus_sysupdate_target_call_describe_feature().
 *
 * Returns: (skip): %TRUE if the call succeeded, %FALSE if @error is set.
 */
gboolean
ms_dbus_sysupdate_target_call_describe_feature_finish (
    MsDBusSysupdateTarget *proxy,
    gchar ** out_json,
    GAsyncResult *res,
    GError **error)
{
  GVariant *_ret;
  _ret = g_dbus_proxy_call_finish (G_DBUS_PROXY (proxy), res, error);
  if (_ret == NULL)
    goto _out;
  g_variant_get (_ret,
                 "(s)",
                 out_json);
  g_variant_unref (_ret);
_out:
  return _ret != NULL;
}

/**
 * ms_dbus_sysupdate_target_call_describe_feature_sync:
 * @proxy: A #MsDBusSysupdateTargetProxy.
 * @arg_feature: Argument to pass with the method invocation.
 * @arg_flags: Argument to pass with the method invocation.
 * @call_flags: Flags from the #GDBusCallFlags enumeration. If you want to allow interactive
       authorization be sure to set %G_DBUS_CALL_FLAGS_ALLOW_INTERACTIVE_AUTHORIZATION.
 * @timeout_msec: The timeout in milliseconds (with %G_MAXINT meaning "infinite") or
       -1 to use the proxy default timeout.
 * @out_json: (out) (optional): Return location for return parameter or %NULL to ignore.
 * @cancellable: (nullable): A #GCancellable or %NULL.
 * @error: Return location for error or %NULL.
 *
 * Synchronously invokes the <link linkend="gdbus-method-org-freedesktop-sysupdate1-Target.DescribeFeature">DescribeFeature()</link> D-Bus method on @proxy. The calling thread is blocked until a reply is received.
 *
 * See ms_dbus_sysupdate_target_call_describe_feature() for the asynchronous version of this method.
 *
 * Returns: (skip): %TRUE if the call succeeded, %FALSE if @error is set.
 */
gboolean
ms_dbus_sysupdate_target_call_describe_feature_sync (
    MsDBusSysupdateTarget *proxy,
    const gchar *arg_feature,
    guint64 arg_flags,
    GDBusCallFlags call_flags,
    gint timeout_msec,
    gchar ** out_json,
    GCancellable *cancellable,
    GError **error)
{
  GVariant *_ret;
  _ret = g_dbus_proxy_call_sync (G_DBUS_PROXY (proxy),
    "DescribeFeature",
    g_variant_new ("(st)",
                   arg_feature,
                   arg_flags),
    call_flags,
    timeout_msec,
    cancellable,
    error);
  if (_ret == NULL)
    goto _out;
  g_variant_get (_ret,
                 "(s)",
                 out_json);
  g_variant_unref (_ret);
_out:
  return _ret != NULL;
}

/**
 * ms_dbus_sysupdate_target_call_set_feature_enabled:
 * @proxy: A #MsDBusSysupdateTargetProxy.
 * @arg_feature: Argument to pass with the method invocation.
 * @arg_enabled: Argument to pass with the method invocation.
 * @arg_flags: Argument to pass with the method invocation.
 * @call_flags: Flags from the #GDBusCallFlags enumeration. If you want to allow interactive
       authorization be sure to set %G_DBUS_CALL_FLAGS_ALLOW_INTERACTIVE_AUTHORIZATION.
 * @timeout_msec: The timeout in milliseconds (with %G_MAXINT meaning "infinite") or
       -1 to use the proxy default timeout.
 * @cancellable: (nullable): A #GCancellable or %NULL.
 * @callback: A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
 * @user_data: User data to pass to @callback.
 *
 * Asynchronously invokes the <link linkend="gdbus-method-org-freedesktop-sysupdate1-Target.SetFeatureEnabled">SetFeatureEnabled()</link> D-Bus method on @proxy.
 * When the operation is finished, @callback will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
 * You can then call ms_dbus_sysupdate_target_call_set_feature_enabled_finish() to get the result of the operation.
 *
 * See ms_dbus_sysupdate_target_call_set_feature_enabled_sync() for the synchronous, blocking version of this method.
 */
void
ms_dbus_sysupdate_target_call_set_feature_enabled (
    MsDBusSysupdateTarget *proxy,
    const gchar *arg_feature,
    gint arg_enabled,
    guint64 arg_flags,
    GDBusCallFlags call_flags,
    gint timeout_msec,
    GCancellable *cancellable,
    GAsyncReadyCallback callback,
    gpointer user_data)
{
  g_dbus_proxy_call (G_DBUS_PROXY (proxy),
    "SetFeatureEnabled",
    g_variant_new ("(sit)",
                   arg_feature,
                   arg_enabled,
                   arg_flags),
    call_flags,
    timeout_msec,
    cancellable,
    callback,
    user_data);
}

/**
 * ms_dbus_sysupdate_target_call_set_feature_enabled_finish:
 * @proxy: A #MsDBusSysupdateTargetProxy.
 * @res: The #GAsyncResult obtained from the #GAsyncReadyCallback passed to ms_dbus_sysupdate_target_call_set_feature_enabled().
 * @error: Return location for error or %NULL.
 *
 * Finishes an operation started with ms_dbus_sysupdate_target_call_set_feature_enabled().
 *
 * Returns: (skip): %TRUE if the call succeeded, %FALSE if @error is set.
 */
gboolean
ms_dbus_sysupdate_target_call_set_feature_enabled_finish (
    MsDBusSysupdateTarget *proxy,
    GAsyncResult *res,
    GError **error)
{
  GVariant *_ret;
  _ret = g_dbus_proxy_call_finish (G_DBUS_PROXY (proxy), res, error);
  if (_ret == NULL)
    goto _out;
  g_variant_get (_ret,
                 "()");
  g_variant_unref (_ret);
_out:
  return _ret != NULL;
}

/**
 * ms_dbus_sysupdate_target_call_set_feature_enabled_sync:
 * @proxy: A #MsDBusSysupdateTargetProxy.
 * @arg_feature: Argument to pass with the method invocation.
 * @arg_enabled: Argument to pass with the method invocation.
 * @arg_flags: Argument to pass with the method invocation.
 * @call_flags: Flags from the #GDBusCallFlags enumeration. If you want to allow interactive
       authorization be sure to set %G_DBUS_CALL_FLAGS_ALLOW_INTERACTIVE_AUTHORIZATION.
 * @timeout_msec: The timeout in milliseconds (with %G_MAXINT meaning "infinite") or
       -1 to use the proxy default timeout.
 * @cancellable: (nullable): A #GCancellable or %NULL.
 * @error: Return location for error or %NULL.
 *
 * Synchronously invokes the <link linkend="gdbus-method-org-freedesktop-sysupdate1-Target.SetFeatureEnabled">SetFeatureEnabled()</link> D-Bus method on @proxy. The calling thread is blocked until a reply is received.
 *
 * See ms_dbus_sysupdate_target_call_set_feature_enabled() for the asynchronous version of this method.
 *
 * Returns: (skip): %TRUE if the call succeeded, %FALSE if @error is set.
 */
gboolean
ms_dbus_sysupdate_target_call_set_feature_enabled_sync (
    MsDBusSysupdateTarget *proxy,
    const gchar *arg_feature,
    gint arg_enabled,
    guint64 arg_flags,
    GDBusCallFlags call_flags,
    gint timeout_msec,
    GCancellable *cancellable,
    GError **error)
{
  GVariant *_ret;
  _ret = g_dbus_proxy_call_sync (G_DBUS_PROXY (proxy),
    "SetFeatureEnabled",
    g_variant_new ("(sit)",
                   arg_feature,
                   arg_enabled,
                   arg_flags),
    call_flags,
    timeout_msec,
    cancellable,
    error);
  if (_ret == NULL)
    goto _out;
  g_variant_get (_ret,
                 "()");
  g_variant_unref (_ret);
_out:
  return _ret != NULL;
}

/**
 * ms_dbus_sysupdate_target_complete_list:
 * @object: A #MsDBusSysupdateTarget.
 * @invocation: (transfer full): A #GDBusMethodInvocation.
 * @versions: Parameter to return.
 *
 * Helper function used in service implementations to finish handling invocations of the <link linkend="gdbus-method-org-freedesktop-sysupdate1-Target.List">List()</link> D-Bus method. If you instead want to finish handling an invocation by returning an error, use g_dbus_method_invocation_return_error() or similar.
 *
 * This method will free @invocation, you cannot use it afterwards.
 */
void
ms_dbus_sysupdate_target_complete_list (
    MsDBusSysupdateTarget *object G_GNUC_UNUSED,
    GDBusMethodInvocation *invocation,
    const gchar *const *versions)
{
  g_dbus_method_invocation_return_value (invocation,
    g_variant_new ("(^as)",
                   versions));
}

/**
 * ms_dbus_sysupdate_target_complete_describe:
 * @object: A #MsDBusSysupdateTarget.
 * @invocation: (transfer full): A #GDBusMethodInvocation.
 * @json: Parameter to return.
 *
 * Helper function used in service implementations to finish handling invocations of the <link linkend="gdbus-method-org-freedesktop-sysupdate1-Target.Describe">Describe()</link> D-Bus method. If you instead want to finish handling an invocation by returning an error, use g_dbus_method_invocation_return_error() or similar.
 *
 * This method will free @invocation, you cannot use it afterwards.
 */
void
ms_dbus_sysupdate_target_complete_describe (
    MsDBusSysupdateTarget *object G_GNUC_UNUSED,
    GDBusMethodInvocation *invocation,
    const gchar *json)
{
  g_dbus_method_invocation_return_value (invocation,
    g_variant_new ("(s)",
                   json));
}

/**
 * ms_dbus_sysupdate_target_complete_check_new:
 * @object: A #MsDBusSysupdateTarget.
 * @invocation: (transfer full): A #GDBusMethodInvocation.
 * @new_version: Parameter to return.
 *
 * Helper function used in service implementations to finish handling invocations of the <link linkend="gdbus-method-org-freedesktop-sysupdate1-Target.CheckNew">CheckNew()</link> D-Bus method. If you instead want to finish handling an invocation by returning an error, use g_dbus_method_invocation_return_error() or similar.
 *
 * This method will free @invocation, you cannot use it afterwards.
 */
void
ms_dbus_sysupdate_target_complete_check_new (
    MsDBusSysupdateTarget *object G_GNUC_UNUSED,
    GDBusMethodInvocation *invocation,
    const gchar *new_version)
{
  g_dbus_method_invocation_return_value (invocation,
    g_variant_new ("(s)",
                   new_version));
}

/**
 * ms_dbus_sysupdate_target_complete_acquire:
 * @object: A #MsDBusSysupdateTarget.
 * @invocation: (transfer full): A #GDBusMethodInvocation.
 * @new_version: Parameter to return.
 * @job_id: Parameter to return.
 * @job_path: Parameter to return.
 *
 * Helper function used in service implementations to finish handling invocations of the <link linkend="gdbus-method-org-freedesktop-sysupdate1-Target.Acquire">Acquire()</link> D-Bus method. If you instead want to finish handling an invocation by returning an error, use g_dbus_method_invocation_return_error() or similar.
 *
 * This method will free @invocation, you cannot use it afterwards.
 */
void
ms_dbus_sysupdate_target_complete_acquire (
    MsDBusSysupdateTarget *object G_GNUC_UNUSED,
    GDBusMethodInvocation *invocation,
    const gchar *new_version,
    guint64 job_id,
    const gchar *job_path)
{
  g_dbus_method_invocation_return_value (invocation,
    g_variant_new ("(sto)",
                   new_version,
                   job_id,
                   job_path));
}

/**
 * ms_dbus_sysupdate_target_complete_install:
 * @object: A #MsDBusSysupdateTarget.
 * @invocation: (transfer full): A #GDBusMethodInvocation.
 * @new_version: Parameter to return.
 * @job_id: Parameter to return.
 * @job_path: Parameter to return.
 *
 * Helper function used in service implementations to finish handling invocations of the <link linkend="gdbus-method-org-freedesktop-sysupdate1-Target.Install">Install()</link> D-Bus method. If you instead want to finish handling an invocation by returning an error, use g_dbus_method_invocation_return_error() or similar.
 *
 * This method will free @invocation, you cannot use it afterwards.
 */
void
ms_dbus_sysupdate_target_complete_install (
    MsDBusSysupdateTarget *object G_GNUC_UNUSED,
    GDBusMethodInvocation *invocation,
    const gchar *new_version,
    guint64 job_id,
    const gchar *job_path)
{
  g_dbus_method_invocation_return_value (invocation,
    g_variant_new ("(sto)",
                   new_version,
                   job_id,
                   job_path));
}

/**
 * ms_dbus_sysupdate_target_complete_vacuum:
 * @object: A #MsDBusSysupdateTarget.
 * @invocation: (transfer full): A #GDBusMethodInvocation.
 * @instances: Parameter to return.
 * @disabled_transfers: Parameter to return.
 *
 * Helper function used in service implementations to finish handling invocations of the <link linkend="gdbus-method-org-freedesktop-sysupdate1-Target.Vacuum">Vacuum()</link> D-Bus method. If you instead want to finish handling an invocation by returning an error, use g_dbus_method_invocation_return_error() or similar.
 *
 * This method will free @invocation, you cannot use it afterwards.
 */
void
ms_dbus_sysupdate_target_complete_vacuum (
    MsDBusSysupdateTarget *object G_GNUC_UNUSED,
    GDBusMethodInvocation *invocation,
    guint instances,
    guint disabled_transfers)
{
  g_dbus_method_invocation_return_value (invocation,
    g_variant_new ("(uu)",
                   instances,
                   disabled_transfers));
}

/**
 * ms_dbus_sysupdate_target_complete_get_app_stream:
 * @object: A #MsDBusSysupdateTarget.
 * @invocation: (transfer full): A #GDBusMethodInvocation.
 * @appstream: Parameter to return.
 *
 * Helper function used in service implementations to finish handling invocations of the <link linkend="gdbus-method-org-freedesktop-sysupdate1-Target.GetAppStream">GetAppStream()</link> D-Bus method. If you instead want to finish handling an invocation by returning an error, use g_dbus_method_invocation_return_error() or similar.
 *
 * This method will free @invocation, you cannot use it afterwards.
 */
void
ms_dbus_sysupdate_target_complete_get_app_stream (
    MsDBusSysupdateTarget *object G_GNUC_UNUSED,
    GDBusMethodInvocation *invocation,
    const gchar *const *appstream)
{
  g_dbus_method_invocation_return_value (invocation,
    g_variant_new ("(^as)",
                   appstream));
}

/**
 * ms_dbus_sysupdate_target_complete_get_version:
 * @object: A #MsDBusSysupdateTarget.
 * @invocation: (transfer full): A #GDBusMethodInvocation.
 * @version: Parameter to return.
 *
 * Helper function used in service implementations to finish handling invocations of the <link linkend="gdbus-method-org-freedesktop-sysupdate1-Target.GetVersion">GetVersion()</link> D-Bus method. If you instead want to finish handling an invocation by returning an error, use g_dbus_method_invocation_return_error() or similar.
 *
 * This method will free @invocation, you cannot use it afterwards.
 */
void
ms_dbus_sysupdate_target_complete_get_version (
    MsDBusSysupdateTarget *object G_GNUC_UNUSED,
    GDBusMethodInvocation *invocation,
    const gchar *version)
{
  g_dbus_method_invocation_return_value (invocation,
    g_variant_new ("(s)",
                   version));
}

/**
 * ms_dbus_sysupdate_target_complete_list_features:
 * @object: A #MsDBusSysupdateTarget.
 * @invocation: (transfer full): A #GDBusMethodInvocation.
 * @features: Parameter to return.
 *
 * Helper function used in service implementations to finish handling invocations of the <link linkend="gdbus-method-org-freedesktop-sysupdate1-Target.ListFeatures">ListFeatures()</link> D-Bus method. If you instead want to finish handling an invocation by returning an error, use g_dbus_method_invocation_return_error() or similar.
 *
 * This method will free @invocation, you cannot use it afterwards.
 */
void
ms_dbus_sysupdate_target_complete_list_features (
    MsDBusSysupdateTarget *object G_GNUC_UNUSED,
    GDBusMethodInvocation *invocation,
    const gchar *const *features)
{
  g_dbus_method_invocation_return_value (invocation,
    g_variant_new ("(^as)",
                   features));
}

/**
 * ms_dbus_sysupdate_target_complete_describe_feature:
 * @object: A #MsDBusSysupdateTarget.
 * @invocation: (transfer full): A #GDBusMethodInvocation.
 * @json: Parameter to return.
 *
 * Helper function used in service implementations to finish handling invocations of the <link linkend="gdbus-method-org-freedesktop-sysupdate1-Target.DescribeFeature">DescribeFeature()</link> D-Bus method. If you instead want to finish handling an invocation by returning an error, use g_dbus_method_invocation_return_error() or similar.
 *
 * This method will free @invocation, you cannot use it afterwards.
 */
void
ms_dbus_sysupdate_target_complete_describe_feature (
    MsDBusSysupdateTarget *object G_GNUC_UNUSED,
    GDBusMethodInvocation *invocation,
    const gchar *json)
{
  g_dbus_method_invocation_return_value (invocation,
    g_variant_new ("(s)",
                   json));
}

/**
 * ms_dbus_sysupdate_target_complete_set_feature_enabled:
 * @object: A #MsDBusSysupdateTarget.
 * @invocation: (transfer full): A #GDBusMethodInvocation.
 *
 * Helper function used in service implementations to finish handling invocations of the <link linkend="gdbus-method-org-freedesktop-sysupdate1-Target.SetFeatureEnabled">SetFeatureEnabled()</link> D-Bus method. If you instead want to finish handling an invocation by returning an error, use g_dbus_method_invocation_return_error() or similar.
 *
 * This method will free @invocation, you cannot use it afterwards.
 */
void
ms_dbus_sysupdate_target_complete_set_feature_enabled (
    MsDBusSysupdateTarget *object G_GNUC_UNUSED,
    GDBusMethodInvocation *invocation)
{
  g_dbus_method_invocation_return_value (invocation,
    g_variant_new ("()"));
}

/* ------------------------------------------------------------------------ */

/**
 * MsDBusSysupdateTargetProxy:
 *
 * The #MsDBusSysupdateTargetProxy structure contains only private data and should only be accessed using the provided API.
 */

/**
 * MsDBusSysupdateTargetProxyClass:
 * @parent_class: The parent class.
 *
 * Class structure for #MsDBusSysupdateTargetProxy.
 */

struct _MsDBusSysupdateTargetProxyPrivate
{
  GData *qdata;
};

static void ms_dbus_sysupdate_target_proxy_iface_init (MsDBusSysupdateTargetIface *iface);

#if GLIB_VERSION_MAX_ALLOWED >= GLIB_VERSION_2_38
G_DEFINE_TYPE_WITH_CODE (MsDBusSysupdateTargetProxy, ms_dbus_sysupdate_target_proxy, G_TYPE_DBUS_PROXY,
                         G_ADD_PRIVATE (MsDBusSysupdateTargetProxy)
                         G_IMPLEMENT_INTERFACE (MS_DBUS_SYSUPDATE_TYPE_TARGET, ms_dbus_sysupdate_target_proxy_iface_init))

#else
G_DEFINE_TYPE_WITH_CODE (MsDBusSysupdateTargetProxy, ms_dbus_sysupdate_target_proxy, G_TYPE_DBUS_PROXY,
                         G_IMPLEMENT_INTERFACE (MS_DBUS_SYSUPDATE_TYPE_TARGET, ms_dbus_sysupdate_target_proxy_iface_init))

#endif
static void
ms_dbus_sysupdate_target_proxy_finalize (GObject *object)
{
  MsDBusSysupdateTargetProxy *proxy = MS_DBUS_SYSUPDATE_TARGET_PROXY (object);
  g_datalist_clear (&proxy->priv->qdata);
  G_OBJECT_CLASS (ms_dbus_sysupdate_target_proxy_parent_class)->finalize (object);
}

static void
ms_dbus_sysupdate_target_proxy_get_property (GObject      *object,
  guint         prop_id,
  GValue       *value,
  GParamSpec   *pspec G_GNUC_UNUSED)
{
  const _ExtendedGDBusPropertyInfo *info;
  GVariant *variant;
  g_assert (prop_id != 0 && prop_id - 1 < 3);
  info = (const _ExtendedGDBusPropertyInfo *) _ms_dbus_sysupdate_target_property_info_pointers[prop_id - 1];
  variant = g_dbus_proxy_get_cached_property (G_DBUS_PROXY (object), info->parent_struct.name);
  if (info->use_gvariant)
    {
      g_value_set_variant (value, variant);
    }
  else
    {
      if (variant != NULL)
        g_dbus_gvariant_to_gvalue (variant, value);
    }
  if (variant != NULL)
    g_variant_unref (variant);
}

static void
ms_dbus_sysupdate_target_proxy_set_property_cb (GDBusProxy *proxy,
  GAsyncResult *res,
  gpointer      user_data)
{
  const _ExtendedGDBusPropertyInfo *info = user_data;
  GError *error;
  GVariant *_ret;
  error = NULL;
  _ret = g_dbus_proxy_call_finish (proxy, res, &error);
  if (!_ret)
    {
      g_warning ("Error setting property '%s' on interface org.freedesktop.sysupdate1.Target: %s (%s, %d)",
                 info->parent_struct.name, 
                 error->message, g_quark_to_string (error->domain), error->code);
      g_error_free (error);
    }
  else
    {
      g_variant_unref (_ret);
    }
}

static void
ms_dbus_sysupdate_target_proxy_set_property (GObject      *object,
  guint         prop_id,
  const GValue *value,
  GParamSpec   *pspec G_GNUC_UNUSED)
{
  const _ExtendedGDBusPropertyInfo *info;
  GVariant *variant;
  g_assert (prop_id != 0 && prop_id - 1 < 3);
  info = (const _ExtendedGDBusPropertyInfo *) _ms_dbus_sysupdate_target_property_info_pointers[prop_id - 1];
  variant = g_dbus_gvalue_to_gvariant (value, G_VARIANT_TYPE (info->parent_struct.signature));
  g_dbus_proxy_call (G_DBUS_PROXY (object),
    "org.freedesktop.DBus.Properties.Set",
    g_variant_new ("(ssv)", "org.freedesktop.sysupdate1.Target", info->parent_struct.name, variant),
    G_DBUS_CALL_FLAGS_NONE,
    -1,
    NULL, (GAsyncReadyCallback) ms_dbus_sysupdate_target_proxy_set_property_cb, (GDBusPropertyInfo *) &info->parent_struct);
  g_variant_unref (variant);
}

static void
ms_dbus_sysupdate_target_proxy_g_signal (GDBusProxy *proxy,
  const gchar *sender_name G_GNUC_UNUSED,
  const gchar *signal_name,
  GVariant *parameters)
{
  _ExtendedGDBusSignalInfo *info;
  GVariantIter iter;
  GVariant *child;
  GValue *paramv;
  gsize num_params;
  gsize n;
  guint signal_id;
  info = (_ExtendedGDBusSignalInfo *) g_dbus_interface_info_lookup_signal ((GDBusInterfaceInfo *) &_ms_dbus_sysupdate_target_interface_info.parent_struct, signal_name);
  if (info == NULL)
    return;
  num_params = g_variant_n_children (parameters);
  paramv = g_new0 (GValue, num_params + 1);
  g_value_init (&paramv[0], MS_DBUS_SYSUPDATE_TYPE_TARGET);
  g_value_set_object (&paramv[0], proxy);
  g_variant_iter_init (&iter, parameters);
  n = 1;
  while ((child = g_variant_iter_next_value (&iter)) != NULL)
    {
      _ExtendedGDBusArgInfo *arg_info = (_ExtendedGDBusArgInfo *) info->parent_struct.args[n - 1];
      if (arg_info->use_gvariant)
        {
          g_value_init (&paramv[n], G_TYPE_VARIANT);
          g_value_set_variant (&paramv[n], child);
          n++;
        }
      else
        g_dbus_gvariant_to_gvalue (child, &paramv[n++]);
      g_variant_unref (child);
    }
  signal_id = g_signal_lookup (info->signal_name, MS_DBUS_SYSUPDATE_TYPE_TARGET);
  g_signal_emitv (paramv, signal_id, 0, NULL);
  for (n = 0; n < num_params + 1; n++)
    g_value_unset (&paramv[n]);
  g_free (paramv);
}

static void
ms_dbus_sysupdate_target_proxy_g_properties_changed (GDBusProxy *_proxy,
  GVariant *changed_properties,
  const gchar *const *invalidated_properties)
{
  MsDBusSysupdateTargetProxy *proxy = MS_DBUS_SYSUPDATE_TARGET_PROXY (_proxy);
  guint n;
  const gchar *key;
  GVariantIter *iter;
  _ExtendedGDBusPropertyInfo *info;
  g_variant_get (changed_properties, "a{sv}", &iter);
  while (g_variant_iter_next (iter, "{&sv}", &key, NULL))
    {
      info = (_ExtendedGDBusPropertyInfo *) g_dbus_interface_info_lookup_property ((GDBusInterfaceInfo *) &_ms_dbus_sysupdate_target_interface_info.parent_struct, key);
      g_datalist_remove_data (&proxy->priv->qdata, key);
      if (info != NULL)
        g_object_notify (G_OBJECT (proxy), info->hyphen_name);
    }
  g_variant_iter_free (iter);
  for (n = 0; invalidated_properties[n] != NULL; n++)
    {
      info = (_ExtendedGDBusPropertyInfo *) g_dbus_interface_info_lookup_property ((GDBusInterfaceInfo *) &_ms_dbus_sysupdate_target_interface_info.parent_struct, invalidated_properties[n]);
      g_datalist_remove_data (&proxy->priv->qdata, invalidated_properties[n]);
      if (info != NULL)
        g_object_notify (G_OBJECT (proxy), info->hyphen_name);
    }
}

static const gchar *
ms_dbus_sysupdate_target_proxy_get_class (MsDBusSysupdateTarget *object)
{
  MsDBusSysupdateTargetProxy *proxy = MS_DBUS_SYSUPDATE_TARGET_PROXY (object);
  GVariant *variant;
  const gchar *value = NULL;
  variant = g_dbus_proxy_get_cached_property (G_DBUS_PROXY (proxy), "Class");
  if (variant != NULL)
    {
      value = g_variant_get_string (variant, NULL);
      g_variant_unref (variant);
    }
  return value;
}

static const gchar *
ms_dbus_sysupdate_target_proxy_get_name (MsDBusSysupdateTarget *object)
{
  MsDBusSysupdateTargetProxy *proxy = MS_DBUS_SYSUPDATE_TARGET_PROXY (object);
  GVariant *variant;
  const gchar *value = NULL;
  variant = g_dbus_proxy_get_cached_property (G_DBUS_PROXY (proxy), "Name");
  if (variant != NULL)
    {
      value = g_variant_get_string (variant, NULL);
      g_variant_unref (variant);
    }
  return value;
}

static const gchar *
ms_dbus_sysupdate_target_proxy_get_path (MsDBusSysupdateTarget *object)
{
  MsDBusSysupdateTargetProxy *proxy = MS_DBUS_SYSUPDATE_TARGET_PROXY (object);
  GVariant *variant;
  const gchar *value = NULL;
  variant = g_dbus_proxy_get_cached_property (G_DBUS_PROXY (proxy), "Path");
  if (variant != NULL)
    {
      value = g_variant_get_string (variant, NULL);
      g_variant_unref (variant);
    }
  return value;
}

static void
ms_dbus_sysupdate_target_proxy_init (MsDBusSysupdateTargetProxy *proxy)
{
#if GLIB_VERSION_MAX_ALLOWED >= GLIB_VERSION_2_38
  proxy->priv = ms_dbus_sysupdate_target_proxy_get_instance_private (proxy);
#else
  proxy->priv = G_TYPE_INSTANCE_GET_PRIVATE (proxy, MS_DBUS_SYSUPDATE_TYPE_TARGET_PROXY, MsDBusSysupdateTargetProxyPrivate);
#endif

  g_dbus_proxy_set_interface_info (G_DBUS_PROXY (proxy), ms_dbus_sysupdate_target_interface_info ());
}

static void
ms_dbus_sysupdate_target_proxy_class_init (MsDBusSysupdateTargetProxyClass *klass)
{
  GObjectClass *gobject_class;
  GDBusProxyClass *proxy_class;

  gobject_class = G_OBJECT_CLASS (klass);
  gobject_class->finalize     = ms_dbus_sysupdate_target_proxy_finalize;
  gobject_class->get_property = ms_dbus_sysupdate_target_proxy_get_property;
  gobject_class->set_property = ms_dbus_sysupdate_target_proxy_set_property;

  proxy_class = G_DBUS_PROXY_CLASS (klass);
  proxy_class->g_signal = ms_dbus_sysupdate_target_proxy_g_signal;
  proxy_class->g_properties_changed = ms_dbus_sysupdate_target_proxy_g_properties_changed;

  ms_dbus_sysupdate_target_override_properties (gobject_class, 1);

#if GLIB_VERSION_MAX_ALLOWED < GLIB_VERSION_2_38
  g_type_class_add_private (klass, sizeof (MsDBusSysupdateTargetProxyPrivate));
#endif
}

static void
ms_dbus_sysupdate_target_proxy_iface_init (MsDBusSysupdateTargetIface *iface)
{
  iface->get_class = ms_dbus_sysupdate_target_proxy_get_class;
  iface->get_name = ms_dbus_sysupdate_target_proxy_get_name;
  iface->get_path = ms_dbus_sysupdate_target_proxy_get_path;
}

/**
 * ms_dbus_sysupdate_target_proxy_new:
 * @connection: A #GDBusConnection.
 * @flags: Flags from the #GDBusProxyFlags enumeration.
 * @name: (nullable): A bus name (well-known or unique) or %NULL if @connection is not a message bus connection.
 * @object_path: An object path.
 * @cancellable: (nullable): A #GCancellable or %NULL.
 * @callback: A #GAsyncReadyCallback to call when the request is satisfied.
 * @user_data: User data to pass to @callback.
 *
 * Asynchronously creates a proxy for the D-Bus interface <link linkend="gdbus-interface-org-freedesktop-sysupdate1-Target.top_of_page">org.freedesktop.sysupdate1.Target</link>. See g_dbus_proxy_new() for more details.
 *
 * When the operation is finished, @callback will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
 * You can then call ms_dbus_sysupdate_target_proxy_new_finish() to get the result of the operation.
 *
 * See ms_dbus_sysupdate_target_proxy_new_sync() for the synchronous, blocking version of this constructor.
 */
void
ms_dbus_sysupdate_target_proxy_new (
    GDBusConnection     *connection,
    GDBusProxyFlags      flags,
    const gchar         *name,
    const gchar         *object_path,
    GCancellable        *cancellable,
    GAsyncReadyCallback  callback,
    gpointer             user_data)
{
  g_async_initable_new_async (MS_DBUS_SYSUPDATE_TYPE_TARGET_PROXY, G_PRIORITY_DEFAULT, cancellable, callback, user_data, "g-flags", flags, "g-name", name, "g-connection", connection, "g-object-path", object_path, "g-interface-name", "org.freedesktop.sysupdate1.Target", NULL);
}

/**
 * ms_dbus_sysupdate_target_proxy_new_finish:
 * @res: The #GAsyncResult obtained from the #GAsyncReadyCallback passed to ms_dbus_sysupdate_target_proxy_new().
 * @error: Return location for error or %NULL
 *
 * Finishes an operation started with ms_dbus_sysupdate_target_proxy_new().
 *
 * Returns: (transfer full) (type MsDBusSysupdateTargetProxy): The constructed proxy object or %NULL if @error is set.
 */
MsDBusSysupdateTarget *
ms_dbus_sysupdate_target_proxy_new_finish (
    GAsyncResult        *res,
    GError             **error)
{
  GObject *ret;
  GObject *source_object;
  source_object = g_async_result_get_source_object (res);
  ret = g_async_initable_new_finish (G_ASYNC_INITABLE (source_object), res, error);
  g_object_unref (source_object);
  if (ret != NULL)
    return MS_DBUS_SYSUPDATE_TARGET (ret);
  else
    return NULL;
}

/**
 * ms_dbus_sysupdate_target_proxy_new_sync:
 * @connection: A #GDBusConnection.
 * @flags: Flags from the #GDBusProxyFlags enumeration.
 * @name: (nullable): A bus name (well-known or unique) or %NULL if @connection is not a message bus connection.
 * @object_path: An object path.
 * @cancellable: (nullable): A #GCancellable or %NULL.
 * @error: Return location for error or %NULL
 *
 * Synchronously creates a proxy for the D-Bus interface <link linkend="gdbus-interface-org-freedesktop-sysupdate1-Target.top_of_page">org.freedesktop.sysupdate1.Target</link>. See g_dbus_proxy_new_sync() for more details.
 *
 * The calling thread is blocked until a reply is received.
 *
 * See ms_dbus_sysupdate_target_proxy_new() for the asynchronous version of this constructor.
 *
 * Returns: (transfer full) (type MsDBusSysupdateTargetProxy): The constructed proxy object or %NULL if @error is set.
 */
MsDBusSysupdateTarget *
ms_dbus_sysupdate_target_proxy_new_sync (
    GDBusConnection     *connection,
    GDBusProxyFlags      flags,
    const gchar         *name,
    const gchar         *object_path,
    GCancellable        *cancellable,
    GError             **error)
{
  GInitable *ret;
  ret = g_initable_new (MS_DBUS_SYSUPDATE_TYPE_TARGET_PROXY, cancellable, error, "g-flags", flags, "g-name", name, "g-connection", connection, "g-object-path", object_path, "g-interface-name", "org.freedesktop.sysupdate1.Target", NULL);
  if (ret != NULL)
    return MS_DBUS_SYSUPDATE_TARGET (ret);
  else
    return NULL;
}


/**
 * ms_dbus_sysupdate_target_proxy_new_for_bus:
 * @bus_type: A #GBusType.
 * @flags: Flags from the #GDBusProxyFlags enumeration.
 * @name: A bus name (well-known or unique).
 * @object_path: An object path.
 * @cancellable: (nullable): A #GCancellable or %NULL.
 * @callback: A #GAsyncReadyCallback to call when the request is satisfied.
 * @user_data: User data to pass to @callback.
 *
 * Like ms_dbus_sysupdate_target_proxy_new() but takes a #GBusType instead of a #GDBusConnection.
 *
 * When the operation is finished, @callback will be invoked in the thread-default main loop of the thread you are calling this method from (see g_main_context_push_thread_default()).
 * You can then call ms_dbus_sysupdate_target_proxy_new_for_bus_finish() to get the result of the operation.
 *
 * See ms_dbus_sysupdate_target_proxy_new_for_bus_sync() for the synchronous, blocking version of this constructor.
 */
void
ms_dbus_sysupdate_target_proxy_new_for_bus (
    GBusType             bus_type,
    GDBusProxyFlags      flags,
    const gchar         *name,
    const gchar         *object_path,
    GCancellable        *cancellable,
    GAsyncReadyCallback  callback,
    gpointer             user_data)
{
  g_async_initable_new_async (MS_DBUS_SYSUPDATE_TYPE_TARGET_PROXY, G_PRIORITY_DEFAULT, cancellable, callback, user_data, "g-flags", flags, "g-name", name, "g-bus-type", bus_type, "g-object-path", object_path, "g-interface-name", "org.freedesktop.sysupdate1.Target", NULL);
}

/**
 * ms_dbus_sysupdate_target_proxy_new_for_bus_finish:
 * @res: The #GAsyncResult obtained from the #GAsyncReadyCallback passed to ms_dbus_sysupdate_target_proxy_new_for_bus().
 * @error: Return location for error or %NULL
 *
 * Finishes an operation started with ms_dbus_sysupdate_target_proxy_new_for_bus().
 *
 * Returns: (transfer full) (type MsDBusSysupdateTargetProxy): The constructed proxy object or %NULL if @error is set.
 */
MsDBusSysupdateTarget *
ms_dbus_sysupdate_target_proxy_new_for_bus_finish (
    GAsyncResult        *res,
    GError             **error)
{
  GObject *ret;
  GObject *source_object;
  source_object = g_async_result_get_source_object (res);
  ret = g_async_initable_new_finish (G_ASYNC_INITABLE (source_object), res, error);
  g_object_unref (source_object);
  if (ret != NULL)
    return MS_DBUS_SYSUPDATE_TARGET (ret);
  else
    return NULL;
}

/**
 * ms_dbus_sysupdate_target_proxy_new_for_bus_sync:
 * @bus_type: A #GBusType.
 * @flags: Flags from the #GDBusProxyFlags enumeration.
 * @name: A bus name (well-known or unique).
 * @object_path: An object path.
 * @cancellable: (nullable): A #GCancellable or %NULL.
 * @error: Return location for error or %NULL
 *
 * Like ms_dbus_sysupdate_target_proxy_new_sync() but takes a #GBusType instead of a #GDBusConnection.
 *
 * The calling thread is blocked until a reply is received.
 *
 * See ms_dbus_sysupdate_target_proxy_new_for_bus() for the asynchronous version of this constructor.
 *
 * Returns: (transfer full) (type MsDBusSysupdateTargetProxy): The constructed proxy object or %NULL if @error is set.
 */
MsDBusSysupdateTarget *
ms_dbus_sysupdate_target_proxy_new_for_bus_sync (
    GBusType             bus_type,
    GDBusProxyFlags      flags,
    const gchar         *name,
    const gchar         *object_path,
    GCancellable        *cancellable,
    GError             **error)
{
  GInitable *ret;
  ret = g_initable_new (MS_DBUS_SYSUPDATE_TYPE_TARGET_PROXY, cancellable, error, "g-flags", flags, "g-name", name, "g-bus-type", bus_type, "g-object-path", object_path, "g-interface-name", "org.freedesktop.sysupdate1.Target", NULL);
  if (ret != NULL)
    return MS_DBUS_SYSUPDATE_TARGET (ret);
  else
    return NULL;
}


/* ------------------------------------------------------------------------ */

/**
 * MsDBusSysupdateTargetSkeleton:
 *
 * The #MsDBusSysupdateTargetSkeleton structure contains only private data and should only be accessed using the provided API.
 */

/**
 * MsDBusSysupdateTargetSkeletonClass:
 * @parent_class: The parent class.
 *
 * Class structure for #MsDBusSysupdateTargetSkeleton.
 */

struct _MsDBusSysupdateTargetSkeletonPrivate
{
  GValue *properties;
  GList *changed_properties;
  GSource *changed_properties_idle_source;
  GMainContext *context;
  GMutex lock;
};

static void
_ms_dbus_sysupdate_target_skeleton_handle_method_call (
  GDBusConnection *connection G_GNUC_UNUSED,
  const gchar *sender G_GNUC_UNUSED,
  const gchar *object_path G_GNUC_UNUSED,
  const gchar *interface_name,
  const gchar *method_name,
  GVariant *parameters,
  GDBusMethodInvocation *invocation,
  gpointer user_data)
{
  MsDBusSysupdateTargetSkeleton *skeleton = MS_DBUS_SYSUPDATE_TARGET_SKELETON (user_data);
  _ExtendedGDBusMethodInfo *info;
  GVariantIter iter;
  GVariant *child;
  GValue *paramv;
  gsize num_params;
  guint num_extra;
  gsize n;
  guint signal_id;
  GValue return_value = G_VALUE_INIT;
  info = (_ExtendedGDBusMethodInfo *) g_dbus_method_invocation_get_method_info (invocation);
  g_assert (info != NULL);
  num_params = g_variant_n_children (parameters);
  num_extra = info->pass_fdlist ? 3 : 2;  paramv = g_new0 (GValue, num_params + num_extra);
  n = 0;
  g_value_init (&paramv[n], MS_DBUS_SYSUPDATE_TYPE_TARGET);
  g_value_set_object (&paramv[n++], skeleton);
  g_value_init (&paramv[n], G_TYPE_DBUS_METHOD_INVOCATION);
  g_value_set_object (&paramv[n++], invocation);
  if (info->pass_fdlist)
    {
#ifdef G_OS_UNIX
      g_value_init (&paramv[n], G_TYPE_UNIX_FD_LIST);
      g_value_set_object (&paramv[n++], g_dbus_message_get_unix_fd_list (g_dbus_method_invocation_get_message (invocation)));
#else
      g_assert_not_reached ();
#endif
    }
  g_variant_iter_init (&iter, parameters);
  while ((child = g_variant_iter_next_value (&iter)) != NULL)
    {
      _ExtendedGDBusArgInfo *arg_info = (_ExtendedGDBusArgInfo *) info->parent_struct.in_args[n - num_extra];
      if (arg_info->use_gvariant)
        {
          g_value_init (&paramv[n], G_TYPE_VARIANT);
          g_value_set_variant (&paramv[n], child);
          n++;
        }
      else
        g_dbus_gvariant_to_gvalue (child, &paramv[n++]);
      g_variant_unref (child);
    }
  signal_id = g_signal_lookup (info->signal_name, MS_DBUS_SYSUPDATE_TYPE_TARGET);
  g_value_init (&return_value, G_TYPE_BOOLEAN);
  g_signal_emitv (paramv, signal_id, 0, &return_value);
  if (!g_value_get_boolean (&return_value))
    g_dbus_method_invocation_return_error (invocation, G_DBUS_ERROR, G_DBUS_ERROR_UNKNOWN_METHOD, "Method %s is not implemented on interface %s", method_name, interface_name);
  g_value_unset (&return_value);
  for (n = 0; n < num_params + num_extra; n++)
    g_value_unset (&paramv[n]);
  g_free (paramv);
}

static GVariant *
_ms_dbus_sysupdate_target_skeleton_handle_get_property (
  GDBusConnection *connection G_GNUC_UNUSED,
  const gchar *sender G_GNUC_UNUSED,
  const gchar *object_path G_GNUC_UNUSED,
  const gchar *interface_name G_GNUC_UNUSED,
  const gchar *property_name,
  GError **error,
  gpointer user_data)
{
  MsDBusSysupdateTargetSkeleton *skeleton = MS_DBUS_SYSUPDATE_TARGET_SKELETON (user_data);
  GValue value = G_VALUE_INIT;
  GParamSpec *pspec;
  _ExtendedGDBusPropertyInfo *info;
  GVariant *ret;
  ret = NULL;
  info = (_ExtendedGDBusPropertyInfo *) g_dbus_interface_info_lookup_property ((GDBusInterfaceInfo *) &_ms_dbus_sysupdate_target_interface_info.parent_struct, property_name);
  g_assert (info != NULL);
  pspec = g_object_class_find_property (G_OBJECT_GET_CLASS (skeleton), info->hyphen_name);
  if (pspec == NULL)
    {
      g_set_error (error, G_DBUS_ERROR, G_DBUS_ERROR_INVALID_ARGS, "No property with name %s", property_name);
    }
  else
    {
      g_value_init (&value, pspec->value_type);
      g_object_get_property (G_OBJECT (skeleton), info->hyphen_name, &value);
      ret = g_dbus_gvalue_to_gvariant (&value, G_VARIANT_TYPE (info->parent_struct.signature));
      g_value_unset (&value);
    }
  return ret;
}

static gboolean
_ms_dbus_sysupdate_target_skeleton_handle_set_property (
  GDBusConnection *connection G_GNUC_UNUSED,
  const gchar *sender G_GNUC_UNUSED,
  const gchar *object_path G_GNUC_UNUSED,
  const gchar *interface_name G_GNUC_UNUSED,
  const gchar *property_name,
  GVariant *variant,
  GError **error,
  gpointer user_data)
{
  MsDBusSysupdateTargetSkeleton *skeleton = MS_DBUS_SYSUPDATE_TARGET_SKELETON (user_data);
  GValue value = G_VALUE_INIT;
  GParamSpec *pspec;
  _ExtendedGDBusPropertyInfo *info;
  gboolean ret;
  ret = FALSE;
  info = (_ExtendedGDBusPropertyInfo *) g_dbus_interface_info_lookup_property ((GDBusInterfaceInfo *) &_ms_dbus_sysupdate_target_interface_info.parent_struct, property_name);
  g_assert (info != NULL);
  pspec = g_object_class_find_property (G_OBJECT_GET_CLASS (skeleton), info->hyphen_name);
  if (pspec == NULL)
    {
      g_set_error (error, G_DBUS_ERROR, G_DBUS_ERROR_INVALID_ARGS, "No property with name %s", property_name);
    }
  else
    {
      if (info->use_gvariant)
        g_value_set_variant (&value, variant);
      else
        g_dbus_gvariant_to_gvalue (variant, &value);
      g_object_set_property (G_OBJECT (skeleton), info->hyphen_name, &value);
      g_value_unset (&value);
      ret = TRUE;
    }
  return ret;
}

static const GDBusInterfaceVTable _ms_dbus_sysupdate_target_skeleton_vtable =
{
  _ms_dbus_sysupdate_target_skeleton_handle_method_call,
  _ms_dbus_sysupdate_target_skeleton_handle_get_property,
  _ms_dbus_sysupdate_target_skeleton_handle_set_property,
  {NULL}
};

static GDBusInterfaceInfo *
ms_dbus_sysupdate_target_skeleton_dbus_interface_get_info (GDBusInterfaceSkeleton *skeleton G_GNUC_UNUSED)
{
  return ms_dbus_sysupdate_target_interface_info ();
}

static GDBusInterfaceVTable *
ms_dbus_sysupdate_target_skeleton_dbus_interface_get_vtable (GDBusInterfaceSkeleton *skeleton G_GNUC_UNUSED)
{
  return (GDBusInterfaceVTable *) &_ms_dbus_sysupdate_target_skeleton_vtable;
}

static GVariant *
ms_dbus_sysupdate_target_skeleton_dbus_interface_get_properties (GDBusInterfaceSkeleton *_skeleton)
{
  MsDBusSysupdateTargetSkeleton *skeleton = MS_DBUS_SYSUPDATE_TARGET_SKELETON (_skeleton);

  GVariantBuilder builder;
  guint n;
#if GLIB_VERSION_MAX_ALLOWED >= GLIB_VERSION_2_84
  g_variant_builder_init_static (&builder, G_VARIANT_TYPE ("a{sv}"));
#else
  g_variant_builder_init(&builder, G_VARIANT_TYPE ("a{sv}"));
#endif
  if (_ms_dbus_sysupdate_target_interface_info.parent_struct.properties == NULL)
    goto out;
  for (n = 0; _ms_dbus_sysupdate_target_interface_info.parent_struct.properties[n] != NULL; n++)
    {
      GDBusPropertyInfo *info = _ms_dbus_sysupdate_target_interface_info.parent_struct.properties[n];
      if (info->flags & G_DBUS_PROPERTY_INFO_FLAGS_READABLE)
        {
          GVariant *value;
          value = _ms_dbus_sysupdate_target_skeleton_handle_get_property (g_dbus_interface_skeleton_get_connection (G_DBUS_INTERFACE_SKELETON (skeleton)), NULL, g_dbus_interface_skeleton_get_object_path (G_DBUS_INTERFACE_SKELETON (skeleton)), "org.freedesktop.sysupdate1.Target", info->name, NULL, skeleton);
          if (value != NULL)
            {
              g_variant_take_ref (value);
              g_variant_builder_add (&builder, "{sv}", info->name, value);
              g_variant_unref (value);
            }
        }
    }
out:
  return g_variant_builder_end (&builder);
}

static gboolean _ms_dbus_sysupdate_target_emit_changed (gpointer user_data);

static void
ms_dbus_sysupdate_target_skeleton_dbus_interface_flush (GDBusInterfaceSkeleton *_skeleton)
{
  MsDBusSysupdateTargetSkeleton *skeleton = MS_DBUS_SYSUPDATE_TARGET_SKELETON (_skeleton);
  gboolean emit_changed = FALSE;

  g_mutex_lock (&skeleton->priv->lock);
  if (skeleton->priv->changed_properties_idle_source != NULL)
    {
      g_source_destroy (skeleton->priv->changed_properties_idle_source);
      skeleton->priv->changed_properties_idle_source = NULL;
      emit_changed = TRUE;
    }
  g_mutex_unlock (&skeleton->priv->lock);

  if (emit_changed)
    _ms_dbus_sysupdate_target_emit_changed (skeleton);
}

static void ms_dbus_sysupdate_target_skeleton_iface_init (MsDBusSysupdateTargetIface *iface);
#if GLIB_VERSION_MAX_ALLOWED >= GLIB_VERSION_2_38
G_DEFINE_TYPE_WITH_CODE (MsDBusSysupdateTargetSkeleton, ms_dbus_sysupdate_target_skeleton, G_TYPE_DBUS_INTERFACE_SKELETON,
                         G_ADD_PRIVATE (MsDBusSysupdateTargetSkeleton)
                         G_IMPLEMENT_INTERFACE (MS_DBUS_SYSUPDATE_TYPE_TARGET, ms_dbus_sysupdate_target_skeleton_iface_init))

#else
G_DEFINE_TYPE_WITH_CODE (MsDBusSysupdateTargetSkeleton, ms_dbus_sysupdate_target_skeleton, G_TYPE_DBUS_INTERFACE_SKELETON,
                         G_IMPLEMENT_INTERFACE (MS_DBUS_SYSUPDATE_TYPE_TARGET, ms_dbus_sysupdate_target_skeleton_iface_init))

#endif
static void
ms_dbus_sysupdate_target_skeleton_finalize (GObject *object)
{
  MsDBusSysupdateTargetSkeleton *skeleton = MS_DBUS_SYSUPDATE_TARGET_SKELETON (object);
  guint n;
  for (n = 0; n < 3; n++)
    g_value_unset (&skeleton->priv->properties[n]);
  g_free (skeleton->priv->properties);
  g_list_free_full (skeleton->priv->changed_properties, (GDestroyNotify) _changed_property_free);
#if GLIB_VERSION_MAX_ALLOWED >= GLIB_VERSION_2_38
  /* coverity[missing_lock : SUPPRESS] */
  g_clear_pointer (&skeleton->priv->changed_properties_idle_source, g_source_destroy);
#else
  if (skeleton->priv->changed_properties_idle_source != NULL)
    g_source_destroy (skeleton->priv->changed_properties_idle_source);
skeleton->priv->changed_properties_idle_source = NULL;
#endif
  g_main_context_unref (skeleton->priv->context);
  g_mutex_clear (&skeleton->priv->lock);
  G_OBJECT_CLASS (ms_dbus_sysupdate_target_skeleton_parent_class)->finalize (object);
}

static void
ms_dbus_sysupdate_target_skeleton_get_property (GObject      *object,
  guint         prop_id,
  GValue       *value,
  GParamSpec   *pspec G_GNUC_UNUSED)
{
  MsDBusSysupdateTargetSkeleton *skeleton = MS_DBUS_SYSUPDATE_TARGET_SKELETON (object);
  g_assert (prop_id != 0 && prop_id - 1 < 3);
  g_mutex_lock (&skeleton->priv->lock);
  g_value_copy (&skeleton->priv->properties[prop_id - 1], value);
  g_mutex_unlock (&skeleton->priv->lock);
}

static gboolean
_ms_dbus_sysupdate_target_emit_changed (gpointer user_data)
{
  MsDBusSysupdateTargetSkeleton *skeleton = MS_DBUS_SYSUPDATE_TARGET_SKELETON (user_data);
  GList *l;
  GVariantBuilder builder;
  GVariantBuilder invalidated_builder;
  guint num_changes;

  g_mutex_lock (&skeleton->priv->lock);
#if GLIB_VERSION_MAX_ALLOWED >= GLIB_VERSION_2_84
  g_variant_builder_init_static (&builder, G_VARIANT_TYPE ("a{sv}"));
  g_variant_builder_init_static (&invalidated_builder, G_VARIANT_TYPE ("as"));
#else
  g_variant_builder_init (&builder, G_VARIANT_TYPE ("a{sv}"));
  g_variant_builder_init (&invalidated_builder, G_VARIANT_TYPE ("as"));
#endif
  for (l = skeleton->priv->changed_properties, num_changes = 0; l != NULL; l = l->next)
    {
      ChangedProperty *cp = l->data;
      GVariant *variant;
      const GValue *cur_value;

      cur_value = &skeleton->priv->properties[cp->prop_id - 1];
      if (!_g_value_equal (cur_value, &cp->orig_value))
        {
          variant = g_dbus_gvalue_to_gvariant (cur_value, G_VARIANT_TYPE (cp->info->parent_struct.signature));
          g_variant_builder_add (&builder, "{sv}", cp->info->parent_struct.name, variant);
          g_variant_unref (variant);
          num_changes++;
        }
    }
  if (num_changes > 0)
    {
      GList *connections, *ll;
      GVariant *signal_variant;
      signal_variant = g_variant_ref_sink (g_variant_new ("(sa{sv}as)", "org.freedesktop.sysupdate1.Target",
                                           &builder, &invalidated_builder));
      connections = g_dbus_interface_skeleton_get_connections (G_DBUS_INTERFACE_SKELETON (skeleton));
      for (ll = connections; ll != NULL; ll = ll->next)
        {
          GDBusConnection *connection = ll->data;

          g_dbus_connection_emit_signal (connection,
                                         NULL, g_dbus_interface_skeleton_get_object_path (G_DBUS_INTERFACE_SKELETON (skeleton)),
                                         "org.freedesktop.DBus.Properties",
                                         "PropertiesChanged",
                                         signal_variant,
                                         NULL);
        }
      g_variant_unref (signal_variant);
      g_list_free_full (connections, g_object_unref);
    }
  else
    {
      g_variant_builder_clear (&builder);
      g_variant_builder_clear (&invalidated_builder);
    }
  g_list_free_full (skeleton->priv->changed_properties, (GDestroyNotify) _changed_property_free);
  skeleton->priv->changed_properties = NULL;
  skeleton->priv->changed_properties_idle_source = NULL;
  g_mutex_unlock (&skeleton->priv->lock);
  return FALSE;
}

static void
_ms_dbus_sysupdate_target_schedule_emit_changed (MsDBusSysupdateTargetSkeleton *skeleton, const _ExtendedGDBusPropertyInfo *info, guint prop_id, const GValue *orig_value)
{
  ChangedProperty *cp;
  GList *l;
  cp = NULL;
  for (l = skeleton->priv->changed_properties; l != NULL; l = l->next)
    {
      ChangedProperty *i_cp = l->data;
      if (i_cp->info == info)
        {
          cp = i_cp;
          break;
        }
    }
  if (cp == NULL)
    {
      cp = g_new0 (ChangedProperty, 1);
      cp->prop_id = prop_id;
      cp->info = info;
      skeleton->priv->changed_properties = g_list_prepend (skeleton->priv->changed_properties, cp);
      g_value_init (&cp->orig_value, G_VALUE_TYPE (orig_value));
      g_value_copy (orig_value, &cp->orig_value);
    }
}

static void
ms_dbus_sysupdate_target_skeleton_notify (GObject      *object,
  GParamSpec *pspec G_GNUC_UNUSED)
{
  MsDBusSysupdateTargetSkeleton *skeleton = MS_DBUS_SYSUPDATE_TARGET_SKELETON (object);
  g_mutex_lock (&skeleton->priv->lock);
  if (skeleton->priv->changed_properties != NULL &&
      skeleton->priv->changed_properties_idle_source == NULL)
    {
      skeleton->priv->changed_properties_idle_source = g_idle_source_new ();
      g_source_set_priority (skeleton->priv->changed_properties_idle_source, G_PRIORITY_DEFAULT);
      g_source_set_callback (skeleton->priv->changed_properties_idle_source, _ms_dbus_sysupdate_target_emit_changed, g_object_ref (skeleton), (GDestroyNotify) g_object_unref);
      g_source_set_name (skeleton->priv->changed_properties_idle_source, "[generated] _ms_dbus_sysupdate_target_emit_changed");
      g_source_attach (skeleton->priv->changed_properties_idle_source, skeleton->priv->context);
      g_source_unref (skeleton->priv->changed_properties_idle_source);
    }
  g_mutex_unlock (&skeleton->priv->lock);
}

static void
ms_dbus_sysupdate_target_skeleton_set_property (GObject      *object,
  guint         prop_id,
  const GValue *value,
  GParamSpec   *pspec)
{
  const _ExtendedGDBusPropertyInfo *info;
  MsDBusSysupdateTargetSkeleton *skeleton = MS_DBUS_SYSUPDATE_TARGET_SKELETON (object);
  g_assert (prop_id != 0 && prop_id - 1 < 3);
  info = (const _ExtendedGDBusPropertyInfo *) _ms_dbus_sysupdate_target_property_info_pointers[prop_id - 1];
  g_mutex_lock (&skeleton->priv->lock);
  g_object_freeze_notify (object);
  if (!_g_value_equal (value, &skeleton->priv->properties[prop_id - 1]))
    {
      if (g_dbus_interface_skeleton_get_connection (G_DBUS_INTERFACE_SKELETON (skeleton)) != NULL &&
          info->emits_changed_signal)
        _ms_dbus_sysupdate_target_schedule_emit_changed (skeleton, info, prop_id, &skeleton->priv->properties[prop_id - 1]);
      g_value_copy (value, &skeleton->priv->properties[prop_id - 1]);
      g_object_notify_by_pspec (object, pspec);
    }
  g_mutex_unlock (&skeleton->priv->lock);
  g_object_thaw_notify (object);
}

static void
ms_dbus_sysupdate_target_skeleton_init (MsDBusSysupdateTargetSkeleton *skeleton)
{
#if GLIB_VERSION_MAX_ALLOWED >= GLIB_VERSION_2_38
  skeleton->priv = ms_dbus_sysupdate_target_skeleton_get_instance_private (skeleton);
#else
  skeleton->priv = G_TYPE_INSTANCE_GET_PRIVATE (skeleton, MS_DBUS_SYSUPDATE_TYPE_TARGET_SKELETON, MsDBusSysupdateTargetSkeletonPrivate);
#endif

  g_mutex_init (&skeleton->priv->lock);
  skeleton->priv->context = g_main_context_ref_thread_default ();
  skeleton->priv->properties = g_new0 (GValue, 3);
  g_value_init (&skeleton->priv->properties[0], G_TYPE_STRING);
  g_value_init (&skeleton->priv->properties[1], G_TYPE_STRING);
  g_value_init (&skeleton->priv->properties[2], G_TYPE_STRING);
}

static const gchar *
ms_dbus_sysupdate_target_skeleton_get_class (MsDBusSysupdateTarget *object)
{
  MsDBusSysupdateTargetSkeleton *skeleton = MS_DBUS_SYSUPDATE_TARGET_SKELETON (object);
  const gchar *value;
  g_mutex_lock (&skeleton->priv->lock);
  value = g_marshal_value_peek_string (&(skeleton->priv->properties[0]));
  g_mutex_unlock (&skeleton->priv->lock);
  return value;
}

static const gchar *
ms_dbus_sysupdate_target_skeleton_get_name (MsDBusSysupdateTarget *object)
{
  MsDBusSysupdateTargetSkeleton *skeleton = MS_DBUS_SYSUPDATE_TARGET_SKELETON (object);
  const gchar *value;
  g_mutex_lock (&skeleton->priv->lock);
  value = g_marshal_value_peek_string (&(skeleton->priv->properties[1]));
  g_mutex_unlock (&skeleton->priv->lock);
  return value;
}

static const gchar *
ms_dbus_sysupdate_target_skeleton_get_path (MsDBusSysupdateTarget *object)
{
  MsDBusSysupdateTargetSkeleton *skeleton = MS_DBUS_SYSUPDATE_TARGET_SKELETON (object);
  const gchar *value;
  g_mutex_lock (&skeleton->priv->lock);
  value = g_marshal_value_peek_string (&(skeleton->priv->properties[2]));
  g_mutex_unlock (&skeleton->priv->lock);
  return value;
}

static void
ms_dbus_sysupdate_target_skeleton_class_init (MsDBusSysupdateTargetSkeletonClass *klass)
{
  GObjectClass *gobject_class;
  GDBusInterfaceSkeletonClass *skeleton_class;

  gobject_class = G_OBJECT_CLASS (klass);
  gobject_class->finalize = ms_dbus_sysupdate_target_skeleton_finalize;
  gobject_class->get_property = ms_dbus_sysupdate_target_skeleton_get_property;
  gobject_class->set_property = ms_dbus_sysupdate_target_skeleton_set_property;
  gobject_class->notify       = ms_dbus_sysupdate_target_skeleton_notify;


  ms_dbus_sysupdate_target_override_properties (gobject_class, 1);

  skeleton_class = G_DBUS_INTERFACE_SKELETON_CLASS (klass);
  skeleton_class->get_info = ms_dbus_sysupdate_target_skeleton_dbus_interface_get_info;
  skeleton_class->get_properties = ms_dbus_sysupdate_target_skeleton_dbus_interface_get_properties;
  skeleton_class->flush = ms_dbus_sysupdate_target_skeleton_dbus_interface_flush;
  skeleton_class->get_vtable = ms_dbus_sysupdate_target_skeleton_dbus_interface_get_vtable;

#if GLIB_VERSION_MAX_ALLOWED < GLIB_VERSION_2_38
  g_type_class_add_private (klass, sizeof (MsDBusSysupdateTargetSkeletonPrivate));
#endif
}

static void
ms_dbus_sysupdate_target_skeleton_iface_init (MsDBusSysupdateTargetIface *iface)
{
  iface->get_class = ms_dbus_sysupdate_target_skeleton_get_class;
  iface->get_name = ms_dbus_sysupdate_target_skeleton_get_name;
  iface->get_path = ms_dbus_sysupdate_target_skeleton_get_path;
}

/**
 * ms_dbus_sysupdate_target_skeleton_new:
 *
 * Creates a skeleton object for the D-Bus interface <link linkend="gdbus-interface-org-freedesktop-sysupdate1-Target.top_of_page">org.freedesktop.sysupdate1.Target</link>.
 *
 * Returns: (transfer full) (type MsDBusSysupdateTargetSkeleton): The skeleton object.
 */
MsDBusSysupdateTarget *
ms_dbus_sysupdate_target_skeleton_new (void)
{
  return MS_DBUS_SYSUPDATE_TARGET (g_object_new (MS_DBUS_SYSUPDATE_TYPE_TARGET_SKELETON, NULL));
}

