/* StandardHostInterface.c generated by valac 0.56.19, the Vala compiler
 * generated from StandardHostInterface.vala, do not modify */

/* Copyright 2016 Software Freedom Conservancy Inc.
 *
 * This software is licensed under the GNU Lesser General Public License
 * (version 2.1 or later).  See the COPYING file in this distribution.
 */

#include <glib-object.h>
#include "shotwell-plugin-dev-1.0.h"
#include <stdlib.h>
#include <string.h>
#include <glib.h>
#include <gio/gio.h>
#include <float.h>
#include <math.h>

#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 PLUGINS_TYPE_STANDARD_HOST_INTERFACE (plugins_standard_host_interface_get_type ())
#define PLUGINS_STANDARD_HOST_INTERFACE(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), PLUGINS_TYPE_STANDARD_HOST_INTERFACE, PluginsStandardHostInterface))
#define PLUGINS_STANDARD_HOST_INTERFACE_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), PLUGINS_TYPE_STANDARD_HOST_INTERFACE, PluginsStandardHostInterfaceClass))
#define PLUGINS_IS_STANDARD_HOST_INTERFACE(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), PLUGINS_TYPE_STANDARD_HOST_INTERFACE))
#define PLUGINS_IS_STANDARD_HOST_INTERFACE_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), PLUGINS_TYPE_STANDARD_HOST_INTERFACE))
#define PLUGINS_STANDARD_HOST_INTERFACE_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), PLUGINS_TYPE_STANDARD_HOST_INTERFACE, PluginsStandardHostInterfaceClass))

typedef struct _PluginsStandardHostInterface PluginsStandardHostInterface;
typedef struct _PluginsStandardHostInterfaceClass PluginsStandardHostInterfaceClass;
typedef struct _PluginsStandardHostInterfacePrivate PluginsStandardHostInterfacePrivate;
enum  {
	PLUGINS_STANDARD_HOST_INTERFACE_0_PROPERTY,
	PLUGINS_STANDARD_HOST_INTERFACE_NUM_PROPERTIES
};
static GParamSpec* plugins_standard_host_interface_properties[PLUGINS_STANDARD_HOST_INTERFACE_NUM_PROPERTIES];
#define _g_free0(var) (var = (g_free (var), NULL))
#define _g_object_unref0(var) ((var == NULL) ? NULL : (var = (g_object_unref (var), NULL)))

#define TYPE_CONFIGURATION_FACADE (configuration_facade_get_type ())
#define CONFIGURATION_FACADE(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TYPE_CONFIGURATION_FACADE, ConfigurationFacade))
#define CONFIGURATION_FACADE_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TYPE_CONFIGURATION_FACADE, ConfigurationFacadeClass))
#define IS_CONFIGURATION_FACADE(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TYPE_CONFIGURATION_FACADE))
#define IS_CONFIGURATION_FACADE_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TYPE_CONFIGURATION_FACADE))
#define CONFIGURATION_FACADE_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TYPE_CONFIGURATION_FACADE, ConfigurationFacadeClass))

typedef struct _ConfigurationFacade ConfigurationFacade;
typedef struct _ConfigurationFacadeClass ConfigurationFacadeClass;

#define CONFIG_TYPE_FACADE (config_facade_get_type ())
#define CONFIG_FACADE(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), CONFIG_TYPE_FACADE, ConfigFacade))
#define CONFIG_FACADE_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), CONFIG_TYPE_FACADE, ConfigFacadeClass))
#define CONFIG_IS_FACADE(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), CONFIG_TYPE_FACADE))
#define CONFIG_IS_FACADE_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), CONFIG_TYPE_FACADE))
#define CONFIG_FACADE_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), CONFIG_TYPE_FACADE, ConfigFacadeClass))

typedef struct _ConfigFacade ConfigFacade;
typedef struct _ConfigFacadeClass ConfigFacadeClass;

struct _PluginsStandardHostInterface {
	GObject parent_instance;
	PluginsStandardHostInterfacePrivate * priv;
};

