/*
 * Copyright 2024 KylinSoft Co., Ltd.
 *
 * This program is free software: you can redistribute it and/or modify it under
 * the terms of the GNU General Public License as published by the Free Software
 * Foundation, either version 3 of the License, or (at your option) any later
 * version.
 *
 * This program is distributed in the hope that it will be useful, but WITHOUT
 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
 * FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License along with
 * this program. If not, see <https://www.gnu.org/licenses/>.
 */

/*
 * This file is generated by gdbus-codegen, do not modify it.
 *
 * The license of this code is the same as for the D-Bus interface description
 * it was derived from. Note that it links to GLib, so must comply with the
 * LGPL linking clauses.
 */

#ifndef __TEXTPROCESSORGLUE_H__
#define __TEXTPROCESSORGLUE_H__

#include <gio/gio.h>

G_BEGIN_DECLS


/* ------------------------------------------------------------------------ */
/* Declarations for org.openkylin.aisdk.TextProcessor */

#define TYPE_AISDK_TEXT_PROCESSOR (aisdk_text_processor_get_type ())
#define AISDK_TEXT_PROCESSOR(o) (G_TYPE_CHECK_INSTANCE_CAST ((o), TYPE_AISDK_TEXT_PROCESSOR, AisdkTextProcessor))
#define IS_AISDK_TEXT_PROCESSOR(o) (G_TYPE_CHECK_INSTANCE_TYPE ((o), TYPE_AISDK_TEXT_PROCESSOR))
#define AISDK_TEXT_PROCESSOR_GET_IFACE(o) (G_TYPE_INSTANCE_GET_INTERFACE ((o), TYPE_AISDK_TEXT_PROCESSOR, AisdkTextProcessorIface))

struct _AisdkTextProcessor;
typedef struct _AisdkTextProcessor AisdkTextProcessor;
typedef struct _AisdkTextProcessorIface AisdkTextProcessorIface;

struct _AisdkTextProcessorIface
{
    GTypeInterface parent_iface;

    gboolean (*handle_chat) (
        AisdkTextProcessor *object,
        GDBusMethodInvocation *invocation,
        const gchar *arg_question);

    gboolean (*handle_clear_context) (
        AisdkTextProcessor *object,
        GDBusMethodInvocation *invocation);

    gboolean (*handle_init) (
        AisdkTextProcessor *object,
        GDBusMethodInvocation *invocation,
        const gchar *arg_engine_name,
        const gchar *arg_app_id,
        const gchar *arg_api_key,
        const gchar *arg_secret_key);

    gboolean (*handle_set_actor) (
        AisdkTextProcessor *object,
        GDBusMethodInvocation *invocation,
        gint arg_actor);

    gboolean (*handle_set_context) (
        AisdkTextProcessor *object,
        GDBusMethodInvocation *invocation,
        gint arg_size);

    gboolean (*handle_stop_chat) (
        AisdkTextProcessor *object,
        GDBusMethodInvocation *invocation);

};

GType aisdk_text_processor_get_type (void) G_GNUC_CONST;

GDBusInterfaceInfo *aisdk_text_processor_interface_info (void);
guint aisdk_text_processor_override_properties (GObjectClass *klass, guint property_id_begin);


/* D-Bus method call completion functions: */
void aisdk_text_processor_complete_init (
    AisdkTextProcessor *object,
    GDBusMethodInvocation *invocation);

void aisdk_text_processor_complete_chat (
    AisdkTextProcessor *object,
    GDBusMethodInvocation *invocation,
    const gchar *answer);

void aisdk_text_processor_complete_stop_chat (
    AisdkTextProcessor *object,
    GDBusMethodInvocation *invocation);

void aisdk_text_processor_complete_set_actor (
    AisdkTextProcessor *object,
    GDBusMethodInvocation *invocation);

void aisdk_text_processor_complete_set_context (
    AisdkTextProcessor *object,
    GDBusMethodInvocation *invocation);

void aisdk_text_processor_complete_clear_context (
    AisdkTextProcessor *object,
    GDBusMethodInvocation *invocation);



/* D-Bus method calls: */
void aisdk_text_processor_call_init (
    AisdkTextProcessor *proxy,
    const gchar *arg_engine_name,
    const gchar *arg_app_id,
    const gchar *arg_api_key,
    const gchar *arg_secret_key,
    GCancellable *cancellable,
    GAsyncReadyCallback callback,
    gpointer user_data);

gboolean aisdk_text_processor_call_init_finish (
    AisdkTextProcessor *proxy,
    GAsyncResult *res,
    GError **error);

