/* collection-source.c generated by valac 0.25.1.6-a1f05, the Vala compiler
 * generated from collection-source.vala, do not modify */

/* This file is part of GNOME Boxes. License: LGPLv2+*/

#include <glib.h>
#include <glib-object.h>
#include <stdlib.h>
#include <string.h>
#include <glib/gstdio.h>


#define BOXES_TYPE_ICONFIG (boxes_iconfig_get_type ())
#define BOXES_ICONFIG(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), BOXES_TYPE_ICONFIG, BoxesIConfig))
#define BOXES_IS_ICONFIG(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), BOXES_TYPE_ICONFIG))
#define BOXES_ICONFIG_GET_INTERFACE(obj) (G_TYPE_INSTANCE_GET_INTERFACE ((obj), BOXES_TYPE_ICONFIG, BoxesIConfigIface))

typedef struct _BoxesIConfig BoxesIConfig;
typedef struct _BoxesIConfigIface BoxesIConfigIface;
#define _g_free0(var) (var = (g_free (var), NULL))
#define _g_error_free0(var) ((var == NULL) ? NULL : (var = (g_error_free (var), NULL)))

#define BOXES_TYPE_COLLECTION_SOURCE (boxes_collection_source_get_type ())
#define BOXES_COLLECTION_SOURCE(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), BOXES_TYPE_COLLECTION_SOURCE, BoxesCollectionSource))
#define BOXES_COLLECTION_SOURCE_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), BOXES_TYPE_COLLECTION_SOURCE, BoxesCollectionSourceClass))
#define BOXES_IS_COLLECTION_SOURCE(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), BOXES_TYPE_COLLECTION_SOURCE))
#define BOXES_IS_COLLECTION_SOURCE_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), BOXES_TYPE_COLLECTION_SOURCE))
#define BOXES_COLLECTION_SOURCE_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), BOXES_TYPE_COLLECTION_SOURCE, BoxesCollectionSourceClass))

typedef struct _BoxesCollectionSource BoxesCollectionSource;
typedef struct _BoxesCollectionSourceClass BoxesCollectionSourceClass;
typedef struct _BoxesCollectionSourcePrivate BoxesCollectionSourcePrivate;
#define _g_key_file_unref0(var) ((var == NULL) ? NULL : (var = (g_key_file_unref (var), NULL)))
#define _g_object_unref0(var) ((var == NULL) ? NULL : (var = (g_object_unref (var), NULL)))

#define BOXES_TYPE_BOX_CONFIG (boxes_box_config_get_type ())
#define BOXES_BOX_CONFIG(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), BOXES_TYPE_BOX_CONFIG, BoxesBoxConfig))
#define BOXES_BOX_CONFIG_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), BOXES_TYPE_BOX_CONFIG, BoxesBoxConfigClass))
#define BOXES_IS_BOX_CONFIG(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), BOXES_TYPE_BOX_CONFIG))
#define BOXES_IS_BOX_CONFIG_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), BOXES_TYPE_BOX_CONFIG))
#define BOXES_BOX_CONFIG_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), BOXES_TYPE_BOX_CONFIG, BoxesBoxConfigClass))

typedef struct _BoxesBoxConfig BoxesBoxConfig;
typedef struct _BoxesBoxConfigClass BoxesBoxConfigClass;

struct _BoxesIConfigIface {
	GTypeInterface parent_iface;
	GKeyFile* (*get_keyfile) (BoxesIConfig* self);
	const gchar* (*get_filename) (BoxesIConfig* self);
	void (*set_filename) (BoxesIConfig* self, const gchar* value);
	gboolean (*get_has_file) (BoxesIConfig* self);
	void (*set_has_file) (BoxesIConfig* self, gboolean value);
};

typedef enum  {
	BOXES_ERROR_INVALID,
	BOXES_ERROR_RESTORE_FAILED,
	BOXES_ERROR_COMMAND_FAILED
} BoxesError;
#define BOXES_ERROR boxes_error_quark ()
struct _BoxesCollectionSource {
	GObject parent_instance;
	BoxesCollectionSourcePrivate * priv;
};

struct _BoxesCollectionSourceClass {
	GObjectClass parent_class;
};

struct _BoxesCollectionSourcePrivate {
	GKeyFile* _keyfile;
	gboolean _has_file;
	gchar* _filename;
};


static gpointer boxes_collection_source_parent_class = NULL;
static BoxesIConfigIface* boxes_collection_source_boxes_iconfig_parent_iface = NULL;

GType boxes_iconfig_get_type (void) G_GNUC_CONST;
void boxes_iconfig_save (BoxesIConfig* self);
gboolean boxes_keyfile_save (GKeyFile* key_file, const gchar* file_name, gboolean overwrite);
GKeyFile* boxes_iconfig_get_keyfile (BoxesIConfig* self);
gchar* boxes_get_user_pkgconfig_source (const gchar* file_name);
const gchar* boxes_iconfig_get_filename (BoxesIConfig* self);
gboolean boxes_iconfig_get_has_file (BoxesIConfig* self);
void boxes_iconfig_set_has_file (BoxesIConfig* self, gboolean value);
gboolean boxes_iconfig_get_boolean (BoxesIConfig* self, const gchar* group, const gchar* key, gboolean default_value);
void boxes_iconfig_set_boolean (BoxesIConfig* self, const gchar* group, const gchar* key, gboolean value);
void boxes_iconfig_load (BoxesIConfig* self, GError** error);
GQuark boxes_error_quark (void);
gchar* boxes_iconfig_get_string (BoxesIConfig* self, const gchar* group, const gchar* key);
gchar** boxes_iconfig_get_string_list (BoxesIConfig* self, const gchar* group, const gchar* key, int* result_length1);
gchar** boxes_iconfig_get_groups (BoxesIConfig* self, const gchar* with_prefix, int* result_length1);
static void _vala_array_add3 (gchar*** array, int* length, int* size, gchar* value);
void boxes_iconfig_set_filename (BoxesIConfig* self, const gchar* value);
GType boxes_collection_source_get_type (void) G_GNUC_CONST;
#define BOXES_COLLECTION_SOURCE_GET_PRIVATE(o) (G_TYPE_INSTANCE_GET_PRIVATE ((o), BOXES_TYPE_COLLECTION_SOURCE, BoxesCollectionSourcePrivate))
enum  {
	BOXES_COLLECTION_SOURCE_DUMMY_PROPERTY,
	BOXES_COLLECTION_SOURCE_NAME,
	BOXES_COLLECTION_SOURCE_SOURCE_TYPE,
	BOXES_COLLECTION_SOURCE_URI,
	BOXES_COLLECTION_SOURCE_ENABLED
};
BoxesCollectionSource* boxes_collection_source_new (const gchar* name, const gchar* source_type, const gchar* uri);
BoxesCollectionSource* boxes_collection_source_construct (GType object_type, const gchar* name, const gchar* source_type, const gchar* uri);
void boxes_collection_source_set_name (BoxesCollectionSource* self, const gchar* value);
void boxes_collection_source_set_source_type (BoxesCollectionSource* self, const gchar* value);
void boxes_collection_source_set_uri (BoxesCollectionSource* self, const gchar* value);
BoxesCollectionSource* boxes_collection_source_new_with_file (const gchar* filename, GError** error);
BoxesCollectionSource* boxes_collection_source_construct_with_file (GType object_type, const gchar* filename, GError** error);
void boxes_collection_source_delete (BoxesCollectionSource* self);
GType boxes_box_config_get_type (void) G_GNUC_CONST;
void boxes_collection_source_purge_stale_box_configs (BoxesCollectionSource* self, GList* used_configs);
const gchar* boxes_box_config_get_group (BoxesBoxConfig* self);
gchar* boxes_make_filename (const gchar* name);
gchar* boxes_collection_source_get_name (BoxesCollectionSource* self);
gchar* boxes_collection_source_get_source_type (BoxesCollectionSource* self);
gchar* boxes_collection_source_get_uri (BoxesCollectionSource* self);
gboolean boxes_collection_source_get_enabled (BoxesCollectionSource* self);
void boxes_collection_source_set_enabled (BoxesCollectionSource* self, gboolean value);
static GObject * boxes_collection_source_constructor (GType type, guint n_construct_properties, GObjectConstructParam * construct_properties);
static void boxes_collection_source_finalize (GObject* obj);
static void _vala_boxes_collection_source_get_property (GObject * object, guint property_id, GValue * value, GParamSpec * pspec);
static void _vala_boxes_collection_source_set_property (GObject * object, guint property_id, const GValue * value, GParamSpec * pspec);
static void _vala_array_destroy (gpointer array, gint array_length, GDestroyNotify destroy_func);
static void _vala_array_free (gpointer array, gint array_length, GDestroyNotify destroy_func);


