2 * tpaw-account-settings.h - Header for TpawAccountSettings
3 * Copyright (C) 2009 Collabora Ltd.
4 * @author Sjoerd Simons <sjoerd.simons@collabora.co.uk>
6 * This library is free software; you can redistribute it and/or
7 * modify it under the terms of the GNU Lesser General Public
8 * License as published by the Free Software Foundation; either
9 * version 2.1 of the License, or (at your option) any later version.
11 * This library is distributed in the hope that it will be useful,
12 * but WITHOUT ANY WARRANTY; without even the implied warranty of
13 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14 * Lesser General Public License for more details.
16 * You should have received a copy of the GNU Lesser General Public
17 * License along with this library; if not, write to the Free Software
18 * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
21 #ifndef __TPAW_ACCOUNT_SETTINGS_H__
22 #define __TPAW_ACCOUNT_SETTINGS_H__
24 #include <glib-object.h>
26 #include <telepathy-glib/telepathy-glib.h>
30 typedef struct _TpawAccountSettings TpawAccountSettings;
31 typedef struct _TpawAccountSettingsPriv TpawAccountSettingsPriv;
32 typedef struct _TpawAccountSettingsClass TpawAccountSettingsClass;
34 struct _TpawAccountSettingsClass {
35 GObjectClass parent_class;
38 struct _TpawAccountSettings {
42 TpawAccountSettingsPriv *priv;
45 GType tpaw_account_settings_get_type (void);
48 #define TPAW_TYPE_ACCOUNT_SETTINGS \
49 (tpaw_account_settings_get_type ())
50 #define TPAW_ACCOUNT_SETTINGS(obj) \
51 (G_TYPE_CHECK_INSTANCE_CAST((obj), \
52 TPAW_TYPE_ACCOUNT_SETTINGS, TpawAccountSettings))
53 #define TPAW_ACCOUNT_SETTINGS_CLASS(klass) \
54 (G_TYPE_CHECK_CLASS_CAST((klass), TPAW_TYPE_ACCOUNT_SETTINGS, \
55 TpawAccountSettingsClass))
56 #define TPAW_IS_ACCOUNT_SETTINGS(obj) \
57 (G_TYPE_CHECK_INSTANCE_TYPE((obj), TPAW_TYPE_ACCOUNT_SETTINGS))
58 #define TPAW_IS_ACCOUNT_SETTINGS_CLASS(klass) \
59 (G_TYPE_CHECK_CLASS_TYPE((klass), TPAW_TYPE_ACCOUNT_SETTINGS))
60 #define TPAW_ACCOUNT_SETTINGS_GET_CLASS(obj) \
61 (G_TYPE_INSTANCE_GET_CLASS ((obj), TPAW_TYPE_ACCOUNT_SETTINGS, \
62 TpawAccountSettingsClass))
64 TpawAccountSettings * tpaw_account_settings_new (
65 const gchar *connection_manager,
66 const gchar *protocol,
68 const char *display_name);
70 TpawAccountSettings * tpaw_account_settings_new_for_account (
73 gboolean tpaw_account_settings_is_ready (TpawAccountSettings *settings);
75 const gchar *tpaw_account_settings_get_cm (TpawAccountSettings *settings);
76 const gchar *tpaw_account_settings_get_protocol (
77 TpawAccountSettings *settings);
79 const gchar *tpaw_account_settings_get_service (
80 TpawAccountSettings *settings);
82 void tpaw_account_settings_set_service (TpawAccountSettings *settings,
83 const gchar *service);
85 TpAccount *tpaw_account_settings_get_account (
86 TpawAccountSettings *settings);
88 gboolean tpaw_account_settings_has_account (
89 TpawAccountSettings *settings, TpAccount *account);
91 GList * tpaw_account_settings_dup_tp_params (
92 TpawAccountSettings *settings);
94 gboolean tpaw_account_settings_have_tp_param (
95 TpawAccountSettings *settings,
98 void tpaw_account_settings_unset (TpawAccountSettings *settings,
101 void tpaw_account_settings_discard_changes (
102 TpawAccountSettings *settings);
105 tpaw_account_settings_get_dbus_signature (TpawAccountSettings *setting,
109 tpaw_account_settings_dup_default (TpawAccountSettings *settings,
112 gchar * tpaw_account_settings_dup_string (
113 TpawAccountSettings *settings,
115 GStrv tpaw_account_settings_dup_strv (
116 TpawAccountSettings *settings,
119 gint32 tpaw_account_settings_get_int32 (TpawAccountSettings *settings,
121 gint64 tpaw_account_settings_get_int64 (TpawAccountSettings *settings,
123 guint32 tpaw_account_settings_get_uint32 (TpawAccountSettings *settings,
125 guint64 tpaw_account_settings_get_uint64 (TpawAccountSettings *settings,
127 gboolean tpaw_account_settings_get_boolean (TpawAccountSettings *settings,
130 void tpaw_account_settings_set (TpawAccountSettings *settings,
134 gchar *tpaw_account_settings_get_icon_name (
135 TpawAccountSettings *settings);
137 void tpaw_account_settings_set_icon_name_async (
138 TpawAccountSettings *settings,
140 GAsyncReadyCallback callback,
143 gboolean tpaw_account_settings_set_icon_name_finish (
144 TpawAccountSettings *settings,
145 GAsyncResult *result,
148 const gchar *tpaw_account_settings_get_display_name (
149 TpawAccountSettings *settings);
151 void tpaw_account_settings_set_display_name_async (
152 TpawAccountSettings *settings,
154 GAsyncReadyCallback callback,
157 gboolean tpaw_account_settings_set_display_name_finish (
158 TpawAccountSettings *settings,
159 GAsyncResult *result,
162 void tpaw_account_settings_apply_async (TpawAccountSettings *settings,
163 GAsyncReadyCallback callback,
166 gboolean tpaw_account_settings_apply_finish (
167 TpawAccountSettings *settings,
168 GAsyncResult *result,
169 gboolean *reconnect_required,
172 void tpaw_account_settings_set_regex (TpawAccountSettings *settings,
176 gboolean tpaw_account_settings_parameter_is_valid (
177 TpawAccountSettings *settings,
180 gboolean tpaw_account_settings_is_valid (TpawAccountSettings *settings);
182 TpProtocol * tpaw_account_settings_get_tp_protocol (
183 TpawAccountSettings *settings);
185 gboolean tpaw_account_settings_supports_sasl (TpawAccountSettings *self);
187 gboolean tpaw_account_settings_param_is_supported (
188 TpawAccountSettings *self,
191 void tpaw_account_settings_set_uri_scheme_tel (TpawAccountSettings *self,
194 gboolean tpaw_account_settings_has_uri_scheme_tel (
195 TpawAccountSettings *self);
197 void tpaw_account_settings_set_storage_provider (
198 TpawAccountSettings *self,
199 const gchar *storage);
201 void tpaw_account_settings_set_remember_password (
202 TpawAccountSettings *self,
207 #endif /* #ifndef __TPAW_ACCOUNT_SETTINGS_H__*/