aboutsummaryrefslogtreecommitdiff
path: root/src/remote-login.h
blob: 6b0d229cc030ee795d5842355f400a07210843dd (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
/*
 * Generated by gdbus-codegen 2.33.12. DO NOT EDIT.
 *
 * The license of this code is the same as for the source it was derived from.
 */

#ifndef __REMOTE_LOGIN_H__
#define __REMOTE_LOGIN_H__

#include <gio/gio.h>

G_BEGIN_DECLS


/* ------------------------------------------------------------------------ */
/* Declarations for com.canonical.RemoteLogin */

#define TYPE_REMOTE_LOGIN (remote_login_get_type ())
#define REMOTE_LOGIN(o) (G_TYPE_CHECK_INSTANCE_CAST ((o), TYPE_REMOTE_LOGIN, RemoteLogin))
#define IS_REMOTE_LOGIN(o) (G_TYPE_CHECK_INSTANCE_TYPE ((o), TYPE_REMOTE_LOGIN))
#define REMOTE_LOGIN_GET_IFACE(o) (G_TYPE_INSTANCE_GET_INTERFACE ((o), TYPE_REMOTE_LOGIN, RemoteLoginIface))

struct _RemoteLogin;
typedef struct _RemoteLogin RemoteLogin;
typedef struct _RemoteLoginIface RemoteLoginIface;

struct _RemoteLoginIface
{
  GTypeInterface parent_iface;


  gboolean (*handle_get_cached_domains_for_server) (
    RemoteLogin *object,
    GDBusMethodInvocation *invocation,
    const gchar *arg_uri);

  gboolean (*handle_get_servers) (
    RemoteLogin *object,
    GDBusMethodInvocation *invocation);

  gboolean (*handle_get_servers_for_login) (
    RemoteLogin *object,
    GDBusMethodInvocation *invocation,
    const gchar *arg_uri,
    const gchar *arg_emailAddress,
    const gchar *arg_password,
    gboolean arg_allowCache);

  gboolean (*handle_set_applications_for_server) (
    RemoteLogin *object,
    GDBusMethodInvocation *invocation,
    const gchar *arg_uccsUri,
    const gchar *arg_serverUri,
    GVariant *arg_applications);

  gboolean (*handle_set_last_used_server) (
    RemoteLogin *object,
    GDBusMethodInvocation *invocation,
    const gchar *arg_uccsUri,
    const gchar *arg_serverUri);

  void (*login_changed) (
    RemoteLogin *object,
    const gchar *arg_uri,
    const gchar *arg_emailAddress);

  void (*login_servers_updated) (
    RemoteLogin *object,
    const gchar *arg_uri,
    const gchar *arg_emailAddress,
    const gchar *arg_dataType,
    GVariant *arg_serverList);

  void (*servers_updated) (
    RemoteLogin *object,
    GVariant *arg_serverList);

};

GType remote_login_get_type (void) G_GNUC_CONST;

GDBusInterfaceInfo *remote_login_interface_info (void);
guint remote_login_override_properties (GObjectClass *klass, guint property_id_begin);


/* D-Bus method call completion functions: */
void remote_login_complete_get_servers (
    RemoteLogin *object,
    GDBusMethodInvocation *invocation,
    GVariant *serverList);

void remote_login_complete_get_servers_for_login (
    RemoteLogin *object,
    GDBusMethodInvocation *invocation,
    gboolean loginSuccess,
    const gchar *dataType,
    GVariant *serverList);

void remote_login_complete_get_cached_domains_for_server (
    RemoteLogin *object,
    GDBusMethodInvocation *invocation,
    const gchar *const *domains);

void remote_login_complete_set_applications_for_server (
    RemoteLogin *object,
    GDBusMethodInvocation *invocation);

void remote_login_complete_set_last_used_server (
    RemoteLogin *object,
    GDBusMethodInvocation *invocation);



/* D-Bus signal emissions functions: */
void remote_login_emit_servers_updated (
    RemoteLogin *object,
    GVariant *arg_serverList);

void remote_login_emit_login_servers_updated (
    RemoteLogin *object,
    const gchar *arg_uri,
    const gchar *arg_emailAddress,
    const gchar *arg_dataType,
    GVariant *arg_serverList);

void remote_login_emit_login_changed (
    RemoteLogin *object,
    const gchar *arg_uri,
    const gchar *arg_emailAddress);



/* D-Bus method calls: */
void remote_login_call_get_servers (
    RemoteLogin *proxy,
    GCancellable *cancellable,
    GAsyncReadyCallback callback,
    gpointer user_data);

gboolean remote_login_call_get_servers_finish (
    RemoteLogin *proxy,
    GVariant **out_serverList,
    GAsyncResult *res,
    GError **error);

gboolean remote_login_call_get_servers_sync (
    RemoteLogin *proxy,
    GVariant **out_serverList,
    GCancellable *cancellable,
    GError **error);

void remote_login_call_get_servers_for_login (
    RemoteLogin *proxy,
    const gchar *arg_uri,
    const gchar *arg_emailAddress,
    const gchar *arg_password,
    gboolean arg_allowCache,
    GCancellable *cancellable,
    GAsyncReadyCallback callback,
    gpointer user_data);

gboolean remote_login_call_get_servers_for_login_finish (
    RemoteLogin *proxy,
    gboolean *out_loginSuccess,
    gchar **out_dataType,
    GVariant **out_serverList,
    GAsyncResult *res,
    GError **error);

gboolean remote_login_call_get_servers_for_login_sync (
    RemoteLogin *proxy,
    const gchar *arg_uri,
    const gchar *arg_emailAddress,
    const gchar *arg_password,
    gboolean arg_allowCache,
    gboolean *out_loginSuccess,
    gchar **out_dataType,
    GVariant **out_serverList,
    GCancellable *cancellable,
    GError **error);

void remote_login_call_get_cached_domains_for_server (
    RemoteLogin *proxy,
    const gchar *arg_uri,
    GCancellable *cancellable,
    GAsyncReadyCallback callback,
    gpointer user_data);

gboolean remote_login_call_get_cached_domains_for_server_finish (
    RemoteLogin *proxy,
    gchar ***out_domains,
    GAsyncResult *res,
    GError **error);

gboolean remote_login_call_get_cached_domains_for_server_sync (
    RemoteLogin *proxy,
    const gchar *arg_uri,
    gchar ***out_domains,
    GCancellable *cancellable,
    GError **error);

void remote_login_call_set_applications_for_server (
    RemoteLogin *proxy,
    const gchar *arg_uccsUri,
    const gchar *arg_serverUri,
    GVariant *arg_applications,
    GCancellable *cancellable,
    GAsyncReadyCallback callback,
    gpointer user_data);

gboolean remote_login_call_set_applications_for_server_finish (
    RemoteLogin *proxy,
    GAsyncResult *res,
    GError **error);

gboolean remote_login_call_set_applications_for_server_sync (
    RemoteLogin *proxy,
    const gchar *arg_uccsUri,
    const gchar *arg_serverUri,
    GVariant *arg_applications,
    GCancellable *cancellable,
    GError **error);

void remote_login_call_set_last_used_server (
    RemoteLogin *proxy,
    const gchar *arg_uccsUri,
    const gchar *arg_serverUri,
    GCancellable *cancellable,
    GAsyncReadyCallback callback,
    gpointer user_data);

gboolean remote_login_call_set_last_used_server_finish (
    RemoteLogin *proxy,
    GAsyncResult *res,
    GError **error);

gboolean remote_login_call_set_last_used_server_sync (
    RemoteLogin *proxy,
    const gchar *arg_uccsUri,
    const gchar *arg_serverUri,
    GCancellable *cancellable,
    GError **error);



/* ---- */

#define TYPE_REMOTE_LOGIN_PROXY (remote_login_proxy_get_type ())
#define REMOTE_LOGIN_PROXY(o) (G_TYPE_CHECK_INSTANCE_CAST ((o), TYPE_REMOTE_LOGIN_PROXY, RemoteLoginProxy))
#define REMOTE_LOGIN_PROXY_CLASS(k) (G_TYPE_CHECK_CLASS_CAST ((k), TYPE_REMOTE_LOGIN_PROXY, RemoteLoginProxyClass))
#define REMOTE_LOGIN_PROXY_GET_CLASS(o) (G_TYPE_INSTANCE_GET_CLASS ((o), TYPE_REMOTE_LOGIN_PROXY, RemoteLoginProxyClass))
#define IS_REMOTE_LOGIN_PROXY(o) (G_TYPE_CHECK_INSTANCE_TYPE ((o), TYPE_REMOTE_LOGIN_PROXY))
#define IS_REMOTE_LOGIN_PROXY_CLASS(k) (G_TYPE_CHECK_CLASS_TYPE ((k), TYPE_REMOTE_LOGIN_PROXY))

typedef struct _RemoteLoginProxy RemoteLoginProxy;
typedef struct _RemoteLoginProxyClass RemoteLoginProxyClass;
typedef struct _RemoteLoginProxyPrivate RemoteLoginProxyPrivate;

struct _RemoteLoginProxy
{
  /*< private >*/
  GDBusProxy parent_instance;
  RemoteLoginProxyPrivate *priv;
};

struct _RemoteLoginProxyClass
{
  GDBusProxyClass parent_class;
};

GType remote_login_proxy_get_type (void) G_GNUC_CONST;

void remote_login_proxy_new (
    GDBusConnection     *connection,
    GDBusProxyFlags      flags,
    const gchar         *name,
    const gchar         *object_path,
    GCancellable        *cancellable,
    GAsyncReadyCallback  callback,
    gpointer             user_data);
RemoteLogin *remote_login_proxy_new_finish (
    GAsyncResult        *res,
    GError             **error);
RemoteLogin *remote_login_proxy_new_sync (
    GDBusConnection     *connection,
    GDBusProxyFlags      flags,
    const gchar         *name,
    const gchar         *object_path,
    GCancellable        *cancellable,
    GError             **error);

void remote_login_proxy_new_for_bus (
    GBusType             bus_type,
    GDBusProxyFlags      flags,
    const gchar         *name,
    const gchar         *object_path,
    GCancellable        *cancellable,
    GAsyncReadyCallback  callback,
    gpointer             user_data);
RemoteLogin *remote_login_proxy_new_for_bus_finish (
    GAsyncResult        *res,
    GError             **error);
RemoteLogin *remote_login_proxy_new_for_bus_sync (
    GBusType             bus_type,
    GDBusProxyFlags      flags,
    const gchar         *name,
    const gchar         *object_path,
    GCancellable        *cancellable,
    GError             **error);


/* ---- */

#define TYPE_REMOTE_LOGIN_SKELETON (remote_login_skeleton_get_type ())
#define REMOTE_LOGIN_SKELETON(o) (G_TYPE_CHECK_INSTANCE_CAST ((o), TYPE_REMOTE_LOGIN_SKELETON, RemoteLoginSkeleton))
#define REMOTE_LOGIN_SKELETON_CLASS(k) (G_TYPE_CHECK_CLASS_CAST ((k), TYPE_REMOTE_LOGIN_SKELETON, RemoteLoginSkeletonClass))
#define REMOTE_LOGIN_SKELETON_GET_CLASS(o) (G_TYPE_INSTANCE_GET_CLASS ((o), TYPE_REMOTE_LOGIN_SKELETON, RemoteLoginSkeletonClass))
#define IS_REMOTE_LOGIN_SKELETON(o) (G_TYPE_CHECK_INSTANCE_TYPE ((o), TYPE_REMOTE_LOGIN_SKELETON))
#define IS_REMOTE_LOGIN_SKELETON_CLASS(k) (G_TYPE_CHECK_CLASS_TYPE ((k), TYPE_REMOTE_LOGIN_SKELETON))

typedef struct _RemoteLoginSkeleton RemoteLoginSkeleton;
typedef struct _RemoteLoginSkeletonClass RemoteLoginSkeletonClass;
typedef struct _RemoteLoginSkeletonPrivate RemoteLoginSkeletonPrivate;

struct _RemoteLoginSkeleton
{
  /*< private >*/
  GDBusInterfaceSkeleton parent_instance;
  RemoteLoginSkeletonPrivate *priv;
};

struct _RemoteLoginSkeletonClass
{
  GDBusInterfaceSkeletonClass parent_class;
};

GType remote_login_skeleton_get_type (void) G_GNUC_CONST;

RemoteLogin *remote_login_skeleton_new (void);


G_END_DECLS

#endif /* __REMOTE_LOGIN_H__ */