/* notiDaemon.c generated by valac 0.56.18-dirty, the Vala compiler
 * generated from notiDaemon.vala, do not modify */

#include <glib.h>
#include <adwaita.h>
#include <glib-object.h>
#include <gio/gio.h>
#include <stdlib.h>
#include <string.h>
#include <gee.h>
#include <gtk/gtk.h>
#include <stdio.h>

#define CONSTANTS_VERSIONNUM "0.12.6"
#if !defined(VALA_STRICT_C)
#if !defined(__clang__) && defined(__GNUC__) && (__GNUC__ >= 14)
#pragma GCC diagnostic warning "-Wincompatible-pointer-types"
#elif defined(__clang__) && (__clang_major__ >= 16)
#pragma clang diagnostic ignored "-Wincompatible-function-pointer-types"
#pragma clang diagnostic ignored "-Wincompatible-pointer-types"
#endif
#endif
#if !defined(VALA_EXTERN)
#if defined(_MSC_VER)
#define VALA_EXTERN __declspec(dllexport) extern
#elif __GNUC__ >= 4
#define VALA_EXTERN __attribute__((visibility("default"))) extern
#else
#define VALA_EXTERN extern
#endif
#endif

#define SWAY_NOTIFICATION_CENTER_TYPE_NOTIFICATION (sway_notification_center_notification_get_type ())
#define SWAY_NOTIFICATION_CENTER_NOTIFICATION(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), SWAY_NOTIFICATION_CENTER_TYPE_NOTIFICATION, SwayNotificationCenterNotification))
#define SWAY_NOTIFICATION_CENTER_NOTIFICATION_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), SWAY_NOTIFICATION_CENTER_TYPE_NOTIFICATION, SwayNotificationCenterNotificationClass))
#define SWAY_NOTIFICATION_CENTER_IS_NOTIFICATION(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), SWAY_NOTIFICATION_CENTER_TYPE_NOTIFICATION))
#define SWAY_NOTIFICATION_CENTER_IS_NOTIFICATION_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), SWAY_NOTIFICATION_CENTER_TYPE_NOTIFICATION))
#define SWAY_NOTIFICATION_CENTER_NOTIFICATION_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), SWAY_NOTIFICATION_CENTER_TYPE_NOTIFICATION, SwayNotificationCenterNotificationClass))

typedef struct _SwayNotificationCenterNotification SwayNotificationCenterNotification;
typedef struct _SwayNotificationCenterNotificationClass SwayNotificationCenterNotificationClass;
typedef gboolean (*SwayNotificationCenternotification_filter_func) (SwayNotificationCenterNotification* notification, gpointer user_data);

#define SWAY_NOTIFICATION_CENTER_TYPE_NOTI_DAEMON (sway_notification_center_noti_daemon_get_type ())
#define SWAY_NOTIFICATION_CENTER_NOTI_DAEMON(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), SWAY_NOTIFICATION_CENTER_TYPE_NOTI_DAEMON, SwayNotificationCenterNotiDaemon))
#define SWAY_NOTIFICATION_CENTER_NOTI_DAEMON_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), SWAY_NOTIFICATION_CENTER_TYPE_NOTI_DAEMON, SwayNotificationCenterNotiDaemonClass))
#define SWAY_NOTIFICATION_CENTER_IS_NOTI_DAEMON(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), SWAY_NOTIFICATION_CENTER_TYPE_NOTI_DAEMON))
#define SWAY_NOTIFICATION_CENTER_IS_NOTI_DAEMON_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), SWAY_NOTIFICATION_CENTER_TYPE_NOTI_DAEMON))
#define SWAY_NOTIFICATION_CENTER_NOTI_DAEMON_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), SWAY_NOTIFICATION_CENTER_TYPE_NOTI_DAEMON, SwayNotificationCenterNotiDaemonClass))

typedef struct _SwayNotificationCenterNotiDaemon SwayNotificationCenterNotiDaemon;
typedef struct _SwayNotificationCenterNotiDaemonClass SwayNotificationCenterNotiDaemonClass;
typedef struct _SwayNotificationCenterNotiDaemonPrivate SwayNotificationCenterNotiDaemonPrivate;
enum  {
	SWAY_NOTIFICATION_CENTER_NOTI_DAEMON_0_PROPERTY,
	SWAY_NOTIFICATION_CENTER_NOTI_DAEMON_DND_PROPERTY,
	SWAY_NOTIFICATION_CENTER_NOTI_DAEMON_N_NOTIFICATIONS_PROPERTY,
	SWAY_NOTIFICATION_CENTER_NOTI_DAEMON_NUM_PROPERTIES
};
static GParamSpec* sway_notification_center_noti_daemon_properties[SWAY_NOTIFICATION_CENTER_NOTI_DAEMON_NUM_PROPERTIES];
#define _g_hash_table_unref0(var) ((var == NULL) ? NULL : (var = (g_hash_table_unref (var), NULL)))
#define _g_object_unref0(var) ((var == NULL) ? NULL : (var = (g_object_unref (var), NULL)))
typedef enum  {
	SWAY_NOTIFICATION_CENTER_CLOSED_REASONS_EXPIRED = 1,
	SWAY_NOTIFICATION_CENTER_CLOSED_REASONS_DISMISSED = 2,
	SWAY_NOTIFICATION_CENTER_CLOSED_REASONS_CLOSED_BY_CLOSENOTIFICATION = 3,
	SWAY_NOTIFICATION_CENTER_CLOSED_REASONS_UNDEFINED = 4
} SwayNotificationCenterClosedReasons;

#define SWAY_NOTIFICATION_CENTER_TYPE_CLOSED_REASONS (sway_notification_center_closed_reasons_get_type ())
#define _g_free0(var) (var = (g_free (var), NULL))

#define SWAY_NOTIFICATION_CENTER_TYPE_NOTIFICATION_WINDOW (sway_notification_center_notification_window_get_type ())
#define SWAY_NOTIFICATION_CENTER_NOTIFICATION_WINDOW(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), SWAY_NOTIFICATION_CENTER_TYPE_NOTIFICATION_WINDOW, SwayNotificationCenterNotificationWindow))
#define SWAY_NOTIFICATION_CENTER_NOTIFICATION_WINDOW_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), SWAY_NOTIFICATION_CENTER_TYPE_NOTIFICATION_WINDOW, SwayNotificationCenterNotificationWindowClass))
#define SWAY_NOTIFICATION_CENTER_IS_NOTIFICATION_WINDOW(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), SWAY_NOTIFICATION_CENTER_TYPE_NOTIFICATION_WINDOW))
#define SWAY_NOTIFICATION_CENTER_IS_NOTIFICATION_WINDOW_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), SWAY_NOTIFICATION_CENTER_TYPE_NOTIFICATION_WINDOW))
#define SWAY_NOTIFICATION_CENTER_NOTIFICATION_WINDOW_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), SWAY_NOTIFICATION_CENTER_TYPE_NOTIFICATION_WINDOW, SwayNotificationCenterNotificationWindowClass))

typedef struct _SwayNotificationCenterNotificationWindow SwayNotificationCenterNotificationWindow;
typedef struct _SwayNotificationCenterNotificationWindowClass SwayNotificationCenterNotificationWindowClass;

#define SWAY_NOTIFICATION_CENTER_WIDGETS_TYPE_BASE_WIDGET (sway_notification_center_widgets_base_widget_get_type ())
#define SWAY_NOTIFICATION_CENTER_WIDGETS_BASE_WIDGET(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), SWAY_NOTIFICATION_CENTER_WIDGETS_TYPE_BASE_WIDGET, SwayNotificationCenterWidgetsBaseWidget))
#define SWAY_NOTIFICATION_CENTER_WIDGETS_BASE_WIDGET_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), SWAY_NOTIFICATION_CENTER_WIDGETS_TYPE_BASE_WIDGET, SwayNotificationCenterWidgetsBaseWidgetClass))
#define SWAY_NOTIFICATION_CENTER_WIDGETS_IS_BASE_WIDGET(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), SWAY_NOTIFICATION_CENTER_WIDGETS_TYPE_BASE_WIDGET))
#define SWAY_NOTIFICATION_CENTER_WIDGETS_IS_BASE_WIDGET_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), SWAY_NOTIFICATION_CENTER_WIDGETS_TYPE_BASE_WIDGET))
#define SWAY_NOTIFICATION_CENTER_WIDGETS_BASE_WIDGET_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), SWAY_NOTIFICATION_CENTER_WIDGETS_TYPE_BASE_WIDGET, SwayNotificationCenterWidgetsBaseWidgetClass))

typedef struct _SwayNotificationCenterWidgetsBaseWidget SwayNotificationCenterWidgetsBaseWidget;
typedef struct _SwayNotificationCenterWidgetsBaseWidgetClass SwayNotificationCenterWidgetsBaseWidgetClass;

#define SWAY_NOTIFICATION_CENTER_WIDGETS_TYPE_NOTIFICATIONS (sway_notification_center_widgets_notifications_get_type ())
#define SWAY_NOTIFICATION_CENTER_WIDGETS_NOTIFICATIONS(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), SWAY_NOTIFICATION_CENTER_WIDGETS_TYPE_NOTIFICATIONS, SwayNotificationCenterWidgetsNotifications))
#define SWAY_NOTIFICATION_CENTER_WIDGETS_NOTIFICATIONS_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), SWAY_NOTIFICATION_CENTER_WIDGETS_TYPE_NOTIFICATIONS, SwayNotificationCenterWidgetsNotificationsClass))
#define SWAY_NOTIFICATION_CENTER_WIDGETS_IS_NOTIFICATIONS(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), SWAY_NOTIFICATION_CENTER_WIDGETS_TYPE_NOTIFICATIONS))
#define SWAY_NOTIFICATION_CENTER_WIDGETS_IS_NOTIFICATIONS_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), SWAY_NOTIFICATION_CENTER_WIDGETS_TYPE_NOTIFICATIONS))
#define SWAY_NOTIFICATION_CENTER_WIDGETS_NOTIFICATIONS_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), SWAY_NOTIFICATION_CENTER_WIDGETS_TYPE_NOTIFICATIONS, SwayNotificationCenterWidgetsNotificationsClass))

typedef struct _SwayNotificationCenterWidgetsNotifications SwayNotificationCenterWidgetsNotifications;
typedef struct _SwayNotificationCenterWidgetsNotificationsClass SwayNotificationCenterWidgetsNotificationsClass;

#define SWAY_NOTIFICATION_CENTER_TYPE_SWAYNC_DAEMON (sway_notification_center_swaync_daemon_get_type ())
#define SWAY_NOTIFICATION_CENTER_SWAYNC_DAEMON(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), SWAY_NOTIFICATION_CENTER_TYPE_SWAYNC_DAEMON, SwayNotificationCenterSwayncDaemon))
#define SWAY_NOTIFICATION_CENTER_SWAYNC_DAEMON_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), SWAY_NOTIFICATION_CENTER_TYPE_SWAYNC_DAEMON, SwayNotificationCenterSwayncDaemonClass))
#define SWAY_NOTIFICATION_CENTER_IS_SWAYNC_DAEMON(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), SWAY_NOTIFICATION_CENTER_TYPE_SWAYNC_DAEMON))
#define SWAY_NOTIFICATION_CENTER_IS_SWAYNC_DAEMON_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), SWAY_NOTIFICATION_CENTER_TYPE_SWAYNC_DAEMON))
#define SWAY_NOTIFICATION_CENTER_SWAYNC_DAEMON_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), SWAY_NOTIFICATION_CENTER_TYPE_SWAYNC_DAEMON, SwayNotificationCenterSwayncDaemonClass))

typedef struct _SwayNotificationCenterSwayncDaemon SwayNotificationCenterSwayncDaemon;
typedef struct _SwayNotificationCenterSwayncDaemonClass SwayNotificationCenterSwayncDaemonClass;

#define SWAY_NOTIFICATION_CENTER_TYPE_NOTIFY_PARAMS (sway_notification_center_notify_params_get_type ())
#define SWAY_NOTIFICATION_CENTER_NOTIFY_PARAMS(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), SWAY_NOTIFICATION_CENTER_TYPE_NOTIFY_PARAMS, SwayNotificationCenterNotifyParams))
#define SWAY_NOTIFICATION_CENTER_NOTIFY_PARAMS_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), SWAY_NOTIFICATION_CENTER_TYPE_NOTIFY_PARAMS, SwayNotificationCenterNotifyParamsClass))
#define SWAY_NOTIFICATION_CENTER_IS_NOTIFY_PARAMS(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), SWAY_NOTIFICATION_CENTER_TYPE_NOTIFY_PARAMS))
#define SWAY_NOTIFICATION_CENTER_IS_NOTIFY_PARAMS_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), SWAY_NOTIFICATION_CENTER_TYPE_NOTIFY_PARAMS))
#define SWAY_NOTIFICATION_CENTER_NOTIFY_PARAMS_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), SWAY_NOTIFICATION_CENTER_TYPE_NOTIFY_PARAMS, SwayNotificationCenterNotifyParamsClass))

typedef struct _SwayNotificationCenterNotifyParams SwayNotificationCenterNotifyParams;
typedef struct _SwayNotificationCenterNotifyParamsClass SwayNotificationCenterNotifyParamsClass;
typedef struct _Block5Data Block5Data;
typedef enum  {
	SWAY_NOTIFICATION_CENTER_NOTIFICATION_STATUS_ENUM_ENABLED,
	SWAY_NOTIFICATION_CENTER_NOTIFICATION_STATUS_ENUM_MUTED,
	SWAY_NOTIFICATION_CENTER_NOTIFICATION_STATUS_ENUM_IGNORED,
	SWAY_NOTIFICATION_CENTER_NOTIFICATION_STATUS_ENUM_TRANSIENT
} SwayNotificationCenterNotificationStatusEnum;

#define SWAY_NOTIFICATION_CENTER_TYPE_NOTIFICATION_STATUS_ENUM (sway_notification_center_notification_status_enum_get_type ())

#define SWAY_NOTIFICATION_CENTER_TYPE_CONTROL_CENTER (sway_notification_center_control_center_get_type ())
#define SWAY_NOTIFICATION_CENTER_CONTROL_CENTER(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), SWAY_NOTIFICATION_CENTER_TYPE_CONTROL_CENTER, SwayNotificationCenterControlCenter))
#define SWAY_NOTIFICATION_CENTER_CONTROL_CENTER_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), SWAY_NOTIFICATION_CENTER_TYPE_CONTROL_CENTER, SwayNotificationCenterControlCenterClass))
#define SWAY_NOTIFICATION_CENTER_IS_CONTROL_CENTER(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), SWAY_NOTIFICATION_CENTER_TYPE_CONTROL_CENTER))
#define SWAY_NOTIFICATION_CENTER_IS_CONTROL_CENTER_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), SWAY_NOTIFICATION_CENTER_TYPE_CONTROL_CENTER))
#define SWAY_NOTIFICATION_CENTER_CONTROL_CENTER_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), SWAY_NOTIFICATION_CENTER_TYPE_CONTROL_CENTER, SwayNotificationCenterControlCenterClass))

typedef struct _SwayNotificationCenterControlCenter SwayNotificationCenterControlCenter;
typedef struct _SwayNotificationCenterControlCenterClass SwayNotificationCenterControlCenterClass;
typedef enum  {
	SWAY_NOTIFICATION_CENTER_URGENCY_LEVELS_LOW = 0,
	SWAY_NOTIFICATION_CENTER_URGENCY_LEVELS_NORMAL = 1,
	SWAY_NOTIFICATION_CENTER_URGENCY_LEVELS_CRITICAL = 2
} SwayNotificationCenterUrgencyLevels;

#define SWAY_NOTIFICATION_CENTER_TYPE_URGENCY_LEVELS (sway_notification_center_urgency_levels_get_type ())

#define SWAY_NOTIFICATION_CENTER_TYPE_ORDERED_HASH_TABLE (sway_notification_center_ordered_hash_table_get_type ())
#define SWAY_NOTIFICATION_CENTER_ORDERED_HASH_TABLE(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), SWAY_NOTIFICATION_CENTER_TYPE_ORDERED_HASH_TABLE, SwayNotificationCenterOrderedHashTable))
#define SWAY_NOTIFICATION_CENTER_ORDERED_HASH_TABLE_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), SWAY_NOTIFICATION_CENTER_TYPE_ORDERED_HASH_TABLE, SwayNotificationCenterOrderedHashTableClass))
#define SWAY_NOTIFICATION_CENTER_IS_ORDERED_HASH_TABLE(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), SWAY_NOTIFICATION_CENTER_TYPE_ORDERED_HASH_TABLE))
#define SWAY_NOTIFICATION_CENTER_IS_ORDERED_HASH_TABLE_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), SWAY_NOTIFICATION_CENTER_TYPE_ORDERED_HASH_TABLE))
#define SWAY_NOTIFICATION_CENTER_ORDERED_HASH_TABLE_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), SWAY_NOTIFICATION_CENTER_TYPE_ORDERED_HASH_TABLE, SwayNotificationCenterOrderedHashTableClass))

typedef struct _SwayNotificationCenterOrderedHashTable SwayNotificationCenterOrderedHashTable;
typedef struct _SwayNotificationCenterOrderedHashTableClass SwayNotificationCenterOrderedHashTableClass;

#define SWAY_NOTIFICATION_CENTER_TYPE_NOTIFICATION_MATCHING (sway_notification_center_notification_matching_get_type ())
#define SWAY_NOTIFICATION_CENTER_NOTIFICATION_MATCHING(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), SWAY_NOTIFICATION_CENTER_TYPE_NOTIFICATION_MATCHING, SwayNotificationCenterNotificationMatching))
#define SWAY_NOTIFICATION_CENTER_NOTIFICATION_MATCHING_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), SWAY_NOTIFICATION_CENTER_TYPE_NOTIFICATION_MATCHING, SwayNotificationCenterNotificationMatchingClass))
#define SWAY_NOTIFICATION_CENTER_IS_NOTIFICATION_MATCHING(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), SWAY_NOTIFICATION_CENTER_TYPE_NOTIFICATION_MATCHING))
#define SWAY_NOTIFICATION_CENTER_IS_NOTIFICATION_MATCHING_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), SWAY_NOTIFICATION_CENTER_TYPE_NOTIFICATION_MATCHING))
#define SWAY_NOTIFICATION_CENTER_NOTIFICATION_MATCHING_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), SWAY_NOTIFICATION_CENTER_TYPE_NOTIFICATION_MATCHING, SwayNotificationCenterNotificationMatchingClass))

typedef struct _SwayNotificationCenterNotificationMatching SwayNotificationCenterNotificationMatching;
typedef struct _SwayNotificationCenterNotificationMatchingClass SwayNotificationCenterNotificationMatchingClass;

