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

#include <glib-object.h>
#include <gtk/gtk.h>
#include <json-glib/json-glib.h>
#include <glib.h>
#include <stdlib.h>
#include <string.h>
#include <gee.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 TUBA_TYPE_WIDGETIZABLE (tuba_widgetizable_get_type ())
#define TUBA_WIDGETIZABLE(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TUBA_TYPE_WIDGETIZABLE, TubaWidgetizable))
#define TUBA_IS_WIDGETIZABLE(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TUBA_TYPE_WIDGETIZABLE))
#define TUBA_WIDGETIZABLE_GET_INTERFACE(obj) (G_TYPE_INSTANCE_GET_INTERFACE ((obj), TUBA_TYPE_WIDGETIZABLE, TubaWidgetizableIface))

typedef struct _TubaWidgetizable TubaWidgetizable;
typedef struct _TubaWidgetizableIface TubaWidgetizableIface;

#define TUBA_TYPE_ENTITY (tuba_entity_get_type ())
#define TUBA_ENTITY(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TUBA_TYPE_ENTITY, TubaEntity))
#define TUBA_ENTITY_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TUBA_TYPE_ENTITY, TubaEntityClass))
#define TUBA_IS_ENTITY(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TUBA_TYPE_ENTITY))
#define TUBA_IS_ENTITY_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TUBA_TYPE_ENTITY))
#define TUBA_ENTITY_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TUBA_TYPE_ENTITY, TubaEntityClass))

typedef struct _TubaEntity TubaEntity;
typedef struct _TubaEntityClass TubaEntityClass;

#define TUBA_API_TYPE_ACCOUNT (tuba_api_account_get_type ())
#define TUBA_API_ACCOUNT(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TUBA_API_TYPE_ACCOUNT, TubaAPIAccount))
#define TUBA_API_ACCOUNT_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TUBA_API_TYPE_ACCOUNT, TubaAPIAccountClass))
#define TUBA_API_IS_ACCOUNT(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TUBA_API_TYPE_ACCOUNT))
#define TUBA_API_IS_ACCOUNT_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TUBA_API_TYPE_ACCOUNT))
#define TUBA_API_ACCOUNT_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TUBA_API_TYPE_ACCOUNT, TubaAPIAccountClass))

typedef struct _TubaAPIAccount TubaAPIAccount;
typedef struct _TubaAPIAccountClass TubaAPIAccountClass;

#define TUBA_TYPE_INSTANCE_ACCOUNT (tuba_instance_account_get_type ())
#define TUBA_INSTANCE_ACCOUNT(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TUBA_TYPE_INSTANCE_ACCOUNT, TubaInstanceAccount))
#define TUBA_INSTANCE_ACCOUNT_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TUBA_TYPE_INSTANCE_ACCOUNT, TubaInstanceAccountClass))
#define TUBA_IS_INSTANCE_ACCOUNT(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TUBA_TYPE_INSTANCE_ACCOUNT))
#define TUBA_IS_INSTANCE_ACCOUNT_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TUBA_TYPE_INSTANCE_ACCOUNT))
#define TUBA_INSTANCE_ACCOUNT_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TUBA_TYPE_INSTANCE_ACCOUNT, TubaInstanceAccountClass))

typedef struct _TubaInstanceAccount TubaInstanceAccount;
typedef struct _TubaInstanceAccountClass TubaInstanceAccountClass;
typedef struct _TubaEntityPrivate TubaEntityPrivate;

#define TUBA_API_TYPE_ACCOUNT_SOURCE (tuba_api_account_source_get_type ())
#define TUBA_API_ACCOUNT_SOURCE(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TUBA_API_TYPE_ACCOUNT_SOURCE, TubaAPIAccountSource))
#define TUBA_API_ACCOUNT_SOURCE_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TUBA_API_TYPE_ACCOUNT_SOURCE, TubaAPIAccountSourceClass))
#define TUBA_API_IS_ACCOUNT_SOURCE(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TUBA_API_TYPE_ACCOUNT_SOURCE))
#define TUBA_API_IS_ACCOUNT_SOURCE_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TUBA_API_TYPE_ACCOUNT_SOURCE))
#define TUBA_API_ACCOUNT_SOURCE_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TUBA_API_TYPE_ACCOUNT_SOURCE, TubaAPIAccountSourceClass))

