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

#include "seafile-object.h"
#include <stdlib.h>
#include <string.h>
#include <glib.h>
#include <glib-object.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

enum  {
	SEAFILE_SHARE_LINK_INFO_0_PROPERTY,
	SEAFILE_SHARE_LINK_INFO_REPO_ID_PROPERTY,
	SEAFILE_SHARE_LINK_INFO_FILE_PATH_PROPERTY,
	SEAFILE_SHARE_LINK_INFO_PARENT_DIR_PROPERTY,
	SEAFILE_SHARE_LINK_INFO_SHARE_TYPE_PROPERTY,
	SEAFILE_SHARE_LINK_INFO_NUM_PROPERTIES
};
static GParamSpec* seafile_share_link_info_properties[SEAFILE_SHARE_LINK_INFO_NUM_PROPERTIES];
#define _g_free0(var) (var = (g_free (var), NULL))

struct _SeafileShareLinkInfoPrivate {
	gchar* _repo_id;
	gchar* _file_path;
	gchar* _parent_dir;
	gchar* _share_type;
};

static gint SeafileShareLinkInfo_private_offset;
static gpointer seafile_share_link_info_parent_class = NULL;

static void seafile_share_link_info_finalize (GObject * obj);
static GType seafile_share_link_info_get_type_once (void);
static void _vala_seafile_share_link_info_get_property (GObject * object,
                                                 guint property_id,
                                                 GValue * value,
                                                 GParamSpec * pspec);
static void _vala_seafile_share_link_info_set_property (GObject * object,
                                                 guint property_id,
                                                 const GValue * value,
                                                 GParamSpec * pspec);

static inline gpointer
seafile_share_link_info_get_instance_private (SeafileShareLinkInfo* self)
{
	return G_STRUCT_MEMBER_P (self, SeafileShareLinkInfo_private_offset);
}

SeafileShareLinkInfo*
seafile_share_link_info_construct (GType object_type)
{
	SeafileShareLinkInfo * self = NULL;
	self = (SeafileShareLinkInfo*) g_object_new (object_type, NULL);
	return self;
}

SeafileShareLinkInfo*
seafile_share_link_info_new (void)
{
	return seafile_share_link_info_construct (SEAFILE_TYPE_SHARE_LINK_INFO);
}

const gchar*
seafile_share_link_info_get_repo_id (SeafileShareLinkInfo* self)
{
	const gchar* result;
	const gchar* _tmp0_;
	g_return_val_if_fail (self != NULL, NULL);
	_tmp0_ = self->priv->_repo_id;
	result = _tmp0_;
	return result;
}

void
seafile_share_link_info_set_repo_id (SeafileShareLinkInfo* self,
                                     const gchar* value)
{
	gchar* old_value;
	g_return_if_fail (self != NULL);
	old_value = seafile_share_link_info_get_repo_id (self);
	if (g_strcmp0 (value, old_value) != 0) {
		gchar* _tmp0_;
		_tmp0_ = g_strdup (value);
		_g_free0 (self->priv->_repo_id);
		self->priv->_repo_id = _tmp0_;
		g_object_notify_by_pspec ((GObject *) self, seafile_share_link_info_properties[SEAFILE_SHARE_LINK_INFO_REPO_ID_PROPERTY]);
	}
}

const gchar*
seafile_share_link_info_get_file_path (SeafileShareLinkInfo* self)
{
	const gchar* result;
	const gchar* _tmp0_;
	g_return_val_if_fail (self != NULL, NULL);
	_tmp0_ = self->priv->_file_path;
	result = _tmp0_;
	return result;
}

void
seafile_share_link_info_set_file_path (SeafileShareLinkInfo* self,
                                       const gchar* value)
{
	gchar* old_value;
	g_return_if_fail (self != NULL);
	old_value = seafile_share_link_info_get_file_path (self);
	if (g_strcmp0 (value, old_value) != 0) {
		gchar* _tmp0_;
		_tmp0_ = g_strdup (value);
		_g_free0 (self->priv->_file_path);
		self->priv->_file_path = _tmp0_;
		g_object_notify_by_pspec ((GObject *) self, seafile_share_link_info_properties[SEAFILE_SHARE_LINK_INFO_FILE_PATH_PROPERTY]);
	}
}

const gchar*
seafile_share_link_info_get_parent_dir (SeafileShareLinkInfo* self)
{
	const gchar* result;
	const gchar* _tmp0_;
	g_return_val_if_fail (self != NULL, NULL);
	_tmp0_ = self->priv->_parent_dir;
	result = _tmp0_;
	return result;
}