void boxes_iconfig_save (BoxesIConfig* self) {
	GKeyFile* _tmp0_ = NULL;
	GKeyFile* _tmp1_ = NULL;
	const gchar* _tmp2_ = NULL;
	const gchar* _tmp3_ = NULL;
	gchar* _tmp4_ = NULL;
	gchar* _tmp5_ = NULL;
	gboolean _tmp6_ = FALSE;
	gboolean _tmp7_ = FALSE;
#line 12 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	_tmp0_ = boxes_iconfig_get_keyfile (self);
#line 12 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	_tmp1_ = _tmp0_;
#line 12 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	_tmp2_ = boxes_iconfig_get_filename (self);
#line 12 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	_tmp3_ = _tmp2_;
#line 12 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	_tmp4_ = boxes_get_user_pkgconfig_source (_tmp3_);
#line 12 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	_tmp5_ = _tmp4_;
#line 12 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	_tmp6_ = boxes_iconfig_get_has_file (self);
#line 12 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	_tmp7_ = _tmp6_;
#line 12 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	boxes_keyfile_save (_tmp1_, _tmp5_, _tmp7_);
#line 12 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	_g_free0 (_tmp5_);
#line 13 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	boxes_iconfig_set_has_file (self, TRUE);
#line 163 "collection-source.c"
}


gboolean boxes_iconfig_get_boolean (BoxesIConfig* self, const gchar* group, const gchar* key, gboolean default_value) {
	gboolean result = FALSE;
	GError * _inner_error_ = NULL;
#line 16 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	g_return_val_if_fail (group != NULL, FALSE);
#line 16 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	g_return_val_if_fail (key != NULL, FALSE);
#line 174 "collection-source.c"
	{
		gboolean _tmp0_ = FALSE;
		GKeyFile* _tmp1_ = NULL;
		GKeyFile* _tmp2_ = NULL;
		const gchar* _tmp3_ = NULL;
		const gchar* _tmp4_ = NULL;
		gboolean _tmp5_ = FALSE;
#line 18 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
		_tmp1_ = boxes_iconfig_get_keyfile (self);
#line 18 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
		_tmp2_ = _tmp1_;
#line 18 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
		_tmp3_ = group;
#line 18 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
		_tmp4_ = key;
#line 18 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
		_tmp5_ = g_key_file_get_boolean (_tmp2_, _tmp3_, _tmp4_, &_inner_error_);
#line 18 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
		_tmp0_ = _tmp5_;
#line 18 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
		if (G_UNLIKELY (_inner_error_ != NULL)) {
#line 18 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
			if (_inner_error_->domain == G_KEY_FILE_ERROR) {
#line 198 "collection-source.c"
				goto __catch2_g_key_file_error;
			}
#line 18 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
			g_critical ("file %s: line %d: unexpected error: %s (%s, %d)", __FILE__, __LINE__, _inner_error_->message, g_quark_to_string (_inner_error_->domain), _inner_error_->code);
#line 18 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
			g_clear_error (&_inner_error_);
#line 18 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
			return FALSE;
#line 207 "collection-source.c"
		}
#line 18 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
		result = _tmp0_;
#line 18 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
		return result;
#line 213 "collection-source.c"
	}
	goto __finally2;
	__catch2_g_key_file_error:
	{
		GError* _error_ = NULL;
		gboolean _tmp6_ = FALSE;
#line 17 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
		_error_ = _inner_error_;
#line 17 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
		_inner_error_ = NULL;
#line 20 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
		_tmp6_ = default_value;
#line 20 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
		result = _tmp6_;
#line 20 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
		_g_error_free0 (_error_);
#line 20 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
		return result;
#line 232 "collection-source.c"
	}
	__finally2:
#line 17 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	g_critical ("file %s: line %d: uncaught error: %s (%s, %d)", __FILE__, __LINE__, _inner_error_->message, g_quark_to_string (_inner_error_->domain), _inner_error_->code);
#line 17 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	g_clear_error (&_inner_error_);
#line 17 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	return FALSE;
#line 241 "collection-source.c"
}


void boxes_iconfig_set_boolean (BoxesIConfig* self, const gchar* group, const gchar* key, gboolean value) {
	GKeyFile* _tmp0_ = NULL;
	GKeyFile* _tmp1_ = NULL;
	const gchar* _tmp2_ = NULL;
	const gchar* _tmp3_ = NULL;
	gboolean _tmp4_ = FALSE;
#line 24 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	g_return_if_fail (group != NULL);
#line 24 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	g_return_if_fail (key != NULL);
#line 25 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	_tmp0_ = boxes_iconfig_get_keyfile (self);
#line 25 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	_tmp1_ = _tmp0_;
#line 25 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	_tmp2_ = group;
#line 25 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	_tmp3_ = key;
#line 25 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	_tmp4_ = value;
#line 25 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	g_key_file_set_boolean (_tmp1_, _tmp2_, _tmp3_, _tmp4_);
#line 267 "collection-source.c"
}


void boxes_iconfig_load (BoxesIConfig* self, GError** error) {
	gboolean _tmp0_ = FALSE;
	gboolean _tmp1_ = FALSE;
	GKeyFile* _tmp3_ = NULL;
	GKeyFile* _tmp4_ = NULL;
	const gchar* _tmp5_ = NULL;
	const gchar* _tmp6_ = NULL;
	gchar* _tmp7_ = NULL;
	gchar* _tmp8_ = NULL;
	GError * _inner_error_ = NULL;
#line 29 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	_tmp0_ = boxes_iconfig_get_has_file (self);
#line 29 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	_tmp1_ = _tmp0_;
#line 29 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	if (!_tmp1_) {
#line 287 "collection-source.c"
		GError* _tmp2_ = NULL;
#line 30 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
		_tmp2_ = g_error_new_literal (BOXES_ERROR, BOXES_ERROR_INVALID, "has_file is false");
#line 30 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
		_inner_error_ = _tmp2_;
#line 30 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
		g_propagate_error (error, _inner_error_);
#line 30 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
		return;
#line 297 "collection-source.c"
	}
