/* vbfproject.c generated by valac 0.12.1.1-323029-dirty, the Vala compiler
 * generated from vbfproject.vala, do not modify */

/*
 *  vbfproject.vala - Vala Build Framework library
 *  
 *  Copyright (C) 2008 - Andrea Del Signore <sejerpz@tin.it>
 *  
 *  This library is free software; you can redistribute it and/or
 *  modify it under the terms of the GNU Lesser General Public
 *  License as published by the Free Software Foundation; either
 *  version 2.1 of the License, or (at your option) any later version.
 *
 *  This library 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
 *  Lesser General Public License for more details.
 *
 *  You should have received a copy of the GNU Lesser General Public
 *  License along with this library; if not, write to the Free Software
 *  Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301  USA
 */

#include <glib.h>
#include <glib-object.h>
#include <stdlib.h>
#include <string.h>
#include <valagee.h>


#define VBF_TYPE_CONFIG_NODE (vbf_config_node_get_type ())
#define VBF_CONFIG_NODE(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), VBF_TYPE_CONFIG_NODE, VbfConfigNode))
#define VBF_CONFIG_NODE_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), VBF_TYPE_CONFIG_NODE, VbfConfigNodeClass))
#define VBF_IS_CONFIG_NODE(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), VBF_TYPE_CONFIG_NODE))
#define VBF_IS_CONFIG_NODE_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), VBF_TYPE_CONFIG_NODE))
#define VBF_CONFIG_NODE_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), VBF_TYPE_CONFIG_NODE, VbfConfigNodeClass))

typedef struct _VbfConfigNode VbfConfigNode;
typedef struct _VbfConfigNodeClass VbfConfigNodeClass;
typedef struct _VbfConfigNodePrivate VbfConfigNodePrivate;

#define VBF_TYPE_PROJECT (vbf_project_get_type ())
#define VBF_PROJECT(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), VBF_TYPE_PROJECT, VbfProject))
#define VBF_PROJECT_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), VBF_TYPE_PROJECT, VbfProjectClass))
#define VBF_IS_PROJECT(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), VBF_TYPE_PROJECT))
#define VBF_IS_PROJECT_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), VBF_TYPE_PROJECT))
#define VBF_PROJECT_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), VBF_TYPE_PROJECT, VbfProjectClass))

typedef struct _VbfProject VbfProject;
typedef struct _VbfProjectClass VbfProjectClass;
typedef struct _VbfProjectPrivate VbfProjectPrivate;

#define VBF_TYPE_IPROJECT_BACKEND (vbf_iproject_backend_get_type ())
#define VBF_IPROJECT_BACKEND(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), VBF_TYPE_IPROJECT_BACKEND, VbfIProjectBackend))
#define VBF_IS_IPROJECT_BACKEND(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), VBF_TYPE_IPROJECT_BACKEND))
#define VBF_IPROJECT_BACKEND_GET_INTERFACE(obj) (G_TYPE_INSTANCE_GET_INTERFACE ((obj), VBF_TYPE_IPROJECT_BACKEND, VbfIProjectBackendIface))

typedef struct _VbfIProjectBackend VbfIProjectBackend;
typedef struct _VbfIProjectBackendIface VbfIProjectBackendIface;

#define VBF_TYPE_GROUP (vbf_group_get_type ())
#define VBF_GROUP(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), VBF_TYPE_GROUP, VbfGroup))
#define VBF_GROUP_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), VBF_TYPE_GROUP, VbfGroupClass))
#define VBF_IS_GROUP(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), VBF_TYPE_GROUP))
#define VBF_IS_GROUP_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), VBF_TYPE_GROUP))
#define VBF_GROUP_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), VBF_TYPE_GROUP, VbfGroupClass))

typedef struct _VbfGroup VbfGroup;
typedef struct _VbfGroupClass VbfGroupClass;

#define VBF_TYPE_MODULE (vbf_module_get_type ())
#define VBF_MODULE(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), VBF_TYPE_MODULE, VbfModule))
#define VBF_MODULE_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), VBF_TYPE_MODULE, VbfModuleClass))
#define VBF_IS_MODULE(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), VBF_TYPE_MODULE))
#define VBF_IS_MODULE_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), VBF_TYPE_MODULE))
#define VBF_MODULE_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), VBF_TYPE_MODULE, VbfModuleClass))

typedef struct _VbfModule VbfModule;
typedef struct _VbfModuleClass VbfModuleClass;

