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

/* Generated by vala-dbus-binding-tool 1.0-aa2fb. Do not modify! */
/* Generated with: vala-dbus-binding-tool --api-path=./org.freedesktop.FileManager1.xml --directory=./ --strip-namespace=org --rename-namespace=freedesktop:Freedesktop --no-synced */

#include "../../application.h"
#include <stdlib.h>
#include <string.h>
#include <glib.h>
#include <gio/gio.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

typedef GDBusProxy FreedesktopFileManager1Proxy;
typedef GDBusProxyClass FreedesktopFileManager1ProxyClass;
#define _g_free0(var) (var = (g_free (var), NULL))

static GType freedesktop_file_manager1_get_type_once (void);
static void freedesktop_file_manager1_proxy_g_signal (GDBusProxy* proxy,
                                               const gchar* sender_name,
                                               const gchar* signal_name,
                                               GVariant* parameters);
static void freedesktop_file_manager1_proxy_show_folders (FreedesktopFileManager1* self,
                                                   gchar** URIs,
                                                   gint URIs_length1,
                                                   const gchar* StartupId,
                                                   GError** error);
static void freedesktop_file_manager1_proxy_show_items (FreedesktopFileManager1* self,
                                                 gchar** URIs,
                                                 gint URIs_length1,
                                                 const gchar* StartupId,
                                                 GError** error);
static void freedesktop_file_manager1_proxy_show_item_properties (FreedesktopFileManager1* self,
                                                           gchar** URIs,
                                                           gint URIs_length1,
                                                           const gchar* StartupId,
                                                           GError** error);
static void freedesktop_file_manager1_proxy_freedesktop_file_manager1_interface_init (FreedesktopFileManager1Iface* iface);
static void _dbus_freedesktop_file_manager1_show_folders (FreedesktopFileManager1* self,
                                                   GVariant* _parameters_,
                                                   GDBusMethodInvocation* invocation);
static void _dbus_freedesktop_file_manager1_show_items (FreedesktopFileManager1* self,
                                                 GVariant* _parameters_,
                                                 GDBusMethodInvocation* invocation);
static void _dbus_freedesktop_file_manager1_show_item_properties (FreedesktopFileManager1* self,
                                                           GVariant* _parameters_,
                                                           GDBusMethodInvocation* invocation);
static void freedesktop_file_manager1_dbus_interface_method_call (GDBusConnection* connection,
                                                           const gchar* sender,
                                                           const gchar* object_path,
                                                           const gchar* interface_name,
                                                           const gchar* method_name,
                                                           GVariant* parameters,
                                                           GDBusMethodInvocation* invocation,
                                                           gpointer user_data);
static GVariant* freedesktop_file_manager1_dbus_interface_get_property (GDBusConnection* connection,
                                                                 const gchar* sender,
                                                                 const gchar* object_path,
                                                                 const gchar* interface_name,
                                                                 const gchar* property_name,
                                                                 GError** error,
                                                                 gpointer user_data);
static gboolean freedesktop_file_manager1_dbus_interface_set_property (GDBusConnection* connection,
                                                                const gchar* sender,
                                                                const gchar* object_path,
                                                                const gchar* interface_name,
                                                                const gchar* property_name,
                                                                GVariant* value,
                                                                GError** error,
                                                                gpointer user_data);
static void _freedesktop_file_manager1_unregister_object (gpointer user_data);
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 _vala_memdup2 (gconstpointer mem,
                        gsize byte_size);