typedef struct _TubaAPIAccountSource TubaAPIAccountSource;
typedef struct _TubaAPIAccountSourceClass TubaAPIAccountSourceClass;
typedef struct _TubaAPIAccountSourcePrivate TubaAPIAccountSourcePrivate;

#define TUBA_API_TYPE_ACCOUNT_FIELD (tuba_api_account_field_get_type ())
#define TUBA_API_ACCOUNT_FIELD(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TUBA_API_TYPE_ACCOUNT_FIELD, TubaAPIAccountField))
#define TUBA_API_ACCOUNT_FIELD_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TUBA_API_TYPE_ACCOUNT_FIELD, TubaAPIAccountFieldClass))
#define TUBA_API_IS_ACCOUNT_FIELD(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TUBA_API_TYPE_ACCOUNT_FIELD))
#define TUBA_API_IS_ACCOUNT_FIELD_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TUBA_API_TYPE_ACCOUNT_FIELD))
#define TUBA_API_ACCOUNT_FIELD_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TUBA_API_TYPE_ACCOUNT_FIELD, TubaAPIAccountFieldClass))

typedef struct _TubaAPIAccountField TubaAPIAccountField;
typedef struct _TubaAPIAccountFieldClass TubaAPIAccountFieldClass;
enum  {
	TUBA_API_ACCOUNT_SOURCE_0_PROPERTY,
	TUBA_API_ACCOUNT_SOURCE_LANGUAGE_PROPERTY,
	TUBA_API_ACCOUNT_SOURCE_QUOTE_POLICY_PROPERTY,
	TUBA_API_ACCOUNT_SOURCE_NOTE_PROPERTY,
	TUBA_API_ACCOUNT_SOURCE_FOLLOW_REQUESTS_COUNT_PROPERTY,
	TUBA_API_ACCOUNT_SOURCE_PRIVACY_PROPERTY,
	TUBA_API_ACCOUNT_SOURCE_FIELDS_PROPERTY,
	TUBA_API_ACCOUNT_SOURCE_NUM_PROPERTIES
};
static GParamSpec* tuba_api_account_source_properties[TUBA_API_ACCOUNT_SOURCE_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)))

struct _TubaWidgetizableIface {
	GTypeInterface parent_iface;
	GtkWidget* (*to_widget) (TubaWidgetizable* self);
	void (*open) (TubaWidgetizable* self);
	void (*resolve_open) (TubaWidgetizable* self, TubaInstanceAccount* account);
};

struct _TubaEntity {
	GObject parent_instance;
	TubaEntityPrivate * priv;
};

struct _TubaEntityClass {
	GObjectClass parent_class;
	gboolean (*is_local) (TubaEntity* self, TubaInstanceAccount* account);
	GType (*deserialize_array_type) (TubaEntity* self, const gchar* prop);
};

struct _TubaAPIAccountSource {
	TubaEntity parent_instance;
	TubaAPIAccountSourcePrivate * priv;
};

struct _TubaAPIAccountSourceClass {
	TubaEntityClass parent_class;
};

struct _TubaAPIAccountSourcePrivate {
	gchar* _language;
	gchar* _quote_policy;
	gchar* _note;
	gint _follow_requests_count;
	gchar* _privacy;
	GeeArrayList* _fields;
};

static gint TubaAPIAccountSource_private_offset;
static gpointer tuba_api_account_source_parent_class = NULL;

VALA_EXTERN GType tuba_entity_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (TubaEntity, g_object_unref)
VALA_EXTERN GType tuba_api_account_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (TubaAPIAccount, g_object_unref)
VALA_EXTERN GType tuba_instance_account_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (TubaInstanceAccount, g_object_unref)
VALA_EXTERN GType tuba_widgetizable_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (TubaWidgetizable, g_object_unref)
VALA_EXTERN GType tuba_api_account_source_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (TubaAPIAccountSource, g_object_unref)
VALA_EXTERN GType tuba_api_account_field_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (TubaAPIAccountField, g_object_unref)
VALA_EXTERN GType tuba_entity_deserialize_array_type (TubaEntity* self,
                                          const gchar* prop);