#line 32 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	_tmp3_ = boxes_iconfig_get_keyfile (self);
#line 32 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	_tmp4_ = _tmp3_;
#line 32 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	_tmp5_ = boxes_iconfig_get_filename (self);
#line 32 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	_tmp6_ = _tmp5_;
#line 32 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	_tmp7_ = boxes_get_user_pkgconfig_source (_tmp6_);
#line 32 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	_tmp8_ = _tmp7_;
#line 32 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	g_key_file_load_from_file (_tmp4_, _tmp8_, G_KEY_FILE_KEEP_COMMENTS | G_KEY_FILE_KEEP_TRANSLATIONS, &_inner_error_);
#line 32 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	_g_free0 (_tmp8_);
#line 32 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	if (G_UNLIKELY (_inner_error_ != NULL)) {
#line 32 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
		g_propagate_error (error, _inner_error_);
#line 32 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
		return;
#line 321 "collection-source.c"
	}
}


gchar* boxes_iconfig_get_string (BoxesIConfig* self, const gchar* group, const gchar* key) {
	gchar* result = NULL;
	GError * _inner_error_ = NULL;
#line 36 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	g_return_val_if_fail (group != NULL, NULL);
#line 36 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	g_return_val_if_fail (key != NULL, NULL);
#line 333 "collection-source.c"
	{
		gchar* _tmp0_ = NULL;
		GKeyFile* _tmp1_ = NULL;
		GKeyFile* _tmp2_ = NULL;
		const gchar* _tmp3_ = NULL;
		const gchar* _tmp4_ = NULL;
		gchar* _tmp5_ = NULL;
		gchar* _tmp6_ = NULL;
#line 38 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
		_tmp1_ = boxes_iconfig_get_keyfile (self);
#line 38 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
		_tmp2_ = _tmp1_;
#line 38 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
		_tmp3_ = group;
#line 38 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
		_tmp4_ = key;
#line 38 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
		_tmp5_ = g_key_file_get_string (_tmp2_, _tmp3_, _tmp4_, &_inner_error_);
#line 38 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
		_tmp0_ = _tmp5_;
#line 38 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
		if (G_UNLIKELY (_inner_error_ != NULL)) {
#line 38 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
			if (_inner_error_->domain == G_KEY_FILE_ERROR) {
#line 358 "collection-source.c"
				goto __catch3_g_key_file_error;
			}
#line 38 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
			g_critical ("file %s: line %d: unexpected error: %s (%s, %d)", __FILE__, __LINE__, _inner_error_->message, g_quark_to_string (_inner_error_->domain), _inner_error_->code);
#line 38 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
			g_clear_error (&_inner_error_);
#line 38 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
			return NULL;
#line 367 "collection-source.c"
		}
#line 38 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
		_tmp6_ = _tmp0_;
#line 38 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
		_tmp0_ = NULL;
#line 38 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
		result = _tmp6_;
#line 38 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
		_g_free0 (_tmp0_);
#line 38 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
		return result;
#line 379 "collection-source.c"
	}
	goto __finally3;
	__catch3_g_key_file_error:
	{
		GError* _error_ = NULL;
#line 37 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
		_error_ = _inner_error_;
#line 37 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
		_inner_error_ = NULL;
#line 40 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
		result = NULL;
#line 40 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
		_g_error_free0 (_error_);
#line 40 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
		return result;
#line 395 "collection-source.c"
	}
	__finally3:
#line 37 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	g_critical ("file %s: line %d: uncaught error: %s (%s, %d)", __FILE__, __LINE__, _inner_error_->message, g_quark_to_string (_inner_error_->domain), _inner_error_->code);
#line 37 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	g_clear_error (&_inner_error_);
#line 37 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	return NULL;
#line 404 "collection-source.c"
}


gchar** boxes_iconfig_get_string_list (BoxesIConfig* self, const gchar* group, const gchar* key, int* result_length1) {
	gchar** result = NULL;
	GError * _inner_error_ = NULL;
#line 44 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	g_return_val_if_fail (group != NULL, NULL);
#line 44 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	g_return_val_if_fail (key != NULL, NULL);
#line 415 "collection-source.c"
	{
		gchar** _tmp0_ = NULL;
		GKeyFile* _tmp1_ = NULL;
		GKeyFile* _tmp2_ = NULL;
		const gchar* _tmp3_ = NULL;
		const gchar* _tmp4_ = NULL;
		gsize _tmp5_;
		gchar** _tmp6_ = NULL;
		gint _tmp0__length1 = 0;
		gint __tmp0__size_ = 0;
		gchar** _tmp7_ = NULL;
		gint _tmp7__length1 = 0;
		gchar** _tmp8_ = NULL;
		gint _tmp8__length1 = 0;
#line 46 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
		_tmp1_ = boxes_iconfig_get_keyfile (self);
#line 46 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
		_tmp2_ = _tmp1_;
#line 46 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
		_tmp3_ = group;
#line 46 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
		_tmp4_ = key;
#line 46 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
		_tmp6_ = g_key_file_get_string_list (_tmp2_, _tmp3_, _tmp4_, &_tmp5_, &_inner_error_);
#line 46 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
		_tmp0_ = _tmp6_;
#line 46 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
		_tmp0__length1 = _tmp5_;
#line 46 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
		__tmp0__size_ = _tmp0__length1;
#line 46 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
		if (G_UNLIKELY (_inner_error_ != NULL)) {
#line 46 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
			if (_inner_error_->domain == G_KEY_FILE_ERROR) {
#line 450 "collection-source.c"
				goto __catch4_g_key_file_error;
			}
#line 46 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
			g_critical ("file %s: line %d: unexpected error: %s (%s, %d)", __FILE__, __LINE__, _inner_error_->message, g_quark_to_string (_inner_error_->domain), _inner_error_->code);
#line 46 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
			g_clear_error (&_inner_error_);
#line 46 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
			return NULL;
#line 459 "collection-source.c"
		}
#line 46 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
		_tmp7_ = _tmp0_;
#line 46 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
		_tmp7__length1 = _tmp0__length1;
#line 46 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
		_tmp0_ = NULL;
#line 46 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
		_tmp0__length1 = 0;
#line 46 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
		_tmp8_ = _tmp7_;
#line 46 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
		_tmp8__length1 = _tmp7__length1;
#line 46 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
		if (result_length1) {
#line 46 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
			*result_length1 = _tmp8__length1;
#line 477 "collection-source.c"
		}
#line 46 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
		result = _tmp8_;
#line 46 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
		_tmp0_ = (_vala_array_free (_tmp0_, _tmp0__length1, (GDestroyNotify) g_free), NULL);
#line 46 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
		return result;
#line 485 "collection-source.c"
	}
	goto __finally4;
	__catch4_g_key_file_error:
	{
		GError* _error_ = NULL;
		gchar** _tmp9_ = NULL;
		gint _tmp9__length1 = 0;
#line 45 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
		_error_ = _inner_error_;
#line 45 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
		_inner_error_ = NULL;
#line 48 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
		_tmp9_ = NULL;
#line 48 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
		_tmp9__length1 = 0;
#line 48 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
		if (result_length1) {
#line 48 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
			*result_length1 = _tmp9__length1;
#line 505 "collection-source.c"
		}
#line 48 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
		result = _tmp9_;
#line 48 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
		_g_error_free0 (_error_);
#line 48 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
		return result;
#line 513 "collection-source.c"
	}
	__finally4:
#line 45 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	g_critical ("file %s: line %d: uncaught error: %s (%s, %d)", __FILE__, __LINE__, _inner_error_->message, g_quark_to_string (_inner_error_->domain), _inner_error_->code);
#line 45 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	g_clear_error (&_inner_error_);
#line 45 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	return NULL;
#line 522 "collection-source.c"
}