static const GDBusArgInfo _freedesktop_file_manager1_dbus_arg_info_show_folders_URIs = {-1, "URIs", "as", NULL};
static const GDBusArgInfo _freedesktop_file_manager1_dbus_arg_info_show_folders_StartupId = {-1, "StartupId", "s", NULL};
static const GDBusArgInfo * const _freedesktop_file_manager1_dbus_arg_info_show_folders_in[] = {&_freedesktop_file_manager1_dbus_arg_info_show_folders_URIs, &_freedesktop_file_manager1_dbus_arg_info_show_folders_StartupId, NULL};
static const GDBusArgInfo * const _freedesktop_file_manager1_dbus_arg_info_show_folders_out[] = {NULL};
static const GDBusMethodInfo _freedesktop_file_manager1_dbus_method_info_show_folders = {-1, "ShowFolders", (GDBusArgInfo **) (&_freedesktop_file_manager1_dbus_arg_info_show_folders_in), (GDBusArgInfo **) (&_freedesktop_file_manager1_dbus_arg_info_show_folders_out), NULL};
static const GDBusArgInfo _freedesktop_file_manager1_dbus_arg_info_show_items_URIs = {-1, "URIs", "as", NULL};
static const GDBusArgInfo _freedesktop_file_manager1_dbus_arg_info_show_items_StartupId = {-1, "StartupId", "s", NULL};
static const GDBusArgInfo * const _freedesktop_file_manager1_dbus_arg_info_show_items_in[] = {&_freedesktop_file_manager1_dbus_arg_info_show_items_URIs, &_freedesktop_file_manager1_dbus_arg_info_show_items_StartupId, NULL};
static const GDBusArgInfo * const _freedesktop_file_manager1_dbus_arg_info_show_items_out[] = {NULL};
static const GDBusMethodInfo _freedesktop_file_manager1_dbus_method_info_show_items = {-1, "ShowItems", (GDBusArgInfo **) (&_freedesktop_file_manager1_dbus_arg_info_show_items_in), (GDBusArgInfo **) (&_freedesktop_file_manager1_dbus_arg_info_show_items_out), NULL};
static const GDBusArgInfo _freedesktop_file_manager1_dbus_arg_info_show_item_properties_URIs = {-1, "URIs", "as", NULL};
static const GDBusArgInfo _freedesktop_file_manager1_dbus_arg_info_show_item_properties_StartupId = {-1, "StartupId", "s", NULL};
static const GDBusArgInfo * const _freedesktop_file_manager1_dbus_arg_info_show_item_properties_in[] = {&_freedesktop_file_manager1_dbus_arg_info_show_item_properties_URIs, &_freedesktop_file_manager1_dbus_arg_info_show_item_properties_StartupId, NULL};
static const GDBusArgInfo * const _freedesktop_file_manager1_dbus_arg_info_show_item_properties_out[] = {NULL};
static const GDBusMethodInfo _freedesktop_file_manager1_dbus_method_info_show_item_properties = {-1, "ShowItemProperties", (GDBusArgInfo **) (&_freedesktop_file_manager1_dbus_arg_info_show_item_properties_in), (GDBusArgInfo **) (&_freedesktop_file_manager1_dbus_arg_info_show_item_properties_out), NULL};
static const GDBusMethodInfo * const _freedesktop_file_manager1_dbus_method_info[] = {&_freedesktop_file_manager1_dbus_method_info_show_folders, &_freedesktop_file_manager1_dbus_method_info_show_items, &_freedesktop_file_manager1_dbus_method_info_show_item_properties, NULL};
static const GDBusSignalInfo * const _freedesktop_file_manager1_dbus_signal_info[] = {NULL};
static const GDBusPropertyInfo * const _freedesktop_file_manager1_dbus_property_info[] = {NULL};
static const GDBusInterfaceInfo _freedesktop_file_manager1_dbus_interface_info = {-1, "org.freedesktop.FileManager1", (GDBusMethodInfo **) (&_freedesktop_file_manager1_dbus_method_info), (GDBusSignalInfo **) (&_freedesktop_file_manager1_dbus_signal_info), (GDBusPropertyInfo **) (&_freedesktop_file_manager1_dbus_property_info), NULL};
static const GDBusInterfaceVTable _freedesktop_file_manager1_dbus_interface_vtable = {freedesktop_file_manager1_dbus_interface_method_call, freedesktop_file_manager1_dbus_interface_get_property, freedesktop_file_manager1_dbus_interface_set_property};