struct _PluginsStandardHostInterfaceClass {
	GObjectClass parent_class;
};

struct _PluginsStandardHostInterfacePrivate {
	gchar* config_domain;
	gchar* config_id;
	GFile* module_file;
	SpitPluggableInfo* info;
};

static gint PluginsStandardHostInterface_private_offset;
static gpointer plugins_standard_host_interface_parent_class = NULL;
static SpitHostInterfaceIface * plugins_standard_host_interface_spit_host_interface_parent_iface = NULL;

VALA_EXTERN GType plugins_standard_host_interface_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (PluginsStandardHostInterface, g_object_unref)
VALA_EXTERN PluginsStandardHostInterface* plugins_standard_host_interface_new (SpitPluggable* pluggable,
                                                                   const gchar* config_domain);
VALA_EXTERN PluginsStandardHostInterface* plugins_standard_host_interface_construct (GType object_type,
                                                                         SpitPluggable* pluggable,
                                                                         const gchar* config_domain);
static gchar* plugins_standard_host_interface_parse_key (const gchar* id);
VALA_EXTERN GFile* plugins_get_pluggable_module_file (SpitPluggable* pluggable);
static GFile* plugins_standard_host_interface_real_get_module_file (SpitHostInterface* base);
static gboolean plugins_standard_host_interface_real_get_config_bool (SpitHostInterface* base,
                                                               const gchar* key,
                                                               gboolean def);
VALA_EXTERN GType configuration_facade_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (ConfigurationFacade, g_object_unref)
VALA_EXTERN GType config_facade_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (ConfigFacade, g_object_unref)
VALA_EXTERN ConfigFacade* config_facade_get_instance (void);
VALA_EXTERN gboolean configuration_facade_get_plugin_bool (ConfigurationFacade* self,
                                               const gchar* domain,
                                               const gchar* id,
                                               const gchar* key,
                                               gboolean def);
static void plugins_standard_host_interface_real_set_config_bool (SpitHostInterface* base,
                                                           const gchar* key,
                                                           gboolean val);
VALA_EXTERN void configuration_facade_set_plugin_bool (ConfigurationFacade* self,
                                           const gchar* domain,
                                           const gchar* id,
                                           const gchar* key,
                                           gboolean val);
static gint plugins_standard_host_interface_real_get_config_int (SpitHostInterface* base,
                                                          const gchar* key,
                                                          gint def);
VALA_EXTERN gint configuration_facade_get_plugin_int (ConfigurationFacade* self,
                                          const gchar* domain,
                                          const gchar* id,
                                          const gchar* key,
                                          gint def);
static void plugins_standard_host_interface_real_set_config_int (SpitHostInterface* base,
                                                          const gchar* key,
                                                          gint val);
VALA_EXTERN void configuration_facade_set_plugin_int (ConfigurationFacade* self,
                                          const gchar* domain,
                                          const gchar* id,
                                          const gchar* key,
                                          gint val);
static gchar* plugins_standard_host_interface_real_get_config_string (SpitHostInterface* base,
                                                               const gchar* key,
                                                               const gchar* def);
VALA_EXTERN gchar* configuration_facade_get_plugin_string (ConfigurationFacade* self,
                                               const gchar* domain,
                                               const gchar* id,
                                               const gchar* key,
                                               const gchar* def);
static void plugins_standard_host_interface_real_set_config_string (SpitHostInterface* base,
                                                             const gchar* key,
                                                             const gchar* val);
VALA_EXTERN void configuration_facade_set_plugin_string (ConfigurationFacade* self,
                                             const gchar* domain,
                                             const gchar* id,
                                             const gchar* key,
                                             const gchar* val);
static gdouble plugins_standard_host_interface_real_get_config_double (SpitHostInterface* base,
                                                                const gchar* key,
                                                                gdouble def);
VALA_EXTERN gdouble configuration_facade_get_plugin_double (ConfigurationFacade* self,
                                                const gchar* domain,
                                                const gchar* id,
                                                const gchar* key,
                                                gdouble def);