static void _vala_array_add3 (gchar*** array, int* length, int* size, gchar* value) {
#line 59 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	if ((*length) == (*size)) {
#line 59 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
		*size = (*size) ? (2 * (*size)) : 4;
#line 59 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
		*array = g_renew (gchar*, *array, (*size) + 1);
#line 533 "collection-source.c"
	}
#line 59 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	(*array)[(*length)++] = value;
#line 59 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	(*array)[*length] = NULL;
#line 539 "collection-source.c"
}


gchar** boxes_iconfig_get_groups (BoxesIConfig* self, const gchar* with_prefix, int* result_length1) {
	gchar** result = NULL;
	gchar** groups = NULL;
	gchar** _tmp0_ = NULL;
	gint groups_length1 = 0;
	gint _groups_size_ = 0;
	GKeyFile* _tmp1_ = NULL;
	GKeyFile* _tmp2_ = NULL;
	gsize _tmp3_;
	gchar** _tmp4_ = NULL;
	gchar** _tmp12_ = NULL;
	gint _tmp12__length1 = 0;
#line 52 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	g_return_val_if_fail (with_prefix != NULL, NULL);
#line 53 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	_tmp0_ = g_new0 (gchar*, 0 + 1);
#line 53 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	groups = _tmp0_;
#line 53 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	groups_length1 = 0;
#line 53 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	_groups_size_ = groups_length1;
#line 55 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	_tmp1_ = boxes_iconfig_get_keyfile (self);
#line 55 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	_tmp2_ = _tmp1_;
#line 55 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	_tmp4_ = g_key_file_get_groups (_tmp2_, &_tmp3_);
#line 571 "collection-source.c"
	{
		gchar** group_collection = NULL;
		gint group_collection_length1 = 0;
		gint _group_collection_size_ = 0;
		gint group_it = 0;
#line 55 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
		group_collection = _tmp4_;
#line 55 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
		group_collection_length1 = _tmp3_;
#line 55 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
		for (group_it = 0; group_it < _tmp3_; group_it = group_it + 1) {
#line 583 "collection-source.c"
			gchar* _tmp5_ = NULL;
			gchar* group = NULL;
#line 55 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
			_tmp5_ = g_strdup (group_collection[group_it]);
#line 55 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
			group = _tmp5_;
#line 590 "collection-source.c"
			{
				const gchar* _tmp6_ = NULL;
				const gchar* _tmp7_ = NULL;
				gboolean _tmp8_ = FALSE;
				gchar** _tmp9_ = NULL;
				gint _tmp9__length1 = 0;
				const gchar* _tmp10_ = NULL;
				gchar* _tmp11_ = NULL;
#line 56 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
				_tmp6_ = group;
#line 56 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
				_tmp7_ = with_prefix;
#line 56 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
				_tmp8_ = g_str_has_prefix (_tmp6_, _tmp7_);
#line 56 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
				if (!_tmp8_) {
#line 57 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
					_g_free0 (group);
#line 57 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
					continue;
#line 611 "collection-source.c"
				}
#line 59 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
				_tmp9_ = groups;
#line 59 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
				_tmp9__length1 = groups_length1;
#line 59 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
				_tmp10_ = group;
#line 59 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
				_tmp11_ = g_strdup (_tmp10_);
#line 59 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
				_vala_array_add3 (&groups, &groups_length1, &_groups_size_, _tmp11_);
#line 55 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
				_g_free0 (group);
#line 625 "collection-source.c"
			}
		}
#line 55 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
		group_collection = (_vala_array_free (group_collection, group_collection_length1, (GDestroyNotify) g_free), NULL);
#line 630 "collection-source.c"
	}
#line 62 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	_tmp12_ = groups;
#line 62 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	_tmp12__length1 = groups_length1;
#line 62 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	if (result_length1) {
#line 62 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
		*result_length1 = _tmp12__length1;
#line 640 "collection-source.c"
	}
#line 62 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	result = _tmp12_;
#line 62 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	return result;
#line 646 "collection-source.c"
}


GKeyFile* boxes_iconfig_get_keyfile (BoxesIConfig* self) {
#line 5 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	g_return_val_if_fail (self != NULL, NULL);
#line 5 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	return BOXES_ICONFIG_GET_INTERFACE (self)->get_keyfile (self);
#line 655 "collection-source.c"
}


const gchar* boxes_iconfig_get_filename (BoxesIConfig* self) {
#line 6 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	g_return_val_if_fail (self != NULL, NULL);
#line 6 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	return BOXES_ICONFIG_GET_INTERFACE (self)->get_filename (self);
#line 664 "collection-source.c"
}


void boxes_iconfig_set_filename (BoxesIConfig* self, const gchar* value) {
#line 6 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	g_return_if_fail (self != NULL);
#line 6 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	BOXES_ICONFIG_GET_INTERFACE (self)->set_filename (self, value);
#line 673 "collection-source.c"
}


gboolean boxes_iconfig_get_has_file (BoxesIConfig* self) {
#line 7 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	g_return_val_if_fail (self != NULL, FALSE);
#line 7 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	return BOXES_ICONFIG_GET_INTERFACE (self)->get_has_file (self);
#line 682 "collection-source.c"
}


void boxes_iconfig_set_has_file (BoxesIConfig* self, gboolean value) {
#line 7 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	g_return_if_fail (self != NULL);
#line 7 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	BOXES_ICONFIG_GET_INTERFACE (self)->set_has_file (self, value);
#line 691 "collection-source.c"
}


static void boxes_iconfig_base_init (BoxesIConfigIface * iface) {
#line 3 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	static gboolean initialized = FALSE;
#line 3 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	if (!initialized) {
#line 3 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
		initialized = TRUE;
#line 702 "collection-source.c"
	}
}