void
freedesktop_file_manager1_show_folders (FreedesktopFileManager1* self,
                                        gchar** URIs,
                                        gint URIs_length1,
                                        const gchar* StartupId,
                                        GError** error)
{
	FreedesktopFileManager1Iface* _iface_;
	g_return_if_fail (self != NULL);
	_iface_ = FREEDESKTOP_FILE_MANAGER1_GET_INTERFACE (self);
	if (_iface_->show_folders) {
		_iface_->show_folders (self, URIs, URIs_length1, StartupId, error);
	}
}

void
freedesktop_file_manager1_show_items (FreedesktopFileManager1* self,
                                      gchar** URIs,
                                      gint URIs_length1,
                                      const gchar* StartupId,
                                      GError** error)
{
	FreedesktopFileManager1Iface* _iface_;
	g_return_if_fail (self != NULL);
	_iface_ = FREEDESKTOP_FILE_MANAGER1_GET_INTERFACE (self);
	if (_iface_->show_items) {
		_iface_->show_items (self, URIs, URIs_length1, StartupId, error);
	}
}

void
freedesktop_file_manager1_show_item_properties (FreedesktopFileManager1* self,
                                                gchar** URIs,
                                                gint URIs_length1,
                                                const gchar* StartupId,
                                                GError** error)
{
	FreedesktopFileManager1Iface* _iface_;
	g_return_if_fail (self != NULL);
	_iface_ = FREEDESKTOP_FILE_MANAGER1_GET_INTERFACE (self);
	if (_iface_->show_item_properties) {
		_iface_->show_item_properties (self, URIs, URIs_length1, StartupId, error);
	}
}

static void
freedesktop_file_manager1_default_init (FreedesktopFileManager1Iface * iface,
                                        gpointer iface_data)
{
}

static GType
freedesktop_file_manager1_get_type_once (void)
{
	static const GTypeInfo g_define_type_info = { sizeof (FreedesktopFileManager1Iface), (GBaseInitFunc) NULL, (GBaseFinalizeFunc) NULL, (GClassInitFunc) freedesktop_file_manager1_default_init, (GClassFinalizeFunc) NULL, NULL, 0, 0, (GInstanceInitFunc) NULL, NULL };
	GType freedesktop_file_manager1_type_id;
	freedesktop_file_manager1_type_id = g_type_register_static (G_TYPE_INTERFACE, "FreedesktopFileManager1", &g_define_type_info, 0);
	g_type_interface_add_prerequisite (freedesktop_file_manager1_type_id, G_TYPE_OBJECT);
	g_type_set_qdata (freedesktop_file_manager1_type_id, g_quark_from_static_string ("vala-dbus-proxy-type"), (void*) freedesktop_file_manager1_proxy_get_type);
	g_type_set_qdata (freedesktop_file_manager1_type_id, g_quark_from_static_string ("vala-dbus-interface-name"), "org.freedesktop.FileManager1");
	g_type_set_qdata (freedesktop_file_manager1_type_id, g_quark_from_static_string ("vala-dbus-interface-info"), (void*) (&_freedesktop_file_manager1_dbus_interface_info));
	g_type_set_qdata (freedesktop_file_manager1_type_id, g_quark_from_static_string ("vala-dbus-register-object"), (void*) freedesktop_file_manager1_register_object);
	return freedesktop_file_manager1_type_id;
}

GType
freedesktop_file_manager1_get_type (void)
{
	static volatile gsize freedesktop_file_manager1_type_id__once = 0;
	if (g_once_init_enter (&freedesktop_file_manager1_type_id__once)) {
		GType freedesktop_file_manager1_type_id;
		freedesktop_file_manager1_type_id = freedesktop_file_manager1_get_type_once ();
		g_once_init_leave (&freedesktop_file_manager1_type_id__once, freedesktop_file_manager1_type_id);
	}
	return freedesktop_file_manager1_type_id__once;
}