#define SWAY_NOTIFICATION_CENTER_TYPE_SCRIPT (sway_notification_center_script_get_type ())
#define SWAY_NOTIFICATION_CENTER_SCRIPT(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), SWAY_NOTIFICATION_CENTER_TYPE_SCRIPT, SwayNotificationCenterScript))
#define SWAY_NOTIFICATION_CENTER_SCRIPT_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), SWAY_NOTIFICATION_CENTER_TYPE_SCRIPT, SwayNotificationCenterScriptClass))
#define SWAY_NOTIFICATION_CENTER_IS_SCRIPT(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), SWAY_NOTIFICATION_CENTER_TYPE_SCRIPT))
#define SWAY_NOTIFICATION_CENTER_IS_SCRIPT_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), SWAY_NOTIFICATION_CENTER_TYPE_SCRIPT))
#define SWAY_NOTIFICATION_CENTER_SCRIPT_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), SWAY_NOTIFICATION_CENTER_TYPE_SCRIPT, SwayNotificationCenterScriptClass))

typedef struct _SwayNotificationCenterScript SwayNotificationCenterScript;
typedef struct _SwayNotificationCenterScriptClass SwayNotificationCenterScriptClass;

#define SWAY_NOTIFICATION_CENTER_TYPE_CONFIG_MODEL (sway_notification_center_config_model_get_type ())
#define SWAY_NOTIFICATION_CENTER_CONFIG_MODEL(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), SWAY_NOTIFICATION_CENTER_TYPE_CONFIG_MODEL, SwayNotificationCenterConfigModel))
#define SWAY_NOTIFICATION_CENTER_CONFIG_MODEL_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), SWAY_NOTIFICATION_CENTER_TYPE_CONFIG_MODEL, SwayNotificationCenterConfigModelClass))
#define SWAY_NOTIFICATION_CENTER_IS_CONFIG_MODEL(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), SWAY_NOTIFICATION_CENTER_TYPE_CONFIG_MODEL))
#define SWAY_NOTIFICATION_CENTER_IS_CONFIG_MODEL_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), SWAY_NOTIFICATION_CENTER_TYPE_CONFIG_MODEL))
#define SWAY_NOTIFICATION_CENTER_CONFIG_MODEL_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), SWAY_NOTIFICATION_CENTER_TYPE_CONFIG_MODEL, SwayNotificationCenterConfigModelClass))

typedef struct _SwayNotificationCenterConfigModel SwayNotificationCenterConfigModel;
typedef struct _SwayNotificationCenterConfigModelClass SwayNotificationCenterConfigModelClass;
#define _sway_notification_center_ordered_hash_table_unref0(var) ((var == NULL) ? NULL : (var = (sway_notification_center_ordered_hash_table_unref (var), NULL)))
typedef enum  {
	SWAY_NOTIFICATION_CENTER_SCRIPT_RUN_ON_TYPE_ACTION,
	SWAY_NOTIFICATION_CENTER_SCRIPT_RUN_ON_TYPE_RECEIVE
} SwayNotificationCenterScriptRunOnType;

#define SWAY_NOTIFICATION_CENTER_TYPE_SCRIPT_RUN_ON_TYPE (sway_notification_center_script_run_on_type_get_type ())
typedef struct _Block6Data Block6Data;
#define _g_error_free0(var) ((var == NULL) ? NULL : (var = (g_error_free (var), NULL)))
enum  {
	SWAY_NOTIFICATION_CENTER_NOTI_DAEMON_ON_DND_TOGGLE_SIGNAL,
	SWAY_NOTIFICATION_CENTER_NOTI_DAEMON_NOTIFICATION_CLOSED_SIGNAL,
	SWAY_NOTIFICATION_CENTER_NOTI_DAEMON_ACTION_INVOKED_SIGNAL,
	SWAY_NOTIFICATION_CENTER_NOTI_DAEMON_ACTIVATION_TOKEN_SIGNAL,
	SWAY_NOTIFICATION_CENTER_NOTI_DAEMON_NOTIFICATION_REPLIED_SIGNAL,
	SWAY_NOTIFICATION_CENTER_NOTI_DAEMON_NUM_SIGNALS
};
static guint sway_notification_center_noti_daemon_signals[SWAY_NOTIFICATION_CENTER_NOTI_DAEMON_NUM_SIGNALS] = {0};

struct _SwayNotificationCenterNotiDaemon {
	GObject parent_instance;
	SwayNotificationCenterNotiDaemonPrivate * priv;
};

struct _SwayNotificationCenterNotiDaemonClass {
	GObjectClass parent_class;
};

struct _SwayNotificationCenterNotiDaemonPrivate {
	guint32 noti_id;
	GHashTable* synchronous_ids;
	GeeHashSet* notification_ids;
	gboolean _dnd;
};

struct _Block5Data {
	int _ref_count_;
	SwayNotificationCenterNotiDaemon* self;
	SwayNotificationCenternotification_filter_func func;
	gpointer func_target;
};

struct _Block6Data {
	int _ref_count_;
	SwayNotificationCenterNotiDaemon* self;
	gchar* key;
	SwayNotificationCenterScript* script;
};

static gint SwayNotificationCenterNotiDaemon_private_offset;
static gpointer sway_notification_center_noti_daemon_parent_class = NULL;
VALA_EXTERN GSettings* sway_notification_center_self_settings;
VALA_EXTERN SwayNotificationCenterNotificationWindow* sway_notification_center_floating_notifications;
VALA_EXTERN SwayNotificationCenterWidgetsNotifications* sway_notification_center_notifications_widget;
VALA_EXTERN SwayNotificationCenterSwayncDaemon* sway_notification_center_swaync_daemon;
VALA_EXTERN SwayNotificationCenterControlCenter* sway_notification_center_control_center;

VALA_EXTERN GType sway_notification_center_notification_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (SwayNotificationCenterNotification, g_object_unref)
VALA_EXTERN GType sway_notification_center_noti_daemon_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (SwayNotificationCenterNotiDaemon, g_object_unref)
VALA_EXTERN guint sway_notification_center_noti_daemon_register_object (void* object,
                                                            GDBusConnection* connection,
                                                            const gchar* path,
                                                            GError** error);
static void _g_free0_ (gpointer var);
VALA_EXTERN SwayNotificationCenterNotiDaemon* sway_notification_center_noti_daemon_new (void);
VALA_EXTERN SwayNotificationCenterNotiDaemon* sway_notification_center_noti_daemon_construct (GType object_type);
static void __lambda4_ (SwayNotificationCenterNotiDaemon* self);
VALA_EXTERN gboolean sway_notification_center_noti_daemon_get_dnd (SwayNotificationCenterNotiDaemon* self);
static void ___lambda4__g_object_notify (GObject* _sender,
                                  GParamSpec* pspec,
                                  gpointer self);
VALA_EXTERN GType sway_notification_center_closed_reasons_get_type (void) G_GNUC_CONST ;
VALA_EXTERN void sway_notification_center_noti_daemon_request_dismiss_notification_id (SwayNotificationCenterNotiDaemon* self,
                                                                           guint32 id,
                                                                           SwayNotificationCenterClosedReasons reason,
                                                                           gboolean ignore_cc);
VALA_EXTERN GType sway_notification_center_notification_window_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (SwayNotificationCenterNotificationWindow, g_object_unref)
VALA_EXTERN void sway_notification_center_notification_window_remove_notification (SwayNotificationCenterNotificationWindow* self,
                                                                       guint32 id);
VALA_EXTERN GType sway_notification_center_widgets_base_widget_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (SwayNotificationCenterWidgetsBaseWidget, g_object_unref)
VALA_EXTERN GType sway_notification_center_widgets_notifications_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (SwayNotificationCenterWidgetsNotifications, g_object_unref)
VALA_EXTERN void sway_notification_center_widgets_notifications_remove_notification (SwayNotificationCenterWidgetsNotifications* self,
                                                                         guint32 id);
VALA_EXTERN GType sway_notification_center_swaync_daemon_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (SwayNotificationCenterSwayncDaemon, g_object_unref)
VALA_EXTERN guint sway_notification_center_swaync_daemon_register_object (void* object,
                                                              GDBusConnection* connection,
                                                              const gchar* path,
                                                              GError** error);
VALA_EXTERN void sway_notification_center_swaync_daemon_emit_subscribe (SwayNotificationCenterSwayncDaemon* self);
VALA_EXTERN GType sway_notification_center_notify_params_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (SwayNotificationCenterNotifyParams, g_object_unref)
VALA_EXTERN void sway_notification_center_noti_daemon_request_dismiss_notification (SwayNotificationCenterNotiDaemon* self,
                                                                        SwayNotificationCenterNotifyParams* param,
                                                                        SwayNotificationCenterClosedReasons reason);
VALA_EXTERN guint32 sway_notification_center_notify_params_get_applied_id (SwayNotificationCenterNotifyParams* self);
VALA_EXTERN gboolean sway_notification_center_notify_params_ignore_cc (SwayNotificationCenterNotifyParams* self);
VALA_EXTERN void sway_notification_center_noti_daemon_request_dismiss_notification_group (SwayNotificationCenterNotiDaemon* self,
                                                                              const gchar* group_name_id,
                                                                              GeeSet* ids,
                                                                              SwayNotificationCenterClosedReasons reason);
VALA_EXTERN void sway_notification_center_widgets_notifications_remove_group (SwayNotificationCenterWidgetsNotifications* self,
                                                                  const gchar* group_name_id);
VALA_EXTERN void sway_notification_center_noti_daemon_request_dismiss_all_notifications (SwayNotificationCenterNotiDaemon* self,
                                                                             SwayNotificationCenterClosedReasons reason);
VALA_EXTERN void sway_notification_center_noti_daemon_remove_all_floating_notifications (SwayNotificationCenterNotiDaemon* self,
                                                                             gboolean transition,
                                                                             SwayNotificationCenternotification_filter_func func,
                                                                             gpointer func_target);
VALA_EXTERN void sway_notification_center_widgets_notifications_remove_all_notifications (SwayNotificationCenterWidgetsNotifications* self,
                                                                              gboolean animate);
static Block5Data* block5_data_ref (Block5Data* _data5_);
static void block5_data_unref (void * _userdata_);
VALA_EXTERN void sway_notification_center_notification_window_remove_all_notifications (SwayNotificationCenterNotificationWindow* self,
                                                                            gboolean transition,
                                                                            SwayNotificationCenternotification_filter_func filter_func,
                                                                            gpointer filter_func_target);
static gboolean __lambda45_ (Block5Data* _data5_,
                      SwayNotificationCenterNotification* notification);
VALA_EXTERN SwayNotificationCenterNotifyParams* sway_notification_center_notification_get_param (SwayNotificationCenterNotification* self);
static gboolean ___lambda45__swaynotificationcenternotification_filter_func (SwayNotificationCenterNotification* notification,
                                                                      gpointer self);
VALA_EXTERN void sway_notification_center_noti_daemon_hide_latest_floating_notification (SwayNotificationCenterNotiDaemon* self,
                                                                             gboolean close);
VALA_EXTERN SwayNotificationCenterNotifyParams* sway_notification_center_notification_window_get_latest_notification (SwayNotificationCenterNotificationWindow* self);
VALA_EXTERN void sway_notification_center_noti_daemon_invoke_latest_floating_action (SwayNotificationCenterNotiDaemon* self,
                                                                         guint32 action_index);
VALA_EXTERN void sway_notification_center_notification_window_latest_notification_action (SwayNotificationCenterNotificationWindow* self,
                                                                              guint32 action);
VALA_EXTERN gchar** sway_notification_center_noti_daemon_get_capabilities (SwayNotificationCenterNotiDaemon* self,
                                                               gint* result_length1,
                                                               GError** error);
VALA_EXTERN guint32 sway_notification_center_noti_daemon_new_notification (SwayNotificationCenterNotiDaemon* self,
                                                               const gchar* app_name,
                                                               guint32 replaces_id,
                                                               const gchar* app_icon,
                                                               const gchar* summary,
                                                               const gchar* body,
                                                               gchar** actions,
                                                               gint actions_length1,
                                                               GHashTable* hints,
                                                               gint expire_timeout,
                                                               GError** error);
VALA_EXTERN SwayNotificationCenterNotifyParams* sway_notification_center_notify_params_new (guint32 applied_id,
                                                                                const gchar* app_name,
                                                                                guint32 replaces_id,
                                                                                const gchar* app_icon,
                                                                                const gchar* summary,
                                                                                const gchar* body,
                                                                                gchar** actions,
                                                                                gint actions_length1,
                                                                                GHashTable* hints,
                                                                                gint expire_timeout);
VALA_EXTERN SwayNotificationCenterNotifyParams* sway_notification_center_notify_params_construct (GType object_type,
                                                                                      guint32 applied_id,
                                                                                      const gchar* app_name,
                                                                                      guint32 replaces_id,
                                                                                      const gchar* app_icon,
                                                                                      const gchar* summary,
                                                                                      const gchar* body,
                                                                                      gchar** actions,
                                                                                      gint actions_length1,
                                                                                      GHashTable* hints,
                                                                                      gint expire_timeout);
VALA_EXTERN GType sway_notification_center_notification_status_enum_get_type (void) G_GNUC_CONST ;
VALA_EXTERN SwayNotificationCenterNotificationStatusEnum sway_notification_center_notify_params_get_status_state (SwayNotificationCenterNotifyParams* self);
VALA_EXTERN gchar* sway_notification_center_notification_status_enum_to_string (SwayNotificationCenterNotificationStatusEnum self);
VALA_EXTERN gchar* sway_notification_center_notify_params_to_string (SwayNotificationCenterNotifyParams* self);
VALA_EXTERN const gchar* sway_notification_center_notify_params_get_synchronous (SwayNotificationCenterNotifyParams* self);
static void _vala_array_add25 (gchar** * array,
                        gint* length,
                        gint* size,
                        gchar* value);
VALA_EXTERN GType sway_notification_center_control_center_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (SwayNotificationCenterControlCenter, g_object_unref)
VALA_EXTERN gboolean sway_notification_center_control_center_get_visibility (SwayNotificationCenterControlCenter* self);
static void _vala_array_add26 (gchar** * array,
                        gint* length,
                        gint* size,
                        gchar* value);
VALA_EXTERN GType sway_notification_center_urgency_levels_get_type (void) G_GNUC_CONST ;
VALA_EXTERN SwayNotificationCenterUrgencyLevels sway_notification_center_notify_params_get_urgency (SwayNotificationCenterNotifyParams* self);
VALA_EXTERN gboolean sway_notification_center_notify_params_get_swaync_bypass_dnd (SwayNotificationCenterNotifyParams* self);
VALA_EXTERN gboolean sway_notification_center_swaync_daemon_get_inhibited (SwayNotificationCenterSwayncDaemon* self);
static void _vala_array_add27 (gchar** * array,
                        gint* length,
                        gint* size,
                        gchar* value);
VALA_EXTERN void sway_notification_center_notification_window_replace_notification (SwayNotificationCenterNotificationWindow* self,
                                                                        guint32 id,
                                                                        SwayNotificationCenterNotifyParams* new_params);
VALA_EXTERN void sway_notification_center_notification_window_add_notification (SwayNotificationCenterNotificationWindow* self,
                                                                    SwayNotificationCenterNotifyParams* param);
VALA_EXTERN void sway_notification_center_widgets_notifications_replace_notification (SwayNotificationCenterWidgetsNotifications* self,
                                                                          guint32 id,
                                                                          SwayNotificationCenterNotifyParams* new_params);
VALA_EXTERN void sway_notification_center_widgets_notifications_add_notification (SwayNotificationCenterWidgetsNotifications* self,
                                                                      SwayNotificationCenterNotifyParams* param);
VALA_EXTERN gboolean sway_notification_center_notify_params_get_swaync_no_script (SwayNotificationCenterNotifyParams* self);
VALA_EXTERN gpointer sway_notification_center_ordered_hash_table_ref (gpointer instance);
VALA_EXTERN void sway_notification_center_ordered_hash_table_unref (gpointer instance);
VALA_EXTERN GParamSpec* sway_notification_center_param_spec_ordered_hash_table (const gchar* name,
                                                                    const gchar* nick,
                                                                    const gchar* blurb,
                                                                    GType object_type,
                                                                    GParamFlags flags);
VALA_EXTERN void sway_notification_center_value_set_ordered_hash_table (GValue* value,
                                                            gpointer v_object);
VALA_EXTERN void sway_notification_center_value_take_ordered_hash_table (GValue* value,
                                                             gpointer v_object);
VALA_EXTERN gpointer sway_notification_center_value_get_ordered_hash_table (const GValue* value);
VALA_EXTERN GType sway_notification_center_ordered_hash_table_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (SwayNotificationCenterOrderedHashTable, sway_notification_center_ordered_hash_table_unref)
VALA_EXTERN GType sway_notification_center_notification_matching_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (SwayNotificationCenterNotificationMatching, g_object_unref)
VALA_EXTERN GType sway_notification_center_script_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (SwayNotificationCenterScript, g_object_unref)
VALA_EXTERN GType sway_notification_center_config_model_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (SwayNotificationCenterConfigModel, g_object_unref)
VALA_EXTERN SwayNotificationCenterConfigModel* sway_notification_center_config_model_get_instance (void);
VALA_EXTERN SwayNotificationCenterOrderedHashTable* sway_notification_center_config_model_get_scripts (SwayNotificationCenterConfigModel* self);
VALA_EXTERN guint sway_notification_center_ordered_hash_table_get_length (SwayNotificationCenterOrderedHashTable* self);
VALA_EXTERN GType sway_notification_center_script_run_on_type_get_type (void) G_GNUC_CONST ;
VALA_EXTERN void sway_notification_center_noti_daemon_run_scripts (SwayNotificationCenterNotiDaemon* self,
                                                       SwayNotificationCenterNotifyParams* param,
                                                       SwayNotificationCenterScriptRunOnType run_on);
VALA_EXTERN GList* sway_notification_center_ordered_hash_table_get_keys (SwayNotificationCenterOrderedHashTable* self);
static Block6Data* block6_data_ref (Block6Data* _data6_);
static void block6_data_unref (void * _userdata_);
VALA_EXTERN gconstpointer sway_notification_center_ordered_hash_table_get (SwayNotificationCenterOrderedHashTable* self,
                                                               const gchar* key);
VALA_EXTERN gboolean sway_notification_center_notification_matching_matches_notification (SwayNotificationCenterNotificationMatching* self,
                                                                              SwayNotificationCenterNotifyParams* param);