static void plugins_standard_host_interface_real_set_config_double (SpitHostInterface* base,
                                                             const gchar* key,
                                                             gdouble val);
VALA_EXTERN void configuration_facade_set_plugin_double (ConfigurationFacade* self,
                                             const gchar* domain,
                                             const gchar* id,
                                             const gchar* key,
                                             gdouble val);
static void plugins_standard_host_interface_real_unset_config_key (SpitHostInterface* base,
                                                            const gchar* key);
VALA_EXTERN void configuration_facade_unset_plugin_key (ConfigurationFacade* self,
                                            const gchar* domain,
                                            const gchar* id,
                                            const gchar* key);
static void plugins_standard_host_interface_finalize (GObject * obj);
static GType plugins_standard_host_interface_get_type_once (void);
static inline gpointer _vala_memdup2 (gconstpointer mem,
                        gsize byte_size);

static inline gpointer
plugins_standard_host_interface_get_instance_private (PluginsStandardHostInterface* self)
{
	return G_STRUCT_MEMBER_P (self, PluginsStandardHostInterface_private_offset);
}

PluginsStandardHostInterface*
plugins_standard_host_interface_construct (GType object_type,
                                           SpitPluggable* pluggable,
                                           const gchar* config_domain)
{
	PluginsStandardHostInterface * self = NULL;
	gchar* _tmp0_;
	const gchar* _tmp1_;
	gchar* _tmp2_;
	GFile* _tmp3_;
	SpitPluggableInfo* _tmp4_;
	g_return_val_if_fail (G_TYPE_CHECK_INSTANCE_TYPE (pluggable, SPIT_TYPE_PLUGGABLE), NULL);
	g_return_val_if_fail (config_domain != NULL, NULL);
	self = (PluginsStandardHostInterface*) g_object_new (object_type, NULL);
	_tmp0_ = g_strdup (config_domain);
	_g_free0 (self->priv->config_domain);
	self->priv->config_domain = _tmp0_;
	_tmp1_ = spit_pluggable_get_id (pluggable);
	_tmp2_ = plugins_standard_host_interface_parse_key (_tmp1_);
	_g_free0 (self->priv->config_id);
	self->priv->config_id = _tmp2_;
	_tmp3_ = plugins_get_pluggable_module_file (pluggable);
	_g_object_unref0 (self->priv->module_file);
	self->priv->module_file = _tmp3_;
	_tmp4_ = spit_pluggable_get_info (pluggable);
	_g_object_unref0 (self->priv->info);
	self->priv->info = _tmp4_;
	return self;
}

PluginsStandardHostInterface*
plugins_standard_host_interface_new (SpitPluggable* pluggable,
                                     const gchar* config_domain)
{
	return plugins_standard_host_interface_construct (PLUGINS_TYPE_STANDARD_HOST_INTERFACE, pluggable, config_domain);
}

static gchar*
plugins_standard_host_interface_parse_key (const gchar* id)
{
	const gchar* _tmp0_;
	GQuark _tmp2_ = 0U;
	static GQuark _tmp1_label0 = 0;
	static GQuark _tmp1_label1 = 0;
	gchar* result;
	g_return_val_if_fail (id != NULL, NULL);
	_tmp0_ = id;
	_tmp2_ = (NULL == _tmp0_) ? 0 : g_quark_from_string (_tmp0_);
	if (_tmp2_ == ((0 != _tmp1_label0) ? _tmp1_label0 : (_tmp1_label0 = g_quark_from_static_string ("org.gnome.shotwell.publishing.flickr")))) {
		switch (0) {
			default:
			{
				gchar* _tmp3_;
				_tmp3_ = g_strdup ("flickr");
				result = _tmp3_;
				return result;
			}
		}
	} else if (_tmp2_ == ((0 != _tmp1_label1) ? _tmp1_label1 : (_tmp1_label1 = g_quark_from_static_string ("org.gnome.shotwell.publishing.youtube")))) {
		switch (0) {
			default:
			{
				gchar* _tmp4_;
				_tmp4_ = g_strdup ("youtube");
				result = _tmp4_;
				return result;
			}
		}
	} else {
		switch (0) {
			default:
			{
				gchar* _tmp5_;
				_tmp5_ = g_strdup (id);
				result = _tmp5_;
				return result;
			}
		}
	}
}