G_DEFINE_TYPE_EXTENDED (FreedesktopFileManager1Proxy, freedesktop_file_manager1_proxy, G_TYPE_DBUS_PROXY, 0, G_IMPLEMENT_INTERFACE (FREEDESKTOP_TYPE_FILE_MANAGER1, freedesktop_file_manager1_proxy_freedesktop_file_manager1_interface_init) )
static void
freedesktop_file_manager1_proxy_class_init (FreedesktopFileManager1ProxyClass* klass)
{
	G_DBUS_PROXY_CLASS (klass)->g_signal = freedesktop_file_manager1_proxy_g_signal;
}

static void
freedesktop_file_manager1_proxy_g_signal (GDBusProxy* proxy,
                                          const gchar* sender_name,
                                          const gchar* signal_name,
                                          GVariant* parameters)
{
}

static void
freedesktop_file_manager1_proxy_init (FreedesktopFileManager1Proxy* self)
{
	g_dbus_proxy_set_interface_info (G_DBUS_PROXY (self), (GDBusInterfaceInfo *) (&_freedesktop_file_manager1_dbus_interface_info));
}

static void
freedesktop_file_manager1_proxy_show_folders (FreedesktopFileManager1* self,
                                              gchar** URIs,
                                              gint URIs_length1,
                                              const gchar* StartupId,
                                              GError** error)
{
	GDBusMessage *_message;
	GVariant *_arguments;
	GVariantBuilder _arguments_builder;
	gchar** _tmp98_;
	GVariantBuilder _tmp99_;
	gint _tmp100_;
	GDBusMessage *_reply_message;
	G_DBUS_ERROR;
	G_IO_ERROR;
	_message = g_dbus_message_new_method_call (g_dbus_proxy_get_name ((GDBusProxy *) self), g_dbus_proxy_get_object_path ((GDBusProxy *) self), "org.freedesktop.FileManager1", "ShowFolders");
	g_variant_builder_init (&_arguments_builder, G_VARIANT_TYPE_TUPLE);
	_tmp98_ = URIs;
	g_variant_builder_init (&_tmp99_, G_VARIANT_TYPE ("as"));
	for (_tmp100_ = 0; _tmp100_ < URIs_length1; _tmp100_++) {
		g_variant_builder_add_value (&_tmp99_, g_variant_new_string (*_tmp98_));
		_tmp98_++;
	}
	g_variant_builder_add_value (&_arguments_builder, g_variant_builder_end (&_tmp99_));
	g_variant_builder_add_value (&_arguments_builder, g_variant_new_string (StartupId));
	_arguments = g_variant_builder_end (&_arguments_builder);
	g_dbus_message_set_body (_message, _arguments);
	_reply_message = g_dbus_connection_send_message_with_reply_sync (g_dbus_proxy_get_connection ((GDBusProxy *) self), _message, G_DBUS_SEND_MESSAGE_FLAGS_NONE, g_dbus_proxy_get_default_timeout ((GDBusProxy *) self), NULL, NULL, error);
	g_object_unref (_message);
	if (!_reply_message) {
		return;
	}
	if (g_dbus_message_to_gerror (_reply_message, error)) {
		g_object_unref (_reply_message);
		return;
	}
	g_object_unref (_reply_message);
}

