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

/*
 * Copyright (C) 2013-2017 elementary Developers
 *
 * 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-object.h>
#include <stdlib.h>
#include <string.h>
#include <glib.h>

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

#define CONTRACTOR_TYPE_GENERIC_CONTRACT (contractor_generic_contract_get_type ())
typedef struct _ContractorGenericContract ContractorGenericContract;
#define _g_free0(var) (var = (g_free (var), NULL))

struct _ContractorGenericContract {
	gchar* id;
	gchar* name;
	gchar* description;
	gchar* icon;
};

VALA_EXTERN GType contractor_generic_contract_get_type (void) G_GNUC_CONST ;
VALA_EXTERN ContractorGenericContract* contractor_generic_contract_dup (const ContractorGenericContract* self);
VALA_EXTERN void contractor_generic_contract_free (ContractorGenericContract* self);
VALA_EXTERN void contractor_generic_contract_copy (const ContractorGenericContract* self,
                                       ContractorGenericContract* dest);
VALA_EXTERN void contractor_generic_contract_destroy (ContractorGenericContract* self);
G_DEFINE_AUTO_CLEANUP_CLEAR_FUNC (ContractorGenericContract, contractor_generic_contract_destroy)

void
contractor_generic_contract_copy (const ContractorGenericContract* self,
                                  ContractorGenericContract* dest)
{
	const gchar* _tmp0_;
	gchar* _tmp1_;
	const gchar* _tmp2_;
	gchar* _tmp3_;
	const gchar* _tmp4_;
	gchar* _tmp5_;
	const gchar* _tmp6_;
	gchar* _tmp7_;
	_tmp0_ = (*self).id;
	_tmp1_ = g_strdup (_tmp0_);
	_g_free0 ((*dest).id);
	(*dest).id = _tmp1_;
	_tmp2_ = (*self).name;
	_tmp3_ = g_strdup (_tmp2_);
	_g_free0 ((*dest).name);
	(*dest).name = _tmp3_;
	_tmp4_ = (*self).description;
	_tmp5_ = g_strdup (_tmp4_);
	_g_free0 ((*dest).description);
	(*dest).description = _tmp5_;
	_tmp6_ = (*self).icon;
	_tmp7_ = g_strdup (_tmp6_);
	_g_free0 ((*dest).icon);
	(*dest).icon = _tmp7_;
}

void
contractor_generic_contract_destroy (ContractorGenericContract* self)
{
	_g_free0 ((*self).id);
	_g_free0 ((*self).name);
	_g_free0 ((*self).description);
	_g_free0 ((*self).icon);
}

ContractorGenericContract*
contractor_generic_contract_dup (const ContractorGenericContract* self)
{
	ContractorGenericContract* dup;
	dup = g_new0 (ContractorGenericContract, 1);
	contractor_generic_contract_copy (self, dup);
	return dup;
}

void
contractor_generic_contract_free (ContractorGenericContract* self)
{
	contractor_generic_contract_destroy (self);
	g_free (self);
}

static GType
contractor_generic_contract_get_type_once (void)
{
	GType contractor_generic_contract_type_id;
	contractor_generic_contract_type_id = g_boxed_type_register_static ("ContractorGenericContract", (GBoxedCopyFunc) contractor_generic_contract_dup, (GBoxedFreeFunc) contractor_generic_contract_free);
	return contractor_generic_contract_type_id;
}

GType
contractor_generic_contract_get_type (void)
{
	static volatile gsize contractor_generic_contract_type_id__once = 0;
	if (g_once_init_enter (&contractor_generic_contract_type_id__once)) {
		GType contractor_generic_contract_type_id;
		contractor_generic_contract_type_id = contractor_generic_contract_get_type_once ();
		g_once_init_leave (&contractor_generic_contract_type_id__once, contractor_generic_contract_type_id);
	}
	return contractor_generic_contract_type_id__once;
}

