/* metadata-file.c generated by valac 0.38.8, the Vala compiler
 * generated from metadata-file.vala, do not modify */

/*
 * Copyright (C) 2011-2014 Daiki Ueno <ueno@gnu.org>
 * Copyright (C) 2011-2014 Red Hat, Inc.
 *
 * This program is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License as published by
 * the Free Software Foundation, either version 3 of the License, or
 * (at your option) any later version.
 *
 * This program is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with this program.  If not, see <http://www.gnu.org/licenses/>.
 */

#include <glib.h>
#include <glib-object.h>
#include <gio/gio.h>
#include <json-glib/json-glib.h>
#include <stdlib.h>
#include <string.h>
#include <glib/gi18n-lib.h>
#include <config.h>


#define KKC_TYPE_METADATA_FILE (kkc_metadata_file_get_type ())
#define KKC_METADATA_FILE(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), KKC_TYPE_METADATA_FILE, KkcMetadataFile))
#define KKC_METADATA_FILE_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), KKC_TYPE_METADATA_FILE, KkcMetadataFileClass))
#define KKC_IS_METADATA_FILE(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), KKC_TYPE_METADATA_FILE))
#define KKC_IS_METADATA_FILE_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), KKC_TYPE_METADATA_FILE))
#define KKC_METADATA_FILE_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), KKC_TYPE_METADATA_FILE, KkcMetadataFileClass))