static void
freedesktop_file_manager1_proxy_show_items (FreedesktopFileManager1* self,
                                            gchar** URIs,
                                            gint URIs_length1,
                                            const gchar* StartupId,
                                            GError** error)
{
	GDBusMessage *_message;
	GVariant *_arguments;
	GVariantBuilder _arguments_builder;
	gchar** _tmp101_;
	GVariantBuilder _tmp102_;
	gint _tmp103_;
	GDBusMessage *_reply_message;
	G_DBUS_ERROR;
	G_IO_ERROR;
	_message = g_dbus_message_new_method_call (g_dbus_proxy_get_name ((GDBusProxy *) self), g_dbus_proxy_get_object_path ((GDBusProxy *) self), "org.freedesktop.FileManager1", "ShowItems");
	g_variant_builder_init (&_arguments_builder, G_VARIANT_TYPE_TUPLE);
	_tmp101_ = URIs;
	g_variant_builder_init (&_tmp102_, G_VARIANT_TYPE ("as"));
	for (_tmp103_ = 0; _tmp103_ < URIs_length1; _tmp103_++) {
		g_variant_builder_add_value (&_tmp102_, g_variant_new_string (*_tmp101_));
		_tmp101_++;
	}
	g_variant_builder_add_value (&_arguments_builder, g_variant_builder_end (&_tmp102_));
	g_variant_builder_add_value (&_arguments_builder, g_variant_new_string (StartupId));
	_arguments = g_variant_builder_end (&_arguments_builder);
	g_dbus_message_set_body (_message, _arguments);
	_reply_message = g_dbus_connection_send_message_with_reply_sync (g_dbus_proxy_get_connection ((GDBusProxy *) self), _message, G_DBUS_SEND_MESSAGE_FLAGS_NONE, g_dbus_proxy_get_default_timeout ((GDBusProxy *) self), NULL, NULL, error);
	g_object_unref (_message);
	if (!_reply_message) {
		return;
	}
	if (g_dbus_message_to_gerror (_reply_message, error)) {
		g_object_unref (_reply_message);
		return;
	}
	g_object_unref (_reply_message);
}

static void
freedesktop_file_manager1_proxy_show_item_properties (FreedesktopFileManager1* self,
                                                      gchar** URIs,
                                                      gint URIs_length1,
                                                      const gchar* StartupId,
                                                      GError** error)
{
	GDBusMessage *_message;
	GVariant *_arguments;
	GVariantBuilder _arguments_builder;
	gchar** _tmp104_;
	GVariantBuilder _tmp105_;
	gint _tmp106_;
	GDBusMessage *_reply_message;
	G_DBUS_ERROR;
	G_IO_ERROR;
	_message = g_dbus_message_new_method_call (g_dbus_proxy_get_name ((GDBusProxy *) self), g_dbus_proxy_get_object_path ((GDBusProxy *) self), "org.freedesktop.FileManager1", "ShowItemProperties");
	g_variant_builder_init (&_arguments_builder, G_VARIANT_TYPE_TUPLE);
	_tmp104_ = URIs;
	g_variant_builder_init (&_tmp105_, G_VARIANT_TYPE ("as"));
	for (_tmp106_ = 0; _tmp106_ < URIs_length1; _tmp106_++) {
		g_variant_builder_add_value (&_tmp105_, g_variant_new_string (*_tmp104_));
		_tmp104_++;
	}
	g_variant_builder_add_value (&_arguments_builder, g_variant_builder_end (&_tmp105_));
	g_variant_builder_add_value (&_arguments_builder, g_variant_new_string (StartupId));
	_arguments = g_variant_builder_end (&_arguments_builder);
	g_dbus_message_set_body (_message, _arguments);
	_reply_message = g_dbus_connection_send_message_with_reply_sync (g_dbus_proxy_get_connection ((GDBusProxy *) self), _message, G_DBUS_SEND_MESSAGE_FLAGS_NONE, g_dbus_proxy_get_default_timeout ((GDBusProxy *) self), NULL, NULL, error);
	g_object_unref (_message);
	if (!_reply_message) {
		return;
	}
	if (g_dbus_message_to_gerror (_reply_message, error)) {
		g_object_unref (_reply_message);
		return;
	}
	g_object_unref (_reply_message);
}

static void
freedesktop_file_manager1_proxy_freedesktop_file_manager1_interface_init (FreedesktopFileManager1Iface* iface)
{
	iface->show_folders = freedesktop_file_manager1_proxy_show_folders;
	iface->show_items = freedesktop_file_manager1_proxy_show_items;
	iface->show_item_properties = freedesktop_file_manager1_proxy_show_item_properties;
}