GType boxes_iconfig_get_type (void) {
	static volatile gsize boxes_iconfig_type_id__volatile = 0;
	if (g_once_init_enter (&boxes_iconfig_type_id__volatile)) {
		static const GTypeInfo g_define_type_info = { sizeof (BoxesIConfigIface), (GBaseInitFunc) boxes_iconfig_base_init, (GBaseFinalizeFunc) NULL, (GClassInitFunc) NULL, (GClassFinalizeFunc) NULL, NULL, 0, 0, (GInstanceInitFunc) NULL, NULL };
		GType boxes_iconfig_type_id;
		boxes_iconfig_type_id = g_type_register_static (G_TYPE_INTERFACE, "BoxesIConfig", &g_define_type_info, 0);
		g_once_init_leave (&boxes_iconfig_type_id__volatile, boxes_iconfig_type_id);
	}
	return boxes_iconfig_type_id__volatile;
}


BoxesCollectionSource* boxes_collection_source_construct (GType object_type, const gchar* name, const gchar* source_type, const gchar* uri) {
	BoxesCollectionSource * self = NULL;
	const gchar* _tmp0_ = NULL;
	const gchar* _tmp1_ = NULL;
	const gchar* _tmp2_ = NULL;
#line 110 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	g_return_val_if_fail (name != NULL, NULL);
#line 110 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	g_return_val_if_fail (source_type != NULL, NULL);
#line 110 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	g_return_val_if_fail (uri != NULL, NULL);
#line 110 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	self = (BoxesCollectionSource*) g_object_new (object_type, NULL);
#line 111 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	_tmp0_ = name;
#line 111 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	boxes_collection_source_set_name (self, _tmp0_);
#line 112 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	_tmp1_ = source_type;
#line 112 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	boxes_collection_source_set_source_type (self, _tmp1_);
#line 113 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	_tmp2_ = uri;
#line 113 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	boxes_collection_source_set_uri (self, _tmp2_);
#line 110 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	return self;
#line 746 "collection-source.c"
}


BoxesCollectionSource* boxes_collection_source_new (const gchar* name, const gchar* source_type, const gchar* uri) {
#line 110 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	return boxes_collection_source_construct (BOXES_TYPE_COLLECTION_SOURCE, name, source_type, uri);
#line 753 "collection-source.c"
}


BoxesCollectionSource* boxes_collection_source_construct_with_file (GType object_type, const gchar* filename, GError** error) {
	BoxesCollectionSource * self = NULL;
	const gchar* _tmp0_ = NULL;
	GError * _inner_error_ = NULL;
#line 116 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	g_return_val_if_fail (filename != NULL, NULL);
#line 116 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	self = (BoxesCollectionSource*) g_object_new (object_type, NULL);
#line 117 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	_tmp0_ = filename;
#line 117 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	boxes_iconfig_set_filename ((BoxesIConfig*) self, _tmp0_);
#line 118 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	boxes_iconfig_set_has_file ((BoxesIConfig*) self, TRUE);
#line 119 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	boxes_iconfig_load ((BoxesIConfig*) self, &_inner_error_);
#line 119 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	if (G_UNLIKELY (_inner_error_ != NULL)) {
#line 119 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
		g_propagate_error (error, _inner_error_);
#line 119 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
		_g_object_unref0 (self);
#line 119 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
		return NULL;
#line 781 "collection-source.c"
	}
#line 116 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	return self;
#line 785 "collection-source.c"
}


BoxesCollectionSource* boxes_collection_source_new_with_file (const gchar* filename, GError** error) {
#line 116 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	return boxes_collection_source_construct_with_file (BOXES_TYPE_COLLECTION_SOURCE, filename, error);
#line 792 "collection-source.c"
}


void boxes_collection_source_delete (BoxesCollectionSource* self) {
	gboolean _tmp0_ = FALSE;
	gboolean _tmp1_ = FALSE;
	const gchar* _tmp2_ = NULL;
	const gchar* _tmp3_ = NULL;
	gchar* _tmp4_ = NULL;
	gchar* _tmp5_ = NULL;
#line 122 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	g_return_if_fail (self != NULL);
#line 123 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	_tmp0_ = boxes_iconfig_get_has_file ((BoxesIConfig*) self);
#line 123 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	_tmp1_ = _tmp0_;
#line 123 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	if (!_tmp1_) {
#line 124 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
		return;
#line 813 "collection-source.c"
	}
#line 126 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	_tmp2_ = boxes_iconfig_get_filename ((BoxesIConfig*) self);
#line 126 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	_tmp3_ = _tmp2_;
#line 126 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	_tmp4_ = boxes_get_user_pkgconfig_source (_tmp3_);
#line 126 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	_tmp5_ = _tmp4_;
#line 126 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	g_unlink (_tmp5_);
#line 126 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	_g_free0 (_tmp5_);
#line 127 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	boxes_iconfig_set_has_file ((BoxesIConfig*) self, FALSE);
#line 829 "collection-source.c"
}


static gpointer _g_object_ref0 (gpointer self) {
#line 136 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	return self ? g_object_ref (self) : NULL;
#line 836 "collection-source.c"
}