#define VBF_TYPE_VARIABLE (vbf_variable_get_type ())
#define VBF_VARIABLE(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), VBF_TYPE_VARIABLE, VbfVariable))
#define VBF_VARIABLE_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), VBF_TYPE_VARIABLE, VbfVariableClass))
#define VBF_IS_VARIABLE(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), VBF_TYPE_VARIABLE))
#define VBF_IS_VARIABLE_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), VBF_TYPE_VARIABLE))
#define VBF_VARIABLE_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), VBF_TYPE_VARIABLE, VbfVariableClass))

typedef struct _VbfVariable VbfVariable;
typedef struct _VbfVariableClass VbfVariableClass;
#define _g_free0(var) (var = (g_free (var), NULL))
#define _vala_iterable_unref0(var) ((var == NULL) ? NULL : (var = (vala_iterable_unref (var), NULL)))
#define _g_object_unref0(var) ((var == NULL) ? NULL : (var = (g_object_unref (var), NULL)))
typedef struct _VbfGroupPrivate VbfGroupPrivate;

#define VBF_TYPE_TARGET (vbf_target_get_type ())
#define VBF_TARGET(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), VBF_TYPE_TARGET, VbfTarget))
#define VBF_TARGET_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), VBF_TYPE_TARGET, VbfTargetClass))
#define VBF_IS_TARGET(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), VBF_TYPE_TARGET))
#define VBF_IS_TARGET_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), VBF_TYPE_TARGET))
#define VBF_TARGET_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), VBF_TYPE_TARGET, VbfTargetClass))

typedef struct _VbfTarget VbfTarget;
typedef struct _VbfTargetClass VbfTargetClass;

#define VBF_TYPE_FILE (vbf_file_get_type ())
#define VBF_FILE(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), VBF_TYPE_FILE, VbfFile))
#define VBF_FILE_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), VBF_TYPE_FILE, VbfFileClass))
#define VBF_IS_FILE(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), VBF_TYPE_FILE))
#define VBF_IS_FILE_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), VBF_TYPE_FILE))
#define VBF_FILE_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), VBF_TYPE_FILE, VbfFileClass))

typedef struct _VbfFile VbfFile;
typedef struct _VbfFileClass VbfFileClass;

#define VBF_TYPE_SOURCE (vbf_source_get_type ())
#define VBF_SOURCE(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), VBF_TYPE_SOURCE, VbfSource))
#define VBF_SOURCE_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), VBF_TYPE_SOURCE, VbfSourceClass))
#define VBF_IS_SOURCE(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), VBF_TYPE_SOURCE))
#define VBF_IS_SOURCE_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), VBF_TYPE_SOURCE))
#define VBF_SOURCE_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), VBF_TYPE_SOURCE, VbfSourceClass))

typedef struct _VbfSource VbfSource;
typedef struct _VbfSourceClass VbfSourceClass;
typedef struct _VbfFilePrivate VbfFilePrivate;

#define VBF_TYPE_FILE_TYPES (vbf_file_types_get_type ())

struct _VbfConfigNode {
	GObject parent_instance;
	VbfConfigNodePrivate * priv;
	VbfConfigNode* parent;
};

struct _VbfConfigNodeClass {
	GObjectClass parent_class;
	gchar* (*to_string) (VbfConfigNode* self);
};

struct _VbfIProjectBackendIface {
	GTypeInterface parent_iface;
	gboolean (*probe) (VbfIProjectBackend* self, const gchar* project_file);
	VbfProject* (*open) (VbfIProjectBackend* self, const gchar* project_file);
	void (*refresh) (VbfIProjectBackend* self, VbfProject* project);
	gchar* (*get_configure_command) (VbfIProjectBackend* self);
	gchar* (*get_build_command) (VbfIProjectBackend* self);
	gchar* (*get_clean_command) (VbfIProjectBackend* self);
};

struct _VbfProject {
	VbfConfigNode parent_instance;
	VbfProjectPrivate * priv;
	gchar* id;
	gchar* name;
	gchar* url;
	gchar* version;
	gchar* working_dir;
	VbfIProjectBackend* backend;
};

struct _VbfProjectClass {
	VbfConfigNodeClass parent_class;
};

struct _VbfProjectPrivate {
	ValaList* groups;
	ValaList* modules;
	ValaList* variables;
	gboolean in_update;
};