static void
_dbus_freedesktop_file_manager1_show_folders (FreedesktopFileManager1* self,
                                              GVariant* _parameters_,
                                              GDBusMethodInvocation* invocation)
{
	GError* error = NULL;
	GVariantIter _arguments_iter;
	gchar** URIs = NULL;
	gint URIs_length1 = 0;
	GVariant* _tmp107_;
	gchar** _tmp108_;
	gint _tmp108__length;
	gint _tmp108__size;
	gint _tmp108__length1;
	GVariantIter _tmp109_;
	GVariant* _tmp110_;
	gchar* StartupId = NULL;
	GVariant* _tmp111_;
	GDBusMessage* _reply_message = NULL;
	GVariant* _reply;
	GVariantBuilder _reply_builder;
	g_variant_iter_init (&_arguments_iter, _parameters_);
	_tmp107_ = g_variant_iter_next_value (&_arguments_iter);
	_tmp108_ = g_new (gchar*, 5);
	_tmp108__length = 0;
	_tmp108__size = 4;
	_tmp108__length1 = 0;
	g_variant_iter_init (&_tmp109_, _tmp107_);
	for (; (_tmp110_ = g_variant_iter_next_value (&_tmp109_)) != NULL; _tmp108__length1++) {
		if (_tmp108__size == _tmp108__length) {
			_tmp108__size = 2 * _tmp108__size;
			_tmp108_ = g_renew (gchar*, _tmp108_, _tmp108__size + 1);
		}
		_tmp108_[_tmp108__length++] = g_variant_dup_string (_tmp110_, NULL);
		g_variant_unref (_tmp110_);
	}
	URIs_length1 = _tmp108__length1;
	_tmp108_[_tmp108__length] = NULL;
	URIs = _tmp108_;
	g_variant_unref (_tmp107_);
	_tmp111_ = g_variant_iter_next_value (&_arguments_iter);
	StartupId = g_variant_dup_string (_tmp111_, NULL);
	g_variant_unref (_tmp111_);
	freedesktop_file_manager1_show_folders (self, URIs, URIs_length1, StartupId, &error);
	if (error) {
		g_dbus_method_invocation_take_error (invocation, error);
		goto _error;
	}
	_reply_message = g_dbus_message_new_method_reply (g_dbus_method_invocation_get_message (invocation));
	g_variant_builder_init (&_reply_builder, G_VARIANT_TYPE_TUPLE);
	_reply = g_variant_builder_end (&_reply_builder);
	g_dbus_message_set_body (_reply_message, _reply);
	g_dbus_connection_send_message (g_dbus_method_invocation_get_connection (invocation), _reply_message, G_DBUS_SEND_MESSAGE_FLAGS_NONE, NULL, NULL);
	g_object_unref (invocation);
	g_object_unref (_reply_message);
	_error:
	URIs = (_vala_array_free (URIs, URIs_length1, (GDestroyNotify) g_free), NULL);
	_g_free0 (StartupId);
	;
}