void boxes_collection_source_purge_stale_box_configs (BoxesCollectionSource* self, GList* used_configs) {
	GKeyFile* _tmp0_ = NULL;
	GKeyFile* _tmp1_ = NULL;
	gsize _tmp2_;
	gchar** _tmp3_ = NULL;
	GError * _inner_error_ = NULL;
#line 130 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	g_return_if_fail (self != NULL);
#line 131 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	_tmp0_ = boxes_iconfig_get_keyfile ((BoxesIConfig*) self);
#line 131 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	_tmp1_ = _tmp0_;
#line 131 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	_tmp3_ = g_key_file_get_groups (_tmp1_, &_tmp2_);
#line 854 "collection-source.c"
	{
		gchar** group_collection = NULL;
		gint group_collection_length1 = 0;
		gint _group_collection_size_ = 0;
		gint group_it = 0;
#line 131 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
		group_collection = _tmp3_;
#line 131 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
		group_collection_length1 = _tmp2_;
#line 131 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
		for (group_it = 0; group_it < _tmp2_; group_it = group_it + 1) {
#line 866 "collection-source.c"
			gchar* _tmp4_ = NULL;
			gchar* group = NULL;
#line 131 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
			_tmp4_ = g_strdup (group_collection[group_it]);
#line 131 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
			group = _tmp4_;
#line 873 "collection-source.c"
			{
				const gchar* _tmp5_ = NULL;
				gboolean stale = FALSE;
				GList* _tmp6_ = NULL;
				gboolean _tmp12_ = FALSE;
#line 132 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
				_tmp5_ = group;
#line 132 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
				if (g_strcmp0 (_tmp5_, "source") == 0) {
#line 133 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
					_g_free0 (group);
#line 133 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
					continue;
#line 887 "collection-source.c"
				}
#line 135 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
				stale = TRUE;
#line 136 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
				_tmp6_ = used_configs;
#line 893 "collection-source.c"
				{
					GList* config_collection = NULL;
					GList* config_it = NULL;
#line 136 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
					config_collection = _tmp6_;
#line 136 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
					for (config_it = config_collection; config_it != NULL; config_it = config_it->next) {
#line 901 "collection-source.c"
						BoxesBoxConfig* _tmp7_ = NULL;
						BoxesBoxConfig* config = NULL;
#line 136 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
						_tmp7_ = _g_object_ref0 ((BoxesBoxConfig*) config_it->data);
#line 136 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
						config = _tmp7_;
#line 908 "collection-source.c"
						{
							BoxesBoxConfig* _tmp8_ = NULL;
							const gchar* _tmp9_ = NULL;
							const gchar* _tmp10_ = NULL;
							const gchar* _tmp11_ = NULL;
#line 137 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
							_tmp8_ = config;
#line 137 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
							_tmp9_ = boxes_box_config_get_group (_tmp8_);
#line 137 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
							_tmp10_ = _tmp9_;
#line 137 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
							_tmp11_ = group;
#line 137 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
							if (g_strcmp0 (_tmp10_, _tmp11_) == 0) {
#line 138 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
								stale = FALSE;
#line 140 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
								_g_object_unref0 (config);
#line 140 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
								break;
#line 930 "collection-source.c"
							}
#line 136 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
							_g_object_unref0 (config);
#line 934 "collection-source.c"
						}
					}
				}
#line 144 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
				_tmp12_ = stale;
#line 144 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
				if (_tmp12_) {
#line 942 "collection-source.c"
					{
						GKeyFile* _tmp13_ = NULL;
						GKeyFile* _tmp14_ = NULL;
						const gchar* _tmp15_ = NULL;
						const gchar* _tmp16_ = NULL;
#line 146 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
						_tmp13_ = boxes_iconfig_get_keyfile ((BoxesIConfig*) self);
#line 146 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
						_tmp14_ = _tmp13_;
#line 146 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
						_tmp15_ = group;
#line 146 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
						g_key_file_remove_group (_tmp14_, _tmp15_, &_inner_error_);
#line 146 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
						if (G_UNLIKELY (_inner_error_ != NULL)) {
#line 958 "collection-source.c"
							goto __catch5_g_error;
						}
#line 147 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
						_tmp16_ = group;
#line 147 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
						g_debug ("collection-source.vala:147: Removed stale box config '%s'", _tmp16_);
#line 965 "collection-source.c"
					}
					goto __finally5;
					__catch5_g_error:
					{
						GError* e = NULL;
						const gchar* _tmp17_ = NULL;
						GError* _tmp18_ = NULL;
						const gchar* _tmp19_ = NULL;
#line 145 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
						e = _inner_error_;
#line 145 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
						_inner_error_ = NULL;
#line 149 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
						_tmp17_ = group;
#line 149 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
						_tmp18_ = e;
#line 149 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
						_tmp19_ = _tmp18_->message;
#line 149 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
						g_debug ("collection-source.vala:149: Error removing stale stale box config '%s'" \
": %s", _tmp17_, _tmp19_);
#line 145 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
						_g_error_free0 (e);
#line 988 "collection-source.c"
					}
					__finally5:
#line 145 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
					if (G_UNLIKELY (_inner_error_ != NULL)) {
#line 145 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
						_g_free0 (group);
#line 145 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
						group_collection = (_vala_array_free (group_collection, group_collection_length1, (GDestroyNotify) g_free), NULL);
#line 145 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
						g_critical ("file %s: line %d: uncaught error: %s (%s, %d)", __FILE__, __LINE__, _inner_error_->message, g_quark_to_string (_inner_error_->domain), _inner_error_->code);
#line 145 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
						g_clear_error (&_inner_error_);
#line 145 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
						return;
#line 1003 "collection-source.c"
					}
				}
#line 131 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
				_g_free0 (group);
#line 1008 "collection-source.c"
			}
		}
#line 131 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
		group_collection = (_vala_array_free (group_collection, group_collection_length1, (GDestroyNotify) g_free), NULL);
#line 1013 "collection-source.c"
	}
#line 154 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	boxes_iconfig_save ((BoxesIConfig*) self);
#line 1017 "collection-source.c"
}


static GKeyFile* boxes_collection_source_real_get_keyfile (BoxesIConfig* base) {
	GKeyFile* result;
	BoxesCollectionSource* self;
	GKeyFile* _tmp0_ = NULL;
#line 68 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	self = (BoxesCollectionSource*) base;
#line 68 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	_tmp0_ = self->priv->_keyfile;
#line 68 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	result = _tmp0_;
#line 68 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	return result;
#line 1033 "collection-source.c"
}


static gboolean boxes_collection_source_real_get_has_file (BoxesIConfig* base) {
	gboolean result;
	BoxesCollectionSource* self;
	gboolean _tmp0_ = FALSE;
#line 70 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	self = (BoxesCollectionSource*) base;
#line 70 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	_tmp0_ = self->priv->_has_file;
#line 70 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	result = _tmp0_;
#line 70 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	return result;
#line 1049 "collection-source.c"
}


static void boxes_collection_source_real_set_has_file (BoxesIConfig* base, gboolean value) {
	BoxesCollectionSource* self;
	gboolean _tmp0_ = FALSE;
#line 70 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	self = (BoxesCollectionSource*) base;
#line 70 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	_tmp0_ = value;
#line 70 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	self->priv->_has_file = _tmp0_;
#line 1062 "collection-source.c"
}


static const gchar* boxes_collection_source_real_get_filename (BoxesIConfig* base) {
	const gchar* result;
	BoxesCollectionSource* self;
	const gchar* _tmp0_ = NULL;
	const gchar* _tmp5_ = NULL;
#line 74 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	self = (BoxesCollectionSource*) base;
#line 75 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	_tmp0_ = self->priv->_filename;
#line 75 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	if (_tmp0_ == NULL) {
#line 1077 "collection-source.c"
		gchar* _tmp1_ = NULL;
		gchar* _tmp2_ = NULL;
		gchar* _tmp3_ = NULL;
		gchar* _tmp4_ = NULL;
#line 76 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
		_tmp1_ = boxes_collection_source_get_name (self);
#line 76 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
		_tmp2_ = _tmp1_;
#line 76 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
		_tmp3_ = _tmp2_;
#line 76 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
		_tmp4_ = boxes_make_filename (_tmp3_);
#line 76 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
		_g_free0 (self->priv->_filename);
#line 76 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
		self->priv->_filename = _tmp4_;
#line 76 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
		_g_free0 (_tmp3_);
#line 1096 "collection-source.c"
	}
#line 77 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	_tmp5_ = self->priv->_filename;
#line 77 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	result = _tmp5_;
#line 77 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	return result;
#line 1104 "collection-source.c"
}


static void boxes_collection_source_real_set_filename (BoxesIConfig* base, const gchar* value) {
	BoxesCollectionSource* self;
	const gchar* _tmp0_ = NULL;
	gchar* _tmp1_ = NULL;
#line 79 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	self = (BoxesCollectionSource*) base;
#line 79 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	_tmp0_ = value;
#line 79 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	_tmp1_ = g_strdup (_tmp0_);
#line 79 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	_g_free0 (self->priv->_filename);
#line 79 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	self->priv->_filename = _tmp1_;
#line 1122 "collection-source.c"
}