struct _VbfGroup {
	GObject parent_instance;
	VbfGroupPrivate * priv;
	gchar* name;
	gchar* id;
	VbfProject* project;
};

struct _VbfGroupClass {
	GObjectClass parent_class;
};

typedef enum  {
	VBF_FILE_TYPES_UNKNOWN,
	VBF_FILE_TYPES_DATA,
	VBF_FILE_TYPES_VALA_SOURCE,
	VBF_FILE_TYPES_OTHER_SOURCE
} VbfFileTypes;

struct _VbfFile {
	GObject parent_instance;
	VbfFilePrivate * priv;
	gchar* name;
	gchar* filename;
	gchar* uri;
	VbfFileTypes type;
	VbfTarget* target;
};

struct _VbfFileClass {
	GObjectClass parent_class;
};


static gpointer vbf_project_parent_class = NULL;

GType vbf_config_node_get_type (void) G_GNUC_CONST;
GType vbf_project_get_type (void) G_GNUC_CONST;
GType vbf_iproject_backend_get_type (void) G_GNUC_CONST;
GType vbf_group_get_type (void) G_GNUC_CONST;
GType vbf_module_get_type (void) G_GNUC_CONST;
GType vbf_variable_get_type (void) G_GNUC_CONST;
#define VBF_PROJECT_GET_PRIVATE(o) (G_TYPE_INSTANCE_GET_PRIVATE ((o), VBF_TYPE_PROJECT, VbfProjectPrivate))
enum  {
	VBF_PROJECT_DUMMY_PROPERTY,
	VBF_PROJECT_CONFIGURE_COMMAND,
	VBF_PROJECT_BUILD_COMMAND,
	VBF_PROJECT_CLEAN_COMMAND
};
VbfProject* vbf_project_new (const gchar* id);
VbfProject* vbf_project_construct (GType object_type, const gchar* id);
VbfConfigNode* vbf_config_node_construct (GType object_type);
ValaList* vbf_project_get_groups (VbfProject* self);
VbfGroup* vbf_project_get_group (VbfProject* self, const gchar* id);
void vbf_project_add_group (VbfProject* self, VbfGroup* group);
ValaList* vbf_project_get_modules (VbfProject* self);
void vbf_project_add_module (VbfProject* self, VbfModule* module);
ValaList* vbf_project_get_variables (VbfProject* self);
void vbf_project_add_variable (VbfProject* self, VbfVariable* variable);
static gchar* vbf_project_real_to_string (VbfConfigNode* base);
gchar* vbf_project_get_all_source_files (VbfProject* self);
GType vbf_target_get_type (void) G_GNUC_CONST;
ValaList* vbf_group_get_targets (VbfGroup* self);
GType vbf_file_get_type (void) G_GNUC_CONST;
GType vbf_source_get_type (void) G_GNUC_CONST;
ValaList* vbf_target_get_sources (VbfTarget* self);
GType vbf_file_types_get_type (void) G_GNUC_CONST;
void vbf_project_clear (VbfProject* self);
void vbf_project_update (VbfProject* self);
void vbf_iproject_backend_refresh (VbfIProjectBackend* self, VbfProject* project);
gchar* vbf_project_get_configure_command (VbfProject* self);
gchar* vbf_iproject_backend_get_configure_command (VbfIProjectBackend* self);
gchar* vbf_project_get_build_command (VbfProject* self);
gchar* vbf_iproject_backend_get_build_command (VbfIProjectBackend* self);
gchar* vbf_project_get_clean_command (VbfProject* self);
gchar* vbf_iproject_backend_get_clean_command (VbfIProjectBackend* self);
static void vbf_project_finalize (GObject* obj);
static void _vala_vbf_project_get_property (GObject * object, guint property_id, GValue * value, GParamSpec * pspec);


VbfProject* vbf_project_construct (GType object_type, const gchar* id) {
	VbfProject * self = NULL;
	gchar* _tmp0_;
	g_return_val_if_fail (id != NULL, NULL);
	self = (VbfProject*) vbf_config_node_construct (object_type);
	_tmp0_ = g_strdup (id);
	_g_free0 (self->id);
	self->id = _tmp0_;
	return self;
}


VbfProject* vbf_project_new (const gchar* id) {
	return vbf_project_construct (VBF_TYPE_PROJECT, id);
}


static gpointer _vala_iterable_ref0 (gpointer self) {
	return self ? vala_iterable_ref (self) : NULL;
}