typedef struct _KkcMetadataFile KkcMetadataFile;
typedef struct _KkcMetadataFileClass KkcMetadataFileClass;
typedef struct _KkcMetadataFilePrivate KkcMetadataFilePrivate;
enum  {
	KKC_METADATA_FILE_0_PROPERTY,
	KKC_METADATA_FILE_NAME_PROPERTY,
	KKC_METADATA_FILE_LABEL_PROPERTY,
	KKC_METADATA_FILE_DESCRIPTION_PROPERTY,
	KKC_METADATA_FILE_FILENAME_PROPERTY,
	KKC_METADATA_FILE_NUM_PROPERTIES
};
static GParamSpec* kkc_metadata_file_properties[KKC_METADATA_FILE_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 __vala_JsonNode_free0(var) ((var == NULL) ? NULL : (var = (_vala_JsonNode_free (var), NULL)))
#define _json_object_unref0(var) ((var == NULL) ? NULL : (var = (json_object_unref (var), NULL)))

typedef enum  {
	KKC_METADATA_FORMAT_ERROR_MISSING_FIELD,
	KKC_METADATA_FORMAT_ERROR_INVALID_FIELD
} KkcMetadataFormatError;
#define KKC_METADATA_FORMAT_ERROR kkc_metadata_format_error_quark ()
struct _KkcMetadataFile {
	GObject parent_instance;
	KkcMetadataFilePrivate * priv;
};

struct _KkcMetadataFileClass {
	GObjectClass parent_class;
	gboolean (*parse) (KkcMetadataFile* self, JsonObject* object, GError** error);
};

struct _KkcMetadataFilePrivate {
	gchar* _name;
	gchar* _label;
	gchar* _description;
	gchar* _filename;
};


static gpointer kkc_metadata_file_parent_class = NULL;
static GInitableIface * kkc_metadata_file_g_initable_parent_iface = NULL;

GQuark kkc_metadata_format_error_quark (void);
GType kkc_metadata_file_get_type (void) G_GNUC_CONST;
#define KKC_METADATA_FILE_GET_PRIVATE(o) (G_TYPE_INSTANCE_GET_PRIVATE ((o), KKC_TYPE_METADATA_FILE, KkcMetadataFilePrivate))
KkcMetadataFile* kkc_metadata_file_construct (GType object_type, const gchar* name, const gchar* filename, GError** error);
gboolean kkc_metadata_file_parse (KkcMetadataFile* self, JsonObject* object, GError** error);
static gboolean kkc_metadata_file_real_parse (KkcMetadataFile* self, JsonObject* object, GError** error);
static gboolean kkc_metadata_file_real_init (GInitable* base, GCancellable* cancellable, GError** error);
const gchar* kkc_metadata_file_get_filename (KkcMetadataFile* self);
static JsonNode* _vala_JsonNode_copy (JsonNode* self);
static void _vala_JsonNode_free (JsonNode* self);
void kkc_metadata_file_set_label (KkcMetadataFile* self, const gchar* value);
void kkc_metadata_file_set_description (KkcMetadataFile* self, const gchar* value);
const gchar* kkc_metadata_file_get_name (KkcMetadataFile* self);
void kkc_metadata_file_set_name (KkcMetadataFile* self, const gchar* value);
const gchar* kkc_metadata_file_get_label (KkcMetadataFile* self);
const gchar* kkc_metadata_file_get_description (KkcMetadataFile* self);
void kkc_metadata_file_set_filename (KkcMetadataFile* self, const gchar* value);
static void kkc_metadata_file_finalize (GObject * obj);
static void _vala_kkc_metadata_file_get_property (GObject * object, guint property_id, GValue * value, GParamSpec * pspec);
static void _vala_kkc_metadata_file_set_property (GObject * object, guint property_id, const GValue * value, GParamSpec * pspec);


GQuark kkc_metadata_format_error_quark (void) {
	return g_quark_from_static_string ("kkc_metadata_format_error-quark");
}


KkcMetadataFile* kkc_metadata_file_construct (GType object_type, const gchar* name, const gchar* filename, GError** error) {
	KkcMetadataFile * self = NULL;
	const gchar* _tmp0_;
	const gchar* _tmp1_;
	GError * _inner_error_ = NULL;
	g_return_val_if_fail (name != NULL, NULL);
	g_return_val_if_fail (filename != NULL, NULL);
	_tmp0_ = name;
	_tmp1_ = filename;
	self = (KkcMetadataFile*) g_object_new (object_type, "name", _tmp0_, "filename", _tmp1_, NULL);
	g_initable_init ((GInitable*) self, NULL, &_inner_error_);
	if (G_UNLIKELY (_inner_error_ != NULL)) {
		g_propagate_error (error, _inner_error_);
		_g_object_unref0 (self);
		return NULL;
	}
	return self;
}


static gboolean kkc_metadata_file_real_parse (KkcMetadataFile* self, JsonObject* object, GError** error) {
	gboolean _tmp0_ = FALSE;
	g_critical ("Type `%s' does not implement abstract method `kkc_metadata_file_parse'", g_type_name (G_TYPE_FROM_INSTANCE (self)));
	return _tmp0_;
}


gboolean kkc_metadata_file_parse (KkcMetadataFile* self, JsonObject* object, GError** error) {
	g_return_val_if_fail (self != NULL, FALSE);
	return KKC_METADATA_FILE_GET_CLASS (self)->parse (self, object, error);
}


static JsonNode* _vala_JsonNode_copy (JsonNode* self) {
	return g_boxed_copy (json_node_get_type (), self);
}


static gpointer __vala_JsonNode_copy0 (gpointer self) {
	return self ? _vala_JsonNode_copy (self) : NULL;
}


static void _vala_JsonNode_free (JsonNode* self) {
	g_boxed_free (json_node_get_type (), self);
}


static gpointer _json_object_ref0 (gpointer self) {
	return self ? json_object_ref (self) : NULL;
}


static gboolean kkc_metadata_file_real_init (GInitable* base, GCancellable* cancellable, GError** error) {
	KkcMetadataFile * self;
	gboolean result = FALSE;
	JsonParser* parser = NULL;
	JsonParser* _tmp0_;
	JsonParser* _tmp1_;
	const gchar* _tmp2_;
	JsonNode* root = NULL;
	JsonParser* _tmp4_;
	JsonNode* _tmp5_;
	JsonNode* _tmp6_;
	JsonNode* _tmp7_;
	JsonNodeType _tmp8_;
	JsonObject* object = NULL;
	JsonNode* _tmp11_;
	JsonObject* _tmp12_;
	JsonObject* _tmp13_;
	JsonNode* member = NULL;
	JsonObject* _tmp14_;
	gboolean _tmp15_;
	JsonObject* _tmp18_;
	JsonNode* _tmp19_;
	JsonNode* _tmp20_;
	gchar* name = NULL;
	JsonNode* _tmp21_;
	const gchar* _tmp22_;
	gchar* _tmp23_;
	JsonObject* _tmp24_;
	gboolean _tmp25_;
	JsonObject* _tmp28_;
	JsonNode* _tmp29_;
	JsonNode* _tmp30_;
	gchar* description = NULL;
	JsonNode* _tmp31_;
	const gchar* _tmp32_;
	gchar* _tmp33_;
	JsonObject* _tmp34_;
	gchar* label = NULL;
	const gchar* _tmp36_;
	gchar* _tmp37_;
	const gchar* _tmp38_;
	const gchar* _tmp41_;
	const gchar* _tmp44_;
	const gchar* _tmp45_;
	GError * _inner_error_ = NULL;
	self = (KkcMetadataFile*) base;
	_tmp0_ = json_parser_new ();
	parser = _tmp0_;
	_tmp1_ = parser;
	_tmp2_ = self->priv->_filename;
	json_parser_load_from_file (_tmp1_, _tmp2_, &_inner_error_);
	if (G_UNLIKELY (_inner_error_ != NULL)) {
		gboolean _tmp3_ = FALSE;
		g_propagate_error (error, _inner_error_);
		_g_object_unref0 (parser);
		return _tmp3_;
	}
	_tmp4_ = parser;
	_tmp5_ = json_parser_get_root (_tmp4_);
	_tmp6_ = __vala_JsonNode_copy0 (_tmp5_);
	root = _tmp6_;
	_tmp7_ = root;
	_tmp8_ = json_node_get_node_type (_tmp7_);
	if (_tmp8_ != JSON_NODE_OBJECT) {
		GError* _tmp9_;
		gboolean _tmp10_ = FALSE;
		_tmp9_ = g_error_new_literal (KKC_METADATA_FORMAT_ERROR, KKC_METADATA_FORMAT_ERROR_MISSING_FIELD, "metadata must be a JSON object");
		_inner_error_ = _tmp9_;
		g_propagate_error (error, _inner_error_);
		__vala_JsonNode_free0 (root);
		_g_object_unref0 (parser);
		return _tmp10_;
	}
	_tmp11_ = root;
	_tmp12_ = json_node_get_object (_tmp11_);
	_tmp13_ = _json_object_ref0 (_tmp12_);
	object = _tmp13_;
	_tmp14_ = object;
	_tmp15_ = json_object_has_member (_tmp14_, "name");
	if (!_tmp15_) {
		GError* _tmp16_;
		gboolean _tmp17_ = FALSE;
		_tmp16_ = g_error_new_literal (KKC_METADATA_FORMAT_ERROR, KKC_METADATA_FORMAT_ERROR_MISSING_FIELD, "name is not defined in metadata");
		_inner_error_ = _tmp16_;
		g_propagate_error (error, _inner_error_);
		__vala_JsonNode_free0 (member);
		_json_object_unref0 (object);
		__vala_JsonNode_free0 (root);
		_g_object_unref0 (parser);
		return _tmp17_;
	}
	_tmp18_ = object;
	_tmp19_ = json_object_get_member (_tmp18_, "name");
	_tmp20_ = __vala_JsonNode_copy0 (_tmp19_);
	__vala_JsonNode_free0 (member);
	member = _tmp20_;
	_tmp21_ = member;
	_tmp22_ = json_node_get_string (_tmp21_);
	_tmp23_ = g_strdup (_tmp22_);
	name = _tmp23_;
	_tmp24_ = object;
	_tmp25_ = json_object_has_member (_tmp24_, "description");
	if (!_tmp25_) {
		GError* _tmp26_;
		gboolean _tmp27_ = FALSE;
		_tmp26_ = g_error_new_literal (KKC_METADATA_FORMAT_ERROR, KKC_METADATA_FORMAT_ERROR_MISSING_FIELD, "description is not defined in metadata");
		_inner_error_ = _tmp26_;
		g_propagate_error (error, _inner_error_);
		_g_free0 (name);
		__vala_JsonNode_free0 (member);
		_json_object_unref0 (object);
		__vala_JsonNode_free0 (root);
		_g_object_unref0 (parser);
		return _tmp27_;
	}
	_tmp28_ = object;
	_tmp29_ = json_object_get_member (_tmp28_, "description");
	_tmp30_ = __vala_JsonNode_copy0 (_tmp29_);
	__vala_JsonNode_free0 (member);
	member = _tmp30_;
	_tmp31_ = member;
	_tmp32_ = json_node_get_string (_tmp31_);
	_tmp33_ = g_strdup (_tmp32_);
	description = _tmp33_;
	_tmp34_ = object;
	kkc_metadata_file_parse (self, _tmp34_, &_inner_error_);
	if (G_UNLIKELY (_inner_error_ != NULL)) {
		gboolean _tmp35_ = FALSE;
		g_propagate_error (error, _inner_error_);
		_g_free0 (description);
		_g_free0 (name);
		__vala_JsonNode_free0 (member);
		_json_object_unref0 (object);
		__vala_JsonNode_free0 (root);
		_g_object_unref0 (parser);
		return _tmp35_;
	}
	_tmp36_ = name;
	_tmp37_ = g_strdup (_tmp36_);
	label = _tmp37_;
	_tmp38_ = label;
	if (g_strcmp0 (_tmp38_, "") != 0) {
		const gchar* _tmp39_;
		gchar* _tmp40_;
		_tmp39_ = label;
		_tmp40_ = g_strdup (g_dgettext (GETTEXT_PACKAGE, _tmp39_));
		_g_free0 (label);
		label = _tmp40_;
	}
	_tmp41_ = description;
	if (g_strcmp0 (_tmp41_, "") != 0) {
		const gchar* _tmp42_;
		gchar* _tmp43_;
		_tmp42_ = description;
		_tmp43_ = g_strdup (g_dgettext (GETTEXT_PACKAGE, _tmp42_));
		_g_free0 (description);
		description = _tmp43_;
	}
	_tmp44_ = label;
	kkc_metadata_file_set_label (self, _tmp44_);
	_tmp45_ = description;
	kkc_metadata_file_set_description (self, _tmp45_);
	result = TRUE;
	_g_free0 (label);
	_g_free0 (description);
	_g_free0 (name);
	__vala_JsonNode_free0 (member);
	_json_object_unref0 (object);
	__vala_JsonNode_free0 (root);
	_g_object_unref0 (parser);
	return result;
}


const gchar* kkc_metadata_file_get_name (KkcMetadataFile* self) {
	const gchar* result;
	const gchar* _tmp0_;
	g_return_val_if_fail (self != NULL, NULL);
	_tmp0_ = self->priv->_name;
	result = _tmp0_;
	return result;
}


void kkc_metadata_file_set_name (KkcMetadataFile* self, const gchar* value) {
	g_return_if_fail (self != NULL);
	if (g_strcmp0 (value, kkc_metadata_file_get_name (self)) != 0) {
		const gchar* _tmp0_;
		gchar* _tmp1_;
		_tmp0_ = value;
		_tmp1_ = g_strdup (_tmp0_);
		_g_free0 (self->priv->_name);
		self->priv->_name = _tmp1_;
		g_object_notify_by_pspec ((GObject *) self, kkc_metadata_file_properties[KKC_METADATA_FILE_NAME_PROPERTY]);
	}
}


const gchar* kkc_metadata_file_get_label (KkcMetadataFile* self) {
	const gchar* result;
	const gchar* _tmp0_;
	g_return_val_if_fail (self != NULL, NULL);
	_tmp0_ = self->priv->_label;
	result = _tmp0_;
	return result;
}


void kkc_metadata_file_set_label (KkcMetadataFile* self, const gchar* value) {
	g_return_if_fail (self != NULL);
	if (g_strcmp0 (value, kkc_metadata_file_get_label (self)) != 0) {
		const gchar* _tmp0_;
		gchar* _tmp1_;
		_tmp0_ = value;
		_tmp1_ = g_strdup (_tmp0_);
		_g_free0 (self->priv->_label);
		self->priv->_label = _tmp1_;
		g_object_notify_by_pspec ((GObject *) self, kkc_metadata_file_properties[KKC_METADATA_FILE_LABEL_PROPERTY]);
	}
}


const gchar* kkc_metadata_file_get_description (KkcMetadataFile* self) {
	const gchar* result;
	const gchar* _tmp0_;
	g_return_val_if_fail (self != NULL, NULL);
	_tmp0_ = self->priv->_description;
	result = _tmp0_;
	return result;
}


void kkc_metadata_file_set_description (KkcMetadataFile* self, const gchar* value) {
	g_return_if_fail (self != NULL);
	if (g_strcmp0 (value, kkc_metadata_file_get_description (self)) != 0) {
		const gchar* _tmp0_;
		gchar* _tmp1_;
		_tmp0_ = value;
		_tmp1_ = g_strdup (_tmp0_);
		_g_free0 (self->priv->_description);
		self->priv->_description = _tmp1_;
		g_object_notify_by_pspec ((GObject *) self, kkc_metadata_file_properties[KKC_METADATA_FILE_DESCRIPTION_PROPERTY]);
	}
}


const gchar* kkc_metadata_file_get_filename (KkcMetadataFile* self) {
	const gchar* result;
	const gchar* _tmp0_;
	g_return_val_if_fail (self != NULL, NULL);
	_tmp0_ = self->priv->_filename;
	result = _tmp0_;
	return result;
}


void kkc_metadata_file_set_filename (KkcMetadataFile* self, const gchar* value) {
	g_return_if_fail (self != NULL);
	if (g_strcmp0 (value, kkc_metadata_file_get_filename (self)) != 0) {
		const gchar* _tmp0_;
		gchar* _tmp1_;
		_tmp0_ = value;
		_tmp1_ = g_strdup (_tmp0_);
		_g_free0 (self->priv->_filename);
		self->priv->_filename = _tmp1_;
		g_object_notify_by_pspec ((GObject *) self, kkc_metadata_file_properties[KKC_METADATA_FILE_FILENAME_PROPERTY]);
	}
}


static void kkc_metadata_file_class_init (KkcMetadataFileClass * klass) {
	kkc_metadata_file_parent_class = g_type_class_peek_parent (klass);
	g_type_class_add_private (klass, sizeof (KkcMetadataFilePrivate));
	((KkcMetadataFileClass *) klass)->parse = (gboolean (*) (KkcMetadataFile *, JsonObject*, GError**)) kkc_metadata_file_real_parse;
	G_OBJECT_CLASS (klass)->get_property = _vala_kkc_metadata_file_get_property;
	G_OBJECT_CLASS (klass)->set_property = _vala_kkc_metadata_file_set_property;
	G_OBJECT_CLASS (klass)->finalize = kkc_metadata_file_finalize;
	/**
	         * Name of the metadata.
	         */
	g_object_class_install_property (G_OBJECT_CLASS (klass), KKC_METADATA_FILE_NAME_PROPERTY, kkc_metadata_file_properties[KKC_METADATA_FILE_NAME_PROPERTY] = 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 | G_PARAM_CONSTRUCT));
	/**
	         * Label string of the metadata.
	         */
	g_object_class_install_property (G_OBJECT_CLASS (klass), KKC_METADATA_FILE_LABEL_PROPERTY, kkc_metadata_file_properties[KKC_METADATA_FILE_LABEL_PROPERTY] = g_param_spec_string ("label", "label", "label", NULL, G_PARAM_STATIC_NAME | G_PARAM_STATIC_NICK | G_PARAM_STATIC_BLURB | G_PARAM_READABLE | G_PARAM_WRITABLE | G_PARAM_CONSTRUCT));
	/**
	         * Description of the metadata.
	         */
	g_object_class_install_property (G_OBJECT_CLASS (klass), KKC_METADATA_FILE_DESCRIPTION_PROPERTY, kkc_metadata_file_properties[KKC_METADATA_FILE_DESCRIPTION_PROPERTY] = g_param_spec_string ("description", "description", "description", NULL, G_PARAM_STATIC_NAME | G_PARAM_STATIC_NICK | G_PARAM_STATIC_BLURB | G_PARAM_READABLE | G_PARAM_WRITABLE | G_PARAM_CONSTRUCT));
	/**
	         * Location of the metadata file.
	         */
	g_object_class_install_property (G_OBJECT_CLASS (klass), KKC_METADATA_FILE_FILENAME_PROPERTY, kkc_metadata_file_properties[KKC_METADATA_FILE_FILENAME_PROPERTY] = g_param_spec_string ("filename", "filename", "filename", NULL, G_PARAM_STATIC_NAME | G_PARAM_STATIC_NICK | G_PARAM_STATIC_BLURB | G_PARAM_READABLE | G_PARAM_WRITABLE | G_PARAM_CONSTRUCT));
}