gchar* boxes_collection_source_get_name (BoxesCollectionSource* self) {
	gchar* result;
	gchar* _tmp0_ = NULL;
#line 83 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	g_return_val_if_fail (self != NULL, NULL);
#line 83 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	_tmp0_ = boxes_iconfig_get_string ((BoxesIConfig*) self, "source", "name");
#line 83 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	result = _tmp0_;
#line 83 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	return result;
#line 1137 "collection-source.c"
}


void boxes_collection_source_set_name (BoxesCollectionSource* self, const gchar* value) {
	GKeyFile* _tmp0_ = NULL;
	GKeyFile* _tmp1_ = NULL;
	const gchar* _tmp2_ = NULL;
	gboolean had_file = FALSE;
	gboolean _tmp3_ = FALSE;
	gboolean _tmp4_ = FALSE;
	gboolean _tmp5_ = FALSE;
#line 84 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	g_return_if_fail (self != NULL);
#line 85 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	_tmp0_ = boxes_iconfig_get_keyfile ((BoxesIConfig*) self);
#line 85 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	_tmp1_ = _tmp0_;
#line 85 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	_tmp2_ = value;
#line 85 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	g_key_file_set_string (_tmp1_, "source", "name", _tmp2_);
#line 86 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	_tmp3_ = boxes_iconfig_get_has_file ((BoxesIConfig*) self);
#line 86 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	_tmp4_ = _tmp3_;
#line 86 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	had_file = _tmp4_;
#line 87 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	boxes_collection_source_delete (self);
#line 88 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	_g_free0 (self->priv->_filename);
#line 88 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	self->priv->_filename = NULL;
#line 89 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	_tmp5_ = had_file;
#line 89 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	if (_tmp5_) {
#line 90 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
		boxes_iconfig_save ((BoxesIConfig*) self);
#line 1177 "collection-source.c"
	}
#line 84 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	g_object_notify ((GObject *) self, "name");
#line 1181 "collection-source.c"
}


gchar* boxes_collection_source_get_source_type (BoxesCollectionSource* self) {
	gchar* result;
	gchar* _tmp0_ = NULL;
#line 94 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	g_return_val_if_fail (self != NULL, NULL);
#line 94 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	_tmp0_ = boxes_iconfig_get_string ((BoxesIConfig*) self, "source", "type");
#line 94 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	result = _tmp0_;
#line 94 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	return result;
#line 1196 "collection-source.c"
}


void boxes_collection_source_set_source_type (BoxesCollectionSource* self, const gchar* value) {
	GKeyFile* _tmp0_ = NULL;
	GKeyFile* _tmp1_ = NULL;
	const gchar* _tmp2_ = NULL;
#line 95 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	g_return_if_fail (self != NULL);
#line 95 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	_tmp0_ = boxes_iconfig_get_keyfile ((BoxesIConfig*) self);
#line 95 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	_tmp1_ = _tmp0_;
#line 95 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	_tmp2_ = value;
#line 95 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	g_key_file_set_string (_tmp1_, "source", "type", _tmp2_);
#line 95 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	g_object_notify ((GObject *) self, "source-type");
#line 1216 "collection-source.c"
}


gchar* boxes_collection_source_get_uri (BoxesCollectionSource* self) {
	gchar* result;
	gchar* _tmp0_ = NULL;
#line 98 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	g_return_val_if_fail (self != NULL, NULL);
#line 98 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	_tmp0_ = boxes_iconfig_get_string ((BoxesIConfig*) self, "source", "uri");
#line 98 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	result = _tmp0_;
#line 98 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	return result;
#line 1231 "collection-source.c"
}


void boxes_collection_source_set_uri (BoxesCollectionSource* self, const gchar* value) {
	GKeyFile* _tmp0_ = NULL;
	GKeyFile* _tmp1_ = NULL;
	const gchar* _tmp2_ = NULL;
#line 99 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	g_return_if_fail (self != NULL);
#line 99 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	_tmp0_ = boxes_iconfig_get_keyfile ((BoxesIConfig*) self);
#line 99 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	_tmp1_ = _tmp0_;
#line 99 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	_tmp2_ = value;
#line 99 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	g_key_file_set_string (_tmp1_, "source", "uri", _tmp2_);
#line 99 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	g_object_notify ((GObject *) self, "uri");
#line 1251 "collection-source.c"
}


gboolean boxes_collection_source_get_enabled (BoxesCollectionSource* self) {
	gboolean result;
	gboolean _tmp0_ = FALSE;
#line 102 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	g_return_val_if_fail (self != NULL, FALSE);
#line 102 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	_tmp0_ = boxes_iconfig_get_boolean ((BoxesIConfig*) self, "source", "enabled", TRUE);
#line 102 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	result = _tmp0_;
#line 102 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	return result;
#line 1266 "collection-source.c"
}


void boxes_collection_source_set_enabled (BoxesCollectionSource* self, gboolean value) {
	gboolean _tmp0_ = FALSE;
#line 103 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	g_return_if_fail (self != NULL);
#line 103 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	_tmp0_ = value;
#line 103 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	boxes_iconfig_set_boolean ((BoxesIConfig*) self, "source", "enabled", _tmp0_);
#line 103 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	g_object_notify ((GObject *) self, "enabled");
#line 1280 "collection-source.c"
}


static GObject * boxes_collection_source_constructor (GType type, guint n_construct_properties, GObjectConstructParam * construct_properties) {
	GObject * obj;
	GObjectClass * parent_class;
	BoxesCollectionSource * self;
	GKeyFile* _tmp0_ = NULL;
#line 106 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	parent_class = G_OBJECT_CLASS (boxes_collection_source_parent_class);
#line 106 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	obj = parent_class->constructor (type, n_construct_properties, construct_properties);
#line 106 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	self = G_TYPE_CHECK_INSTANCE_CAST (obj, BOXES_TYPE_COLLECTION_SOURCE, BoxesCollectionSource);
#line 107 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	_tmp0_ = g_key_file_new ();
#line 107 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	_g_key_file_unref0 (self->priv->_keyfile);
#line 107 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	self->priv->_keyfile = _tmp0_;
#line 106 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	return obj;
#line 1303 "collection-source.c"
}


static void boxes_collection_source_class_init (BoxesCollectionSourceClass * klass) {
#line 66 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	boxes_collection_source_parent_class = g_type_class_peek_parent (klass);
#line 66 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	g_type_class_add_private (klass, sizeof (BoxesCollectionSourcePrivate));
#line 66 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	G_OBJECT_CLASS (klass)->get_property = _vala_boxes_collection_source_get_property;
#line 66 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	G_OBJECT_CLASS (klass)->set_property = _vala_boxes_collection_source_set_property;
#line 66 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	G_OBJECT_CLASS (klass)->constructor = boxes_collection_source_constructor;
#line 66 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	G_OBJECT_CLASS (klass)->finalize = boxes_collection_source_finalize;
#line 66 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	g_object_class_install_property (G_OBJECT_CLASS (klass), BOXES_COLLECTION_SOURCE_NAME, g_param_spec_string ("name", "name", "name", NULL, G_PARAM_STATIC_NAME | G_PARAM_STATIC_NICK | G_PARAM_STATIC_BLURB | G_PARAM_READABLE | G_PARAM_WRITABLE));
#line 66 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	g_object_class_install_property (G_OBJECT_CLASS (klass), BOXES_COLLECTION_SOURCE_SOURCE_TYPE, g_param_spec_string ("source-type", "source-type", "source-type", NULL, G_PARAM_STATIC_NAME | G_PARAM_STATIC_NICK | G_PARAM_STATIC_BLURB | G_PARAM_READABLE | G_PARAM_WRITABLE));
#line 66 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	g_object_class_install_property (G_OBJECT_CLASS (klass), BOXES_COLLECTION_SOURCE_URI, g_param_spec_string ("uri", "uri", "uri", NULL, G_PARAM_STATIC_NAME | G_PARAM_STATIC_NICK | G_PARAM_STATIC_BLURB | G_PARAM_READABLE | G_PARAM_WRITABLE));
#line 66 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	g_object_class_install_property (G_OBJECT_CLASS (klass), BOXES_COLLECTION_SOURCE_ENABLED, g_param_spec_boolean ("enabled", "enabled", "enabled", FALSE, G_PARAM_STATIC_NAME | G_PARAM_STATIC_NICK | G_PARAM_STATIC_BLURB | G_PARAM_READABLE | G_PARAM_WRITABLE));
#line 1328 "collection-source.c"
}