VALA_EXTERN SwayNotificationCenterScriptRunOnType sway_notification_center_script_get_run_on (SwayNotificationCenterScript* self);
VALA_EXTERN void sway_notification_center_script_run_script (SwayNotificationCenterScript* self,
                                                 SwayNotificationCenterNotifyParams* param,
                                                 GAsyncReadyCallback _callback_,
                                                 gpointer _user_data_);
VALA_EXTERN gboolean sway_notification_center_script_run_script_finish (SwayNotificationCenterScript* self,
                                                            GAsyncResult* _res_,
                                                            gchar** msg);
static void ____lambda37_ (Block6Data* _data6_,
                    GObject* obj,
                    GAsyncResult* res);
VALA_EXTERN gboolean sway_notification_center_config_model_get_script_fail_notify (SwayNotificationCenterConfigModel* self);
VALA_EXTERN const gchar* sway_notification_center_script_get_exec (SwayNotificationCenterScript* self);
static void _g_variant_unref0_ (gpointer var);
static GVariant* _variant_new1 (gboolean value);
VALA_EXTERN guint8 sway_notification_center_urgency_levels_to_byte (SwayNotificationCenterUrgencyLevels self);
static GVariant* _variant_new2 (guint8 value);
static void _____lambda37__gasync_ready_callback (GObject* source_object,
                                           GAsyncResult* res,
                                           gpointer self);
VALA_EXTERN void sway_notification_center_noti_daemon_close_notification (SwayNotificationCenterNotiDaemon* self,
                                                              guint32 id,
                                                              GError** error);
VALA_EXTERN void sway_notification_center_noti_daemon_get_server_information (SwayNotificationCenterNotiDaemon* self,
                                                                  gchar** name,
                                                                  gchar** vendor,
                                                                  gchar** version,
                                                                  gchar** spec_version,
                                                                  GError** error);
VALA_EXTERN void sway_notification_center_noti_daemon_set_dnd (SwayNotificationCenterNotiDaemon* self,
                                                   gboolean value);
VALA_EXTERN guint sway_notification_center_noti_daemon_get_n_notifications (SwayNotificationCenterNotiDaemon* self);
VALA_EXTERN guint sway_notification_center_widgets_notifications_get_n_notifications (SwayNotificationCenterWidgetsNotifications* self);
static void g_cclosure_user_marshal_VOID__UINT_UINT (GClosure * closure,
                                              GValue * return_value,
                                              guint n_param_values,
                                              const GValue * param_values,
                                              gpointer invocation_hint,
                                              gpointer marshal_data);
static void g_cclosure_user_marshal_VOID__UINT_STRING (GClosure * closure,
                                                GValue * return_value,
                                                guint n_param_values,
                                                const GValue * param_values,
                                                gpointer invocation_hint,
                                                gpointer marshal_data);
static void sway_notification_center_noti_daemon_finalize (GObject * obj);
static GType sway_notification_center_noti_daemon_get_type_once (void);
static void _vala_sway_notification_center_noti_daemon_get_property (GObject * object,
                                                              guint property_id,
                                                              GValue * value,
                                                              GParamSpec * pspec);
static void _vala_sway_notification_center_noti_daemon_set_property (GObject * object,
                                                              guint property_id,
                                                              const GValue * value,
                                                              GParamSpec * pspec);
static void _dbus_sway_notification_center_noti_daemon_get_capabilities (SwayNotificationCenterNotiDaemon* self,
                                                                  GVariant* _parameters_,
                                                                  GDBusMethodInvocation* invocation);
static void _dbus_sway_notification_center_noti_daemon_new_notification (SwayNotificationCenterNotiDaemon* self,
                                                                  GVariant* _parameters_,
                                                                  GDBusMethodInvocation* invocation);
static void _dbus_sway_notification_center_noti_daemon_close_notification (SwayNotificationCenterNotiDaemon* self,
                                                                    GVariant* _parameters_,
                                                                    GDBusMethodInvocation* invocation);
static void _dbus_sway_notification_center_noti_daemon_get_server_information (SwayNotificationCenterNotiDaemon* self,
                                                                        GVariant* _parameters_,
                                                                        GDBusMethodInvocation* invocation);
static void sway_notification_center_noti_daemon_dbus_interface_method_call (GDBusConnection* connection,
                                                                      const gchar* sender,
                                                                      const gchar* object_path,
                                                                      const gchar* interface_name,
                                                                      const gchar* method_name,
                                                                      GVariant* parameters,
                                                                      GDBusMethodInvocation* invocation,
                                                                      gpointer user_data);
static GVariant* sway_notification_center_noti_daemon_dbus_interface_get_property (GDBusConnection* connection,
                                                                            const gchar* sender,
                                                                            const gchar* object_path,
                                                                            const gchar* interface_name,
                                                                            const gchar* property_name,
                                                                            GError** error,
                                                                            gpointer user_data);
static gboolean sway_notification_center_noti_daemon_dbus_interface_set_property (GDBusConnection* connection,
                                                                           const gchar* sender,
                                                                           const gchar* object_path,
                                                                           const gchar* interface_name,
                                                                           const gchar* property_name,
                                                                           GVariant* value,
                                                                           GError** error,
                                                                           gpointer user_data);
static void _dbus_sway_notification_center_noti_daemon_notification_closed (GObject* _sender,
                                                                     guint32 id,
                                                                     guint32 reason,
                                                                     gpointer* _data);
static void _dbus_sway_notification_center_noti_daemon_action_invoked (GObject* _sender,
                                                                guint32 id,
                                                                const gchar* action_key,
                                                                gpointer* _data);
static void _dbus_sway_notification_center_noti_daemon_activation_token (GObject* _sender,
                                                                  guint32 id,
                                                                  const gchar* activation_token,
                                                                  gpointer* _data);
static void _dbus_sway_notification_center_noti_daemon_notification_replied (GObject* _sender,
                                                                      guint32 id,
                                                                      const gchar* text,
                                                                      gpointer* _data);
static void _sway_notification_center_noti_daemon_unregister_object (gpointer user_data);
static void _vala_array_destroy (gpointer array,
                          gssize array_length,
                          GDestroyNotify destroy_func);
static void _vala_array_free (gpointer array,
                       gssize array_length,
                       GDestroyNotify destroy_func);

static const GDBusArgInfo _sway_notification_center_noti_daemon_dbus_arg_info_get_capabilities_result = {-1, "result", "as", NULL};
static const GDBusArgInfo * const _sway_notification_center_noti_daemon_dbus_arg_info_get_capabilities_in[] = {NULL};
static const GDBusArgInfo * const _sway_notification_center_noti_daemon_dbus_arg_info_get_capabilities_out[] = {&_sway_notification_center_noti_daemon_dbus_arg_info_get_capabilities_result, NULL};
static const GDBusMethodInfo _sway_notification_center_noti_daemon_dbus_method_info_get_capabilities = {-1, "GetCapabilities", (GDBusArgInfo **) (&_sway_notification_center_noti_daemon_dbus_arg_info_get_capabilities_in), (GDBusArgInfo **) (&_sway_notification_center_noti_daemon_dbus_arg_info_get_capabilities_out), NULL};
static const GDBusArgInfo _sway_notification_center_noti_daemon_dbus_arg_info_new_notification_app_name = {-1, "app_name", "s", NULL};
static const GDBusArgInfo _sway_notification_center_noti_daemon_dbus_arg_info_new_notification_replaces_id = {-1, "replaces_id", "u", NULL};
static const GDBusArgInfo _sway_notification_center_noti_daemon_dbus_arg_info_new_notification_app_icon = {-1, "app_icon", "s", NULL};
static const GDBusArgInfo _sway_notification_center_noti_daemon_dbus_arg_info_new_notification_summary = {-1, "summary", "s", NULL};
static const GDBusArgInfo _sway_notification_center_noti_daemon_dbus_arg_info_new_notification_body = {-1, "body", "s", NULL};
static const GDBusArgInfo _sway_notification_center_noti_daemon_dbus_arg_info_new_notification_actions = {-1, "actions", "as", NULL};
static const GDBusArgInfo _sway_notification_center_noti_daemon_dbus_arg_info_new_notification_hints = {-1, "hints", "a{sv}", NULL};
static const GDBusArgInfo _sway_notification_center_noti_daemon_dbus_arg_info_new_notification_expire_timeout = {-1, "expire_timeout", "i", NULL};
static const GDBusArgInfo _sway_notification_center_noti_daemon_dbus_arg_info_new_notification_result = {-1, "result", "u", NULL};
static const GDBusArgInfo * const _sway_notification_center_noti_daemon_dbus_arg_info_new_notification_in[] = {&_sway_notification_center_noti_daemon_dbus_arg_info_new_notification_app_name, &_sway_notification_center_noti_daemon_dbus_arg_info_new_notification_replaces_id, &_sway_notification_center_noti_daemon_dbus_arg_info_new_notification_app_icon, &_sway_notification_center_noti_daemon_dbus_arg_info_new_notification_summary, &_sway_notification_center_noti_daemon_dbus_arg_info_new_notification_body, &_sway_notification_center_noti_daemon_dbus_arg_info_new_notification_actions, &_sway_notification_center_noti_daemon_dbus_arg_info_new_notification_hints, &_sway_notification_center_noti_daemon_dbus_arg_info_new_notification_expire_timeout, NULL};
static const GDBusArgInfo * const _sway_notification_center_noti_daemon_dbus_arg_info_new_notification_out[] = {&_sway_notification_center_noti_daemon_dbus_arg_info_new_notification_result, NULL};
static const GDBusMethodInfo _sway_notification_center_noti_daemon_dbus_method_info_new_notification = {-1, "Notify", (GDBusArgInfo **) (&_sway_notification_center_noti_daemon_dbus_arg_info_new_notification_in), (GDBusArgInfo **) (&_sway_notification_center_noti_daemon_dbus_arg_info_new_notification_out), NULL};
static const GDBusArgInfo _sway_notification_center_noti_daemon_dbus_arg_info_close_notification_id = {-1, "id", "u", NULL};
static const GDBusArgInfo * const _sway_notification_center_noti_daemon_dbus_arg_info_close_notification_in[] = {&_sway_notification_center_noti_daemon_dbus_arg_info_close_notification_id, NULL};
static const GDBusArgInfo * const _sway_notification_center_noti_daemon_dbus_arg_info_close_notification_out[] = {NULL};
static const GDBusMethodInfo _sway_notification_center_noti_daemon_dbus_method_info_close_notification = {-1, "CloseNotification", (GDBusArgInfo **) (&_sway_notification_center_noti_daemon_dbus_arg_info_close_notification_in), (GDBusArgInfo **) (&_sway_notification_center_noti_daemon_dbus_arg_info_close_notification_out), NULL};
static const GDBusArgInfo _sway_notification_center_noti_daemon_dbus_arg_info_get_server_information_name = {-1, "name", "s", NULL};
static const GDBusArgInfo _sway_notification_center_noti_daemon_dbus_arg_info_get_server_information_vendor = {-1, "vendor", "s", NULL};
static const GDBusArgInfo _sway_notification_center_noti_daemon_dbus_arg_info_get_server_information_version = {-1, "version", "s", NULL};
static const GDBusArgInfo _sway_notification_center_noti_daemon_dbus_arg_info_get_server_information_spec_version = {-1, "spec_version", "s", NULL};
static const GDBusArgInfo * const _sway_notification_center_noti_daemon_dbus_arg_info_get_server_information_in[] = {NULL};
static const GDBusArgInfo * const _sway_notification_center_noti_daemon_dbus_arg_info_get_server_information_out[] = {&_sway_notification_center_noti_daemon_dbus_arg_info_get_server_information_name, &_sway_notification_center_noti_daemon_dbus_arg_info_get_server_information_vendor, &_sway_notification_center_noti_daemon_dbus_arg_info_get_server_information_version, &_sway_notification_center_noti_daemon_dbus_arg_info_get_server_information_spec_version, NULL};
static const GDBusMethodInfo _sway_notification_center_noti_daemon_dbus_method_info_get_server_information = {-1, "GetServerInformation", (GDBusArgInfo **) (&_sway_notification_center_noti_daemon_dbus_arg_info_get_server_information_in), (GDBusArgInfo **) (&_sway_notification_center_noti_daemon_dbus_arg_info_get_server_information_out), NULL};
static const GDBusMethodInfo * const _sway_notification_center_noti_daemon_dbus_method_info[] = {&_sway_notification_center_noti_daemon_dbus_method_info_get_capabilities, &_sway_notification_center_noti_daemon_dbus_method_info_new_notification, &_sway_notification_center_noti_daemon_dbus_method_info_close_notification, &_sway_notification_center_noti_daemon_dbus_method_info_get_server_information, NULL};
static const GDBusArgInfo _sway_notification_center_noti_daemon_dbus_arg_info_notification_closed_id = {-1, "id", "u", NULL};
static const GDBusArgInfo _sway_notification_center_noti_daemon_dbus_arg_info_notification_closed_reason = {-1, "reason", "u", NULL};
static const GDBusArgInfo * const _sway_notification_center_noti_daemon_dbus_arg_info_notification_closed[] = {&_sway_notification_center_noti_daemon_dbus_arg_info_notification_closed_id, &_sway_notification_center_noti_daemon_dbus_arg_info_notification_closed_reason, NULL};
static const GDBusSignalInfo _sway_notification_center_noti_daemon_dbus_signal_info_notification_closed = {-1, "NotificationClosed", (GDBusArgInfo **) (&_sway_notification_center_noti_daemon_dbus_arg_info_notification_closed), NULL};
static const GDBusArgInfo _sway_notification_center_noti_daemon_dbus_arg_info_action_invoked_id = {-1, "id", "u", NULL};
static const GDBusArgInfo _sway_notification_center_noti_daemon_dbus_arg_info_action_invoked_action_key = {-1, "action_key", "s", NULL};
static const GDBusArgInfo * const _sway_notification_center_noti_daemon_dbus_arg_info_action_invoked[] = {&_sway_notification_center_noti_daemon_dbus_arg_info_action_invoked_id, &_sway_notification_center_noti_daemon_dbus_arg_info_action_invoked_action_key, NULL};
static const GDBusSignalInfo _sway_notification_center_noti_daemon_dbus_signal_info_action_invoked = {-1, "ActionInvoked", (GDBusArgInfo **) (&_sway_notification_center_noti_daemon_dbus_arg_info_action_invoked), NULL};
static const GDBusArgInfo _sway_notification_center_noti_daemon_dbus_arg_info_activation_token_id = {-1, "id", "u", NULL};
static const GDBusArgInfo _sway_notification_center_noti_daemon_dbus_arg_info_activation_token_activation_token = {-1, "activation_token", "s", NULL};
static const GDBusArgInfo * const _sway_notification_center_noti_daemon_dbus_arg_info_activation_token[] = {&_sway_notification_center_noti_daemon_dbus_arg_info_activation_token_id, &_sway_notification_center_noti_daemon_dbus_arg_info_activation_token_activation_token, NULL};
static const GDBusSignalInfo _sway_notification_center_noti_daemon_dbus_signal_info_activation_token = {-1, "ActivationToken", (GDBusArgInfo **) (&_sway_notification_center_noti_daemon_dbus_arg_info_activation_token), NULL};
static const GDBusArgInfo _sway_notification_center_noti_daemon_dbus_arg_info_notification_replied_id = {-1, "id", "u", NULL};
static const GDBusArgInfo _sway_notification_center_noti_daemon_dbus_arg_info_notification_replied_text = {-1, "text", "s", NULL};
static const GDBusArgInfo * const _sway_notification_center_noti_daemon_dbus_arg_info_notification_replied[] = {&_sway_notification_center_noti_daemon_dbus_arg_info_notification_replied_id, &_sway_notification_center_noti_daemon_dbus_arg_info_notification_replied_text, NULL};
static const GDBusSignalInfo _sway_notification_center_noti_daemon_dbus_signal_info_notification_replied = {-1, "NotificationReplied", (GDBusArgInfo **) (&_sway_notification_center_noti_daemon_dbus_arg_info_notification_replied), NULL};
static const GDBusSignalInfo * const _sway_notification_center_noti_daemon_dbus_signal_info[] = {&_sway_notification_center_noti_daemon_dbus_signal_info_notification_closed, &_sway_notification_center_noti_daemon_dbus_signal_info_action_invoked, &_sway_notification_center_noti_daemon_dbus_signal_info_activation_token, &_sway_notification_center_noti_daemon_dbus_signal_info_notification_replied, NULL};
static const GDBusPropertyInfo * const _sway_notification_center_noti_daemon_dbus_property_info[] = {NULL};
static const GDBusInterfaceInfo _sway_notification_center_noti_daemon_dbus_interface_info = {-1, "org.freedesktop.Notifications", (GDBusMethodInfo **) (&_sway_notification_center_noti_daemon_dbus_method_info), (GDBusSignalInfo **) (&_sway_notification_center_noti_daemon_dbus_signal_info), (GDBusPropertyInfo **) (&_sway_notification_center_noti_daemon_dbus_property_info), NULL};
static const GDBusInterfaceVTable _sway_notification_center_noti_daemon_dbus_interface_vtable = {sway_notification_center_noti_daemon_dbus_interface_method_call, sway_notification_center_noti_daemon_dbus_interface_get_property, sway_notification_center_noti_daemon_dbus_interface_set_property};

static inline gpointer
sway_notification_center_noti_daemon_get_instance_private (SwayNotificationCenterNotiDaemon* self)
{
	return G_STRUCT_MEMBER_P (self, SwayNotificationCenterNotiDaemon_private_offset);
}

static void
_g_free0_ (gpointer var)
{
	var = (g_free (var), NULL);
}

static void
__lambda4_ (SwayNotificationCenterNotiDaemon* self)
{
	gboolean _tmp0_;
	_tmp0_ = self->priv->_dnd;
	g_signal_emit (self, sway_notification_center_noti_daemon_signals[SWAY_NOTIFICATION_CENTER_NOTI_DAEMON_ON_DND_TOGGLE_SIGNAL], 0, _tmp0_);
}

static void
___lambda4__g_object_notify (GObject* _sender,
                             GParamSpec* pspec,
                             gpointer self)
{
	__lambda4_ ((SwayNotificationCenterNotiDaemon*) self);
}

SwayNotificationCenterNotiDaemon*
sway_notification_center_noti_daemon_construct (GType object_type)
{
	SwayNotificationCenterNotiDaemon * self = NULL;
	GSettings* _tmp0_;
	self = (SwayNotificationCenterNotiDaemon*) g_object_new (object_type, NULL);
	g_signal_connect_object (G_TYPE_CHECK_INSTANCE_CAST (self, G_TYPE_OBJECT, GObject), "notify::dnd", (GCallback) ___lambda4__g_object_notify, self, 0);
	_tmp0_ = sway_notification_center_self_settings;
	g_settings_bind (_tmp0_, "dnd-state", G_TYPE_CHECK_INSTANCE_CAST (self, G_TYPE_OBJECT, GObject), "dnd", G_SETTINGS_BIND_DEFAULT);
	return self;
}