static GType tuba_api_account_source_real_deserialize_array_type (TubaEntity* base,
                                                           const gchar* prop);
VALA_EXTERN TubaAPIAccountSource* tuba_api_account_source_new (void);
VALA_EXTERN TubaAPIAccountSource* tuba_api_account_source_construct (GType object_type);
VALA_EXTERN TubaEntity* tuba_entity_new (void);
VALA_EXTERN TubaEntity* tuba_entity_construct (GType object_type);
VALA_EXTERN const gchar* tuba_api_account_source_get_language (TubaAPIAccountSource* self);
VALA_EXTERN void tuba_api_account_source_set_language (TubaAPIAccountSource* self,
                                           const gchar* value);
VALA_EXTERN const gchar* tuba_api_account_source_get_quote_policy (TubaAPIAccountSource* self);
VALA_EXTERN void tuba_api_account_source_set_quote_policy (TubaAPIAccountSource* self,
                                               const gchar* value);
VALA_EXTERN const gchar* tuba_api_account_source_get_note (TubaAPIAccountSource* self);
VALA_EXTERN void tuba_api_account_source_set_note (TubaAPIAccountSource* self,
                                       const gchar* value);
VALA_EXTERN gint tuba_api_account_source_get_follow_requests_count (TubaAPIAccountSource* self);
VALA_EXTERN void tuba_api_account_source_set_follow_requests_count (TubaAPIAccountSource* self,
                                                        gint value);
VALA_EXTERN const gchar* tuba_api_account_source_get_privacy (TubaAPIAccountSource* self);
VALA_EXTERN void tuba_api_account_source_set_privacy (TubaAPIAccountSource* self,
                                          const gchar* value);
VALA_EXTERN GeeArrayList* tuba_api_account_source_get_fields (TubaAPIAccountSource* self);
VALA_EXTERN void tuba_api_account_source_set_fields (TubaAPIAccountSource* self,
                                         GeeArrayList* value);
static void tuba_api_account_source_finalize (GObject * obj);
static GType tuba_api_account_source_get_type_once (void);
static void _vala_tuba_api_account_source_get_property (GObject * object,
                                                 guint property_id,
                                                 GValue * value,
                                                 GParamSpec * pspec);
static void _vala_tuba_api_account_source_set_property (GObject * object,
                                                 guint property_id,
                                                 const GValue * value,
                                                 GParamSpec * pspec);

static inline gpointer
tuba_api_account_source_get_instance_private (TubaAPIAccountSource* self)
{
	return G_STRUCT_MEMBER_P (self, TubaAPIAccountSource_private_offset);
}

static GType
tuba_api_account_source_real_deserialize_array_type (TubaEntity* base,
                                                     const gchar* prop)
{
	TubaAPIAccountSource * self;
	const gchar* _tmp0_;
	GQuark _tmp2_ = 0U;
	static GQuark _tmp1_label0 = 0;
	GType result;
	self = (TubaAPIAccountSource*) base;
	g_return_val_if_fail (prop != NULL, G_TYPE_INVALID);
	_tmp0_ = prop;
	_tmp2_ = (NULL == _tmp0_) ? 0 : g_quark_from_string (_tmp0_);
	if (_tmp2_ == ((0 != _tmp1_label0) ? _tmp1_label0 : (_tmp1_label0 = g_quark_from_static_string ("fields")))) {
		switch (0) {
			default:
			{
				result = TUBA_API_TYPE_ACCOUNT_FIELD;
				return result;
			}
		}
	}
	result = TUBA_ENTITY_CLASS (tuba_api_account_source_parent_class)->deserialize_array_type (G_TYPE_CHECK_INSTANCE_CAST (self, TUBA_TYPE_ENTITY, TubaEntity), prop);
	return result;
}