static void boxes_collection_source_boxes_iconfig_interface_init (BoxesIConfigIface * iface) {
#line 66 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	boxes_collection_source_boxes_iconfig_parent_iface = g_type_interface_peek_parent (iface);
#line 66 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	iface->get_keyfile = boxes_collection_source_real_get_keyfile;
#line 66 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	iface->get_has_file = boxes_collection_source_real_get_has_file;
#line 66 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	iface->set_has_file = boxes_collection_source_real_set_has_file;
#line 66 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	iface->get_filename = boxes_collection_source_real_get_filename;
#line 66 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	iface->set_filename = boxes_collection_source_real_set_filename;
#line 1345 "collection-source.c"
}


static void boxes_collection_source_instance_init (BoxesCollectionSource * self) {
#line 66 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	self->priv = BOXES_COLLECTION_SOURCE_GET_PRIVATE (self);
#line 1352 "collection-source.c"
}


static void boxes_collection_source_finalize (GObject* obj) {
	BoxesCollectionSource * self;
#line 66 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	self = G_TYPE_CHECK_INSTANCE_CAST (obj, BOXES_TYPE_COLLECTION_SOURCE, BoxesCollectionSource);
#line 67 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	_g_key_file_unref0 (self->priv->_keyfile);
#line 72 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	_g_free0 (self->priv->_filename);
#line 66 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	G_OBJECT_CLASS (boxes_collection_source_parent_class)->finalize (obj);
#line 1366 "collection-source.c"
}


GType boxes_collection_source_get_type (void) {
	static volatile gsize boxes_collection_source_type_id__volatile = 0;
	if (g_once_init_enter (&boxes_collection_source_type_id__volatile)) {
		static const GTypeInfo g_define_type_info = { sizeof (BoxesCollectionSourceClass), (GBaseInitFunc) NULL, (GBaseFinalizeFunc) NULL, (GClassInitFunc) boxes_collection_source_class_init, (GClassFinalizeFunc) NULL, NULL, sizeof (BoxesCollectionSource), 0, (GInstanceInitFunc) boxes_collection_source_instance_init, NULL };
		static const GInterfaceInfo boxes_iconfig_info = { (GInterfaceInitFunc) boxes_collection_source_boxes_iconfig_interface_init, (GInterfaceFinalizeFunc) NULL, NULL};
		GType boxes_collection_source_type_id;
		boxes_collection_source_type_id = g_type_register_static (G_TYPE_OBJECT, "BoxesCollectionSource", &g_define_type_info, 0);
		g_type_add_interface_static (boxes_collection_source_type_id, BOXES_TYPE_ICONFIG, &boxes_iconfig_info);
		g_once_init_leave (&boxes_collection_source_type_id__volatile, boxes_collection_source_type_id);
	}
	return boxes_collection_source_type_id__volatile;
}


static void _vala_boxes_collection_source_get_property (GObject * object, guint property_id, GValue * value, GParamSpec * pspec) {
	BoxesCollectionSource * self;
	self = G_TYPE_CHECK_INSTANCE_CAST (object, BOXES_TYPE_COLLECTION_SOURCE, BoxesCollectionSource);
#line 66 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	switch (property_id) {
#line 66 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
		case BOXES_COLLECTION_SOURCE_NAME:
#line 66 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
		g_value_take_string (value, boxes_collection_source_get_name (self));
#line 66 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
		break;
#line 66 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
		case BOXES_COLLECTION_SOURCE_SOURCE_TYPE:
#line 66 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
		g_value_take_string (value, boxes_collection_source_get_source_type (self));
#line 66 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
		break;
#line 66 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
		case BOXES_COLLECTION_SOURCE_URI:
#line 66 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
		g_value_take_string (value, boxes_collection_source_get_uri (self));
#line 66 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
		break;
#line 66 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
		case BOXES_COLLECTION_SOURCE_ENABLED:
#line 66 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
		g_value_set_boolean (value, boxes_collection_source_get_enabled (self));
#line 66 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
		break;
#line 1413 "collection-source.c"
		default:
#line 66 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
		G_OBJECT_WARN_INVALID_PROPERTY_ID (object, property_id, pspec);
#line 66 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
		break;
#line 1419 "collection-source.c"
	}
}


static void _vala_boxes_collection_source_set_property (GObject * object, guint property_id, const GValue * value, GParamSpec * pspec) {
	BoxesCollectionSource * self;
	self = G_TYPE_CHECK_INSTANCE_CAST (object, BOXES_TYPE_COLLECTION_SOURCE, BoxesCollectionSource);
#line 66 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
	switch (property_id) {
#line 66 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
		case BOXES_COLLECTION_SOURCE_NAME:
#line 66 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
		boxes_collection_source_set_name (self, g_value_get_string (value));
#line 66 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
		break;
#line 66 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
		case BOXES_COLLECTION_SOURCE_SOURCE_TYPE:
#line 66 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
		boxes_collection_source_set_source_type (self, g_value_get_string (value));
#line 66 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
		break;
#line 66 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
		case BOXES_COLLECTION_SOURCE_URI:
#line 66 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
		boxes_collection_source_set_uri (self, g_value_get_string (value));
#line 66 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
		break;
#line 66 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
		case BOXES_COLLECTION_SOURCE_ENABLED:
#line 66 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
		boxes_collection_source_set_enabled (self, g_value_get_boolean (value));
#line 66 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
		break;
#line 1453 "collection-source.c"
		default:
#line 66 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
		G_OBJECT_WARN_INVALID_PROPERTY_ID (object, property_id, pspec);
#line 66 "/home/zeenix/checkout/gnome/gnome-boxes/src/collection-source.vala"
		break;
#line 1459 "collection-source.c"
	}
}


static void _vala_array_destroy (gpointer array, gint array_length, GDestroyNotify destroy_func) {
	if ((array != NULL) && (destroy_func != NULL)) {
		int 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, gint array_length, GDestroyNotify destroy_func) {
	_vala_array_destroy (array, array_length, destroy_func);
	g_free (array);
}