SwayNotificationCenterNotiDaemon*
sway_notification_center_noti_daemon_new (void)
{
	return sway_notification_center_noti_daemon_construct (SWAY_NOTIFICATION_CENTER_TYPE_NOTI_DAEMON);
}

void
sway_notification_center_noti_daemon_request_dismiss_notification_id (SwayNotificationCenterNotiDaemon* self,
                                                                      guint32 id,
                                                                      SwayNotificationCenterClosedReasons reason,
                                                                      gboolean ignore_cc)
{
	gboolean _tmp0_ = FALSE;
	gchar* _tmp3_;
	GeeHashSet* _tmp4_;
	SwayNotificationCenterWidgetsNotifications* _tmp5_;
	SwayNotificationCenterNotificationWindow* _tmp6_;
	SwayNotificationCenterSwayncDaemon* _tmp7_;
	g_return_if_fail (SWAY_NOTIFICATION_CENTER_IS_NOTI_DAEMON (self));
	if (reason == SWAY_NOTIFICATION_CENTER_CLOSED_REASONS_EXPIRED) {
		_tmp0_ = !ignore_cc;
	} else {
		_tmp0_ = FALSE;
	}
	if (_tmp0_) {
		gchar* _tmp1_;
		SwayNotificationCenterNotificationWindow* _tmp2_;
		_tmp1_ = g_enum_to_string (SWAY_NOTIFICATION_CENTER_TYPE_CLOSED_REASONS, reason);
		g_debug ("notiDaemon.vala:35: Hiding floating notification with ID:%u, reason:%s", (guint) id, _tmp1_);
		_g_free0 (_tmp1_);
		_tmp2_ = sway_notification_center_floating_notifications;
		sway_notification_center_notification_window_remove_notification (_tmp2_, id);
		return;
	}
	_tmp3_ = g_enum_to_string (SWAY_NOTIFICATION_CENTER_TYPE_CLOSED_REASONS, reason);
	g_debug ("notiDaemon.vala:41: Dismissing notification with ID:%u, reason:%s", (guint) id, _tmp3_);
	_g_free0 (_tmp3_);
	g_signal_emit (self, sway_notification_center_noti_daemon_signals[SWAY_NOTIFICATION_CENTER_NOTI_DAEMON_NOTIFICATION_CLOSED_SIGNAL], 0, id, (guint32) reason);
	_tmp4_ = self->priv->notification_ids;
	gee_abstract_collection_remove (G_TYPE_CHECK_INSTANCE_CAST (_tmp4_, GEE_TYPE_ABSTRACT_COLLECTION, GeeAbstractCollection), (gpointer) ((guintptr) id));
	_tmp5_ = sway_notification_center_notifications_widget;
	sway_notification_center_widgets_notifications_remove_notification (_tmp5_, id);
	_tmp6_ = sway_notification_center_floating_notifications;
	sway_notification_center_notification_window_remove_notification (_tmp6_, id);
	_tmp7_ = sway_notification_center_swaync_daemon;
	sway_notification_center_swaync_daemon_emit_subscribe (_tmp7_);
}

inline void
sway_notification_center_noti_daemon_request_dismiss_notification (SwayNotificationCenterNotiDaemon* self,
                                                                   SwayNotificationCenterNotifyParams* param,
                                                                   SwayNotificationCenterClosedReasons reason)
{
	guint32 _tmp0_;
	guint32 _tmp1_;
	g_return_if_fail (SWAY_NOTIFICATION_CENTER_IS_NOTI_DAEMON (self));
	g_return_if_fail (SWAY_NOTIFICATION_CENTER_IS_NOTIFY_PARAMS (param));
	_tmp0_ = sway_notification_center_notify_params_get_applied_id (param);
	_tmp1_ = _tmp0_;
	sway_notification_center_noti_daemon_request_dismiss_notification_id (self, _tmp1_, reason, sway_notification_center_notify_params_ignore_cc (param));
}

void
sway_notification_center_noti_daemon_request_dismiss_notification_group (SwayNotificationCenterNotiDaemon* self,
                                                                         const gchar* group_name_id,
                                                                         GeeSet* ids,
                                                                         SwayNotificationCenterClosedReasons reason)
{
	gchar* _tmp0_;
	SwayNotificationCenterWidgetsNotifications* _tmp7_;
	SwayNotificationCenterSwayncDaemon* _tmp8_;
	g_return_if_fail (SWAY_NOTIFICATION_CENTER_IS_NOTI_DAEMON (self));
	g_return_if_fail (group_name_id != NULL);
	g_return_if_fail (G_TYPE_CHECK_INSTANCE_TYPE (ids, GEE_TYPE_SET));
	_tmp0_ = g_enum_to_string (SWAY_NOTIFICATION_CENTER_TYPE_CLOSED_REASONS, reason);
	g_debug ("notiDaemon.vala:60: Dismissing notification group with ID:%s, reason:%" \
"s", group_name_id, _tmp0_);
	_g_free0 (_tmp0_);
	{
		GeeIterator* _id_it = NULL;
		GeeIterator* _tmp1_;
		_tmp1_ = gee_iterable_iterator (G_TYPE_CHECK_INSTANCE_CAST (ids, GEE_TYPE_ITERABLE, GeeIterable));
		_id_it = _tmp1_;
		while (TRUE) {
			GeeIterator* _tmp2_;
			guint32 id = 0U;
			GeeIterator* _tmp3_;
			gpointer _tmp4_;
			GeeHashSet* _tmp5_;
			SwayNotificationCenterNotificationWindow* _tmp6_;
			_tmp2_ = _id_it;
			if (!gee_iterator_next (_tmp2_)) {
				break;
			}
			_tmp3_ = _id_it;
			_tmp4_ = gee_iterator_get (_tmp3_);
			id = (guint32) ((guintptr) _tmp4_);
			g_signal_emit (self, sway_notification_center_noti_daemon_signals[SWAY_NOTIFICATION_CENTER_NOTI_DAEMON_NOTIFICATION_CLOSED_SIGNAL], 0, id, (guint32) reason);
			_tmp5_ = self->priv->notification_ids;
			gee_abstract_collection_remove (G_TYPE_CHECK_INSTANCE_CAST (_tmp5_, GEE_TYPE_ABSTRACT_COLLECTION, GeeAbstractCollection), (gpointer) ((guintptr) id));
			_tmp6_ = sway_notification_center_floating_notifications;
			sway_notification_center_notification_window_remove_notification (_tmp6_, id);
		}
		_g_object_unref0 (_id_it);
	}
	_tmp7_ = sway_notification_center_notifications_widget;
	sway_notification_center_widgets_notifications_remove_group (_tmp7_, group_name_id);
	_tmp8_ = sway_notification_center_swaync_daemon;
	sway_notification_center_swaync_daemon_emit_subscribe (_tmp8_);
}

void
sway_notification_center_noti_daemon_request_dismiss_all_notifications (SwayNotificationCenterNotiDaemon* self,
                                                                        SwayNotificationCenterClosedReasons reason)
{
	gchar* _tmp0_;
	GeeHashSet* _tmp6_;
	SwayNotificationCenterWidgetsNotifications* _tmp7_;
	SwayNotificationCenterSwayncDaemon* _tmp8_;
	g_return_if_fail (SWAY_NOTIFICATION_CENTER_IS_NOTI_DAEMON (self));
	_tmp0_ = g_enum_to_string (SWAY_NOTIFICATION_CENTER_TYPE_CLOSED_REASONS, reason);
	g_debug ("notiDaemon.vala:73: Dismissing all notifications, reason:%s", _tmp0_);
	_g_free0 (_tmp0_);
	{
		GeeIterator* _id_it = NULL;
		GeeHashSet* _tmp1_;
		GeeIterator* _tmp2_;
		_tmp1_ = self->priv->notification_ids;
		_tmp2_ = gee_abstract_collection_iterator (G_TYPE_CHECK_INSTANCE_CAST (_tmp1_, GEE_TYPE_ABSTRACT_COLLECTION, GeeAbstractCollection));
		_id_it = _tmp2_;
		while (TRUE) {
			GeeIterator* _tmp3_;
			guint32 id = 0U;
			GeeIterator* _tmp4_;
			gpointer _tmp5_;
			_tmp3_ = _id_it;
			if (!gee_iterator_next (_tmp3_)) {
				break;
			}
			_tmp4_ = _id_it;
			_tmp5_ = gee_iterator_get (_tmp4_);
			id = (guint32) ((guintptr) _tmp5_);
			g_signal_emit (self, sway_notification_center_noti_daemon_signals[SWAY_NOTIFICATION_CENTER_NOTI_DAEMON_NOTIFICATION_CLOSED_SIGNAL], 0, id, (guint32) reason);
		}
		_g_object_unref0 (_id_it);
	}
	_tmp6_ = self->priv->notification_ids;
	gee_abstract_collection_clear (G_TYPE_CHECK_INSTANCE_CAST (_tmp6_, GEE_TYPE_ABSTRACT_COLLECTION, GeeAbstractCollection));
	sway_notification_center_noti_daemon_remove_all_floating_notifications (self, FALSE, NULL, NULL);
	_tmp7_ = sway_notification_center_notifications_widget;
	sway_notification_center_widgets_notifications_remove_all_notifications (_tmp7_, TRUE);
	_tmp8_ = sway_notification_center_swaync_daemon;
	sway_notification_center_swaync_daemon_emit_subscribe (_tmp8_);
}

/** Hides all floating notifications (closes transient) */
static Block5Data*
block5_data_ref (Block5Data* _data5_)
{
	g_atomic_int_inc (&_data5_->_ref_count_);
	return _data5_;
}

static void
block5_data_unref (void * _userdata_)
{
	Block5Data* _data5_;
	_data5_ = (Block5Data*) _userdata_;
	if (g_atomic_int_dec_and_test (&_data5_->_ref_count_)) {
		SwayNotificationCenterNotiDaemon* self;
		self = _data5_->self;
		_g_object_unref0 (self);
		g_slice_free (Block5Data, _data5_);
	}
}

static gboolean
__lambda45_ (Block5Data* _data5_,
             SwayNotificationCenterNotification* notification)
{
	SwayNotificationCenterNotiDaemon* self;
	gboolean _tmp0_ = FALSE;
	gboolean result;
	self = _data5_->self;
	g_return_val_if_fail (SWAY_NOTIFICATION_CENTER_IS_NOTIFICATION (notification), FALSE);
	if (_data5_->func == NULL) {
		_tmp0_ = TRUE;
	} else {
		_tmp0_ = _data5_->func (notification, _data5_->func_target);
	}
	if (_tmp0_) {
		SwayNotificationCenterNotifyParams* param = NULL;
		SwayNotificationCenterNotifyParams* _tmp1_;
		SwayNotificationCenterNotifyParams* _tmp2_;
		gboolean _tmp3_ = FALSE;
		SwayNotificationCenterNotifyParams* _tmp4_;
		guint32 _tmp5_;
		guint32 _tmp6_;
		_tmp1_ = sway_notification_center_notification_get_param (notification);
		_tmp2_ = _tmp1_;
		param = _tmp2_;
		_tmp4_ = param;
		_tmp5_ = sway_notification_center_notify_params_get_applied_id (_tmp4_);
		_tmp6_ = _tmp5_;
		if (_tmp6_ > ((guint32) 0)) {
			SwayNotificationCenterNotifyParams* _tmp7_;
			_tmp7_ = param;
			_tmp3_ = sway_notification_center_notify_params_ignore_cc (_tmp7_);
		} else {
			_tmp3_ = FALSE;
		}
		if (_tmp3_) {
			SwayNotificationCenterNotifyParams* _tmp8_;
			guint32 _tmp9_;
			guint32 _tmp10_;
			SwayNotificationCenterNotifyParams* _tmp11_;
			guint32 _tmp12_;
			guint32 _tmp13_;
			GeeHashSet* _tmp14_;
			SwayNotificationCenterNotifyParams* _tmp15_;
			guint32 _tmp16_;
			guint32 _tmp17_;
			_tmp8_ = param;
			_tmp9_ = sway_notification_center_notify_params_get_applied_id (_tmp8_);
			_tmp10_ = _tmp9_;
			g_debug ("notiDaemon.vala:94: Closing floating-only notification with ID:%u whil" \
"e hiding", (guint) _tmp10_);
			_tmp11_ = param;
			_tmp12_ = sway_notification_center_notify_params_get_applied_id (_tmp11_);
			_tmp13_ = _tmp12_;
			g_signal_emit (self, sway_notification_center_noti_daemon_signals[SWAY_NOTIFICATION_CENTER_NOTI_DAEMON_NOTIFICATION_CLOSED_SIGNAL], 0, _tmp13_, (guint32) SWAY_NOTIFICATION_CENTER_CLOSED_REASONS_DISMISSED);
			_tmp14_ = self->priv->notification_ids;
			_tmp15_ = param;
			_tmp16_ = sway_notification_center_notify_params_get_applied_id (_tmp15_);
			_tmp17_ = _tmp16_;
			gee_abstract_collection_remove (G_TYPE_CHECK_INSTANCE_CAST (_tmp14_, GEE_TYPE_ABSTRACT_COLLECTION, GeeAbstractCollection), (gpointer) ((guintptr) _tmp17_));
		}
		result = TRUE;
		return result;
	}
	result = FALSE;
	return result;
}

static gboolean
___lambda45__swaynotificationcenternotification_filter_func (SwayNotificationCenterNotification* notification,
                                                             gpointer self)
{
	gboolean result;
	result = __lambda45_ (self, notification);
	return result;
}

inline void
sway_notification_center_noti_daemon_remove_all_floating_notifications (SwayNotificationCenterNotiDaemon* self,
                                                                        gboolean transition,
                                                                        SwayNotificationCenternotification_filter_func func,
                                                                        gpointer func_target)
{
	Block5Data* _data5_;
	SwayNotificationCenterNotificationWindow* _tmp0_;
	g_return_if_fail (SWAY_NOTIFICATION_CENTER_IS_NOTI_DAEMON (self));
	_data5_ = g_slice_new0 (Block5Data);
	_data5_->_ref_count_ = 1;
	_data5_->self = g_object_ref (self);
	_data5_->func = func;
	_data5_->func_target = func_target;
	g_debug ("notiDaemon.vala:88: Hiding all floating notifications");
	_tmp0_ = sway_notification_center_floating_notifications;
	sway_notification_center_notification_window_remove_all_notifications (_tmp0_, transition, ___lambda45__swaynotificationcenternotification_filter_func, _data5_);
	block5_data_unref (_data5_);
	_data5_ = NULL;
}

/** Hides/closes latest floating notification */
void
sway_notification_center_noti_daemon_hide_latest_floating_notification (SwayNotificationCenterNotiDaemon* self,
                                                                        gboolean close)
{
	SwayNotificationCenterNotifyParams* param = NULL;
	SwayNotificationCenterNotificationWindow* _tmp0_;
	SwayNotificationCenterNotifyParams* _tmp1_;
	SwayNotificationCenterNotifyParams* _tmp2_;
	gboolean _tmp3_ = FALSE;
	g_return_if_fail (SWAY_NOTIFICATION_CENTER_IS_NOTI_DAEMON (self));
	_tmp0_ = sway_notification_center_floating_notifications;
	_tmp1_ = sway_notification_center_notification_window_get_latest_notification (_tmp0_);
	param = _tmp1_;
	_tmp2_ = param;
	if (_tmp2_ == NULL) {
		_g_object_unref0 (param);
		return;
	}
	if (close) {
		_tmp3_ = TRUE;
	} else {
		SwayNotificationCenterNotifyParams* _tmp4_;
		_tmp4_ = param;
		_tmp3_ = sway_notification_center_notify_params_ignore_cc (_tmp4_);
	}
	if (_tmp3_) {
		SwayNotificationCenterNotifyParams* _tmp5_;
		_tmp5_ = param;
		sway_notification_center_noti_daemon_request_dismiss_notification (self, _tmp5_, SWAY_NOTIFICATION_CENTER_CLOSED_REASONS_DISMISSED);
	} else {
		SwayNotificationCenterNotificationWindow* _tmp6_;
		SwayNotificationCenterNotifyParams* _tmp7_;
		guint32 _tmp8_;
		guint32 _tmp9_;
		_tmp6_ = sway_notification_center_floating_notifications;
		_tmp7_ = param;
		_tmp8_ = sway_notification_center_notify_params_get_applied_id (_tmp7_);
		_tmp9_ = _tmp8_;
		sway_notification_center_notification_window_remove_notification (_tmp6_, _tmp9_);
	}
	_g_object_unref0 (param);
}

/** Activates the `action_index` action of the latest notification */
void
sway_notification_center_noti_daemon_invoke_latest_floating_action (SwayNotificationCenterNotiDaemon* self,
                                                                    guint32 action_index)
{
	SwayNotificationCenterNotificationWindow* _tmp0_;
	g_return_if_fail (SWAY_NOTIFICATION_CENTER_IS_NOTI_DAEMON (self));
	_tmp0_ = sway_notification_center_floating_notifications;
	sway_notification_center_notification_window_latest_notification_action (_tmp0_, action_index);
}

/**
         * It returns an array of strings. Each string describes an optional
         * capability implemented by the server.
         *
         * New vendor-specific caps may be specified as long as they start with
         * "x-vendor". For instance, "x-gnome-foo-cap". Capability names must
         * not contain spaces. They are limited to alphanumeric characters
         * and dashes ("-").
         */
gchar**
sway_notification_center_noti_daemon_get_capabilities (SwayNotificationCenterNotiDaemon* self,
                                                       gint* result_length1,
                                                       GError** error)
{
	gchar* _tmp0_;
	gchar* _tmp1_;
	gchar* _tmp2_;
	gchar* _tmp3_;
	gchar* _tmp4_;
	gchar* _tmp5_;
	gchar* _tmp6_;
	gchar* _tmp7_;
	gchar* _tmp8_;
	gchar** _tmp9_;
	gchar** _tmp10_;
	gint _tmp10__length1;
	gchar** result;
	g_return_val_if_fail (SWAY_NOTIFICATION_CENTER_IS_NOTI_DAEMON (self), NULL);
	_tmp0_ = g_strdup ("actions");
	_tmp1_ = g_strdup ("body");
	_tmp2_ = g_strdup ("body-markup");
	_tmp3_ = g_strdup ("body-images");
	_tmp4_ = g_strdup ("persistence");
	_tmp5_ = g_strdup ("synchronous");
	_tmp6_ = g_strdup ("private-synchronous");
	_tmp7_ = g_strdup ("x-canonical-private-synchronous");
	_tmp8_ = g_strdup ("inline-reply");
	_tmp9_ = g_new0 (gchar*, 9 + 1);
	_tmp9_[0] = _tmp0_;
	_tmp9_[1] = _tmp1_;
	_tmp9_[2] = _tmp2_;
	_tmp9_[3] = _tmp3_;
	_tmp9_[4] = _tmp4_;
	_tmp9_[5] = _tmp5_;
	_tmp9_[6] = _tmp6_;
	_tmp9_[7] = _tmp7_;
	_tmp9_[8] = _tmp8_;
	_tmp10_ = _tmp9_;
	_tmp10__length1 = 9;
	if (result_length1) {
		*result_length1 = _tmp10__length1;
	}
	result = _tmp10_;
	return result;
}