void
seafile_share_link_info_set_parent_dir (SeafileShareLinkInfo* self,
                                        const gchar* value)
{
	gchar* old_value;
	g_return_if_fail (self != NULL);
	old_value = seafile_share_link_info_get_parent_dir (self);
	if (g_strcmp0 (value, old_value) != 0) {
		gchar* _tmp0_;
		_tmp0_ = g_strdup (value);
		_g_free0 (self->priv->_parent_dir);
		self->priv->_parent_dir = _tmp0_;
		g_object_notify_by_pspec ((GObject *) self, seafile_share_link_info_properties[SEAFILE_SHARE_LINK_INFO_PARENT_DIR_PROPERTY]);
	}
}

const gchar*
seafile_share_link_info_get_share_type (SeafileShareLinkInfo* self)
{
	const gchar* result;
	const gchar* _tmp0_;
	g_return_val_if_fail (self != NULL, NULL);
	_tmp0_ = self->priv->_share_type;
	result = _tmp0_;
	return result;
}

void
seafile_share_link_info_set_share_type (SeafileShareLinkInfo* self,
                                        const gchar* value)
{
	gchar* old_value;
	g_return_if_fail (self != NULL);
	old_value = seafile_share_link_info_get_share_type (self);
	if (g_strcmp0 (value, old_value) != 0) {
		gchar* _tmp0_;
		_tmp0_ = g_strdup (value);
		_g_free0 (self->priv->_share_type);
		self->priv->_share_type = _tmp0_;
		g_object_notify_by_pspec ((GObject *) self, seafile_share_link_info_properties[SEAFILE_SHARE_LINK_INFO_SHARE_TYPE_PROPERTY]);
	}
}

static void
seafile_share_link_info_class_init (SeafileShareLinkInfoClass * klass,
                                    gpointer klass_data)
{
	seafile_share_link_info_parent_class = g_type_class_peek_parent (klass);
	g_type_class_adjust_private_offset (klass, &SeafileShareLinkInfo_private_offset);
	G_OBJECT_CLASS (klass)->get_property = _vala_seafile_share_link_info_get_property;
	G_OBJECT_CLASS (klass)->set_property = _vala_seafile_share_link_info_set_property;
	G_OBJECT_CLASS (klass)->finalize = seafile_share_link_info_finalize;
	g_object_class_install_property (G_OBJECT_CLASS (klass), SEAFILE_SHARE_LINK_INFO_REPO_ID_PROPERTY, seafile_share_link_info_properties[SEAFILE_SHARE_LINK_INFO_REPO_ID_PROPERTY] = g_param_spec_string ("repo-id", "repo-id", "repo-id", NULL, G_PARAM_STATIC_STRINGS | G_PARAM_READABLE | G_PARAM_WRITABLE));
	g_object_class_install_property (G_OBJECT_CLASS (klass), SEAFILE_SHARE_LINK_INFO_FILE_PATH_PROPERTY, seafile_share_link_info_properties[SEAFILE_SHARE_LINK_INFO_FILE_PATH_PROPERTY] = g_param_spec_string ("file-path", "file-path", "file-path", NULL, G_PARAM_STATIC_STRINGS | G_PARAM_READABLE | G_PARAM_WRITABLE));
	g_object_class_install_property (G_OBJECT_CLASS (klass), SEAFILE_SHARE_LINK_INFO_PARENT_DIR_PROPERTY, seafile_share_link_info_properties[SEAFILE_SHARE_LINK_INFO_PARENT_DIR_PROPERTY] = g_param_spec_string ("parent-dir", "parent-dir", "parent-dir", NULL, G_PARAM_STATIC_STRINGS | G_PARAM_READABLE | G_PARAM_WRITABLE));
	g_object_class_install_property (G_OBJECT_CLASS (klass), SEAFILE_SHARE_LINK_INFO_SHARE_TYPE_PROPERTY, seafile_share_link_info_properties[SEAFILE_SHARE_LINK_INFO_SHARE_TYPE_PROPERTY] = g_param_spec_string ("share-type", "share-type", "share-type", NULL, G_PARAM_STATIC_STRINGS | G_PARAM_READABLE | G_PARAM_WRITABLE));
}

static void
seafile_share_link_info_instance_init (SeafileShareLinkInfo * self,
                                       gpointer klass)
{
	self->priv = seafile_share_link_info_get_instance_private (self);
}