gboolean aisdk_text_processor_call_init_sync (
    AisdkTextProcessor *proxy,
    const gchar *arg_engine_name,
    const gchar *arg_app_id,
    const gchar *arg_api_key,
    const gchar *arg_secret_key,
    GCancellable *cancellable,
    GError **error);

void aisdk_text_processor_call_chat (
    AisdkTextProcessor *proxy,
    const gchar *arg_question,
    GCancellable *cancellable,
    GAsyncReadyCallback callback,
    gpointer user_data);

gboolean aisdk_text_processor_call_chat_finish (
    AisdkTextProcessor *proxy,
    gchar **out_answer,
    GAsyncResult *res,
    GError **error);

gboolean aisdk_text_processor_call_chat_sync (
    AisdkTextProcessor *proxy,
    const gchar *arg_question,
    gchar **out_answer,
    GCancellable *cancellable,
    GError **error);

void aisdk_text_processor_call_stop_chat (
    AisdkTextProcessor *proxy,
    GCancellable *cancellable,
    GAsyncReadyCallback callback,
    gpointer user_data);

gboolean aisdk_text_processor_call_stop_chat_finish (
    AisdkTextProcessor *proxy,
    GAsyncResult *res,
    GError **error);

gboolean aisdk_text_processor_call_stop_chat_sync (
    AisdkTextProcessor *proxy,
    GCancellable *cancellable,
    GError **error);

void aisdk_text_processor_call_set_actor (
    AisdkTextProcessor *proxy,
    gint arg_actor,
    GCancellable *cancellable,
    GAsyncReadyCallback callback,
    gpointer user_data);

gboolean aisdk_text_processor_call_set_actor_finish (
    AisdkTextProcessor *proxy,
    GAsyncResult *res,
    GError **error);

gboolean aisdk_text_processor_call_set_actor_sync (
    AisdkTextProcessor *proxy,
    gint arg_actor,
    GCancellable *cancellable,
    GError **error);

void aisdk_text_processor_call_set_context (
    AisdkTextProcessor *proxy,
    gint arg_size,
    GCancellable *cancellable,
    GAsyncReadyCallback callback,
    gpointer user_data);

gboolean aisdk_text_processor_call_set_context_finish (
    AisdkTextProcessor *proxy,
    GAsyncResult *res,
    GError **error);

gboolean aisdk_text_processor_call_set_context_sync (
    AisdkTextProcessor *proxy,
    gint arg_size,
    GCancellable *cancellable,
    GError **error);

void aisdk_text_processor_call_clear_context (
    AisdkTextProcessor *proxy,
    GCancellable *cancellable,
    GAsyncReadyCallback callback,
    gpointer user_data);

gboolean aisdk_text_processor_call_clear_context_finish (
    AisdkTextProcessor *proxy,
    GAsyncResult *res,
    GError **error);

gboolean aisdk_text_processor_call_clear_context_sync (
    AisdkTextProcessor *proxy,
    GCancellable *cancellable,
    GError **error);



/* ---- */

#define TYPE_AISDK_TEXT_PROCESSOR_PROXY (aisdk_text_processor_proxy_get_type ())
#define AISDK_TEXT_PROCESSOR_PROXY(o) (G_TYPE_CHECK_INSTANCE_CAST ((o), TYPE_AISDK_TEXT_PROCESSOR_PROXY, AisdkTextProcessorProxy))
#define AISDK_TEXT_PROCESSOR_PROXY_CLASS(k) (G_TYPE_CHECK_CLASS_CAST ((k), TYPE_AISDK_TEXT_PROCESSOR_PROXY, AisdkTextProcessorProxyClass))
#define AISDK_TEXT_PROCESSOR_PROXY_GET_CLASS(o) (G_TYPE_INSTANCE_GET_CLASS ((o), TYPE_AISDK_TEXT_PROCESSOR_PROXY, AisdkTextProcessorProxyClass))
#define IS_AISDK_TEXT_PROCESSOR_PROXY(o) (G_TYPE_CHECK_INSTANCE_TYPE ((o), TYPE_AISDK_TEXT_PROCESSOR_PROXY))
#define IS_AISDK_TEXT_PROCESSOR_PROXY_CLASS(k) (G_TYPE_CHECK_CLASS_TYPE ((k), TYPE_AISDK_TEXT_PROCESSOR_PROXY))

typedef struct _AisdkTextProcessorProxy AisdkTextProcessorProxy;
typedef struct _AisdkTextProcessorProxyClass AisdkTextProcessorProxyClass;
typedef struct _AisdkTextProcessorProxyPrivate AisdkTextProcessorProxyPrivate;