/**
         * Sends a notification to the notification server.
         *
         * If replaces_id is 0, the return value is a UINT32 that represent
         * the notification. It is unique, and will not be reused unless a
         * MAXINT number of notifications have been generated. An acceptable
         * implementation may just use an incrementing counter for the ID.
         * The returned ID is always greater than zero. Servers must make
         * sure not to return zero as an ID.
         *
         * If replaces_id is not 0, the returned value is the same value
         * as replaces_id.
         */
static void
_vala_array_add25 (gchar** * array,
                   gint* length,
                   gint* size,
                   gchar* value)
{
	if ((*length) == (*size)) {
		*size = (*size) ? (2 * (*size)) : 4;
		*array = g_renew (gchar*, *array, (*size) + 1);
	}
	(*array)[(*length)++] = value;
	(*array)[*length] = NULL;
}

static void
_vala_array_add26 (gchar** * array,
                   gint* length,
                   gint* size,
                   gchar* value)
{
	if ((*length) == (*size)) {
		*size = (*size) ? (2 * (*size)) : 4;
		*array = g_renew (gchar*, *array, (*size) + 1);
	}
	(*array)[(*length)++] = value;
	(*array)[*length] = NULL;
}

static void
_vala_array_add27 (gchar** * array,
                   gint* length,
                   gint* size,
                   gchar* value)
{
	if ((*length) == (*size)) {
		*size = (*size) ? (2 * (*size)) : 4;
		*array = g_renew (gchar*, *array, (*size) + 1);
	}
	(*array)[(*length)++] = value;
	(*array)[*length] = NULL;
}

static gchar*
_vala_g_strjoinv (const gchar* separator,
                  gchar** str_array,
                  gint str_array_length1)
{
	gboolean _tmp0_ = FALSE;
	gchar* result;
	if (separator == NULL) {
		separator = "";
	}
	if (str_array != NULL) {
		gboolean _tmp1_ = FALSE;
		if (str_array_length1 > 0) {
			_tmp1_ = TRUE;
		} else {
			gboolean _tmp2_ = FALSE;
			if (str_array_length1 == -1) {
				const gchar* _tmp3_;
				_tmp3_ = str_array[0];
				_tmp2_ = _tmp3_ != NULL;
			} else {
				_tmp2_ = FALSE;
			}
			_tmp1_ = _tmp2_;
		}
		_tmp0_ = _tmp1_;
	} else {
		_tmp0_ = FALSE;
	}
	if (_tmp0_) {
		gint i = 0;
		gsize len = 0UL;
		gint _tmp16_;
		gint _tmp17_;
		const gchar* res = NULL;
		void* _tmp18_;
		const gchar* _tmp19_ = NULL;
		const gchar* _tmp20_;
		void* ptr = NULL;
		const gchar* _tmp22_;
		void* _tmp23_;
		const gchar* _tmp33_;
		len = (gsize) 1;
		{
			gboolean _tmp4_ = FALSE;
			i = 0;
			_tmp4_ = TRUE;
			while (TRUE) {
				gboolean _tmp6_ = FALSE;
				gboolean _tmp7_ = FALSE;
				gint _tmp10_ = 0;
				const gchar* _tmp11_;
				if (!_tmp4_) {
					gint _tmp5_;
					_tmp5_ = i;
					i = _tmp5_ + 1;
				}
				_tmp4_ = FALSE;
				if (str_array_length1 != -1) {
					_tmp7_ = i < str_array_length1;
				} else {
					_tmp7_ = FALSE;
				}
				if (_tmp7_) {
					_tmp6_ = TRUE;
				} else {
					gboolean _tmp8_ = FALSE;
					if (str_array_length1 == -1) {
						const gchar* _tmp9_;
						_tmp9_ = str_array[i];
						_tmp8_ = _tmp9_ != NULL;
					} else {
						_tmp8_ = FALSE;
					}
					_tmp6_ = _tmp8_;
				}
				if (!_tmp6_) {
					break;
				}
				_tmp11_ = str_array[i];
				if (_tmp11_ != NULL) {
					const gchar* _tmp12_;
					gint _tmp13_;
					gint _tmp14_;
					_tmp12_ = str_array[i];
					_tmp13_ = strlen ((const gchar*) _tmp12_);
					_tmp14_ = _tmp13_;
					_tmp10_ = _tmp14_;
				} else {
					_tmp10_ = 0;
				}
				len += (gsize) _tmp10_;
			}
		}
		if (i == 0) {
			gchar* _tmp15_;
			_tmp15_ = g_strdup ("");
			result = _tmp15_;
			return result;
		}
		str_array_length1 = i;
		_tmp16_ = strlen ((const gchar*) separator);
		_tmp17_ = _tmp16_;
		len += (gsize) (_tmp17_ * (i - 1));
		_tmp18_ = g_malloc (len);
		res = _tmp18_;
		_tmp20_ = str_array[0];
		if (_tmp20_ != NULL) {
			const gchar* _tmp21_;
			_tmp21_ = str_array[0];
			_tmp19_ = (const gchar*) _tmp21_;
		} else {
			_tmp19_ = "";
		}
		_tmp22_ = res;
		_tmp23_ = g_stpcpy ((void*) _tmp22_, _tmp19_);
		ptr = _tmp23_;
		{
			gboolean _tmp24_ = FALSE;
			i = 1;
			_tmp24_ = TRUE;
			while (TRUE) {
				void* _tmp26_;
				void* _tmp27_;
				const gchar* _tmp28_ = NULL;
				const gchar* _tmp29_;
				void* _tmp31_;
				void* _tmp32_;
				if (!_tmp24_) {
					gint _tmp25_;
					_tmp25_ = i;
					i = _tmp25_ + 1;
				}
				_tmp24_ = FALSE;
				if (!(i < str_array_length1)) {
					break;
				}
				_tmp26_ = ptr;
				_tmp27_ = g_stpcpy (_tmp26_, (const gchar*) separator);
				ptr = _tmp27_;
				_tmp29_ = str_array[i];
				if (_tmp29_ != NULL) {
					const gchar* _tmp30_;
					_tmp30_ = str_array[i];
					_tmp28_ = (const gchar*) _tmp30_;
				} else {
					_tmp28_ = "";
				}
				_tmp31_ = ptr;
				_tmp32_ = g_stpcpy (_tmp31_, _tmp28_);
				ptr = _tmp32_;
			}
		}
		_tmp33_ = res;
		res = NULL;
		result = (gchar*) _tmp33_;
		return result;
	} else {
		gchar* _tmp34_;
		_tmp34_ = g_strdup ("");
		result = _tmp34_;
		return result;
	}
}

static gpointer
_sway_notification_center_ordered_hash_table_ref0 (gpointer self)
{
	return self ? sway_notification_center_ordered_hash_table_ref (self) : NULL;
}

guint32
sway_notification_center_noti_daemon_new_notification (SwayNotificationCenterNotiDaemon* self,
                                                       const gchar* app_name,
                                                       guint32 replaces_id,
                                                       const gchar* app_icon,
                                                       const gchar* summary,
                                                       const gchar* body,
                                                       gchar** actions,
                                                       gint actions_length1,
                                                       GHashTable* hints,
                                                       gint expire_timeout,
                                                       GError** error)
{
	guint32 id = 0U;
	gboolean _tmp0_ = FALSE;
	SwayNotificationCenterNotifyParams* param = NULL;
	SwayNotificationCenterNotifyParams* _tmp2_;
	SwayNotificationCenterNotifyParams* _tmp3_;
	guint32 _tmp4_;
	guint32 _tmp5_;
	SwayNotificationCenterNotifyParams* _tmp6_;
	SwayNotificationCenterNotificationStatusEnum _tmp7_;
	SwayNotificationCenterNotificationStatusEnum _tmp8_;
	gchar* _tmp9_;
	gchar* _tmp10_;
	SwayNotificationCenterNotifyParams* _tmp11_;
	gchar* _tmp12_;
	gchar* _tmp13_;
	guint32 notification_id_to_replace = 0U;
	gchar** hide_floating_notification_reasons = NULL;
	gchar** _tmp34_;
	gint hide_floating_notification_reasons_length1;
	gint _hide_floating_notification_reasons_size_;
	gboolean _tmp35_ = FALSE;
	SwayNotificationCenterNotifyParams* _tmp36_;
	SwayNotificationCenterNotificationStatusEnum _tmp37_;
	SwayNotificationCenterNotificationStatusEnum _tmp38_;
	SwayNotificationCenterControlCenter* _tmp43_;
	gboolean _tmp45_ = FALSE;
	SwayNotificationCenterNotifyParams* _tmp46_;
	SwayNotificationCenterUrgencyLevels _tmp47_;
	SwayNotificationCenterUrgencyLevels _tmp48_;
	gboolean bypass_dnd = FALSE;
	gboolean _tmp52_ = FALSE;
	gboolean added = FALSE;
	gboolean removed = FALSE;
	gchar** _tmp59_;
	gint _tmp59__length1;
	SwayNotificationCenterNotifyParams* _tmp77_;
	gboolean _tmp92_ = FALSE;
	SwayNotificationCenterNotifyParams* _tmp96_;
	gboolean _tmp97_;
	gboolean _tmp98_;
	SwayNotificationCenterOrderedHashTable* scripts = NULL;
	SwayNotificationCenterConfigModel* _tmp99_;
	SwayNotificationCenterConfigModel* _tmp100_;
	SwayNotificationCenterOrderedHashTable* _tmp101_;
	SwayNotificationCenterOrderedHashTable* _tmp102_;
	SwayNotificationCenterOrderedHashTable* _tmp103_;
	SwayNotificationCenterOrderedHashTable* _tmp104_;
	guint _tmp105_;
	guint _tmp106_;
	SwayNotificationCenterNotifyParams* _tmp107_;
	guint32 result;
	g_return_val_if_fail (SWAY_NOTIFICATION_CENTER_IS_NOTI_DAEMON (self), 0U);
	g_return_val_if_fail (app_name != NULL, 0U);
	g_return_val_if_fail (app_icon != NULL, 0U);
	g_return_val_if_fail (summary != NULL, 0U);
	g_return_val_if_fail (body != NULL, 0U);
	g_return_val_if_fail (hints != NULL, 0U);
	id = replaces_id;
	if (replaces_id == ((guint32) 0)) {
		_tmp0_ = TRUE;
	} else {
		_tmp0_ = replaces_id > self->priv->noti_id;
	}
	if (_tmp0_) {
		guint32 _tmp1_;
		self->priv->noti_id = self->priv->noti_id + 1;
		_tmp1_ = self->priv->noti_id;
		id = _tmp1_;
	}
	id = MAX (id, (guint32) 1);
	_tmp2_ = sway_notification_center_notify_params_new (id, app_name, replaces_id, app_icon, summary, body, actions, actions_length1, hints, expire_timeout);
	if (_tmp2_) {
		g_object_set_data ((GObject *) _tmp2_, "vala-creation-function", "SwayNotificationCenter.NotiDaemon.new_notification");
	}
	param = _tmp2_;
	_tmp3_ = param;
	_tmp4_ = sway_notification_center_notify_params_get_applied_id (_tmp3_);
	_tmp5_ = _tmp4_;
	_tmp6_ = param;
	_tmp7_ = sway_notification_center_notify_params_get_status_state (_tmp6_);
	_tmp8_ = _tmp7_;
	_tmp9_ = sway_notification_center_notification_status_enum_to_string (_tmp8_);
	_tmp10_ = _tmp9_;
	_tmp11_ = param;
	_tmp12_ = sway_notification_center_notify_params_to_string (_tmp11_);
	_tmp13_ = _tmp12_;
	g_debug ("notiDaemon.vala:193: Notification (ID:%u, state: %s): %s\n", (guint) _tmp5_, _tmp10_, _tmp13_);
	_g_free0 (_tmp13_);
	_g_free0 (_tmp10_);
	notification_id_to_replace = (guint32) 0;
	if (id == replaces_id) {
		notification_id_to_replace = replaces_id;
	} else {
		gboolean _tmp14_ = FALSE;
		SwayNotificationCenterNotifyParams* _tmp15_;
		const gchar* _tmp16_;
		const gchar* _tmp17_;
		_tmp15_ = param;
		_tmp16_ = sway_notification_center_notify_params_get_synchronous (_tmp15_);
		_tmp17_ = _tmp16_;
		if (_tmp17_ != NULL) {
			SwayNotificationCenterNotifyParams* _tmp18_;
			const gchar* _tmp19_;
			const gchar* _tmp20_;
			gint _tmp21_;
			gint _tmp22_;
			_tmp18_ = param;
			_tmp19_ = sway_notification_center_notify_params_get_synchronous (_tmp18_);
			_tmp20_ = _tmp19_;
			_tmp21_ = strlen (_tmp20_);
			_tmp22_ = _tmp21_;
			_tmp14_ = _tmp22_ > 0;
		} else {
			_tmp14_ = FALSE;
		}
		if (_tmp14_) {
			guint32 r_id = 0U;
			GHashTable* _tmp23_;
			SwayNotificationCenterNotifyParams* _tmp24_;
			const gchar* _tmp25_;
			const gchar* _tmp26_;
			gconstpointer _tmp27_ = NULL;
			gboolean _tmp28_;
			GHashTable* _tmp29_;
			SwayNotificationCenterNotifyParams* _tmp30_;
			const gchar* _tmp31_;
			const gchar* _tmp32_;
			gchar* _tmp33_;
			_tmp23_ = self->priv->synchronous_ids;
			_tmp24_ = param;
			_tmp25_ = sway_notification_center_notify_params_get_synchronous (_tmp24_);
			_tmp26_ = _tmp25_;
			_tmp28_ = g_hash_table_lookup_extended (_tmp23_, _tmp26_, NULL, &_tmp27_);
			r_id = (guint32) ((guintptr) _tmp27_);
			if (_tmp28_) {
				notification_id_to_replace = r_id;
			}
			_tmp29_ = self->priv->synchronous_ids;
			_tmp30_ = param;
			_tmp31_ = sway_notification_center_notify_params_get_synchronous (_tmp30_);
			_tmp32_ = _tmp31_;
			_tmp33_ = g_strdup (_tmp32_);
			g_hash_table_insert (_tmp29_, _tmp33_, (gpointer) ((guintptr) id));
		}
	}
	_tmp34_ = g_new0 (gchar*, 0 + 1);
	hide_floating_notification_reasons = _tmp34_;
	hide_floating_notification_reasons_length1 = 0;
	_hide_floating_notification_reasons_size_ = hide_floating_notification_reasons_length1;
	_tmp36_ = param;
	_tmp37_ = sway_notification_center_notify_params_get_status_state (_tmp36_);
	_tmp38_ = _tmp37_;
	if (_tmp38_ != SWAY_NOTIFICATION_CENTER_NOTIFICATION_STATUS_ENUM_ENABLED) {
		SwayNotificationCenterNotifyParams* _tmp39_;
		SwayNotificationCenterNotificationStatusEnum _tmp40_;
		SwayNotificationCenterNotificationStatusEnum _tmp41_;
		_tmp39_ = param;
		_tmp40_ = sway_notification_center_notify_params_get_status_state (_tmp39_);
		_tmp41_ = _tmp40_;
		_tmp35_ = _tmp41_ != SWAY_NOTIFICATION_CENTER_NOTIFICATION_STATUS_ENUM_TRANSIENT;
	} else {
		_tmp35_ = FALSE;
	}
	if (_tmp35_) {
		gchar* _tmp42_;
		_tmp42_ = g_strdup ("Notification status is not Enabled or Transient in Config");
		_vala_array_add25 (&hide_floating_notification_reasons, &hide_floating_notification_reasons_length1, &_hide_floating_notification_reasons_size_, _tmp42_);
	}
	_tmp43_ = sway_notification_center_control_center;
	if (sway_notification_center_control_center_get_visibility (_tmp43_)) {
		gchar* _tmp44_;
		_tmp44_ = g_strdup ("Control Center is visible");
		_vala_array_add26 (&hide_floating_notification_reasons, &hide_floating_notification_reasons_length1, &_hide_floating_notification_reasons_size_, _tmp44_);
	}
	_tmp46_ = param;
	_tmp47_ = sway_notification_center_notify_params_get_urgency (_tmp46_);
	_tmp48_ = _tmp47_;
	if (_tmp48_ == SWAY_NOTIFICATION_CENTER_URGENCY_LEVELS_CRITICAL) {
		_tmp45_ = TRUE;
	} else {
		SwayNotificationCenterNotifyParams* _tmp49_;
		gboolean _tmp50_;
		gboolean _tmp51_;
		_tmp49_ = param;
		_tmp50_ = sway_notification_center_notify_params_get_swaync_bypass_dnd (_tmp49_);
		_tmp51_ = _tmp50_;
		_tmp45_ = _tmp51_;
	}
	bypass_dnd = _tmp45_;
	if (!bypass_dnd) {
		gboolean _tmp53_ = FALSE;
		gboolean _tmp54_;
		_tmp54_ = self->priv->_dnd;
		if (_tmp54_) {
			_tmp53_ = TRUE;
		} else {
			SwayNotificationCenterSwayncDaemon* _tmp55_;
			gboolean _tmp56_;
			gboolean _tmp57_;
			_tmp55_ = sway_notification_center_swaync_daemon;
			_tmp56_ = sway_notification_center_swaync_daemon_get_inhibited (_tmp55_);
			_tmp57_ = _tmp56_;
			_tmp53_ = _tmp57_;
		}
		_tmp52_ = _tmp53_;
	} else {
		_tmp52_ = FALSE;
	}
	if (_tmp52_) {
		gchar* _tmp58_;
		_tmp58_ = g_strdup ("Do Not Disturb is enabled or an Inhibitor is running");
		_vala_array_add27 (&hide_floating_notification_reasons, &hide_floating_notification_reasons_length1, &_hide_floating_notification_reasons_size_, _tmp58_);
	}
	added = FALSE;
	removed = FALSE;
	_tmp59_ = hide_floating_notification_reasons;
	_tmp59__length1 = hide_floating_notification_reasons_length1;
	if (_tmp59__length1 == 0) {
		added = TRUE;
		if (notification_id_to_replace > ((guint32) 0)) {
			SwayNotificationCenterNotifyParams* _tmp60_;
			guint32 _tmp61_;
			guint32 _tmp62_;
			SwayNotificationCenterNotificationWindow* _tmp63_;
			SwayNotificationCenterNotifyParams* _tmp64_;
			_tmp60_ = param;
			_tmp61_ = sway_notification_center_notify_params_get_applied_id (_tmp60_);
			_tmp62_ = _tmp61_;
			g_debug ("notiDaemon.vala:236: Replacing Notification: ID:%u -> ID:%u\n", (guint) notification_id_to_replace, (guint) _tmp62_);
			_tmp63_ = sway_notification_center_floating_notifications;
			_tmp64_ = param;
			sway_notification_center_notification_window_replace_notification (_tmp63_, notification_id_to_replace, _tmp64_);
		} else {
			SwayNotificationCenterNotifyParams* _tmp65_;
			guint32 _tmp66_;
			guint32 _tmp67_;
			SwayNotificationCenterNotificationWindow* _tmp68_;
			SwayNotificationCenterNotifyParams* _tmp69_;
			_tmp65_ = param;
			_tmp66_ = sway_notification_center_notify_params_get_applied_id (_tmp65_);
			_tmp67_ = _tmp66_;
			g_debug ("notiDaemon.vala:240: Adding Floating Notification: ID:%u\n", (guint) _tmp67_);
			_tmp68_ = sway_notification_center_floating_notifications;
			_tmp69_ = param;
			sway_notification_center_notification_window_add_notification (_tmp68_, _tmp69_);
		}
	} else {
		SwayNotificationCenterNotifyParams* _tmp70_;
		guint32 _tmp71_;
		guint32 _tmp72_;
		gchar** _tmp73_;
		gint _tmp73__length1;
		gchar* _tmp74_;
		gchar* _tmp75_;
		_tmp70_ = param;
		_tmp71_ = sway_notification_center_notify_params_get_applied_id (_tmp70_);
		_tmp72_ = _tmp71_;
		_tmp73_ = hide_floating_notification_reasons;
		_tmp73__length1 = hide_floating_notification_reasons_length1;
		_tmp74_ = _vala_g_strjoinv ("\", \"", _tmp73_, (gint) _tmp73__length1);
		_tmp75_ = _tmp74_;
		g_debug ("notiDaemon.vala:244: Not displaying floating Notification: ID:%u, Reas" \
"ons: {\"%s\"}\n", (guint) _tmp72_, _tmp75_);
		_g_free0 (_tmp75_);
		if (notification_id_to_replace > ((guint32) 0)) {
			SwayNotificationCenterNotificationWindow* _tmp76_;
			removed = TRUE;
			g_debug ("notiDaemon.vala:252: Removing replaced Floating Notification: ID:%u\n", (guint) notification_id_to_replace);
			_tmp76_ = sway_notification_center_floating_notifications;
			sway_notification_center_notification_window_remove_notification (_tmp76_, notification_id_to_replace);
		}
	}
	_tmp77_ = param;
	if (!sway_notification_center_notify_params_ignore_cc (_tmp77_)) {
		added = TRUE;
		if (notification_id_to_replace > ((guint32) 0)) {
			SwayNotificationCenterNotifyParams* _tmp78_;
			guint32 _tmp79_;
			guint32 _tmp80_;
			SwayNotificationCenterWidgetsNotifications* _tmp81_;
			SwayNotificationCenterNotifyParams* _tmp82_;
			_tmp78_ = param;
			_tmp79_ = sway_notification_center_notify_params_get_applied_id (_tmp78_);
			_tmp80_ = _tmp79_;
			g_debug ("notiDaemon.vala:261: Replacing CC Notification: ID:%u -> ID:%u\n", (guint) notification_id_to_replace, (guint) _tmp80_);
			_tmp81_ = sway_notification_center_notifications_widget;
			_tmp82_ = param;
			sway_notification_center_widgets_notifications_replace_notification (_tmp81_, notification_id_to_replace, _tmp82_);
		} else {
			SwayNotificationCenterNotifyParams* _tmp83_;
			guint32 _tmp84_;
			guint32 _tmp85_;
			SwayNotificationCenterWidgetsNotifications* _tmp86_;
			SwayNotificationCenterNotifyParams* _tmp87_;
			_tmp83_ = param;
			_tmp84_ = sway_notification_center_notify_params_get_applied_id (_tmp83_);
			_tmp85_ = _tmp84_;
			g_debug ("notiDaemon.vala:265: Adding Control Center Notification: ID:%u\n", (guint) _tmp85_);
			_tmp86_ = sway_notification_center_notifications_widget;
			_tmp87_ = param;
			sway_notification_center_widgets_notifications_add_notification (_tmp86_, _tmp87_);
		}
	} else {
		SwayNotificationCenterNotifyParams* _tmp88_;
		guint32 _tmp89_;
		guint32 _tmp90_;
		_tmp88_ = param;
		_tmp89_ = sway_notification_center_notify_params_get_applied_id (_tmp88_);
		_tmp90_ = _tmp89_;
		g_debug ("notiDaemon.vala:269: Not Placing Notification in CC: ID:%u\n", (guint) _tmp90_);
		if (notification_id_to_replace > ((guint32) 0)) {
			SwayNotificationCenterWidgetsNotifications* _tmp91_;
			removed = TRUE;
			g_debug ("notiDaemon.vala:274: Removing replaced CC Notification: ID:%u\n", (guint) notification_id_to_replace);
			_tmp91_ = sway_notification_center_notifications_widget;
			sway_notification_center_widgets_notifications_remove_notification (_tmp91_, notification_id_to_replace);
		}
	}
	if (added) {
		_tmp92_ = TRUE;
	} else {
		_tmp92_ = removed;
	}
	if (_tmp92_) {
		SwayNotificationCenterSwayncDaemon* _tmp95_;
		if (notification_id_to_replace > ((guint32) 0)) {
			GeeHashSet* _tmp93_;
			_tmp93_ = self->priv->notification_ids;
			gee_abstract_collection_remove (G_TYPE_CHECK_INSTANCE_CAST (_tmp93_, GEE_TYPE_ABSTRACT_COLLECTION, GeeAbstractCollection), (gpointer) ((guintptr) notification_id_to_replace));
		}
		if (added) {
			GeeHashSet* _tmp94_;
			_tmp94_ = self->priv->notification_ids;
			gee_abstract_collection_add (G_TYPE_CHECK_INSTANCE_CAST (_tmp94_, GEE_TYPE_ABSTRACT_COLLECTION, GeeAbstractCollection), (gpointer) ((guintptr) id));
		}
		_tmp95_ = sway_notification_center_swaync_daemon;
		sway_notification_center_swaync_daemon_emit_subscribe (_tmp95_);
	}
	_tmp96_ = param;
	_tmp97_ = sway_notification_center_notify_params_get_swaync_no_script (_tmp96_);
	_tmp98_ = _tmp97_;
	if (_tmp98_) {
		g_debug ("notiDaemon.vala:294: Skipped scripts for this notification\n");
		result = id;
		hide_floating_notification_reasons = (_vala_array_free (hide_floating_notification_reasons, hide_floating_notification_reasons_length1, (GDestroyNotify) g_free), NULL);
		_g_object_unref0 (param);
		return result;
	}
	_tmp99_ = sway_notification_center_config_model_get_instance ();
	_tmp100_ = _tmp99_;
	_tmp101_ = sway_notification_center_config_model_get_scripts (_tmp100_);
	_tmp102_ = _tmp101_;
	_tmp103_ = _sway_notification_center_ordered_hash_table_ref0 (_tmp102_);
	scripts = _tmp103_;
	_tmp104_ = scripts;
	_tmp105_ = sway_notification_center_ordered_hash_table_get_length (_tmp104_);
	_tmp106_ = _tmp105_;
	if (_tmp106_ == ((guint) 0)) {
		result = id;
		_sway_notification_center_ordered_hash_table_unref0 (scripts);
		hide_floating_notification_reasons = (_vala_array_free (hide_floating_notification_reasons, hide_floating_notification_reasons_length1, (GDestroyNotify) g_free), NULL);
		_g_object_unref0 (param);
		return result;
	}
	_tmp107_ = param;
	sway_notification_center_noti_daemon_run_scripts (self, _tmp107_, SWAY_NOTIFICATION_CENTER_SCRIPT_RUN_ON_TYPE_RECEIVE);
	g_debug ("notiDaemon.vala:304: \n");
	result = id;
	_sway_notification_center_ordered_hash_table_unref0 (scripts);
	hide_floating_notification_reasons = (_vala_array_free (hide_floating_notification_reasons, hide_floating_notification_reasons_length1, (GDestroyNotify) g_free), NULL);
	_g_object_unref0 (param);
	return result;
}