TubaAPIAccountSource*
tuba_api_account_source_construct (GType object_type)
{
	TubaAPIAccountSource * self = NULL;
	self = (TubaAPIAccountSource*) tuba_entity_construct (object_type);
	return self;
}

TubaAPIAccountSource*
tuba_api_account_source_new (void)
{
	return tuba_api_account_source_construct (TUBA_API_TYPE_ACCOUNT_SOURCE);
}

const gchar*
tuba_api_account_source_get_language (TubaAPIAccountSource* self)
{
	const gchar* result;
	const gchar* _tmp0_;
	g_return_val_if_fail (self != NULL, NULL);
	_tmp0_ = self->priv->_language;
	result = _tmp0_;
	return result;
}

void
tuba_api_account_source_set_language (TubaAPIAccountSource* self,
                                      const gchar* value)
{
	gchar* old_value;
	g_return_if_fail (self != NULL);
	old_value = tuba_api_account_source_get_language (self);
	if (g_strcmp0 (value, old_value) != 0) {
		gchar* _tmp0_;
		_tmp0_ = g_strdup (value);
		_g_free0 (self->priv->_language);
		self->priv->_language = _tmp0_;
		g_object_notify_by_pspec ((GObject *) self, tuba_api_account_source_properties[TUBA_API_ACCOUNT_SOURCE_LANGUAGE_PROPERTY]);
	}
}

const gchar*
tuba_api_account_source_get_quote_policy (TubaAPIAccountSource* self)
{
	const gchar* result;
	const gchar* _tmp0_;
	g_return_val_if_fail (self != NULL, NULL);
	_tmp0_ = self->priv->_quote_policy;
	result = _tmp0_;
	return result;
}

void
tuba_api_account_source_set_quote_policy (TubaAPIAccountSource* self,
                                          const gchar* value)
{
	gchar* old_value;
	g_return_if_fail (self != NULL);
	old_value = tuba_api_account_source_get_quote_policy (self);
	if (g_strcmp0 (value, old_value) != 0) {
		gchar* _tmp0_;
		_tmp0_ = g_strdup (value);
		_g_free0 (self->priv->_quote_policy);
		self->priv->_quote_policy = _tmp0_;
		g_object_notify_by_pspec ((GObject *) self, tuba_api_account_source_properties[TUBA_API_ACCOUNT_SOURCE_QUOTE_POLICY_PROPERTY]);
	}
}

const gchar*
tuba_api_account_source_get_note (TubaAPIAccountSource* self)
{
	const gchar* result;
	const gchar* _tmp0_;
	g_return_val_if_fail (self != NULL, NULL);
	_tmp0_ = self->priv->_note;
	result = _tmp0_;
	return result;
}

void
tuba_api_account_source_set_note (TubaAPIAccountSource* self,
                                  const gchar* value)
{
	gchar* old_value;
	g_return_if_fail (self != NULL);
	old_value = tuba_api_account_source_get_note (self);
	if (g_strcmp0 (value, old_value) != 0) {
		gchar* _tmp0_;
		_tmp0_ = g_strdup (value);
		_g_free0 (self->priv->_note);
		self->priv->_note = _tmp0_;
		g_object_notify_by_pspec ((GObject *) self, tuba_api_account_source_properties[TUBA_API_ACCOUNT_SOURCE_NOTE_PROPERTY]);
	}
}

gint
tuba_api_account_source_get_follow_requests_count (TubaAPIAccountSource* self)
{
	gint result;
	g_return_val_if_fail (self != NULL, -1);
	result = self->priv->_follow_requests_count;
	return result;
}

void
tuba_api_account_source_set_follow_requests_count (TubaAPIAccountSource* self,
                                                   gint value)
{
	gint old_value;
	g_return_if_fail (self != NULL);
	old_value = tuba_api_account_source_get_follow_requests_count (self);
	if (old_value != value) {
		self->priv->_follow_requests_count = value;
		g_object_notify_by_pspec ((GObject *) self, tuba_api_account_source_properties[TUBA_API_ACCOUNT_SOURCE_FOLLOW_REQUESTS_COUNT_PROPERTY]);
	}
}