static void
seafile_share_link_info_finalize (GObject * obj)
{
	SeafileShareLinkInfo * self;
	self = G_TYPE_CHECK_INSTANCE_CAST (obj, SEAFILE_TYPE_SHARE_LINK_INFO, SeafileShareLinkInfo);
	_g_free0 (self->priv->_repo_id);
	_g_free0 (self->priv->_file_path);
	_g_free0 (self->priv->_parent_dir);
	_g_free0 (self->priv->_share_type);
	G_OBJECT_CLASS (seafile_share_link_info_parent_class)->finalize (obj);
}

static GType
seafile_share_link_info_get_type_once (void)
{
	static const GTypeInfo g_define_type_info = { sizeof (SeafileShareLinkInfoClass), (GBaseInitFunc) NULL, (GBaseFinalizeFunc) NULL, (GClassInitFunc) seafile_share_link_info_class_init, (GClassFinalizeFunc) NULL, NULL, sizeof (SeafileShareLinkInfo), 0, (GInstanceInitFunc) seafile_share_link_info_instance_init, NULL };
	GType seafile_share_link_info_type_id;
	seafile_share_link_info_type_id = g_type_register_static (G_TYPE_OBJECT, "SeafileShareLinkInfo", &g_define_type_info, 0);
	SeafileShareLinkInfo_private_offset = g_type_add_instance_private (seafile_share_link_info_type_id, sizeof (SeafileShareLinkInfoPrivate));
	return seafile_share_link_info_type_id;
}

GType
seafile_share_link_info_get_type (void)
{
	static volatile gsize seafile_share_link_info_type_id__once = 0;
	if (g_once_init_enter (&seafile_share_link_info_type_id__once)) {
		GType seafile_share_link_info_type_id;
		seafile_share_link_info_type_id = seafile_share_link_info_get_type_once ();
		g_once_init_leave (&seafile_share_link_info_type_id__once, seafile_share_link_info_type_id);
	}
	return seafile_share_link_info_type_id__once;
}

static void
_vala_seafile_share_link_info_get_property (GObject * object,
                                            guint property_id,
                                            GValue * value,
                                            GParamSpec * pspec)
{
	SeafileShareLinkInfo * self;
	self = G_TYPE_CHECK_INSTANCE_CAST (object, SEAFILE_TYPE_SHARE_LINK_INFO, SeafileShareLinkInfo);
	switch (property_id) {
		case SEAFILE_SHARE_LINK_INFO_REPO_ID_PROPERTY:
		g_value_set_string (value, seafile_share_link_info_get_repo_id (self));
		break;
		case SEAFILE_SHARE_LINK_INFO_FILE_PATH_PROPERTY:
		g_value_set_string (value, seafile_share_link_info_get_file_path (self));
		break;
		case SEAFILE_SHARE_LINK_INFO_PARENT_DIR_PROPERTY:
		g_value_set_string (value, seafile_share_link_info_get_parent_dir (self));
		break;
		case SEAFILE_SHARE_LINK_INFO_SHARE_TYPE_PROPERTY:
		g_value_set_string (value, seafile_share_link_info_get_share_type (self));
		break;
		default:
		G_OBJECT_WARN_INVALID_PROPERTY_ID (object, property_id, pspec);
		break;
	}
}

static void
_vala_seafile_share_link_info_set_property (GObject * object,
                                            guint property_id,
                                            const GValue * value,
                                            GParamSpec * pspec)
{
	SeafileShareLinkInfo * self;
	self = G_TYPE_CHECK_INSTANCE_CAST (object, SEAFILE_TYPE_SHARE_LINK_INFO, SeafileShareLinkInfo);
	switch (property_id) {
		case SEAFILE_SHARE_LINK_INFO_REPO_ID_PROPERTY:
		seafile_share_link_info_set_repo_id (self, g_value_get_string (value));
		break;
		case SEAFILE_SHARE_LINK_INFO_FILE_PATH_PROPERTY:
		seafile_share_link_info_set_file_path (self, g_value_get_string (value));
		break;
		case SEAFILE_SHARE_LINK_INFO_PARENT_DIR_PROPERTY:
		seafile_share_link_info_set_parent_dir (self, g_value_get_string (value));
		break;
		case SEAFILE_SHARE_LINK_INFO_SHARE_TYPE_PROPERTY:
		seafile_share_link_info_set_share_type (self, g_value_get_string (value));
		break;
		default:
		G_OBJECT_WARN_INVALID_PROPERTY_ID (object, property_id, pspec);
		break;
	}
}