ValaList* vbf_project_get_groups (VbfProject* self) {
	ValaList* result = NULL;
	ValaList* _tmp0_;
	g_return_val_if_fail (self != NULL, NULL);
	_tmp0_ = _vala_iterable_ref0 (self->priv->groups);
	result = _tmp0_;
	return result;
}


VbfGroup* vbf_project_get_group (VbfProject* self, const gchar* id) {
	VbfGroup* result = NULL;
	g_return_val_if_fail (self != NULL, NULL);
	g_return_val_if_fail (id != NULL, NULL);
	{
		ValaList* _tmp0_;
		ValaList* _group_list;
		gint _tmp1_;
		gint _group_size;
		gint _group_index;
		_tmp0_ = _vala_iterable_ref0 (self->priv->groups);
		_group_list = _tmp0_;
		_tmp1_ = vala_collection_get_size ((ValaCollection*) _group_list);
		_group_size = _tmp1_;
		_group_index = -1;
		while (TRUE) {
			gpointer _tmp2_ = NULL;
			VbfGroup* group;
			_group_index = _group_index + 1;
			if (!(_group_index < _group_size)) {
				break;
			}
			_tmp2_ = vala_list_get (_group_list, _group_index);
			group = (VbfGroup*) _tmp2_;
			if (g_strcmp0 (group->id, id) == 0) {
				result = group;
				_vala_iterable_unref0 (_group_list);
				return result;
			}
			_g_object_unref0 (group);
		}
		_vala_iterable_unref0 (_group_list);
	}
	result = NULL;
	return result;
}


void vbf_project_add_group (VbfProject* self, VbfGroup* group) {
	g_return_if_fail (self != NULL);
	g_return_if_fail (group != NULL);
	vala_collection_add ((ValaCollection*) self->priv->groups, group);
}


ValaList* vbf_project_get_modules (VbfProject* self) {
	ValaList* result = NULL;
	ValaList* _tmp0_;
	g_return_val_if_fail (self != NULL, NULL);
	_tmp0_ = _vala_iterable_ref0 (self->priv->modules);
	result = _tmp0_;
	return result;
}


void vbf_project_add_module (VbfProject* self, VbfModule* module) {
	g_return_if_fail (self != NULL);
	g_return_if_fail (module != NULL);
	vala_collection_add ((ValaCollection*) self->priv->modules, module);
}


ValaList* vbf_project_get_variables (VbfProject* self) {
	ValaList* result = NULL;
	ValaList* _tmp0_;
	g_return_val_if_fail (self != NULL, NULL);
	_tmp0_ = _vala_iterable_ref0 (self->priv->variables);
	result = _tmp0_;
	return result;
}


void vbf_project_add_variable (VbfProject* self, VbfVariable* variable) {
	g_return_if_fail (self != NULL);
	g_return_if_fail (variable != NULL);
	vala_collection_add ((ValaCollection*) self->priv->variables, variable);
}


static gchar* vbf_project_real_to_string (VbfConfigNode* base) {
	VbfProject * self;
	gchar* result = NULL;
	gchar* _tmp0_ = NULL;
	self = (VbfProject*) base;
	_tmp0_ = g_strdup_printf ("%s %s: %s", self->name, self->version, self->id);
	result = _tmp0_;
	return result;
}