static void kkc_metadata_file_g_initable_interface_init (GInitableIface * iface) {
	kkc_metadata_file_g_initable_parent_iface = g_type_interface_peek_parent (iface);
	iface->init = (gboolean (*) (GInitable *, GCancellable*, GError**)) kkc_metadata_file_real_init;
}


static void kkc_metadata_file_instance_init (KkcMetadataFile * self) {
	self->priv = KKC_METADATA_FILE_GET_PRIVATE (self);
}


static void kkc_metadata_file_finalize (GObject * obj) {
	KkcMetadataFile * self;
	self = G_TYPE_CHECK_INSTANCE_CAST (obj, KKC_TYPE_METADATA_FILE, KkcMetadataFile);
	_g_free0 (self->priv->_name);
	_g_free0 (self->priv->_label);
	_g_free0 (self->priv->_description);
	_g_free0 (self->priv->_filename);
	G_OBJECT_CLASS (kkc_metadata_file_parent_class)->finalize (obj);
}


GType kkc_metadata_file_get_type (void) {
	static volatile gsize kkc_metadata_file_type_id__volatile = 0;
	if (g_once_init_enter (&kkc_metadata_file_type_id__volatile)) {
		static const GTypeInfo g_define_type_info = { sizeof (KkcMetadataFileClass), (GBaseInitFunc) NULL, (GBaseFinalizeFunc) NULL, (GClassInitFunc) kkc_metadata_file_class_init, (GClassFinalizeFunc) NULL, NULL, sizeof (KkcMetadataFile), 0, (GInstanceInitFunc) kkc_metadata_file_instance_init, NULL };
		static const GInterfaceInfo g_initable_info = { (GInterfaceInitFunc) kkc_metadata_file_g_initable_interface_init, (GInterfaceFinalizeFunc) NULL, NULL};
		GType kkc_metadata_file_type_id;
		kkc_metadata_file_type_id = g_type_register_static (G_TYPE_OBJECT, "KkcMetadataFile", &g_define_type_info, G_TYPE_FLAG_ABSTRACT);
		g_type_add_interface_static (kkc_metadata_file_type_id, g_initable_get_type (), &g_initable_info);
		g_once_init_leave (&kkc_metadata_file_type_id__volatile, kkc_metadata_file_type_id);
	}
	return kkc_metadata_file_type_id__volatile;
}


