/* retro-simple-type.c generated by valac 0.36.1.39-72bb2, the Vala compiler
 * generated from retro-simple-type.vala, do not modify */

/* This file is part of GNOME Games. License: GPL-3.0+.*/

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


#define GAMES_TYPE_RETRO_SIMPLE_TYPE (games_retro_simple_type_get_type ())
typedef struct _GamesRetroSimpleType GamesRetroSimpleType;
#define _g_free0(var) (var = (g_free (var), NULL))

struct _GamesRetroSimpleType {
	gchar* mime_type;
	gboolean search_mime_type;
	gchar* platform;
	gchar* prefix;
};



GType games_retro_simple_type_get_type (void) G_GNUC_CONST;
GamesRetroSimpleType* games_retro_simple_type_dup (const GamesRetroSimpleType* self);
void games_retro_simple_type_free (GamesRetroSimpleType* self);
void games_retro_simple_type_copy (const GamesRetroSimpleType* self, GamesRetroSimpleType* dest);
void games_retro_simple_type_destroy (GamesRetroSimpleType* self);


void games_retro_simple_type_copy (const GamesRetroSimpleType* self, GamesRetroSimpleType* dest) {
	const gchar* _tmp0_;
	gchar* _tmp1_;
	gboolean _tmp2_;
	const gchar* _tmp3_;
	gchar* _tmp4_;
	const gchar* _tmp5_;
	gchar* _tmp6_;
	_tmp0_ = (*self).mime_type;
	_tmp1_ = g_strdup (_tmp0_);
	_g_free0 ((*dest).mime_type);
	(*dest).mime_type = _tmp1_;
	_tmp2_ = (*self).search_mime_type;
	(*dest).search_mime_type = _tmp2_;
	_tmp3_ = (*self).platform;
	_tmp4_ = g_strdup (_tmp3_);
	_g_free0 ((*dest).platform);
	(*dest).platform = _tmp4_;
	_tmp5_ = (*self).prefix;
	_tmp6_ = g_strdup (_tmp5_);
	_g_free0 ((*dest).prefix);
	(*dest).prefix = _tmp6_;
}


void games_retro_simple_type_destroy (GamesRetroSimpleType* self) {
	_g_free0 ((*self).mime_type);
	_g_free0 ((*self).platform);
	_g_free0 ((*self).prefix);
}


GamesRetroSimpleType* games_retro_simple_type_dup (const GamesRetroSimpleType* self) {
	GamesRetroSimpleType* dup;
	dup = g_new0 (GamesRetroSimpleType, 1);
	games_retro_simple_type_copy (self, dup);
	return dup;
}


void games_retro_simple_type_free (GamesRetroSimpleType* self) {
	games_retro_simple_type_destroy (self);
	g_free (self);
}


GType games_retro_simple_type_get_type (void) {
	static volatile gsize games_retro_simple_type_type_id__volatile = 0;
	if (g_once_init_enter (&games_retro_simple_type_type_id__volatile)) {
		GType games_retro_simple_type_type_id;
		games_retro_simple_type_type_id = g_boxed_type_register_static ("GamesRetroSimpleType", (GBoxedCopyFunc) games_retro_simple_type_dup, (GBoxedFreeFunc) games_retro_simple_type_free);
		g_once_init_leave (&games_retro_simple_type_type_id__volatile, games_retro_simple_type_type_id);
	}
	return games_retro_simple_type_type_id__volatile;
}



