/* Statuses.c generated by valac 0.56.19, the Vala compiler
 * generated from Statuses.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>

#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_MASTODON_CONFIGURATION_TYPE_STATUSES (tuba_api_mastodon_configuration_statuses_get_type ())
#define TUBA_API_MASTODON_CONFIGURATION_STATUSES(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TUBA_API_MASTODON_CONFIGURATION_TYPE_STATUSES, TubaAPIMastodonConfigurationStatuses))
#define TUBA_API_MASTODON_CONFIGURATION_STATUSES_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TUBA_API_MASTODON_CONFIGURATION_TYPE_STATUSES, TubaAPIMastodonConfigurationStatusesClass))
#define TUBA_API_MASTODON_CONFIGURATION_IS_STATUSES(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TUBA_API_MASTODON_CONFIGURATION_TYPE_STATUSES))
#define TUBA_API_MASTODON_CONFIGURATION_IS_STATUSES_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TUBA_API_MASTODON_CONFIGURATION_TYPE_STATUSES))
#define TUBA_API_MASTODON_CONFIGURATION_STATUSES_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TUBA_API_MASTODON_CONFIGURATION_TYPE_STATUSES, TubaAPIMastodonConfigurationStatusesClass))

typedef struct _TubaAPIMastodonConfigurationStatuses TubaAPIMastodonConfigurationStatuses;
typedef struct _TubaAPIMastodonConfigurationStatusesClass TubaAPIMastodonConfigurationStatusesClass;
typedef struct _TubaAPIMastodonConfigurationStatusesPrivate TubaAPIMastodonConfigurationStatusesPrivate;
enum  {
	TUBA_API_MASTODON_CONFIGURATION_STATUSES_0_PROPERTY,
	TUBA_API_MASTODON_CONFIGURATION_STATUSES_MAX_CHARACTERS_PROPERTY,
	TUBA_API_MASTODON_CONFIGURATION_STATUSES_MAX_MEDIA_ATTACHMENTS_PROPERTY,
	TUBA_API_MASTODON_CONFIGURATION_STATUSES_CHARACTERS_RESERVED_PER_URL_PROPERTY,
	TUBA_API_MASTODON_CONFIGURATION_STATUSES_SUPPORTED_MIME_TYPES_PROPERTY,
	TUBA_API_MASTODON_CONFIGURATION_STATUSES_NUM_PROPERTIES
};
static GParamSpec* tuba_api_mastodon_configuration_statuses_properties[TUBA_API_MASTODON_CONFIGURATION_STATUSES_NUM_PROPERTIES];

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 _TubaAPIMastodonConfigurationStatuses {
	TubaEntity parent_instance;
	TubaAPIMastodonConfigurationStatusesPrivate * priv;
};

struct _TubaAPIMastodonConfigurationStatusesClass {
	TubaEntityClass parent_class;
};

struct _TubaAPIMastodonConfigurationStatusesPrivate {
	gint64 _max_characters;
	gint64 _max_media_attachments;
	gint _characters_reserved_per_url;
	gchar** _supported_mime_types;
	gint _supported_mime_types_length1;
	gint __supported_mime_types_size_;
};

static gint TubaAPIMastodonConfigurationStatuses_private_offset;
static gpointer tuba_api_mastodon_configuration_statuses_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_mastodon_configuration_statuses_get_type (void) G_GNUC_CONST ;
G_DEFINE_AUTOPTR_CLEANUP_FUNC (TubaAPIMastodonConfigurationStatuses, g_object_unref)
VALA_EXTERN TubaAPIMastodonConfigurationStatuses* tuba_api_mastodon_configuration_statuses_new (void);
VALA_EXTERN TubaAPIMastodonConfigurationStatuses* tuba_api_mastodon_configuration_statuses_construct (GType object_type);
VALA_EXTERN TubaEntity* tuba_entity_new (void);
VALA_EXTERN TubaEntity* tuba_entity_construct (GType object_type);
VALA_EXTERN gint64 tuba_api_mastodon_configuration_statuses_get_max_characters (TubaAPIMastodonConfigurationStatuses* self);
VALA_EXTERN void tuba_api_mastodon_configuration_statuses_set_max_characters (TubaAPIMastodonConfigurationStatuses* self,
                                                                  gint64 value);
VALA_EXTERN gint64 tuba_api_mastodon_configuration_statuses_get_max_media_attachments (TubaAPIMastodonConfigurationStatuses* self);
VALA_EXTERN void tuba_api_mastodon_configuration_statuses_set_max_media_attachments (TubaAPIMastodonConfigurationStatuses* self,
                                                                         gint64 value);
VALA_EXTERN gint tuba_api_mastodon_configuration_statuses_get_characters_reserved_per_url (TubaAPIMastodonConfigurationStatuses* self);
VALA_EXTERN void tuba_api_mastodon_configuration_statuses_set_characters_reserved_per_url (TubaAPIMastodonConfigurationStatuses* self,
                                                                               gint value);
VALA_EXTERN gchar** tuba_api_mastodon_configuration_statuses_get_supported_mime_types (TubaAPIMastodonConfigurationStatuses* self,
                                                                           gint* result_length1);
VALA_EXTERN void tuba_api_mastodon_configuration_statuses_set_supported_mime_types (TubaAPIMastodonConfigurationStatuses* self,
                                                                        gchar** value,
                                                                        gint value_length1);
static gchar** _vala_array_dup7 (gchar** self,
                          gssize length);
static void tuba_api_mastodon_configuration_statuses_finalize (GObject * obj);
static GType tuba_api_mastodon_configuration_statuses_get_type_once (void);
static void _vala_tuba_api_mastodon_configuration_statuses_get_property (GObject * object,
                                                                  guint property_id,
                                                                  GValue * value,
                                                                  GParamSpec * pspec);
static void _vala_tuba_api_mastodon_configuration_statuses_set_property (GObject * object,
                                                                  guint property_id,
                                                                  const GValue * value,
                                                                  GParamSpec * pspec);
static void _vala_array_destroy (gpointer array,
                          gssize array_length,
                          GDestroyNotify destroy_func);
static void _vala_array_free (gpointer array,
                       gssize array_length,
                       GDestroyNotify destroy_func);

static inline gpointer
tuba_api_mastodon_configuration_statuses_get_instance_private (TubaAPIMastodonConfigurationStatuses* self)
{
	return G_STRUCT_MEMBER_P (self, TubaAPIMastodonConfigurationStatuses_private_offset);
}

TubaAPIMastodonConfigurationStatuses*
tuba_api_mastodon_configuration_statuses_construct (GType object_type)
{
	TubaAPIMastodonConfigurationStatuses * self = NULL;
	self = (TubaAPIMastodonConfigurationStatuses*) tuba_entity_construct (object_type);
	return self;
}

TubaAPIMastodonConfigurationStatuses*
tuba_api_mastodon_configuration_statuses_new (void)
{
	return tuba_api_mastodon_configuration_statuses_construct (TUBA_API_MASTODON_CONFIGURATION_TYPE_STATUSES);
}

gint64
tuba_api_mastodon_configuration_statuses_get_max_characters (TubaAPIMastodonConfigurationStatuses* self)
{
	gint64 result;
	g_return_val_if_fail (self != NULL, -1LL);
	result = self->priv->_max_characters;
	return result;
}

void
tuba_api_mastodon_configuration_statuses_set_max_characters (TubaAPIMastodonConfigurationStatuses* self,
                                                             gint64 value)
{
	gint64 old_value;
	g_return_if_fail (self != NULL);
	old_value = tuba_api_mastodon_configuration_statuses_get_max_characters (self);
	if (old_value != value) {
		self->priv->_max_characters = value;
		g_object_notify_by_pspec ((GObject *) self, tuba_api_mastodon_configuration_statuses_properties[TUBA_API_MASTODON_CONFIGURATION_STATUSES_MAX_CHARACTERS_PROPERTY]);
	}
}

gint64
tuba_api_mastodon_configuration_statuses_get_max_media_attachments (TubaAPIMastodonConfigurationStatuses* self)
{
	gint64 result;
	g_return_val_if_fail (self != NULL, -1LL);
	result = self->priv->_max_media_attachments;
	return result;
}

void
tuba_api_mastodon_configuration_statuses_set_max_media_attachments (TubaAPIMastodonConfigurationStatuses* self,
                                                                    gint64 value)
{
	gint64 old_value;
	g_return_if_fail (self != NULL);
	old_value = tuba_api_mastodon_configuration_statuses_get_max_media_attachments (self);
	if (old_value != value) {
		self->priv->_max_media_attachments = value;
		g_object_notify_by_pspec ((GObject *) self, tuba_api_mastodon_configuration_statuses_properties[TUBA_API_MASTODON_CONFIGURATION_STATUSES_MAX_MEDIA_ATTACHMENTS_PROPERTY]);
	}
}

gint
tuba_api_mastodon_configuration_statuses_get_characters_reserved_per_url (TubaAPIMastodonConfigurationStatuses* self)
{
	gint result;
	g_return_val_if_fail (self != NULL, -1);
	result = self->priv->_characters_reserved_per_url;
	return result;
}

void
tuba_api_mastodon_configuration_statuses_set_characters_reserved_per_url (TubaAPIMastodonConfigurationStatuses* self,
                                                                          gint value)
{
	gint old_value;
	g_return_if_fail (self != NULL);
	old_value = tuba_api_mastodon_configuration_statuses_get_characters_reserved_per_url (self);
	if (old_value != value) {
		self->priv->_characters_reserved_per_url = value;
		g_object_notify_by_pspec ((GObject *) self, tuba_api_mastodon_configuration_statuses_properties[TUBA_API_MASTODON_CONFIGURATION_STATUSES_CHARACTERS_RESERVED_PER_URL_PROPERTY]);
	}
}

gchar**
tuba_api_mastodon_configuration_statuses_get_supported_mime_types (TubaAPIMastodonConfigurationStatuses* self,
                                                                   gint* result_length1)
{
	gchar** result;
	gchar** _tmp0_;
	gint _tmp0__length1;
	gchar** _tmp1_;
	gint _tmp1__length1;
	g_return_val_if_fail (self != NULL, NULL);
	_tmp0_ = self->priv->_supported_mime_types;
	_tmp0__length1 = self->priv->_supported_mime_types_length1;
	_tmp1_ = _tmp0_;
	_tmp1__length1 = _tmp0__length1;
	if (result_length1) {
		*result_length1 = _tmp1__length1;
	}
	result = _tmp1_;
	return result;
}

static gchar**
_vala_array_dup7 (gchar** self,
                  gssize length)
{
	if (length >= 0) {
		gchar** result;
		gssize i;
		result = g_new0 (gchar*, length + 1);
		for (i = 0; i < length; i++) {
			gchar* _tmp0_;
			_tmp0_ = g_strdup (self[i]);
			result[i] = _tmp0_;
		}
		return result;
	}
	return NULL;
}

void
tuba_api_mastodon_configuration_statuses_set_supported_mime_types (TubaAPIMastodonConfigurationStatuses* self,
                                                                   gchar** value,
                                                                   gint value_length1)
{
	gchar** old_value;
	gint old_value_length;
	g_return_if_fail (self != NULL);
	old_value = tuba_api_mastodon_configuration_statuses_get_supported_mime_types (self, &old_value_length);
	if (old_value != value) {
		gchar** _tmp0_;
		gint _tmp0__length1;
		_tmp0_ = (value != NULL) ? _vala_array_dup7 (value, value_length1) : value;
		_tmp0__length1 = value_length1;
		self->priv->_supported_mime_types = (_vala_array_free (self->priv->_supported_mime_types, self->priv->_supported_mime_types_length1, (GDestroyNotify) g_free), NULL);
		self->priv->_supported_mime_types = _tmp0_;
		self->priv->_supported_mime_types_length1 = _tmp0__length1;
		self->priv->__supported_mime_types_size_ = self->priv->_supported_mime_types_length1;
		g_object_notify_by_pspec ((GObject *) self, tuba_api_mastodon_configuration_statuses_properties[TUBA_API_MASTODON_CONFIGURATION_STATUSES_SUPPORTED_MIME_TYPES_PROPERTY]);
	}
}

static void
tuba_api_mastodon_configuration_statuses_class_init (TubaAPIMastodonConfigurationStatusesClass * klass,
                                                     gpointer klass_data)
{
	tuba_api_mastodon_configuration_statuses_parent_class = g_type_class_peek_parent (klass);
	g_type_class_adjust_private_offset (klass, &TubaAPIMastodonConfigurationStatuses_private_offset);
	G_OBJECT_CLASS (klass)->get_property = _vala_tuba_api_mastodon_configuration_statuses_get_property;
	G_OBJECT_CLASS (klass)->set_property = _vala_tuba_api_mastodon_configuration_statuses_set_property;
	G_OBJECT_CLASS (klass)->finalize = tuba_api_mastodon_configuration_statuses_finalize;
	g_object_class_install_property (G_OBJECT_CLASS (klass), TUBA_API_MASTODON_CONFIGURATION_STATUSES_MAX_CHARACTERS_PROPERTY, tuba_api_mastodon_configuration_statuses_properties[TUBA_API_MASTODON_CONFIGURATION_STATUSES_MAX_CHARACTERS_PROPERTY] = g_param_spec_int64 ("max-characters", "max-characters", "max-characters", G_MININT64, G_MAXINT64, 0, G_PARAM_STATIC_STRINGS | G_PARAM_READABLE | G_PARAM_WRITABLE));
	g_object_class_install_property (G_OBJECT_CLASS (klass), TUBA_API_MASTODON_CONFIGURATION_STATUSES_MAX_MEDIA_ATTACHMENTS_PROPERTY, tuba_api_mastodon_configuration_statuses_properties[TUBA_API_MASTODON_CONFIGURATION_STATUSES_MAX_MEDIA_ATTACHMENTS_PROPERTY] = g_param_spec_int64 ("max-media-attachments", "max-media-attachments", "max-media-attachments", G_MININT64, G_MAXINT64, 0, G_PARAM_STATIC_STRINGS | G_PARAM_READABLE | G_PARAM_WRITABLE));
	g_object_class_install_property (G_OBJECT_CLASS (klass), TUBA_API_MASTODON_CONFIGURATION_STATUSES_CHARACTERS_RESERVED_PER_URL_PROPERTY, tuba_api_mastodon_configuration_statuses_properties[TUBA_API_MASTODON_CONFIGURATION_STATUSES_CHARACTERS_RESERVED_PER_URL_PROPERTY] = g_param_spec_int ("characters-reserved-per-url", "characters-reserved-per-url", "characters-reserved-per-url", 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_MASTODON_CONFIGURATION_STATUSES_SUPPORTED_MIME_TYPES_PROPERTY, tuba_api_mastodon_configuration_statuses_properties[TUBA_API_MASTODON_CONFIGURATION_STATUSES_SUPPORTED_MIME_TYPES_PROPERTY] = g_param_spec_boxed ("supported-mime-types", "supported-mime-types", "supported-mime-types", G_TYPE_STRV, G_PARAM_STATIC_STRINGS | G_PARAM_READABLE | G_PARAM_WRITABLE));
}

static void
tuba_api_mastodon_configuration_statuses_instance_init (TubaAPIMastodonConfigurationStatuses * self,
                                                        gpointer klass)
{
	self->priv = tuba_api_mastodon_configuration_statuses_get_instance_private (self);
	self->priv->_characters_reserved_per_url = 0;
	self->priv->_supported_mime_types = NULL;
	self->priv->_supported_mime_types_length1 = 0;
	self->priv->__supported_mime_types_size_ = self->priv->_supported_mime_types_length1;
}

static void
tuba_api_mastodon_configuration_statuses_finalize (GObject * obj)
{
	TubaAPIMastodonConfigurationStatuses * self;
	self = G_TYPE_CHECK_INSTANCE_CAST (obj, TUBA_API_MASTODON_CONFIGURATION_TYPE_STATUSES, TubaAPIMastodonConfigurationStatuses);
	self->priv->_supported_mime_types = (_vala_array_free (self->priv->_supported_mime_types, self->priv->_supported_mime_types_length1, (GDestroyNotify) g_free), NULL);
	G_OBJECT_CLASS (tuba_api_mastodon_configuration_statuses_parent_class)->finalize (obj);
}

 G_GNUC_NO_INLINE static GType
tuba_api_mastodon_configuration_statuses_get_type_once (void)
{
	static const GTypeInfo g_define_type_info = { sizeof (TubaAPIMastodonConfigurationStatusesClass), (GBaseInitFunc) NULL, (GBaseFinalizeFunc) NULL, (GClassInitFunc) tuba_api_mastodon_configuration_statuses_class_init, (GClassFinalizeFunc) NULL, NULL, sizeof (TubaAPIMastodonConfigurationStatuses), 0, (GInstanceInitFunc) tuba_api_mastodon_configuration_statuses_instance_init, NULL };
	GType tuba_api_mastodon_configuration_statuses_type_id;
	tuba_api_mastodon_configuration_statuses_type_id = g_type_register_static (TUBA_TYPE_ENTITY, "TubaAPIMastodonConfigurationStatuses", &g_define_type_info, G_TYPE_FLAG_NONE);
	TubaAPIMastodonConfigurationStatuses_private_offset = g_type_add_instance_private (tuba_api_mastodon_configuration_statuses_type_id, sizeof (TubaAPIMastodonConfigurationStatusesPrivate));
	return tuba_api_mastodon_configuration_statuses_type_id;
}

GType
tuba_api_mastodon_configuration_statuses_get_type (void)
{
	static GType tuba_api_mastodon_configuration_statuses_type_id__once = 0;
	if (g_once_init_enter_pointer (&tuba_api_mastodon_configuration_statuses_type_id__once)) {
		GType tuba_api_mastodon_configuration_statuses_type_id;
		tuba_api_mastodon_configuration_statuses_type_id = tuba_api_mastodon_configuration_statuses_get_type_once ();
		g_once_init_leave_pointer (&tuba_api_mastodon_configuration_statuses_type_id__once, tuba_api_mastodon_configuration_statuses_type_id);
	}
	return tuba_api_mastodon_configuration_statuses_type_id__once;
}

static void
_vala_tuba_api_mastodon_configuration_statuses_get_property (GObject * object,
                                                             guint property_id,
                                                             GValue * value,
                                                             GParamSpec * pspec)
{
	TubaAPIMastodonConfigurationStatuses * self;
	self = G_TYPE_CHECK_INSTANCE_CAST (object, TUBA_API_MASTODON_CONFIGURATION_TYPE_STATUSES, TubaAPIMastodonConfigurationStatuses);
	switch (property_id) {
		case TUBA_API_MASTODON_CONFIGURATION_STATUSES_MAX_CHARACTERS_PROPERTY:
		g_value_set_int64 (value, tuba_api_mastodon_configuration_statuses_get_max_characters (self));
		break;
		case TUBA_API_MASTODON_CONFIGURATION_STATUSES_MAX_MEDIA_ATTACHMENTS_PROPERTY:
		g_value_set_int64 (value, tuba_api_mastodon_configuration_statuses_get_max_media_attachments (self));
		break;
		case TUBA_API_MASTODON_CONFIGURATION_STATUSES_CHARACTERS_RESERVED_PER_URL_PROPERTY:
		g_value_set_int (value, tuba_api_mastodon_configuration_statuses_get_characters_reserved_per_url (self));
		break;
		case TUBA_API_MASTODON_CONFIGURATION_STATUSES_SUPPORTED_MIME_TYPES_PROPERTY:
		{
			int length;
			g_value_set_boxed (value, tuba_api_mastodon_configuration_statuses_get_supported_mime_types (self, &length));
		}
		break;
		default:
		G_OBJECT_WARN_INVALID_PROPERTY_ID (object, property_id, pspec);
		break;
	}
}

static void
_vala_tuba_api_mastodon_configuration_statuses_set_property (GObject * object,
                                                             guint property_id,
                                                             const GValue * value,
                                                             GParamSpec * pspec)
{
	TubaAPIMastodonConfigurationStatuses * self;
	self = G_TYPE_CHECK_INSTANCE_CAST (object, TUBA_API_MASTODON_CONFIGURATION_TYPE_STATUSES, TubaAPIMastodonConfigurationStatuses);
	switch (property_id) {
		case TUBA_API_MASTODON_CONFIGURATION_STATUSES_MAX_CHARACTERS_PROPERTY:
		tuba_api_mastodon_configuration_statuses_set_max_characters (self, g_value_get_int64 (value));
		break;
		case TUBA_API_MASTODON_CONFIGURATION_STATUSES_MAX_MEDIA_ATTACHMENTS_PROPERTY:
		tuba_api_mastodon_configuration_statuses_set_max_media_attachments (self, g_value_get_int64 (value));
		break;
		case TUBA_API_MASTODON_CONFIGURATION_STATUSES_CHARACTERS_RESERVED_PER_URL_PROPERTY:
		tuba_api_mastodon_configuration_statuses_set_characters_reserved_per_url (self, g_value_get_int (value));
		break;
		case TUBA_API_MASTODON_CONFIGURATION_STATUSES_SUPPORTED_MIME_TYPES_PROPERTY:
		{
			gpointer boxed;
			boxed = g_value_get_boxed (value);
			tuba_api_mastodon_configuration_statuses_set_supported_mime_types (self, boxed, (boxed == NULL) ? 0 : g_strv_length (boxed));
		}
		break;
		default:
		G_OBJECT_WARN_INVALID_PROPERTY_ID (object, property_id, pspec);
		break;
	}
}

static void
_vala_array_destroy (gpointer array,
                     gssize array_length,
                     GDestroyNotify destroy_func)
{
	if ((array != NULL) && (destroy_func != NULL)) {
		gssize i;
		for (i = 0; i < array_length; i = i + 1) {
			if (((gpointer*) array)[i] != NULL) {
				destroy_func (((gpointer*) array)[i]);
			}
		}
	}
}

static void
_vala_array_free (gpointer array,
                  gssize array_length,
                  GDestroyNotify destroy_func)
{
	_vala_array_destroy (array, array_length, destroy_func);
	g_free (array);
}