/**
         * Runs scripts that meet the requirements of the given `param`.
         */
static Block6Data*
block6_data_ref (Block6Data* _data6_)
{
	g_atomic_int_inc (&_data6_->_ref_count_);
	return _data6_;
}

static void
block6_data_unref (void * _userdata_)
{
	Block6Data* _data6_;
	_data6_ = (Block6Data*) _userdata_;
	if (g_atomic_int_dec_and_test (&_data6_->_ref_count_)) {
		SwayNotificationCenterNotiDaemon* self;
		self = _data6_->self;
		_g_free0 (_data6_->key);
		_g_object_unref0 (self);
		g_slice_free (Block6Data, _data6_);
	}
}

static void
_g_variant_unref0_ (gpointer var)
{
	(var == NULL) ? NULL : (var = (g_variant_unref (var), NULL));
}

static GVariant*
_variant_new1 (gboolean value)
{
	return g_variant_ref_sink (g_variant_new_boolean (value));
}

static GVariant*
_variant_new2 (guint8 value)
{
	return g_variant_ref_sink (g_variant_new_byte (value));
}

static void
____lambda37_ (Block6Data* _data6_,
               GObject* obj,
               GAsyncResult* res)
{
	SwayNotificationCenterNotiDaemon* self;
	gchar* error_msg = NULL;
	SwayNotificationCenterScript* _tmp0_;
	gchar* _tmp1_ = NULL;
	gboolean _tmp2_;
	SwayNotificationCenterConfigModel* _tmp3_;
	SwayNotificationCenterConfigModel* _tmp4_;
	gboolean _tmp5_;
	gboolean _tmp6_;
	GError* _inner_error0_ = NULL;
	self = _data6_->self;
	g_return_if_fail ((obj == NULL) || G_TYPE_CHECK_INSTANCE_TYPE (obj, G_TYPE_OBJECT));
	g_return_if_fail (G_TYPE_CHECK_INSTANCE_TYPE (res, g_async_result_get_type ()));
	_tmp0_ = _data6_->script;
	_tmp2_ = sway_notification_center_script_run_script_finish (_tmp0_, res, &_tmp1_);
	_g_free0 (error_msg);
	error_msg = _tmp1_;
	if (_tmp2_) {
		_g_free0 (error_msg);
		return;
	}
	_tmp3_ = sway_notification_center_config_model_get_instance ();
	_tmp4_ = _tmp3_;
	_tmp5_ = sway_notification_center_config_model_get_script_fail_notify (_tmp4_);
	_tmp6_ = _tmp5_;
	if (!_tmp6_) {
		FILE* _tmp7_;
		const gchar* _tmp8_;
		SwayNotificationCenterScript* _tmp9_;
		const gchar* _tmp10_;
		const gchar* _tmp11_;
		_tmp7_ = stderr;
		_tmp8_ = _data6_->key;
		_tmp9_ = _data6_->script;
		_tmp10_ = sway_notification_center_script_get_exec (_tmp9_);
		_tmp11_ = _tmp10_;
		fprintf (_tmp7_, "Failed to run script: \"%s\" with exec: \"%s\"\n", _tmp8_, _tmp11_);
	} else {
		{
			GHashTable* _hints = NULL;
			GHashFunc _tmp12_;
			GEqualFunc _tmp13_;
			GHashTable* _tmp14_;
			GHashTable* _tmp15_;
			gchar* _tmp16_;
			GVariant* _tmp17_;
			GHashTable* _tmp18_;
			gchar* _tmp19_;
			GVariant* _tmp20_;
			gchar* _summary = NULL;
			const gchar* _tmp21_;
			gchar* _tmp22_;
			gchar* _body = NULL;
			const gchar* _tmp23_;
			gchar* _tmp24_;
			const gchar* _tmp25_;
			const gchar* _tmp26_;
			gchar** _tmp27_;
			gchar** _tmp28_;
			gint _tmp28__length1;
			GHashTable* _tmp29_;
			_tmp12_ = g_str_hash;
			_tmp13_ = g_str_equal;
			_tmp14_ = g_hash_table_new_full (_tmp12_, _tmp13_, _g_free0_, _g_variant_unref0_);
			_hints = _tmp14_;
			_tmp15_ = _hints;
			_tmp16_ = g_strdup ("SWAYNC_NO_SCRIPT");
			_tmp17_ = _variant_new1 (TRUE);
			g_hash_table_insert (_tmp15_, _tmp16_, _tmp17_);
			_tmp18_ = _hints;
			_tmp19_ = g_strdup ("urgency");
			_tmp20_ = _variant_new2 (sway_notification_center_urgency_levels_to_byte (SWAY_NOTIFICATION_CENTER_URGENCY_LEVELS_CRITICAL));
			g_hash_table_insert (_tmp18_, _tmp19_, _tmp20_);
			_tmp21_ = _data6_->key;
			_tmp22_ = g_strdup_printf ("Failed to run script: %s", _tmp21_);
			_summary = _tmp22_;
			_tmp23_ = error_msg;
			_tmp24_ = g_strconcat ("<b>Output:</b> ", _tmp23_, NULL);
			_body = _tmp24_;
			_tmp25_ = _summary;
			_tmp26_ = _body;
			_tmp27_ = g_new0 (gchar*, 0 + 1);
			_tmp28_ = _tmp27_;
			_tmp28__length1 = 0;
			_tmp29_ = _hints;
			sway_notification_center_noti_daemon_new_notification (self, "SwayNotificationCenter", (guint32) 0, "dialog-error", _tmp25_, _tmp26_, _tmp28_, (gint) 0, _tmp29_, -1, &_inner_error0_);
			_tmp28_ = (_vala_array_free (_tmp28_, _tmp28__length1, (GDestroyNotify) g_free), NULL);
			if (G_UNLIKELY (_inner_error0_ != NULL)) {
				_g_free0 (_body);
				_g_free0 (_summary);
				_g_hash_table_unref0 (_hints);
				goto __catch0_g_error;
			}
			_g_free0 (_body);
			_g_free0 (_summary);
			_g_hash_table_unref0 (_hints);
		}
		goto __finally0;
		__catch0_g_error:
		{
			GError* e = NULL;
			FILE* _tmp30_;
			GError* _tmp31_;
			const gchar* _tmp32_;
			e = _inner_error0_;
			_inner_error0_ = NULL;
			_tmp30_ = stderr;
			_tmp31_ = e;
			_tmp32_ = _tmp31_->message;
			fprintf (_tmp30_, "NOTIFING SCRIPT-FAIL ERROR: %s\n", _tmp32_);
			_g_error_free0 (e);
		}
		__finally0:
		if (G_UNLIKELY (_inner_error0_ != NULL)) {
			_g_free0 (error_msg);
			g_critical ("file %s: line %d: uncaught error: %s (%s, %d)", __FILE__, __LINE__, _inner_error0_->message, g_quark_to_string (_inner_error0_->domain), _inner_error0_->code);
			g_clear_error (&_inner_error0_);
			return;
		}
	}
	_g_free0 (error_msg);
}

static void
_____lambda37__gasync_ready_callback (GObject* source_object,
                                      GAsyncResult* res,
                                      gpointer self)
{
	____lambda37_ (self, source_object, res);
	block6_data_unref (self);
}

void
sway_notification_center_noti_daemon_run_scripts (SwayNotificationCenterNotiDaemon* self,
                                                  SwayNotificationCenterNotifyParams* param,
                                                  SwayNotificationCenterScriptRunOnType run_on)
{
	gboolean _tmp0_;
	gboolean _tmp1_;
	SwayNotificationCenterOrderedHashTable* scripts = NULL;
	SwayNotificationCenterConfigModel* _tmp2_;
	SwayNotificationCenterConfigModel* _tmp3_;
	SwayNotificationCenterOrderedHashTable* _tmp4_;
	SwayNotificationCenterOrderedHashTable* _tmp5_;
	SwayNotificationCenterOrderedHashTable* _tmp6_;
	SwayNotificationCenterOrderedHashTable* _tmp7_;
	guint _tmp8_;
	guint _tmp9_;
	SwayNotificationCenterOrderedHashTable* _tmp10_;
	GList* _tmp11_;
	g_return_if_fail (SWAY_NOTIFICATION_CENTER_IS_NOTI_DAEMON (self));
	g_return_if_fail (SWAY_NOTIFICATION_CENTER_IS_NOTIFY_PARAMS (param));
	_tmp0_ = sway_notification_center_notify_params_get_swaync_no_script (param);
	_tmp1_ = _tmp0_;
	if (_tmp1_) {
		g_debug ("notiDaemon.vala:314: Skipped action scripts for this notification\n");
		return;
	}
	_tmp2_ = sway_notification_center_config_model_get_instance ();
	_tmp3_ = _tmp2_;
	_tmp4_ = sway_notification_center_config_model_get_scripts (_tmp3_);
	_tmp5_ = _tmp4_;
	_tmp6_ = _sway_notification_center_ordered_hash_table_ref0 (_tmp5_);
	scripts = _tmp6_;
	_tmp7_ = scripts;
	_tmp8_ = sway_notification_center_ordered_hash_table_get_length (_tmp7_);
	_tmp9_ = _tmp8_;
	if (_tmp9_ == ((guint) 0)) {
		_sway_notification_center_ordered_hash_table_unref0 (scripts);
		return;
	}
	_tmp10_ = scripts;
	_tmp11_ = sway_notification_center_ordered_hash_table_get_keys (_tmp10_);
	{
		GList* key_collection = NULL;
		GList* key_it = NULL;
		key_collection = _tmp11_;
		for (key_it = key_collection; key_it != NULL; key_it = key_it->next) {
			gchar* _tmp12_;
			gchar* key = NULL;
			_tmp12_ = g_strdup ((const gchar*) key_it->data);
			key = _tmp12_;
			{
				Block6Data* _data6_;
				SwayNotificationCenterOrderedHashTable* _tmp13_;
				const gchar* _tmp14_;
				gconstpointer _tmp15_;
				SwayNotificationCenterScript* _tmp16_;
				SwayNotificationCenterScript* _tmp17_;
				SwayNotificationCenterScriptRunOnType _tmp18_;
				SwayNotificationCenterScriptRunOnType _tmp19_;
				SwayNotificationCenterScript* _tmp20_;
				_data6_ = g_slice_new0 (Block6Data);
				_data6_->_ref_count_ = 1;
				_data6_->self = g_object_ref (self);
				_data6_->key = key;
				_tmp13_ = scripts;
				_tmp14_ = _data6_->key;
				_tmp15_ = sway_notification_center_ordered_hash_table_get (_tmp13_, _tmp14_);
				_data6_->script = (SwayNotificationCenterScript*) _tmp15_;
				_tmp16_ = _data6_->script;
				if (!sway_notification_center_notification_matching_matches_notification (G_TYPE_CHECK_INSTANCE_CAST (_tmp16_, SWAY_NOTIFICATION_CENTER_TYPE_NOTIFICATION_MATCHING, SwayNotificationCenterNotificationMatching), param)) {
					block6_data_unref (_data6_);
					_data6_ = NULL;
					continue;
				}
				_tmp17_ = _data6_->script;
				_tmp18_ = sway_notification_center_script_get_run_on (_tmp17_);
				_tmp19_ = _tmp18_;
				if (_tmp19_ != run_on) {
					block6_data_unref (_data6_);
					_data6_ = NULL;
					continue;
				}
				_tmp20_ = _data6_->script;
				sway_notification_center_script_run_script (_tmp20_, param, _____lambda37__gasync_ready_callback, block6_data_ref (_data6_));
				block6_data_unref (_data6_);
				_data6_ = NULL;
				break;
			}
		}
		(key_collection == NULL) ? NULL : (key_collection = (g_list_free (key_collection), NULL));
	}
	_sway_notification_center_ordered_hash_table_unref0 (scripts);
}