static void _vala_kkc_metadata_file_get_property (GObject * object, guint property_id, GValue * value, GParamSpec * pspec) {
	KkcMetadataFile * self;
	self = G_TYPE_CHECK_INSTANCE_CAST (object, KKC_TYPE_METADATA_FILE, KkcMetadataFile);
	switch (property_id) {
		case KKC_METADATA_FILE_NAME_PROPERTY:
		g_value_set_string (value, kkc_metadata_file_get_name (self));
		break;
		case KKC_METADATA_FILE_LABEL_PROPERTY:
		g_value_set_string (value, kkc_metadata_file_get_label (self));
		break;
		case KKC_METADATA_FILE_DESCRIPTION_PROPERTY:
		g_value_set_string (value, kkc_metadata_file_get_description (self));
		break;
		case KKC_METADATA_FILE_FILENAME_PROPERTY:
		g_value_set_string (value, kkc_metadata_file_get_filename (self));
		break;
		default:
		G_OBJECT_WARN_INVALID_PROPERTY_ID (object, property_id, pspec);
		break;
	}
}


static void _vala_kkc_metadata_file_set_property (GObject * object, guint property_id, const GValue * value, GParamSpec * pspec) {
	KkcMetadataFile * self;
	self = G_TYPE_CHECK_INSTANCE_CAST (object, KKC_TYPE_METADATA_FILE, KkcMetadataFile);
	switch (property_id) {
		case KKC_METADATA_FILE_NAME_PROPERTY:
		kkc_metadata_file_set_name (self, g_value_get_string (value));
		break;
		case KKC_METADATA_FILE_LABEL_PROPERTY:
		kkc_metadata_file_set_label (self, g_value_get_string (value));
		break;
		case KKC_METADATA_FILE_DESCRIPTION_PROPERTY:
		kkc_metadata_file_set_description (self, g_value_get_string (value));
		break;
		case KKC_METADATA_FILE_FILENAME_PROPERTY:
		kkc_metadata_file_set_filename (self, g_value_get_string (value));
		break;
		default:
		G_OBJECT_WARN_INVALID_PROPERTY_ID (object, property_id, pspec);
		break;
	}
}