static gpointer
_g_object_ref0 (gpointer self)
{
	return self ? g_object_ref (self) : NULL;
}

static GFile*
plugins_standard_host_interface_real_get_module_file (SpitHostInterface* base)
{
	PluginsStandardHostInterface * self;
	GFile* _tmp0_;
	GFile* _tmp1_;
	GFile* result;
	self = G_TYPE_CHECK_INSTANCE_CAST (base, PLUGINS_TYPE_STANDARD_HOST_INTERFACE, PluginsStandardHostInterface);
	_tmp0_ = self->priv->module_file;
	_tmp1_ = _g_object_ref0 (_tmp0_);
	result = _tmp1_;
	return result;
}

static gboolean
plugins_standard_host_interface_real_get_config_bool (SpitHostInterface* base,
                                                      const gchar* key,
                                                      gboolean def)
{
	PluginsStandardHostInterface * self;
	ConfigFacade* _tmp0_;
	ConfigFacade* _tmp1_;
	const gchar* _tmp2_;
	const gchar* _tmp3_;
	gboolean _tmp4_;
	gboolean result;
	self = G_TYPE_CHECK_INSTANCE_CAST (base, PLUGINS_TYPE_STANDARD_HOST_INTERFACE, PluginsStandardHostInterface);
	g_return_val_if_fail (key != NULL, FALSE);
	_tmp0_ = config_facade_get_instance ();
	_tmp1_ = _tmp0_;
	_tmp2_ = self->priv->config_domain;
	_tmp3_ = self->priv->config_id;
	_tmp4_ = configuration_facade_get_plugin_bool (G_TYPE_CHECK_INSTANCE_CAST (_tmp1_, TYPE_CONFIGURATION_FACADE, ConfigurationFacade), _tmp2_, _tmp3_, key, def);
	_g_object_unref0 (_tmp1_);
	result = _tmp4_;
	return result;
}

static void
plugins_standard_host_interface_real_set_config_bool (SpitHostInterface* base,
                                                      const gchar* key,
                                                      gboolean val)
{
	PluginsStandardHostInterface * self;
	ConfigFacade* _tmp0_;
	ConfigFacade* _tmp1_;
	const gchar* _tmp2_;
	const gchar* _tmp3_;
	self = G_TYPE_CHECK_INSTANCE_CAST (base, PLUGINS_TYPE_STANDARD_HOST_INTERFACE, PluginsStandardHostInterface);
	g_return_if_fail (key != NULL);
	_tmp0_ = config_facade_get_instance ();
	_tmp1_ = _tmp0_;
	_tmp2_ = self->priv->config_domain;
	_tmp3_ = self->priv->config_id;
	configuration_facade_set_plugin_bool (G_TYPE_CHECK_INSTANCE_CAST (_tmp1_, TYPE_CONFIGURATION_FACADE, ConfigurationFacade), _tmp2_, _tmp3_, key, val);
	_g_object_unref0 (_tmp1_);
}

static gint
plugins_standard_host_interface_real_get_config_int (SpitHostInterface* base,
                                                     const gchar* key,
                                                     gint def)
{
	PluginsStandardHostInterface * self;
	ConfigFacade* _tmp0_;
	ConfigFacade* _tmp1_;
	const gchar* _tmp2_;
	const gchar* _tmp3_;
	gint _tmp4_;
	gint result;
	self = G_TYPE_CHECK_INSTANCE_CAST (base, PLUGINS_TYPE_STANDARD_HOST_INTERFACE, PluginsStandardHostInterface);
	g_return_val_if_fail (key != NULL, -1);
	_tmp0_ = config_facade_get_instance ();
	_tmp1_ = _tmp0_;
	_tmp2_ = self->priv->config_domain;
	_tmp3_ = self->priv->config_id;
	_tmp4_ = configuration_facade_get_plugin_int (G_TYPE_CHECK_INSTANCE_CAST (_tmp1_, TYPE_CONFIGURATION_FACADE, ConfigurationFacade), _tmp2_, _tmp3_, key, def);
	_g_object_unref0 (_tmp1_);
	result = _tmp4_;
	return result;
}