static void
_dbus_freedesktop_file_manager1_show_items (FreedesktopFileManager1* self,
                                            GVariant* _parameters_,
                                            GDBusMethodInvocation* invocation)
{
	GError* error = NULL;
	GVariantIter _arguments_iter;
	gchar** URIs = NULL;
	gint URIs_length1 = 0;
	GVariant* _tmp112_;
	gchar** _tmp113_;
	gint _tmp113__length;
	gint _tmp113__size;
	gint _tmp113__length1;
	GVariantIter _tmp114_;
	GVariant* _tmp115_;
	gchar* StartupId = NULL;
	GVariant* _tmp116_;
	GDBusMessage* _reply_message = NULL;
	GVariant* _reply;
	GVariantBuilder _reply_builder;
	g_variant_iter_init (&_arguments_iter, _parameters_);
	_tmp112_ = g_variant_iter_next_value (&_arguments_iter);
	_tmp113_ = g_new (gchar*, 5);
	_tmp113__length = 0;
	_tmp113__size = 4;
	_tmp113__length1 = 0;
	g_variant_iter_init (&_tmp114_, _tmp112_);
	for (; (_tmp115_ = g_variant_iter_next_value (&_tmp114_)) != NULL; _tmp113__length1++) {
		if (_tmp113__size == _tmp113__length) {
			_tmp113__size = 2 * _tmp113__size;
			_tmp113_ = g_renew (gchar*, _tmp113_, _tmp113__size + 1);
		}
		_tmp113_[_tmp113__length++] = g_variant_dup_string (_tmp115_, NULL);
		g_variant_unref (_tmp115_);
	}
	URIs_length1 = _tmp113__length1;
	_tmp113_[_tmp113__length] = NULL;
	URIs = _tmp113_;
	g_variant_unref (_tmp112_);
	_tmp116_ = g_variant_iter_next_value (&_arguments_iter);
	StartupId = g_variant_dup_string (_tmp116_, NULL);
	g_variant_unref (_tmp116_);
	freedesktop_file_manager1_show_items (self, URIs, URIs_length1, StartupId, &error);
	if (error) {
		g_dbus_method_invocation_take_error (invocation, error);
		goto _error;
	}
	_reply_message = g_dbus_message_new_method_reply (g_dbus_method_invocation_get_message (invocation));
	g_variant_builder_init (&_reply_builder, G_VARIANT_TYPE_TUPLE);
	_reply = g_variant_builder_end (&_reply_builder);
	g_dbus_message_set_body (_reply_message, _reply);
	g_dbus_connection_send_message (g_dbus_method_invocation_get_connection (invocation), _reply_message, G_DBUS_SEND_MESSAGE_FLAGS_NONE, NULL, NULL);
	g_object_unref (invocation);
	g_object_unref (_reply_message);
	_error:
	URIs = (_vala_array_free (URIs, URIs_length1, (GDestroyNotify) g_free), NULL);
	_g_free0 (StartupId);
	;
}

static void
_dbus_freedesktop_file_manager1_show_item_properties (FreedesktopFileManager1* self,
                                                      GVariant* _parameters_,
                                                      GDBusMethodInvocation* invocation)
{
	GError* error = NULL;
	GVariantIter _arguments_iter;
	gchar** URIs = NULL;
	gint URIs_length1 = 0;
	GVariant* _tmp117_;
	gchar** _tmp118_;
	gint _tmp118__length;
	gint _tmp118__size;
	gint _tmp118__length1;
	GVariantIter _tmp119_;
	GVariant* _tmp120_;
	gchar* StartupId = NULL;
	GVariant* _tmp121_;
	GDBusMessage* _reply_message = NULL;
	GVariant* _reply;
	GVariantBuilder _reply_builder;
	g_variant_iter_init (&_arguments_iter, _parameters_);
	_tmp117_ = g_variant_iter_next_value (&_arguments_iter);
	_tmp118_ = g_new (gchar*, 5);
	_tmp118__length = 0;
	_tmp118__size = 4;
	_tmp118__length1 = 0;
	g_variant_iter_init (&_tmp119_, _tmp117_);
	for (; (_tmp120_ = g_variant_iter_next_value (&_tmp119_)) != NULL; _tmp118__length1++) {
		if (_tmp118__size == _tmp118__length) {
			_tmp118__size = 2 * _tmp118__size;
			_tmp118_ = g_renew (gchar*, _tmp118_, _tmp118__size + 1);
		}
		_tmp118_[_tmp118__length++] = g_variant_dup_string (_tmp120_, NULL);
		g_variant_unref (_tmp120_);
	}
	URIs_length1 = _tmp118__length1;
	_tmp118_[_tmp118__length] = NULL;
	URIs = _tmp118_;
	g_variant_unref (_tmp117_);
	_tmp121_ = g_variant_iter_next_value (&_arguments_iter);
	StartupId = g_variant_dup_string (_tmp121_, NULL);
	g_variant_unref (_tmp121_);
	freedesktop_file_manager1_show_item_properties (self, URIs, URIs_length1, StartupId, &error);
	if (error) {
		g_dbus_method_invocation_take_error (invocation, error);
		goto _error;
	}
	_reply_message = g_dbus_message_new_method_reply (g_dbus_method_invocation_get_message (invocation));
	g_variant_builder_init (&_reply_builder, G_VARIANT_TYPE_TUPLE);
	_reply = g_variant_builder_end (&_reply_builder);
	g_dbus_message_set_body (_reply_message, _reply);
	g_dbus_connection_send_message (g_dbus_method_invocation_get_connection (invocation), _reply_message, G_DBUS_SEND_MESSAGE_FLAGS_NONE, NULL, NULL);
	g_object_unref (invocation);
	g_object_unref (_reply_message);
	_error:
	URIs = (_vala_array_free (URIs, URIs_length1, (GDestroyNotify) g_free), NULL);
	_g_free0 (StartupId);
	;
}