const gchar*
tuba_api_account_source_get_privacy (TubaAPIAccountSource* self)
{
	const gchar* result;
	const gchar* _tmp0_;
	g_return_val_if_fail (self != NULL, NULL);
	_tmp0_ = self->priv->_privacy;
	result = _tmp0_;
	return result;
}

void
tuba_api_account_source_set_privacy (TubaAPIAccountSource* self,
                                     const gchar* value)
{
	gchar* old_value;
	g_return_if_fail (self != NULL);
	old_value = tuba_api_account_source_get_privacy (self);
	if (g_strcmp0 (value, old_value) != 0) {
		gchar* _tmp0_;
		_tmp0_ = g_strdup (value);
		_g_free0 (self->priv->_privacy);
		self->priv->_privacy = _tmp0_;
		g_object_notify_by_pspec ((GObject *) self, tuba_api_account_source_properties[TUBA_API_ACCOUNT_SOURCE_PRIVACY_PROPERTY]);
	}
}

GeeArrayList*
tuba_api_account_source_get_fields (TubaAPIAccountSource* self)
{
	GeeArrayList* result;
	GeeArrayList* _tmp0_;
	g_return_val_if_fail (self != NULL, NULL);
	_tmp0_ = self->priv->_fields;
	result = _tmp0_;
	return result;
}

static gpointer
_g_object_ref0 (gpointer self)
{
	return self ? g_object_ref (self) : NULL;
}

void
tuba_api_account_source_set_fields (TubaAPIAccountSource* self,
                                    GeeArrayList* value)
{
	GeeArrayList* old_value;
	g_return_if_fail (self != NULL);
	old_value = tuba_api_account_source_get_fields (self);
	if (old_value != value) {
		GeeArrayList* _tmp0_;
		_tmp0_ = _g_object_ref0 (value);
		_g_object_unref0 (self->priv->_fields);
		self->priv->_fields = _tmp0_;
		g_object_notify_by_pspec ((GObject *) self, tuba_api_account_source_properties[TUBA_API_ACCOUNT_SOURCE_FIELDS_PROPERTY]);
	}
}