static void
plugins_standard_host_interface_real_set_config_int (SpitHostInterface* base,
                                                     const gchar* key,
                                                     gint val)
{
	PluginsStandardHostInterface * self;
	ConfigFacade* _tmp0_;
	ConfigFacade* _tmp1_;
	const gchar* _tmp2_;
	const gchar* _tmp3_;
	self = G_TYPE_CHECK_INSTANCE_CAST (base, PLUGINS_TYPE_STANDARD_HOST_INTERFACE, PluginsStandardHostInterface);
	g_return_if_fail (key != NULL);
	_tmp0_ = config_facade_get_instance ();
	_tmp1_ = _tmp0_;
	_tmp2_ = self->priv->config_domain;
	_tmp3_ = self->priv->config_id;
	configuration_facade_set_plugin_int (G_TYPE_CHECK_INSTANCE_CAST (_tmp1_, TYPE_CONFIGURATION_FACADE, ConfigurationFacade), _tmp2_, _tmp3_, key, val);
	_g_object_unref0 (_tmp1_);
}

static gchar*
plugins_standard_host_interface_real_get_config_string (SpitHostInterface* base,
                                                        const gchar* key,
                                                        const gchar* def)
{
	PluginsStandardHostInterface * self;
	ConfigFacade* _tmp0_;
	ConfigFacade* _tmp1_;
	const gchar* _tmp2_;
	const gchar* _tmp3_;
	gchar* _tmp4_;
	gchar* _tmp5_;
	gchar* result;
	self = G_TYPE_CHECK_INSTANCE_CAST (base, PLUGINS_TYPE_STANDARD_HOST_INTERFACE, PluginsStandardHostInterface);
	g_return_val_if_fail (key != NULL, NULL);
	_tmp0_ = config_facade_get_instance ();
	_tmp1_ = _tmp0_;
	_tmp2_ = self->priv->config_domain;
	_tmp3_ = self->priv->config_id;
	_tmp4_ = configuration_facade_get_plugin_string (G_TYPE_CHECK_INSTANCE_CAST (_tmp1_, TYPE_CONFIGURATION_FACADE, ConfigurationFacade), _tmp2_, _tmp3_, key, def);
	_tmp5_ = _tmp4_;
	_g_object_unref0 (_tmp1_);
	result = _tmp5_;
	return result;
}

static void
plugins_standard_host_interface_real_set_config_string (SpitHostInterface* base,
                                                        const gchar* key,
                                                        const gchar* val)
{
	PluginsStandardHostInterface * self;
	ConfigFacade* _tmp0_;
	ConfigFacade* _tmp1_;
	const gchar* _tmp2_;
	const gchar* _tmp3_;
	self = G_TYPE_CHECK_INSTANCE_CAST (base, PLUGINS_TYPE_STANDARD_HOST_INTERFACE, PluginsStandardHostInterface);
	g_return_if_fail (key != NULL);
	_tmp0_ = config_facade_get_instance ();
	_tmp1_ = _tmp0_;
	_tmp2_ = self->priv->config_domain;
	_tmp3_ = self->priv->config_id;
	configuration_facade_set_plugin_string (G_TYPE_CHECK_INSTANCE_CAST (_tmp1_, TYPE_CONFIGURATION_FACADE, ConfigurationFacade), _tmp2_, _tmp3_, key, val);
	_g_object_unref0 (_tmp1_);
}