static void
freedesktop_file_manager1_dbus_interface_method_call (GDBusConnection* connection,
                                                      const gchar* sender,
                                                      const gchar* object_path,
                                                      const gchar* interface_name,
                                                      const gchar* method_name,
                                                      GVariant* parameters,
                                                      GDBusMethodInvocation* invocation,
                                                      gpointer user_data)
{
	gpointer* data;
	gpointer object;
	data = user_data;
	object = data[0];
	if (strcmp (method_name, "ShowFolders") == 0) {
		_dbus_freedesktop_file_manager1_show_folders (object, parameters, invocation);
	} else if (strcmp (method_name, "ShowItems") == 0) {
		_dbus_freedesktop_file_manager1_show_items (object, parameters, invocation);
	} else if (strcmp (method_name, "ShowItemProperties") == 0) {
		_dbus_freedesktop_file_manager1_show_item_properties (object, parameters, invocation);
	} else {
		g_object_unref (invocation);
	}
}

static GVariant*
freedesktop_file_manager1_dbus_interface_get_property (GDBusConnection* connection,
                                                       const gchar* sender,
                                                       const gchar* object_path,
                                                       const gchar* interface_name,
                                                       const gchar* property_name,
                                                       GError** error,
                                                       gpointer user_data)
{
	gpointer* data;
	gpointer object;
	data = user_data;
	object = data[0];
	return NULL;
}

static gboolean
freedesktop_file_manager1_dbus_interface_set_property (GDBusConnection* connection,
                                                       const gchar* sender,
                                                       const gchar* object_path,
                                                       const gchar* interface_name,
                                                       const gchar* property_name,
                                                       GVariant* value,
                                                       GError** error,
                                                       gpointer user_data)
{
	gpointer* data;
	gpointer object;
	data = user_data;
	object = data[0];
	return FALSE;
}

guint
freedesktop_file_manager1_register_object (gpointer object,
                                           GDBusConnection* connection,
                                           const gchar* path,
                                           GError** error)
{
	guint result;
	gpointer *data;
	data = g_new (gpointer, 3);
	data[0] = g_object_ref (object);
	data[1] = g_object_ref (connection);
	data[2] = g_strdup (path);
	result = g_dbus_connection_register_object (connection, path, (GDBusInterfaceInfo *) (&_freedesktop_file_manager1_dbus_interface_info), &_freedesktop_file_manager1_dbus_interface_vtable, data, _freedesktop_file_manager1_unregister_object, error);
	if (!result) {
		return 0;
	}
	return result;
}

static void
_freedesktop_file_manager1_unregister_object (gpointer user_data)
{
	gpointer* data;
	data = user_data;
	g_object_unref (data[0]);
	g_object_unref (data[1]);
	g_free (data[2]);
	g_free (data);
}

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);
}

static inline gpointer
_vala_memdup2 (gconstpointer mem,
               gsize byte_size)
{
	gpointer new_mem;
	if (mem && byte_size != 0) {
		new_mem = g_malloc (byte_size);
		memcpy (new_mem, mem, byte_size);
	} else {
		new_mem = NULL;
	}
	return new_mem;
}

