changes: Bump to 3.8.1
[platform/upstream/evolution-data-server.git] / libedataserver / e-source-camel.h
1 /*
2  * e-source-camel.h
3  *
4  * This library is free software you can redistribute it and/or modify it
5  * under the terms of the GNU Lesser General Public License as published by
6  * the Free Software Foundation.
7  *
8  * This library is distributed in the hope that it will be useful, but
9  * WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
10  * or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
11  * for more details.
12  *
13  * You should have received a copy of the GNU Lesser General Public License
14  * along with this library; if not, see <http://www.gnu.org/licenses/>.
15  *
16  */
17
18 #if !defined (__LIBEDATASERVER_H_INSIDE__) && !defined (LIBEDATASERVER_COMPILATION)
19 #error "Only <libedataserver/libedataserver.h> should be included directly."
20 #endif
21
22 #ifndef E_SOURCE_CAMEL_H
23 #define E_SOURCE_CAMEL_H
24
25 #include <camel/camel.h>
26 #include <libedataserver/e-source-extension.h>
27
28 /* Standard GObject macros */
29 #define E_TYPE_SOURCE_CAMEL \
30         (e_source_camel_get_type ())
31 #define E_SOURCE_CAMEL(obj) \
32         (G_TYPE_CHECK_INSTANCE_CAST \
33         ((obj), E_TYPE_SOURCE_CAMEL, ESourceCamel))
34 #define E_SOURCE_CAMEL_CLASS(cls) \
35         (G_TYPE_CHECK_CLASS_CAST \
36         ((cls), E_TYPE_SOURCE_CAMEL, ESourceCamelClass))
37 #define E_IS_SOURCE_CAMEL(obj) \
38         (G_TYPE_CHECK_INSTANCE_TYPE \
39         ((obj), E_TYPE_SOURCE_CAMEL))
40 #define E_IS_SOURCE_CAMEL_CLASS(cls) \
41         (G_TYPE_CHECK_CLASS_TYPE \
42         ((cls), E_TYPE_SOURCE_CAMEL))
43 #define E_SOURCE_CAMEL_GET_CLASS(obj) \
44         (G_TYPE_INSTANCE_GET_CLASS \
45         ((obj), E_TYPE_SOURCE_CAMEL, ESourceCamelClass))
46
47 G_BEGIN_DECLS
48
49 typedef struct _ESourceCamel ESourceCamel;
50 typedef struct _ESourceCamelClass ESourceCamelClass;
51 typedef struct _ESourceCamelPrivate ESourceCamelPrivate;
52
53 /**
54  * ESourceCamel:
55  *
56  * Contains only private data that should be read and manipulated using the
57  * functions below.
58  *
59  * Since: 3.6
60  **/
61 struct _ESourceCamel {
62         ESourceExtension parent;
63         ESourceCamelPrivate *priv;
64 };
65
66 struct _ESourceCamelClass {
67         ESourceExtensionClass parent_class;
68
69         /* Same idea as in CamelServiceClass. */
70         GType settings_type;
71 };
72
73 GType           e_source_camel_get_type         (void) G_GNUC_CONST;
74 void            e_source_camel_register_types   (void);
75 GType           e_source_camel_generate_subtype (const gchar *protocol,
76                                                  GType settings_type);
77 CamelSettings * e_source_camel_get_settings     (ESourceCamel *extension);
78 const gchar *   e_source_camel_get_type_name    (const gchar *protocol);
79 const gchar *   e_source_camel_get_extension_name
80                                                 (const gchar *protocol);
81 void            e_source_camel_configure_service
82                                                 (ESource *source,
83                                                  CamelService *service);
84
85 G_END_DECLS
86
87 #endif /* E_SOURCE_CAMEL_H */