/* geary-folder-supports-empty.c generated by valac 0.56.19, the Vala compiler
 * generated from geary-folder-supports-empty.vala, do not modify */

/*
 * Copyright 2016 Software Freedom Conservancy Inc.
 *
 * This software is licensed under the GNU Lesser General Public License
 * (version 2.1 or later).  See the COPYING file in this distribution.
 */

#include "geary-engine.h"
#include <gio/gio.h>
#include <glib.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

static GType geary_folder_support_empty_get_type_once (void);

void
geary_folder_support_empty_empty_folder_async (GearyFolderSupportEmpty* self,
                                               GCancellable* cancellable,
                                               GAsyncReadyCallback _callback_,
                                               gpointer _user_data_)
{
	GearyFolderSupportEmptyIface* _iface_;
	_iface_ = GEARY_FOLDER_SUPPORT_EMPTY_GET_INTERFACE (self);
	if (_iface_->empty_folder_async) {
		_iface_->empty_folder_async (self, cancellable, _callback_, _user_data_);
	}
}

void
geary_folder_support_empty_empty_folder_finish (GearyFolderSupportEmpty* self,
                                                GAsyncResult* _res_,
                                                GError** error)
{
	GearyFolderSupportEmptyIface* _iface_;
	_iface_ = GEARY_FOLDER_SUPPORT_EMPTY_GET_INTERFACE (self);
	if (_iface_->empty_folder_finish) {
		_iface_->empty_folder_finish (self, _res_, error);
	}
}

static void
geary_folder_support_empty_default_init (GearyFolderSupportEmptyIface * iface,
                                         gpointer iface_data)
{
}

/**
 * The addition of the Geary.FolderSupport.Empty interface to a {@link
 * Geary.Folder} indicates that it supports removing (deleting) all
 * email quickly.
 *
 * This generally means that the message is deleted from the server
 * and is not recoverable.  It does ''not'' mean the messages are
 * moved to a Trash folder where they may or may not be automatically
 * deleted some time later.  Users invoking empty are expecting all
 * contents on the remote to be removed entirely, whether or not any
 * or all of them have been synchronized locally.
 *
 * @see FolderSupport.Remove
 */
 G_GNUC_NO_INLINE static GType
geary_folder_support_empty_get_type_once (void)
{
	static const GTypeInfo g_define_type_info = { sizeof (GearyFolderSupportEmptyIface), (GBaseInitFunc) NULL, (GBaseFinalizeFunc) NULL, (GClassInitFunc) geary_folder_support_empty_default_init, (GClassFinalizeFunc) NULL, NULL, 0, 0, (GInstanceInitFunc) NULL, NULL };
	GType geary_folder_support_empty_type_id;
	geary_folder_support_empty_type_id = g_type_register_static (G_TYPE_INTERFACE, "GearyFolderSupportEmpty", &g_define_type_info, 0);
	g_type_interface_add_prerequisite (geary_folder_support_empty_type_id, GEARY_TYPE_FOLDER);
	return geary_folder_support_empty_type_id;
}

GType
geary_folder_support_empty_get_type (void)
{
	static gsize geary_folder_support_empty_type_id__once = 0;
	if (g_once_init_enter (&geary_folder_support_empty_type_id__once)) {
		GType geary_folder_support_empty_type_id;
		geary_folder_support_empty_type_id = geary_folder_support_empty_get_type_once ();
		g_once_init_leave (&geary_folder_support_empty_type_id__once, geary_folder_support_empty_type_id);
	}
	return geary_folder_support_empty_type_id__once;
}