/**
         * Causes a notification to be forcefully closed and removed from the
         * user's view. It can be used, for example, in the event that what
         * the notification pertains to is no longer relevant, or to cancel a
         * notification with no expiration time.
         *
         * The NotificationClosed signal is emitted by this method.
         *
         * If the notification no longer exists, an empty D-BUS Error message
         * is sent back.
         */
void
sway_notification_center_noti_daemon_close_notification (SwayNotificationCenterNotiDaemon* self,
                                                         guint32 id,
                                                         GError** error)
{
	g_return_if_fail (SWAY_NOTIFICATION_CENTER_IS_NOTI_DAEMON (self));
	sway_notification_center_noti_daemon_request_dismiss_notification_id (self, id, SWAY_NOTIFICATION_CENTER_CLOSED_REASONS_CLOSED_BY_CLOSENOTIFICATION, FALSE);
}

/**
         * This message returns the information on the server. Specifically, the
         * server name, vendor, and version number.
         */
void
sway_notification_center_noti_daemon_get_server_information (SwayNotificationCenterNotiDaemon* self,
                                                             gchar** name,
                                                             gchar** vendor,
                                                             gchar** version,
                                                             gchar** spec_version,
                                                             GError** error)
{
	gchar* _vala_name = NULL;
	gchar* _vala_vendor = NULL;
	gchar* _vala_version = NULL;
	gchar* _vala_spec_version = NULL;
	gchar* _tmp0_;
	gchar* _tmp1_;
	gchar* _tmp2_;
	gchar* _tmp3_;
	g_return_if_fail (SWAY_NOTIFICATION_CENTER_IS_NOTI_DAEMON (self));
	_tmp0_ = g_strdup ("SwayNotificationCenter");
	_g_free0 (_vala_name);
	_vala_name = _tmp0_;
	_tmp1_ = g_strdup ("ErikReider");
	_g_free0 (_vala_vendor);
	_vala_vendor = _tmp1_;
	_tmp2_ = g_strdup (CONSTANTS_VERSIONNUM);
	_g_free0 (_vala_version);
	_vala_version = _tmp2_;
	_tmp3_ = g_strdup ("1.3");
	_g_free0 (_vala_spec_version);
	_vala_spec_version = _tmp3_;
	if (name) {
		*name = _vala_name;
	} else {
		_g_free0 (_vala_name);
	}
	if (vendor) {
		*vendor = _vala_vendor;
	} else {
		_g_free0 (_vala_vendor);
	}
	if (version) {
		*version = _vala_version;
	} else {
		_g_free0 (_vala_version);
	}
	if (spec_version) {
		*spec_version = _vala_spec_version;
	} else {
		_g_free0 (_vala_spec_version);
	}
}

gboolean
sway_notification_center_noti_daemon_get_dnd (SwayNotificationCenterNotiDaemon* self)
{
	gboolean result;
	g_return_val_if_fail (SWAY_NOTIFICATION_CENTER_IS_NOTI_DAEMON (self), FALSE);
	result = self->priv->_dnd;
	return result;
}

void
sway_notification_center_noti_daemon_set_dnd (SwayNotificationCenterNotiDaemon* self,
                                              gboolean value)
{
	gboolean old_value;
	g_return_if_fail (SWAY_NOTIFICATION_CENTER_IS_NOTI_DAEMON (self));
	old_value = sway_notification_center_noti_daemon_get_dnd (self);
	if (old_value != value) {
		self->priv->_dnd = value;
		g_object_notify_by_pspec ((GObject *) self, sway_notification_center_noti_daemon_properties[SWAY_NOTIFICATION_CENTER_NOTI_DAEMON_DND_PROPERTY]);
	}
}

guint
sway_notification_center_noti_daemon_get_n_notifications (SwayNotificationCenterNotiDaemon* self)
{
	guint result;
	SwayNotificationCenterWidgetsNotifications* _tmp0_;
	guint _tmp1_;
	guint _tmp2_;
	g_return_val_if_fail (SWAY_NOTIFICATION_CENTER_IS_NOTI_DAEMON (self), 0U);
	_tmp0_ = sway_notification_center_notifications_widget;
	_tmp1_ = sway_notification_center_widgets_notifications_get_n_notifications (_tmp0_);
	_tmp2_ = _tmp1_;
	result = _tmp2_;
	return result;
}

static void
g_cclosure_user_marshal_VOID__UINT_UINT (GClosure * closure,
                                         GValue * return_value,
                                         guint n_param_values,
                                         const GValue * param_values,
                                         gpointer invocation_hint,
                                         gpointer marshal_data)
{
	typedef void (*GMarshalFunc_VOID__UINT_UINT) (gpointer data1, guint32 arg_1, guint32 arg_2, gpointer data2);
	register GMarshalFunc_VOID__UINT_UINT callback;
	register GCClosure * cc;
	register gpointer data1;
	register gpointer data2;
	cc = (GCClosure *) closure;
	g_return_if_fail (n_param_values == 3);
	if (G_CCLOSURE_SWAP_DATA (closure)) {
		data1 = closure->data;
		data2 = param_values->data[0].v_pointer;
	} else {
		data1 = param_values->data[0].v_pointer;
		data2 = closure->data;
	}
	callback = (GMarshalFunc_VOID__UINT_UINT) (marshal_data ? marshal_data : cc->callback);
	callback (data1, g_value_get_uint (param_values + 1), g_value_get_uint (param_values + 2), data2);
}

static void
g_cclosure_user_marshal_VOID__UINT_STRING (GClosure * closure,
                                           GValue * return_value,
                                           guint n_param_values,
                                           const GValue * param_values,
                                           gpointer invocation_hint,
                                           gpointer marshal_data)
{
	typedef void (*GMarshalFunc_VOID__UINT_STRING) (gpointer data1, guint32 arg_1, const char* arg_2, gpointer data2);
	register GMarshalFunc_VOID__UINT_STRING callback;
	register GCClosure * cc;
	register gpointer data1;
	register gpointer data2;
	cc = (GCClosure *) closure;
	g_return_if_fail (n_param_values == 3);
	if (G_CCLOSURE_SWAP_DATA (closure)) {
		data1 = closure->data;
		data2 = param_values->data[0].v_pointer;
	} else {
		data1 = param_values->data[0].v_pointer;
		data2 = closure->data;
	}
	callback = (GMarshalFunc_VOID__UINT_STRING) (marshal_data ? marshal_data : cc->callback);
	callback (data1, g_value_get_uint (param_values + 1), g_value_get_string (param_values + 2), data2);
}

static void
sway_notification_center_noti_daemon_class_init (SwayNotificationCenterNotiDaemonClass * klass,
                                                 gpointer klass_data)
{
	sway_notification_center_noti_daemon_parent_class = g_type_class_peek_parent (klass);
	g_type_class_adjust_private_offset (klass, &SwayNotificationCenterNotiDaemon_private_offset);
	G_OBJECT_CLASS (klass)->get_property = _vala_sway_notification_center_noti_daemon_get_property;
	G_OBJECT_CLASS (klass)->set_property = _vala_sway_notification_center_noti_daemon_set_property;
	G_OBJECT_CLASS (klass)->finalize = sway_notification_center_noti_daemon_finalize;
	/** Do Not Disturb state */
	g_object_class_install_property (G_OBJECT_CLASS (klass), SWAY_NOTIFICATION_CENTER_NOTI_DAEMON_DND_PROPERTY, sway_notification_center_noti_daemon_properties[SWAY_NOTIFICATION_CENTER_NOTI_DAEMON_DND_PROPERTY] = g_param_spec_boolean ("dnd", "dnd", "dnd", FALSE, G_PARAM_STATIC_STRINGS | G_PARAM_READABLE | G_PARAM_WRITABLE));
	g_object_class_install_property (G_OBJECT_CLASS (klass), SWAY_NOTIFICATION_CENTER_NOTI_DAEMON_N_NOTIFICATIONS_PROPERTY, sway_notification_center_noti_daemon_properties[SWAY_NOTIFICATION_CENTER_NOTI_DAEMON_N_NOTIFICATIONS_PROPERTY] = g_param_spec_uint ("n-notifications", "n-notifications", "n-notifications", 0, G_MAXUINT, 0U, G_PARAM_STATIC_STRINGS | G_PARAM_READABLE));
	/** Called when Do Not Disturb state changes */
	sway_notification_center_noti_daemon_signals[SWAY_NOTIFICATION_CENTER_NOTI_DAEMON_ON_DND_TOGGLE_SIGNAL] = g_signal_new ("on-dnd-toggle", SWAY_NOTIFICATION_CENTER_TYPE_NOTI_DAEMON, G_SIGNAL_RUN_LAST, 0, NULL, NULL, g_cclosure_marshal_VOID__BOOLEAN, G_TYPE_NONE, 1, G_TYPE_BOOLEAN);
	/**
	         * A completed notification is one that has timed out, or has been
	         * dismissed by the user.
	         *
	         * The ID specified in the signal is invalidated before the signal
	         * is sent and may not be used in any further communications
	         * with the server.
	         */
	sway_notification_center_noti_daemon_signals[SWAY_NOTIFICATION_CENTER_NOTI_DAEMON_NOTIFICATION_CLOSED_SIGNAL] = g_signal_new ("notification-closed", SWAY_NOTIFICATION_CENTER_TYPE_NOTI_DAEMON, G_SIGNAL_RUN_LAST, 0, NULL, NULL, g_cclosure_user_marshal_VOID__UINT_UINT, G_TYPE_NONE, 2, G_TYPE_UINT, G_TYPE_UINT);
	/**
	         * This signal is emitted when one of the following occurs:
	         *
	         * - The user performs some global "invoking" action upon a
	         * notification. For instance, clicking somewhere on the
	         * notification itself.
	         *
	         * - The user invokes a specific action as specified in the original
	         * Notify request. For example, clicking on an action button.
	         *
	         * #Note
	         *
	         * Clients should not assume the server will generate this signal.
	         * Some servers may not support user interaction at all, or may not
	         * support the concept of being able to "invoke" a notification.
	         */
	sway_notification_center_noti_daemon_signals[SWAY_NOTIFICATION_CENTER_NOTI_DAEMON_ACTION_INVOKED_SIGNAL] = g_signal_new ("action-invoked", SWAY_NOTIFICATION_CENTER_TYPE_NOTI_DAEMON, G_SIGNAL_RUN_LAST, 0, NULL, NULL, g_cclosure_user_marshal_VOID__UINT_STRING, G_TYPE_NONE, 2, G_TYPE_UINT, G_TYPE_STRING);
	/**
	         * This signal can be emitted before a ActionInvoked signal. It
	         * carries an activation token that can be used to activate a toplevel.
	         */
	sway_notification_center_noti_daemon_signals[SWAY_NOTIFICATION_CENTER_NOTI_DAEMON_ACTIVATION_TOKEN_SIGNAL] = g_signal_new ("activation-token", SWAY_NOTIFICATION_CENTER_TYPE_NOTI_DAEMON, G_SIGNAL_RUN_LAST, 0, NULL, NULL, g_cclosure_user_marshal_VOID__UINT_STRING, G_TYPE_NONE, 2, G_TYPE_UINT, G_TYPE_STRING);
	/** To be used by the non-standard "inline-reply" capability */
	sway_notification_center_noti_daemon_signals[SWAY_NOTIFICATION_CENTER_NOTI_DAEMON_NOTIFICATION_REPLIED_SIGNAL] = g_signal_new ("notification-replied", SWAY_NOTIFICATION_CENTER_TYPE_NOTI_DAEMON, G_SIGNAL_RUN_LAST, 0, NULL, NULL, g_cclosure_user_marshal_VOID__UINT_STRING, G_TYPE_NONE, 2, G_TYPE_UINT, G_TYPE_STRING);
}

static void
sway_notification_center_noti_daemon_instance_init (SwayNotificationCenterNotiDaemon * self,
                                                    gpointer klass)
{
	GHashFunc _tmp0_;
	GEqualFunc _tmp1_;
	GHashTable* _tmp2_;
	GeeHashSet* _tmp3_;
	self->priv = sway_notification_center_noti_daemon_get_instance_private (self);
	self->priv->noti_id = (guint32) 0;
	_tmp0_ = g_str_hash;
	_tmp1_ = g_str_equal;
	_tmp2_ = g_hash_table_new_full (_tmp0_, _tmp1_, _g_free0_, NULL);
	self->priv->synchronous_ids = _tmp2_;
	_tmp3_ = gee_hash_set_new (G_TYPE_UINT, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL);
	if (_tmp3_) {
		g_object_set_data ((GObject *) _tmp3_, "vala-creation-function", "");
	}
	self->priv->notification_ids = _tmp3_;
	self->priv->_dnd = FALSE;
}

static void
sway_notification_center_noti_daemon_finalize (GObject * obj)
{
	SwayNotificationCenterNotiDaemon * self;
	self = G_TYPE_CHECK_INSTANCE_CAST (obj, SWAY_NOTIFICATION_CENTER_TYPE_NOTI_DAEMON, SwayNotificationCenterNotiDaemon);
	_g_hash_table_unref0 (self->priv->synchronous_ids);
	_g_object_unref0 (self->priv->notification_ids);
	G_OBJECT_CLASS (sway_notification_center_noti_daemon_parent_class)->finalize (obj);
}

 G_GNUC_NO_INLINE static GType
sway_notification_center_noti_daemon_get_type_once (void)
{
	static const GTypeInfo g_define_type_info = { sizeof (SwayNotificationCenterNotiDaemonClass), (GBaseInitFunc) NULL, (GBaseFinalizeFunc) NULL, (GClassInitFunc) sway_notification_center_noti_daemon_class_init, (GClassFinalizeFunc) NULL, NULL, sizeof (SwayNotificationCenterNotiDaemon), 0, (GInstanceInitFunc) sway_notification_center_noti_daemon_instance_init, NULL };
	GType sway_notification_center_noti_daemon_type_id;
	sway_notification_center_noti_daemon_type_id = g_type_register_static (G_TYPE_OBJECT, "SwayNotificationCenterNotiDaemon", &g_define_type_info, 0);
	g_type_set_qdata (sway_notification_center_noti_daemon_type_id, g_quark_from_static_string ("vala-dbus-register-object"), (void*) sway_notification_center_noti_daemon_register_object);
	SwayNotificationCenterNotiDaemon_private_offset = g_type_add_instance_private (sway_notification_center_noti_daemon_type_id, sizeof (SwayNotificationCenterNotiDaemonPrivate));
	return sway_notification_center_noti_daemon_type_id;
}

GType
sway_notification_center_noti_daemon_get_type (void)
{
	static gsize sway_notification_center_noti_daemon_type_id__once = 0;
	if (g_once_init_enter (&sway_notification_center_noti_daemon_type_id__once)) {
		GType sway_notification_center_noti_daemon_type_id;
		sway_notification_center_noti_daemon_type_id = sway_notification_center_noti_daemon_get_type_once ();
		g_once_init_leave (&sway_notification_center_noti_daemon_type_id__once, sway_notification_center_noti_daemon_type_id);
	}
	return sway_notification_center_noti_daemon_type_id__once;
}

static void
_vala_sway_notification_center_noti_daemon_get_property (GObject * object,
                                                         guint property_id,
                                                         GValue * value,
                                                         GParamSpec * pspec)
{
	SwayNotificationCenterNotiDaemon * self;
	self = G_TYPE_CHECK_INSTANCE_CAST (object, SWAY_NOTIFICATION_CENTER_TYPE_NOTI_DAEMON, SwayNotificationCenterNotiDaemon);
	switch (property_id) {
		case SWAY_NOTIFICATION_CENTER_NOTI_DAEMON_DND_PROPERTY:
		g_value_set_boolean (value, sway_notification_center_noti_daemon_get_dnd (self));
		break;
		case SWAY_NOTIFICATION_CENTER_NOTI_DAEMON_N_NOTIFICATIONS_PROPERTY:
		g_value_set_uint (value, sway_notification_center_noti_daemon_get_n_notifications (self));
		break;
		default:
		G_OBJECT_WARN_INVALID_PROPERTY_ID (object, property_id, pspec);
		break;
	}
}

static void
_vala_sway_notification_center_noti_daemon_set_property (GObject * object,
                                                         guint property_id,
                                                         const GValue * value,
                                                         GParamSpec * pspec)
{
	SwayNotificationCenterNotiDaemon * self;
	self = G_TYPE_CHECK_INSTANCE_CAST (object, SWAY_NOTIFICATION_CENTER_TYPE_NOTI_DAEMON, SwayNotificationCenterNotiDaemon);
	switch (property_id) {
		case SWAY_NOTIFICATION_CENTER_NOTI_DAEMON_DND_PROPERTY:
		sway_notification_center_noti_daemon_set_dnd (self, g_value_get_boolean (value));
		break;
		default:
		G_OBJECT_WARN_INVALID_PROPERTY_ID (object, property_id, pspec);
		break;
	}
}