struct _AisdkTextProcessorProxy
{
    /*< private >*/
    GDBusProxy parent_instance;
    AisdkTextProcessorProxyPrivate *priv;
};

struct _AisdkTextProcessorProxyClass
{
    GDBusProxyClass parent_class;
};

GType aisdk_text_processor_proxy_get_type (void) G_GNUC_CONST;

#if GLIB_CHECK_VERSION(2, 44, 0)
G_DEFINE_AUTOPTR_CLEANUP_FUNC (AisdkTextProcessorProxy, g_object_unref)
#endif

void aisdk_text_processor_proxy_new (
    GDBusConnection     *connection,
    GDBusProxyFlags      flags,
    const gchar         *name,
    const gchar         *object_path,
    GCancellable        *cancellable,
    GAsyncReadyCallback  callback,
    gpointer             user_data);
AisdkTextProcessor *aisdk_text_processor_proxy_new_finish (
    GAsyncResult        *res,
    GError             **error);
AisdkTextProcessor *aisdk_text_processor_proxy_new_sync (
    GDBusConnection     *connection,
    GDBusProxyFlags      flags,
    const gchar         *name,
    const gchar         *object_path,
    GCancellable        *cancellable,
    GError             **error);

void aisdk_text_processor_proxy_new_for_bus (
    GBusType             bus_type,
    GDBusProxyFlags      flags,
    const gchar         *name,
    const gchar         *object_path,
    GCancellable        *cancellable,
    GAsyncReadyCallback  callback,
    gpointer             user_data);
AisdkTextProcessor *aisdk_text_processor_proxy_new_for_bus_finish (
    GAsyncResult        *res,
    GError             **error);
AisdkTextProcessor *aisdk_text_processor_proxy_new_for_bus_sync (
    GBusType             bus_type,
    GDBusProxyFlags      flags,
    const gchar         *name,
    const gchar         *object_path,
    GCancellable        *cancellable,
    GError             **error);


/* ---- */

#define TYPE_AISDK_TEXT_PROCESSOR_SKELETON (aisdk_text_processor_skeleton_get_type ())
#define AISDK_TEXT_PROCESSOR_SKELETON(o) (G_TYPE_CHECK_INSTANCE_CAST ((o), TYPE_AISDK_TEXT_PROCESSOR_SKELETON, AisdkTextProcessorSkeleton))
#define AISDK_TEXT_PROCESSOR_SKELETON_CLASS(k) (G_TYPE_CHECK_CLASS_CAST ((k), TYPE_AISDK_TEXT_PROCESSOR_SKELETON, AisdkTextProcessorSkeletonClass))
#define AISDK_TEXT_PROCESSOR_SKELETON_GET_CLASS(o) (G_TYPE_INSTANCE_GET_CLASS ((o), TYPE_AISDK_TEXT_PROCESSOR_SKELETON, AisdkTextProcessorSkeletonClass))
#define IS_AISDK_TEXT_PROCESSOR_SKELETON(o) (G_TYPE_CHECK_INSTANCE_TYPE ((o), TYPE_AISDK_TEXT_PROCESSOR_SKELETON))
#define IS_AISDK_TEXT_PROCESSOR_SKELETON_CLASS(k) (G_TYPE_CHECK_CLASS_TYPE ((k), TYPE_AISDK_TEXT_PROCESSOR_SKELETON))

typedef struct _AisdkTextProcessorSkeleton AisdkTextProcessorSkeleton;
typedef struct _AisdkTextProcessorSkeletonClass AisdkTextProcessorSkeletonClass;
typedef struct _AisdkTextProcessorSkeletonPrivate AisdkTextProcessorSkeletonPrivate;

struct _AisdkTextProcessorSkeleton
{
    /*< private >*/
    GDBusInterfaceSkeleton parent_instance;
    AisdkTextProcessorSkeletonPrivate *priv;
};

struct _AisdkTextProcessorSkeletonClass
{
    GDBusInterfaceSkeletonClass parent_class;
};

GType aisdk_text_processor_skeleton_get_type (void) G_GNUC_CONST;

#if GLIB_CHECK_VERSION(2, 44, 0)
G_DEFINE_AUTOPTR_CLEANUP_FUNC (AisdkTextProcessorSkeleton, g_object_unref)
#endif

AisdkTextProcessor *aisdk_text_processor_skeleton_new (void);


G_END_DECLS

#endif /* __TEXTPROCESSORGLUE_H__ */