static gdouble
plugins_standard_host_interface_real_get_config_double (SpitHostInterface* base,
                                                        const gchar* key,
                                                        gdouble def)
{
	PluginsStandardHostInterface * self;
	ConfigFacade* _tmp0_;
	ConfigFacade* _tmp1_;
	const gchar* _tmp2_;
	const gchar* _tmp3_;
	gdouble _tmp4_;
	gdouble result;
	self = G_TYPE_CHECK_INSTANCE_CAST (base, PLUGINS_TYPE_STANDARD_HOST_INTERFACE, PluginsStandardHostInterface);
	g_return_val_if_fail (key != NULL, -1.0);
	_tmp0_ = config_facade_get_instance ();
	_tmp1_ = _tmp0_;
	_tmp2_ = self->priv->config_domain;
	_tmp3_ = self->priv->config_id;
	_tmp4_ = configuration_facade_get_plugin_double (G_TYPE_CHECK_INSTANCE_CAST (_tmp1_, TYPE_CONFIGURATION_FACADE, ConfigurationFacade), _tmp2_, _tmp3_, key, def);
	_g_object_unref0 (_tmp1_);
	result = _tmp4_;
	return result;
}

static void
plugins_standard_host_interface_real_set_config_double (SpitHostInterface* base,
                                                        const gchar* key,
                                                        gdouble val)
{
	PluginsStandardHostInterface * self;
	ConfigFacade* _tmp0_;
	ConfigFacade* _tmp1_;
	const gchar* _tmp2_;
	const gchar* _tmp3_;
	self = G_TYPE_CHECK_INSTANCE_CAST (base, PLUGINS_TYPE_STANDARD_HOST_INTERFACE, PluginsStandardHostInterface);
	g_return_if_fail (key != NULL);
	_tmp0_ = config_facade_get_instance ();
	_tmp1_ = _tmp0_;
	_tmp2_ = self->priv->config_domain;
	_tmp3_ = self->priv->config_id;
	configuration_facade_set_plugin_double (G_TYPE_CHECK_INSTANCE_CAST (_tmp1_, TYPE_CONFIGURATION_FACADE, ConfigurationFacade), _tmp2_, _tmp3_, key, val);
	_g_object_unref0 (_tmp1_);
}

static void
plugins_standard_host_interface_real_unset_config_key (SpitHostInterface* base,
                                                       const gchar* key)
{
	PluginsStandardHostInterface * self;
	ConfigFacade* _tmp0_;
	ConfigFacade* _tmp1_;
	const gchar* _tmp2_;
	const gchar* _tmp3_;
	self = G_TYPE_CHECK_INSTANCE_CAST (base, PLUGINS_TYPE_STANDARD_HOST_INTERFACE, PluginsStandardHostInterface);
	g_return_if_fail (key != NULL);
	_tmp0_ = config_facade_get_instance ();
	_tmp1_ = _tmp0_;
	_tmp2_ = self->priv->config_domain;
	_tmp3_ = self->priv->config_id;
	configuration_facade_unset_plugin_key (G_TYPE_CHECK_INSTANCE_CAST (_tmp1_, TYPE_CONFIGURATION_FACADE, ConfigurationFacade), _tmp2_, _tmp3_, key);
	_g_object_unref0 (_tmp1_);
}

static void
plugins_standard_host_interface_class_init (PluginsStandardHostInterfaceClass * klass,
                                            gpointer klass_data)
{
	plugins_standard_host_interface_parent_class = g_type_class_peek_parent (klass);
	g_type_class_adjust_private_offset (klass, &PluginsStandardHostInterface_private_offset);
	G_OBJECT_CLASS (klass)->finalize = plugins_standard_host_interface_finalize;
}