static void
_dbus_sway_notification_center_noti_daemon_get_capabilities (SwayNotificationCenterNotiDaemon* self,
                                                             GVariant* _parameters_,
                                                             GDBusMethodInvocation* invocation)
{
	GError* error = NULL;
	GVariantIter _arguments_iter;
	GDBusMessage* _reply_message = NULL;
	GVariant* _reply;
	GVariantBuilder _reply_builder;
	gchar** result;
	gint result_length1 = 0;
	gchar** _tmp14_;
	GVariantBuilder _tmp15_;
	gint _tmp16_;
	g_variant_iter_init (&_arguments_iter, _parameters_);
	result = sway_notification_center_noti_daemon_get_capabilities (self, &result_length1, &error);
	if (error) {
		g_dbus_method_invocation_take_error (invocation, error);
		return;
	}
	_reply_message = g_dbus_message_new_method_reply (g_dbus_method_invocation_get_message (invocation));
	g_variant_builder_init (&_reply_builder, G_VARIANT_TYPE_TUPLE);
	_tmp14_ = result;
	g_variant_builder_init (&_tmp15_, G_VARIANT_TYPE ("as"));
	for (_tmp16_ = 0; _tmp16_ < result_length1; _tmp16_++) {
		g_variant_builder_add_value (&_tmp15_, g_variant_new_string (*_tmp14_));
		_tmp14_++;
	}
	g_variant_builder_add_value (&_reply_builder, g_variant_builder_end (&_tmp15_));
	result = (_vala_array_free (result, result_length1, (GDestroyNotify) g_free), NULL);
	_reply = g_variant_builder_end (&_reply_builder);
	g_dbus_message_set_body (_reply_message, _reply);
	g_dbus_connection_send_message (g_dbus_method_invocation_get_connection (invocation), _reply_message, G_DBUS_SEND_MESSAGE_FLAGS_NONE, NULL, NULL);
	g_object_unref (invocation);
	g_object_unref (_reply_message);
}

static void
_dbus_sway_notification_center_noti_daemon_new_notification (SwayNotificationCenterNotiDaemon* self,
                                                             GVariant* _parameters_,
                                                             GDBusMethodInvocation* invocation)
{
	GError* error = NULL;
	GVariantIter _arguments_iter;
	gchar* app_name = NULL;
	GVariant* _tmp17_;
	guint32 replaces_id = 0U;
	GVariant* _tmp18_;
	gchar* app_icon = NULL;
	GVariant* _tmp19_;
	gchar* summary = NULL;
	GVariant* _tmp20_;
	gchar* body = NULL;
	GVariant* _tmp21_;
	gchar** actions = NULL;
	gint actions_length1 = 0;
	GVariant* _tmp22_;
	gchar** _tmp23_;
	gint _tmp23__length;
	gint _tmp23__size;
	gint _tmp23__length1;
	GVariantIter _tmp24_;
	GVariant* _tmp25_;
	GHashTable* hints = NULL;
	GVariant* _tmp26_;
	GHashTable* _tmp27_;
	GVariantIter _tmp28_;
	GVariant* _tmp29_;
	GVariant* _tmp30_;
	gint expire_timeout = 0;
	GVariant* _tmp31_;
	GDBusMessage* _reply_message = NULL;
	GVariant* _reply;
	GVariantBuilder _reply_builder;
	guint32 result;
	g_variant_iter_init (&_arguments_iter, _parameters_);
	_tmp17_ = g_variant_iter_next_value (&_arguments_iter);
	app_name = g_variant_dup_string (_tmp17_, NULL);
	g_variant_unref (_tmp17_);
	_tmp18_ = g_variant_iter_next_value (&_arguments_iter);
	replaces_id = g_variant_get_uint32 (_tmp18_);
	g_variant_unref (_tmp18_);
	_tmp19_ = g_variant_iter_next_value (&_arguments_iter);
	app_icon = g_variant_dup_string (_tmp19_, NULL);
	g_variant_unref (_tmp19_);
	_tmp20_ = g_variant_iter_next_value (&_arguments_iter);
	summary = g_variant_dup_string (_tmp20_, NULL);
	g_variant_unref (_tmp20_);
	_tmp21_ = g_variant_iter_next_value (&_arguments_iter);
	body = g_variant_dup_string (_tmp21_, NULL);
	g_variant_unref (_tmp21_);
	_tmp22_ = g_variant_iter_next_value (&_arguments_iter);
	_tmp23_ = g_new (gchar*, 5);
	_tmp23__length = 0;
	_tmp23__size = 4;
	_tmp23__length1 = 0;
	g_variant_iter_init (&_tmp24_, _tmp22_);
	for (; (_tmp25_ = g_variant_iter_next_value (&_tmp24_)) != NULL; _tmp23__length1++) {
		if (_tmp23__size == _tmp23__length) {
			_tmp23__size = 2 * _tmp23__size;
			_tmp23_ = g_renew (gchar*, _tmp23_, _tmp23__size + 1);
		}
		_tmp23_[_tmp23__length++] = g_variant_dup_string (_tmp25_, NULL);
		g_variant_unref (_tmp25_);
	}
	actions_length1 = _tmp23__length1;
	_tmp23_[_tmp23__length] = NULL;
	actions = _tmp23_;
	g_variant_unref (_tmp22_);
	_tmp26_ = g_variant_iter_next_value (&_arguments_iter);
	_tmp27_ = g_hash_table_new_full (g_str_hash, g_str_equal, g_free, (GDestroyNotify) g_variant_unref);
	g_variant_iter_init (&_tmp28_, _tmp26_);
	while (g_variant_iter_loop (&_tmp28_, "{?*}", &_tmp29_, &_tmp30_)) {
		g_hash_table_insert (_tmp27_, g_variant_dup_string (_tmp29_, NULL), g_variant_get_variant (_tmp30_));
	}
	hints = _tmp27_;
	g_variant_unref (_tmp26_);
	_tmp31_ = g_variant_iter_next_value (&_arguments_iter);
	expire_timeout = g_variant_get_int32 (_tmp31_);
	g_variant_unref (_tmp31_);
	result = sway_notification_center_noti_daemon_new_notification (self, app_name, replaces_id, app_icon, summary, body, actions, actions_length1, hints, expire_timeout, &error);
	if (error) {
		g_dbus_method_invocation_take_error (invocation, error);
		goto _error;
	}
	_reply_message = g_dbus_message_new_method_reply (g_dbus_method_invocation_get_message (invocation));
	g_variant_builder_init (&_reply_builder, G_VARIANT_TYPE_TUPLE);
	g_variant_builder_add_value (&_reply_builder, g_variant_new_uint32 (result));
	_reply = g_variant_builder_end (&_reply_builder);
	g_dbus_message_set_body (_reply_message, _reply);
	g_dbus_connection_send_message (g_dbus_method_invocation_get_connection (invocation), _reply_message, G_DBUS_SEND_MESSAGE_FLAGS_NONE, NULL, NULL);
	g_object_unref (invocation);
	g_object_unref (_reply_message);
	_error:
	_g_free0 (app_name);
	_g_free0 (app_icon);
	_g_free0 (summary);
	_g_free0 (body);
	actions = (_vala_array_free (actions, actions_length1, (GDestroyNotify) g_free), NULL);
	_g_hash_table_unref0 (hints);
	;
}

static void
_dbus_sway_notification_center_noti_daemon_close_notification (SwayNotificationCenterNotiDaemon* self,
                                                               GVariant* _parameters_,
                                                               GDBusMethodInvocation* invocation)
{
	GError* error = NULL;
	GVariantIter _arguments_iter;
	guint32 id = 0U;
	GVariant* _tmp32_;
	GDBusMessage* _reply_message = NULL;
	GVariant* _reply;
	GVariantBuilder _reply_builder;
	g_variant_iter_init (&_arguments_iter, _parameters_);
	_tmp32_ = g_variant_iter_next_value (&_arguments_iter);
	id = g_variant_get_uint32 (_tmp32_);
	g_variant_unref (_tmp32_);
	sway_notification_center_noti_daemon_close_notification (self, id, &error);
	if (error) {
		g_dbus_method_invocation_take_error (invocation, error);
		return;
	}
	_reply_message = g_dbus_message_new_method_reply (g_dbus_method_invocation_get_message (invocation));
	g_variant_builder_init (&_reply_builder, G_VARIANT_TYPE_TUPLE);
	_reply = g_variant_builder_end (&_reply_builder);
	g_dbus_message_set_body (_reply_message, _reply);
	g_dbus_connection_send_message (g_dbus_method_invocation_get_connection (invocation), _reply_message, G_DBUS_SEND_MESSAGE_FLAGS_NONE, NULL, NULL);
	g_object_unref (invocation);
	g_object_unref (_reply_message);
}

static void
_dbus_sway_notification_center_noti_daemon_get_server_information (SwayNotificationCenterNotiDaemon* self,
                                                                   GVariant* _parameters_,
                                                                   GDBusMethodInvocation* invocation)
{
	GError* error = NULL;
	GVariantIter _arguments_iter;
	GDBusMessage* _reply_message = NULL;
	GVariant* _reply;
	GVariantBuilder _reply_builder;
	gchar* name = NULL;
	gchar* vendor = NULL;
	gchar* version = NULL;
	gchar* spec_version = NULL;
	g_variant_iter_init (&_arguments_iter, _parameters_);
	sway_notification_center_noti_daemon_get_server_information (self, &name, &vendor, &version, &spec_version, &error);
	if (error) {
		g_dbus_method_invocation_take_error (invocation, error);
		return;
	}
	_reply_message = g_dbus_message_new_method_reply (g_dbus_method_invocation_get_message (invocation));
	g_variant_builder_init (&_reply_builder, G_VARIANT_TYPE_TUPLE);
	g_variant_builder_add_value (&_reply_builder, g_variant_new_string (name));
	g_variant_builder_add_value (&_reply_builder, g_variant_new_string (vendor));
	g_variant_builder_add_value (&_reply_builder, g_variant_new_string (version));
	g_variant_builder_add_value (&_reply_builder, g_variant_new_string (spec_version));
	_reply = g_variant_builder_end (&_reply_builder);
	g_dbus_message_set_body (_reply_message, _reply);
	g_dbus_connection_send_message (g_dbus_method_invocation_get_connection (invocation), _reply_message, G_DBUS_SEND_MESSAGE_FLAGS_NONE, NULL, NULL);
	g_object_unref (invocation);
	g_object_unref (_reply_message);
	_g_free0 (name);
	_g_free0 (vendor);
	_g_free0 (version);
	_g_free0 (spec_version);
}

static void
sway_notification_center_noti_daemon_dbus_interface_method_call (GDBusConnection* connection,
                                                                 const gchar* sender,
                                                                 const gchar* object_path,
                                                                 const gchar* interface_name,
                                                                 const gchar* method_name,
                                                                 GVariant* parameters,
                                                                 GDBusMethodInvocation* invocation,
                                                                 gpointer user_data)
{
	gpointer* data;
	gpointer object;
	data = user_data;
	object = data[0];
	if (strcmp (method_name, "GetCapabilities") == 0) {
		_dbus_sway_notification_center_noti_daemon_get_capabilities (object, parameters, invocation);
	} else if (strcmp (method_name, "Notify") == 0) {
		_dbus_sway_notification_center_noti_daemon_new_notification (object, parameters, invocation);
	} else if (strcmp (method_name, "CloseNotification") == 0) {
		_dbus_sway_notification_center_noti_daemon_close_notification (object, parameters, invocation);
	} else if (strcmp (method_name, "GetServerInformation") == 0) {
		_dbus_sway_notification_center_noti_daemon_get_server_information (object, parameters, invocation);
	} else {
		g_object_unref (invocation);
	}
}

static GVariant*
sway_notification_center_noti_daemon_dbus_interface_get_property (GDBusConnection* connection,
                                                                  const gchar* sender,
                                                                  const gchar* object_path,
                                                                  const gchar* interface_name,
                                                                  const gchar* property_name,
                                                                  GError** error,
                                                                  gpointer user_data)
{
	gpointer* data;
	gpointer object;
	data = user_data;
	object = data[0];
	return NULL;
}

static gboolean
sway_notification_center_noti_daemon_dbus_interface_set_property (GDBusConnection* connection,
                                                                  const gchar* sender,
                                                                  const gchar* object_path,
                                                                  const gchar* interface_name,
                                                                  const gchar* property_name,
                                                                  GVariant* value,
                                                                  GError** error,
                                                                  gpointer user_data)
{
	gpointer* data;
	gpointer object;
	data = user_data;
	object = data[0];
	return FALSE;
}

static void
_dbus_sway_notification_center_noti_daemon_notification_closed (GObject* _sender,
                                                                guint32 id,
                                                                guint32 reason,
                                                                gpointer* _data)
{
	GDBusConnection * _connection;
	const gchar * _path;
	GVariant *_arguments;
	GVariantBuilder _arguments_builder;
	_connection = _data[1];
	_path = _data[2];
	g_variant_builder_init (&_arguments_builder, G_VARIANT_TYPE_TUPLE);
	g_variant_builder_add_value (&_arguments_builder, g_variant_new_uint32 (id));
	g_variant_builder_add_value (&_arguments_builder, g_variant_new_uint32 (reason));
	_arguments = g_variant_builder_end (&_arguments_builder);
	g_dbus_connection_emit_signal (_connection, NULL, _path, "org.freedesktop.Notifications", "NotificationClosed", _arguments, NULL);
}

static void
_dbus_sway_notification_center_noti_daemon_action_invoked (GObject* _sender,
                                                           guint32 id,
                                                           const gchar* action_key,
                                                           gpointer* _data)
{
	GDBusConnection * _connection;
	const gchar * _path;
	GVariant *_arguments;
	GVariantBuilder _arguments_builder;
	_connection = _data[1];
	_path = _data[2];
	g_variant_builder_init (&_arguments_builder, G_VARIANT_TYPE_TUPLE);
	g_variant_builder_add_value (&_arguments_builder, g_variant_new_uint32 (id));
	g_variant_builder_add_value (&_arguments_builder, g_variant_new_string (action_key));
	_arguments = g_variant_builder_end (&_arguments_builder);
	g_dbus_connection_emit_signal (_connection, NULL, _path, "org.freedesktop.Notifications", "ActionInvoked", _arguments, NULL);
}

static void
_dbus_sway_notification_center_noti_daemon_activation_token (GObject* _sender,
                                                             guint32 id,
                                                             const gchar* activation_token,
                                                             gpointer* _data)
{
	GDBusConnection * _connection;
	const gchar * _path;
	GVariant *_arguments;
	GVariantBuilder _arguments_builder;
	_connection = _data[1];
	_path = _data[2];
	g_variant_builder_init (&_arguments_builder, G_VARIANT_TYPE_TUPLE);
	g_variant_builder_add_value (&_arguments_builder, g_variant_new_uint32 (id));
	g_variant_builder_add_value (&_arguments_builder, g_variant_new_string (activation_token));
	_arguments = g_variant_builder_end (&_arguments_builder);
	g_dbus_connection_emit_signal (_connection, NULL, _path, "org.freedesktop.Notifications", "ActivationToken", _arguments, NULL);
}

static void
_dbus_sway_notification_center_noti_daemon_notification_replied (GObject* _sender,
                                                                 guint32 id,
                                                                 const gchar* text,
                                                                 gpointer* _data)
{
	GDBusConnection * _connection;
	const gchar * _path;
	GVariant *_arguments;
	GVariantBuilder _arguments_builder;
	_connection = _data[1];
	_path = _data[2];
	g_variant_builder_init (&_arguments_builder, G_VARIANT_TYPE_TUPLE);
	g_variant_builder_add_value (&_arguments_builder, g_variant_new_uint32 (id));
	g_variant_builder_add_value (&_arguments_builder, g_variant_new_string (text));
	_arguments = g_variant_builder_end (&_arguments_builder);
	g_dbus_connection_emit_signal (_connection, NULL, _path, "org.freedesktop.Notifications", "NotificationReplied", _arguments, NULL);
}

guint
sway_notification_center_noti_daemon_register_object (gpointer object,
                                                      GDBusConnection* connection,
                                                      const gchar* path,
                                                      GError** error)
{
	guint result;
	gpointer *data;
	data = g_new (gpointer, 3);
	data[0] = g_object_ref (object);
	data[1] = g_object_ref (connection);
	data[2] = g_strdup (path);
	result = g_dbus_connection_register_object (connection, path, (GDBusInterfaceInfo *) (&_sway_notification_center_noti_daemon_dbus_interface_info), &_sway_notification_center_noti_daemon_dbus_interface_vtable, data, _sway_notification_center_noti_daemon_unregister_object, error);
	if (!result) {
		return 0;
	}
	g_signal_connect (object, "notification-closed", (GCallback) _dbus_sway_notification_center_noti_daemon_notification_closed, data);
	g_signal_connect (object, "action-invoked", (GCallback) _dbus_sway_notification_center_noti_daemon_action_invoked, data);
	g_signal_connect (object, "activation-token", (GCallback) _dbus_sway_notification_center_noti_daemon_activation_token, data);
	g_signal_connect (object, "notification-replied", (GCallback) _dbus_sway_notification_center_noti_daemon_notification_replied, data);
	return result;
}

static void
_sway_notification_center_noti_daemon_unregister_object (gpointer user_data)
{
	gpointer* data;
	data = user_data;
	g_signal_handlers_disconnect_by_func (data[0], _dbus_sway_notification_center_noti_daemon_notification_closed, data);
	g_signal_handlers_disconnect_by_func (data[0], _dbus_sway_notification_center_noti_daemon_action_invoked, data);
	g_signal_handlers_disconnect_by_func (data[0], _dbus_sway_notification_center_noti_daemon_activation_token, data);
	g_signal_handlers_disconnect_by_func (data[0], _dbus_sway_notification_center_noti_daemon_notification_replied, data);
	g_object_unref (data[0]);
	g_object_unref (data[1]);
	g_free (data[2]);
	g_free (data);
}

static void
_vala_array_destroy (gpointer array,
                     gssize array_length,
                     GDestroyNotify destroy_func)
{
	if ((array != NULL) && (destroy_func != NULL)) {
		gssize i;
		for (i = 0; i < array_length; i = i + 1) {
			if (((gpointer*) array)[i] != NULL) {
				destroy_func (((gpointer*) array)[i]);
			}
		}
	}
}

static void
_vala_array_free (gpointer array,
                  gssize array_length,
                  GDestroyNotify destroy_func)
{
	_vala_array_destroy (array, array_length, destroy_func);
	g_free (array);
}