static void
tuba_api_account_source_class_init (TubaAPIAccountSourceClass * klass,
                                    gpointer klass_data)
{
	tuba_api_account_source_parent_class = g_type_class_peek_parent (klass);
	g_type_class_adjust_private_offset (klass, &TubaAPIAccountSource_private_offset);
	((TubaEntityClass *) klass)->deserialize_array_type = (GType (*) (TubaEntity*, const gchar*)) tuba_api_account_source_real_deserialize_array_type;
	G_OBJECT_CLASS (klass)->get_property = _vala_tuba_api_account_source_get_property;
	G_OBJECT_CLASS (klass)->set_property = _vala_tuba_api_account_source_set_property;
	G_OBJECT_CLASS (klass)->finalize = tuba_api_account_source_finalize;
	g_object_class_install_property (G_OBJECT_CLASS (klass), TUBA_API_ACCOUNT_SOURCE_LANGUAGE_PROPERTY, tuba_api_account_source_properties[TUBA_API_ACCOUNT_SOURCE_LANGUAGE_PROPERTY] = g_param_spec_string ("language", "language", "language", NULL, G_PARAM_STATIC_STRINGS | G_PARAM_READABLE | G_PARAM_WRITABLE));
	g_object_class_install_property (G_OBJECT_CLASS (klass), TUBA_API_ACCOUNT_SOURCE_QUOTE_POLICY_PROPERTY, tuba_api_account_source_properties[TUBA_API_ACCOUNT_SOURCE_QUOTE_POLICY_PROPERTY] = g_param_spec_string ("quote-policy", "quote-policy", "quote-policy", NULL, G_PARAM_STATIC_STRINGS | G_PARAM_READABLE | G_PARAM_WRITABLE));
	g_object_class_install_property (G_OBJECT_CLASS (klass), TUBA_API_ACCOUNT_SOURCE_NOTE_PROPERTY, tuba_api_account_source_properties[TUBA_API_ACCOUNT_SOURCE_NOTE_PROPERTY] = g_param_spec_string ("note", "note", "note", NULL, G_PARAM_STATIC_STRINGS | G_PARAM_READABLE | G_PARAM_WRITABLE));
	g_object_class_install_property (G_OBJECT_CLASS (klass), TUBA_API_ACCOUNT_SOURCE_FOLLOW_REQUESTS_COUNT_PROPERTY, tuba_api_account_source_properties[TUBA_API_ACCOUNT_SOURCE_FOLLOW_REQUESTS_COUNT_PROPERTY] = g_param_spec_int ("follow-requests-count", "follow-requests-count", "follow-requests-count", G_MININT, G_MAXINT, 0, G_PARAM_STATIC_STRINGS | G_PARAM_READABLE | G_PARAM_WRITABLE));
	g_object_class_install_property (G_OBJECT_CLASS (klass), TUBA_API_ACCOUNT_SOURCE_PRIVACY_PROPERTY, tuba_api_account_source_properties[TUBA_API_ACCOUNT_SOURCE_PRIVACY_PROPERTY] = g_param_spec_string ("privacy", "privacy", "privacy", NULL, G_PARAM_STATIC_STRINGS | G_PARAM_READABLE | G_PARAM_WRITABLE));
	g_object_class_install_property (G_OBJECT_CLASS (klass), TUBA_API_ACCOUNT_SOURCE_FIELDS_PROPERTY, tuba_api_account_source_properties[TUBA_API_ACCOUNT_SOURCE_FIELDS_PROPERTY] = g_param_spec_object ("fields", "fields", "fields", GEE_TYPE_ARRAY_LIST, G_PARAM_STATIC_STRINGS | G_PARAM_READABLE | G_PARAM_WRITABLE));
}

static void
tuba_api_account_source_instance_init (TubaAPIAccountSource * self,
                                       gpointer klass)
{
	gchar* _tmp0_;
	gchar* _tmp1_;
	gchar* _tmp2_;
	gchar* _tmp3_;
	self->priv = tuba_api_account_source_get_instance_private (self);
	_tmp0_ = g_strdup ("");
	self->priv->_language = _tmp0_;
	_tmp1_ = g_strdup ("");
	self->priv->_quote_policy = _tmp1_;
	_tmp2_ = g_strdup ("");
	self->priv->_note = _tmp2_;
	self->priv->_follow_requests_count = 0;
	_tmp3_ = g_strdup ("");
	self->priv->_privacy = _tmp3_;
	self->priv->_fields = NULL;
}

static void
tuba_api_account_source_finalize (GObject * obj)
{
	TubaAPIAccountSource * self;
	self = G_TYPE_CHECK_INSTANCE_CAST (obj, TUBA_API_TYPE_ACCOUNT_SOURCE, TubaAPIAccountSource);
	_g_free0 (self->priv->_language);
	_g_free0 (self->priv->_quote_policy);
	_g_free0 (self->priv->_note);
	_g_free0 (self->priv->_privacy);
	_g_object_unref0 (self->priv->_fields);
	G_OBJECT_CLASS (tuba_api_account_source_parent_class)->finalize (obj);
}

 G_GNUC_NO_INLINE static GType
tuba_api_account_source_get_type_once (void)
{
	static const GTypeInfo g_define_type_info = { sizeof (TubaAPIAccountSourceClass), (GBaseInitFunc) NULL, (GBaseFinalizeFunc) NULL, (GClassInitFunc) tuba_api_account_source_class_init, (GClassFinalizeFunc) NULL, NULL, sizeof (TubaAPIAccountSource), 0, (GInstanceInitFunc) tuba_api_account_source_instance_init, NULL };
	GType tuba_api_account_source_type_id;
	tuba_api_account_source_type_id = g_type_register_static (TUBA_TYPE_ENTITY, "TubaAPIAccountSource", &g_define_type_info, G_TYPE_FLAG_NONE);
	TubaAPIAccountSource_private_offset = g_type_add_instance_private (tuba_api_account_source_type_id, sizeof (TubaAPIAccountSourcePrivate));
	return tuba_api_account_source_type_id;
}