static void
plugins_standard_host_interface_spit_host_interface_interface_init (SpitHostInterfaceIface * iface,
                                                                    gpointer iface_data)
{
	plugins_standard_host_interface_spit_host_interface_parent_iface = g_type_interface_peek_parent (iface);
	iface->get_module_file = (GFile* (*) (SpitHostInterface*)) plugins_standard_host_interface_real_get_module_file;
	iface->get_config_bool = (gboolean (*) (SpitHostInterface*, const gchar*, gboolean)) plugins_standard_host_interface_real_get_config_bool;
	iface->set_config_bool = (void (*) (SpitHostInterface*, const gchar*, gboolean)) plugins_standard_host_interface_real_set_config_bool;
	iface->get_config_int = (gint (*) (SpitHostInterface*, const gchar*, gint)) plugins_standard_host_interface_real_get_config_int;
	iface->set_config_int = (void (*) (SpitHostInterface*, const gchar*, gint)) plugins_standard_host_interface_real_set_config_int;
	iface->get_config_string = (gchar* (*) (SpitHostInterface*, const gchar*, const gchar*)) plugins_standard_host_interface_real_get_config_string;
	iface->set_config_string = (void (*) (SpitHostInterface*, const gchar*, const gchar*)) plugins_standard_host_interface_real_set_config_string;
	iface->get_config_double = (gdouble (*) (SpitHostInterface*, const gchar*, gdouble)) plugins_standard_host_interface_real_get_config_double;
	iface->set_config_double = (void (*) (SpitHostInterface*, const gchar*, gdouble)) plugins_standard_host_interface_real_set_config_double;
	iface->unset_config_key = (void (*) (SpitHostInterface*, const gchar*)) plugins_standard_host_interface_real_unset_config_key;
}

static void
plugins_standard_host_interface_instance_init (PluginsStandardHostInterface * self,
                                               gpointer klass)
{
	self->priv = plugins_standard_host_interface_get_instance_private (self);
}

static void
plugins_standard_host_interface_finalize (GObject * obj)
{
	PluginsStandardHostInterface * self;
	self = G_TYPE_CHECK_INSTANCE_CAST (obj, PLUGINS_TYPE_STANDARD_HOST_INTERFACE, PluginsStandardHostInterface);
	_g_free0 (self->priv->config_domain);
	_g_free0 (self->priv->config_id);
	_g_object_unref0 (self->priv->module_file);
	_g_object_unref0 (self->priv->info);
	G_OBJECT_CLASS (plugins_standard_host_interface_parent_class)->finalize (obj);
}

static GType
plugins_standard_host_interface_get_type_once (void)
{
	static const GTypeInfo g_define_type_info = { sizeof (PluginsStandardHostInterfaceClass), (GBaseInitFunc) NULL, (GBaseFinalizeFunc) NULL, (GClassInitFunc) plugins_standard_host_interface_class_init, (GClassFinalizeFunc) NULL, NULL, sizeof (PluginsStandardHostInterface), 0, (GInstanceInitFunc) plugins_standard_host_interface_instance_init, NULL };
	static const GInterfaceInfo spit_host_interface_info = { (GInterfaceInitFunc) plugins_standard_host_interface_spit_host_interface_interface_init, (GInterfaceFinalizeFunc) NULL, NULL};
	GType plugins_standard_host_interface_type_id;
	plugins_standard_host_interface_type_id = g_type_register_static (G_TYPE_OBJECT, "PluginsStandardHostInterface", &g_define_type_info, 0);
	g_type_add_interface_static (plugins_standard_host_interface_type_id, SPIT_TYPE_HOST_INTERFACE, &spit_host_interface_info);
	PluginsStandardHostInterface_private_offset = g_type_add_instance_private (plugins_standard_host_interface_type_id, sizeof (PluginsStandardHostInterfacePrivate));
	return plugins_standard_host_interface_type_id;
}

GType
plugins_standard_host_interface_get_type (void)
{
	static volatile gsize plugins_standard_host_interface_type_id__once = 0;
	if (g_once_init_enter (&plugins_standard_host_interface_type_id__once)) {
		GType plugins_standard_host_interface_type_id;
		plugins_standard_host_interface_type_id = plugins_standard_host_interface_get_type_once ();
		g_once_init_leave (&plugins_standard_host_interface_type_id__once, plugins_standard_host_interface_type_id);
	}
	return plugins_standard_host_interface_type_id__once;
}

static inline gpointer
_vala_memdup2 (gconstpointer mem,
               gsize byte_size)
{
	gpointer new_mem;
	if (mem && byte_size != 0) {
		new_mem = g_malloc (byte_size);
		memcpy (new_mem, mem, byte_size);
	} else {
		new_mem = NULL;
	}
	return new_mem;
}