gchar* vbf_project_get_all_source_files (VbfProject* self) {
	gchar* result = NULL;
	gchar* _tmp0_;
	gchar* res;
	g_return_val_if_fail (self != NULL, NULL);
	_tmp0_ = g_strdup ("");
	res = _tmp0_;
	{
		ValaList* _tmp1_;
		ValaList* _group_list;
		gint _tmp2_;
		gint _group_size;
		gint _group_index;
		_tmp1_ = _vala_iterable_ref0 (self->priv->groups);
		_group_list = _tmp1_;
		_tmp2_ = vala_collection_get_size ((ValaCollection*) _group_list);
		_group_size = _tmp2_;
		_group_index = -1;
		while (TRUE) {
			gpointer _tmp3_ = NULL;
			VbfGroup* group;
			_group_index = _group_index + 1;
			if (!(_group_index < _group_size)) {
				break;
			}
			_tmp3_ = vala_list_get (_group_list, _group_index);
			group = (VbfGroup*) _tmp3_;
			{
				ValaList* _tmp4_ = NULL;
				ValaList* _target_list;
				gint _tmp5_;
				gint _target_size;
				gint _target_index;
				_tmp4_ = vbf_group_get_targets (group);
				_target_list = _tmp4_;
				_tmp5_ = vala_collection_get_size ((ValaCollection*) _target_list);
				_target_size = _tmp5_;
				_target_index = -1;
				while (TRUE) {
					gpointer _tmp6_ = NULL;
					VbfTarget* target;
					_target_index = _target_index + 1;
					if (!(_target_index < _target_size)) {
						break;
					}
					_tmp6_ = vala_list_get (_target_list, _target_index);
					target = (VbfTarget*) _tmp6_;
					{
						ValaList* _tmp7_ = NULL;
						ValaList* _source_list;
						gint _tmp8_;
						gint _source_size;
						gint _source_index;
						_tmp7_ = vbf_target_get_sources (target);
						_source_list = _tmp7_;
						_tmp8_ = vala_collection_get_size ((ValaCollection*) _source_list);
						_source_size = _tmp8_;
						_source_index = -1;
						while (TRUE) {
							gpointer _tmp9_ = NULL;
							VbfSource* source;
							gchar* _tmp10_ = NULL;
							_source_index = _source_index + 1;
							if (!(_source_index < _source_size)) {
								break;
							}
							_tmp9_ = vala_list_get (_source_list, _source_index);
							source = (VbfSource*) _tmp9_;
							_tmp10_ = g_strconcat (res, "\"", ((VbfFile*) source)->filename, "\"", NULL);
							_g_free0 (res);
							res = _tmp10_;
							_g_object_unref0 (source);
						}
						_vala_iterable_unref0 (_source_list);
					}
					_g_object_unref0 (target);
				}
				_vala_iterable_unref0 (_target_list);
			}
			_g_object_unref0 (group);
		}
		_vala_iterable_unref0 (_group_list);
	}
	result = res;
	return result;
}


void vbf_project_clear (VbfProject* self) {
	g_return_if_fail (self != NULL);
	vala_collection_clear ((ValaCollection*) self->priv->groups);
	vala_collection_clear ((ValaCollection*) self->priv->variables);
	vala_collection_clear ((ValaCollection*) self->priv->modules);
}


void vbf_project_update (VbfProject* self) {
	g_return_if_fail (self != NULL);
	if (self->priv->in_update) {
		return;
	}
	self->priv->in_update = TRUE;
	if (self->backend != NULL) {
		vbf_iproject_backend_refresh (self->backend, self);
	}
	g_signal_emit_by_name (self, "updated");
	self->priv->in_update = FALSE;
}


gchar* vbf_project_get_configure_command (VbfProject* self) {
	gchar* result;
	gchar* _tmp0_ = NULL;
	g_return_val_if_fail (self != NULL, NULL);
	if (self->backend == NULL) {
		result = NULL;
		return result;
	}
	_tmp0_ = vbf_iproject_backend_get_configure_command (self->backend);
	result = _tmp0_;
	return result;
}


gchar* vbf_project_get_build_command (VbfProject* self) {
	gchar* result;
	gchar* _tmp0_ = NULL;
	g_return_val_if_fail (self != NULL, NULL);
	if (self->backend == NULL) {
		result = NULL;
		return result;
	}
	_tmp0_ = vbf_iproject_backend_get_build_command (self->backend);
	result = _tmp0_;
	return result;
}


gchar* vbf_project_get_clean_command (VbfProject* self) {
	gchar* result;
	gchar* _tmp0_ = NULL;
	g_return_val_if_fail (self != NULL, NULL);
	if (self->backend == NULL) {
		result = NULL;
		return result;
	}
	_tmp0_ = vbf_iproject_backend_get_clean_command (self->backend);
	result = _tmp0_;
	return result;
}