GType
tuba_api_account_source_get_type (void)
{
	static GType tuba_api_account_source_type_id__once = 0;
	if (g_once_init_enter_pointer (&tuba_api_account_source_type_id__once)) {
		GType tuba_api_account_source_type_id;
		tuba_api_account_source_type_id = tuba_api_account_source_get_type_once ();
		g_once_init_leave_pointer (&tuba_api_account_source_type_id__once, tuba_api_account_source_type_id);
	}
	return tuba_api_account_source_type_id__once;
}

static void
_vala_tuba_api_account_source_get_property (GObject * object,
                                            guint property_id,
                                            GValue * value,
                                            GParamSpec * pspec)
{
	TubaAPIAccountSource * self;
	self = G_TYPE_CHECK_INSTANCE_CAST (object, TUBA_API_TYPE_ACCOUNT_SOURCE, TubaAPIAccountSource);
	switch (property_id) {
		case TUBA_API_ACCOUNT_SOURCE_LANGUAGE_PROPERTY:
		g_value_set_string (value, tuba_api_account_source_get_language (self));
		break;
		case TUBA_API_ACCOUNT_SOURCE_QUOTE_POLICY_PROPERTY:
		g_value_set_string (value, tuba_api_account_source_get_quote_policy (self));
		break;
		case TUBA_API_ACCOUNT_SOURCE_NOTE_PROPERTY:
		g_value_set_string (value, tuba_api_account_source_get_note (self));
		break;
		case TUBA_API_ACCOUNT_SOURCE_FOLLOW_REQUESTS_COUNT_PROPERTY:
		g_value_set_int (value, tuba_api_account_source_get_follow_requests_count (self));
		break;
		case TUBA_API_ACCOUNT_SOURCE_PRIVACY_PROPERTY:
		g_value_set_string (value, tuba_api_account_source_get_privacy (self));
		break;
		case TUBA_API_ACCOUNT_SOURCE_FIELDS_PROPERTY:
		g_value_set_object (value, tuba_api_account_source_get_fields (self));
		break;
		default:
		G_OBJECT_WARN_INVALID_PROPERTY_ID (object, property_id, pspec);
		break;
	}
}

static void
_vala_tuba_api_account_source_set_property (GObject * object,
                                            guint property_id,
                                            const GValue * value,
                                            GParamSpec * pspec)
{
	TubaAPIAccountSource * self;
	self = G_TYPE_CHECK_INSTANCE_CAST (object, TUBA_API_TYPE_ACCOUNT_SOURCE, TubaAPIAccountSource);
	switch (property_id) {
		case TUBA_API_ACCOUNT_SOURCE_LANGUAGE_PROPERTY:
		tuba_api_account_source_set_language (self, g_value_get_string (value));
		break;
		case TUBA_API_ACCOUNT_SOURCE_QUOTE_POLICY_PROPERTY:
		tuba_api_account_source_set_quote_policy (self, g_value_get_string (value));
		break;
		case TUBA_API_ACCOUNT_SOURCE_NOTE_PROPERTY:
		tuba_api_account_source_set_note (self, g_value_get_string (value));
		break;
		case TUBA_API_ACCOUNT_SOURCE_FOLLOW_REQUESTS_COUNT_PROPERTY:
		tuba_api_account_source_set_follow_requests_count (self, g_value_get_int (value));
		break;
		case TUBA_API_ACCOUNT_SOURCE_PRIVACY_PROPERTY:
		tuba_api_account_source_set_privacy (self, g_value_get_string (value));
		break;
		case TUBA_API_ACCOUNT_SOURCE_FIELDS_PROPERTY:
		tuba_api_account_source_set_fields (self, g_value_get_object (value));
		break;
		default:
		G_OBJECT_WARN_INVALID_PROPERTY_ID (object, property_id, pspec);
		break;
	}
}