static void vbf_project_class_init (VbfProjectClass * klass) {
	vbf_project_parent_class = g_type_class_peek_parent (klass);
	g_type_class_add_private (klass, sizeof (VbfProjectPrivate));
	VBF_CONFIG_NODE_CLASS (klass)->to_string = vbf_project_real_to_string;
	G_OBJECT_CLASS (klass)->get_property = _vala_vbf_project_get_property;
	G_OBJECT_CLASS (klass)->finalize = vbf_project_finalize;
	g_object_class_install_property (G_OBJECT_CLASS (klass), VBF_PROJECT_CONFIGURE_COMMAND, g_param_spec_string ("configure-command", "configure-command", "configure-command", NULL, G_PARAM_STATIC_NAME | G_PARAM_STATIC_NICK | G_PARAM_STATIC_BLURB | G_PARAM_READABLE));
	g_object_class_install_property (G_OBJECT_CLASS (klass), VBF_PROJECT_BUILD_COMMAND, g_param_spec_string ("build-command", "build-command", "build-command", NULL, G_PARAM_STATIC_NAME | G_PARAM_STATIC_NICK | G_PARAM_STATIC_BLURB | G_PARAM_READABLE));
	g_object_class_install_property (G_OBJECT_CLASS (klass), VBF_PROJECT_CLEAN_COMMAND, g_param_spec_string ("clean-command", "clean-command", "clean-command", NULL, G_PARAM_STATIC_NAME | G_PARAM_STATIC_NICK | G_PARAM_STATIC_BLURB | G_PARAM_READABLE));
	g_signal_new ("updated", VBF_TYPE_PROJECT, G_SIGNAL_RUN_LAST, 0, NULL, NULL, g_cclosure_marshal_VOID__VOID, G_TYPE_NONE, 0);
}


static void vbf_project_instance_init (VbfProject * self) {
	ValaArrayList* _tmp0_ = NULL;
	ValaArrayList* _tmp1_ = NULL;
	ValaArrayList* _tmp2_ = NULL;
	self->priv = VBF_PROJECT_GET_PRIVATE (self);
	_tmp0_ = vala_array_list_new (VBF_TYPE_GROUP, (GBoxedCopyFunc) g_object_ref, g_object_unref, g_direct_equal);
	self->priv->groups = (ValaList*) _tmp0_;
	_tmp1_ = vala_array_list_new (VBF_TYPE_MODULE, (GBoxedCopyFunc) g_object_ref, g_object_unref, g_direct_equal);
	self->priv->modules = (ValaList*) _tmp1_;
	_tmp2_ = vala_array_list_new (VBF_TYPE_VARIABLE, (GBoxedCopyFunc) g_object_ref, g_object_unref, g_direct_equal);
	self->priv->variables = (ValaList*) _tmp2_;
	self->priv->in_update = FALSE;
	self->backend = NULL;
}


static void vbf_project_finalize (GObject* obj) {
	VbfProject * self;
	self = VBF_PROJECT (obj);
	_g_free0 (self->id);
	_g_free0 (self->name);
	_g_free0 (self->url);
	_g_free0 (self->version);
	_g_free0 (self->working_dir);
	_vala_iterable_unref0 (self->priv->groups);
	_vala_iterable_unref0 (self->priv->modules);
	_vala_iterable_unref0 (self->priv->variables);
	_g_object_unref0 (self->backend);
	G_OBJECT_CLASS (vbf_project_parent_class)->finalize (obj);
}


GType vbf_project_get_type (void) {
	static volatile gsize vbf_project_type_id__volatile = 0;
	if (g_once_init_enter (&vbf_project_type_id__volatile)) {
		static const GTypeInfo g_define_type_info = { sizeof (VbfProjectClass), (GBaseInitFunc) NULL, (GBaseFinalizeFunc) NULL, (GClassInitFunc) vbf_project_class_init, (GClassFinalizeFunc) NULL, NULL, sizeof (VbfProject), 0, (GInstanceInitFunc) vbf_project_instance_init, NULL };
		GType vbf_project_type_id;
		vbf_project_type_id = g_type_register_static (VBF_TYPE_CONFIG_NODE, "VbfProject", &g_define_type_info, 0);
		g_once_init_leave (&vbf_project_type_id__volatile, vbf_project_type_id);
	}
	return vbf_project_type_id__volatile;
}


static void _vala_vbf_project_get_property (GObject * object, guint property_id, GValue * value, GParamSpec * pspec) {
	VbfProject * self;
	self = VBF_PROJECT (object);
	switch (property_id) {
		case VBF_PROJECT_CONFIGURE_COMMAND:
		g_value_take_string (value, vbf_project_get_configure_command (self));
		break;
		case VBF_PROJECT_BUILD_COMMAND:
		g_value_take_string (value, vbf_project_get_build_command (self));
		break;
		case VBF_PROJECT_CLEAN_COMMAND:
		g_value_take_string (value, vbf_project_get_clean_command (self));
		break;
		default:
		G_OBJECT_WARN_INVALID_PROPERTY_ID (object, property_id, pspec);
		break;
	}
}



