goa: Add missing linker flag (for real).
[platform/upstream/evolution-data-server.git] / libedataserver / e-source-openpgp.h
1 /*
2  * e-source-openpgp.h
3  *
4  * This program is free software; you can redistribute it and/or
5  * modify it under the terms of the GNU Lesser General Public
6  * License as published by the Free Software Foundation; either
7  * version 2 of the License, or (at your option) version 3.
8  *
9  * This program is distributed in the hope that it will be useful,
10  * but WITHOUT ANY WARRANTY; without even the implied warranty of
11  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
12  * Lesser General Public License for more details.
13  *
14  * You should have received a copy of the GNU Lesser General Public
15  * License along with the program; if not, see <http://www.gnu.org/licenses/>
16  *
17  */
18
19 #if !defined (__LIBEDATASERVER_H_INSIDE__) && !defined (LIBEDATASERVER_COMPILATION)
20 #error "Only <libedataserver/libedataserver.h> should be included directly."
21 #endif
22
23 #ifndef E_SOURCE_OPENPGP_H
24 #define E_SOURCE_OPENPGP_H
25
26 #include <libedataserver/e-source-extension.h>
27
28 /* Standard GObject macros */
29 #define E_TYPE_SOURCE_OPENPGP \
30         (e_source_openpgp_get_type ())
31 #define E_SOURCE_OPENPGP(obj) \
32         (G_TYPE_CHECK_INSTANCE_CAST \
33         ((obj), E_TYPE_SOURCE_OPENPGP, ESourceOpenPGP))
34 #define E_SOURCE_OPENPGP_CLASS(cls) \
35         (G_TYPE_CHECK_CLASS_CAST \
36         ((cls), E_TYPE_SOURCE_OPENPGP, ESourceOpenPGPClass))
37 #define E_IS_SOURCE_OPENPGP(obj) \
38         (G_TYPE_CHECK_INSTANCE_TYPE \
39         ((obj), E_TYPE_SOURCE_OPENPGP))
40 #define E_IS_SOURCE_OPENPGP_CLASS(cls) \
41         (G_TYPE_CHECK_CLASS_TYPE \
42         ((cls), E_TYPE_SOURCE_OPENPGP))
43 #define E_SOURCE_OPENPGP_GET_CLASS(obj) \
44         (G_TYPE_INSTANCE_GET_CLASS \
45         ((obj), E_TYPE_SOURCE_OPENPGP, ESourceOpenPGPClass))
46
47 /**
48  * E_SOURCE_EXTENSION_OPENPGP:
49  *
50  * Pass this extension name to e_source_get_extension() to access
51  * #ESourceOpenPGP.  This is also used as a group name in key files.
52  *
53  * Since: 3.6
54  **/
55 #define E_SOURCE_EXTENSION_OPENPGP "Pretty Good Privacy (OpenPGP)"
56
57 G_BEGIN_DECLS
58
59 typedef struct _ESourceOpenPGP ESourceOpenPGP;
60 typedef struct _ESourceOpenPGPClass ESourceOpenPGPClass;
61 typedef struct _ESourceOpenPGPPrivate ESourceOpenPGPPrivate;
62
63 /**
64  * ESourceOpenPGP:
65  *
66  * Contains only private data that should be read and manipulated using the
67  * functions below.
68  *
69  * Since: 3.6
70  **/
71 struct _ESourceOpenPGP {
72         ESourceExtension parent;
73         ESourceOpenPGPPrivate *priv;
74 };
75
76 struct _ESourceOpenPGPClass {
77         ESourceExtensionClass parent_class;
78 };
79
80 GType           e_source_openpgp_get_type       (void) G_GNUC_CONST;
81 gboolean        e_source_openpgp_get_always_trust
82                                                 (ESourceOpenPGP *extension);
83 void            e_source_openpgp_set_always_trust
84                                                 (ESourceOpenPGP *extension,
85                                                  gboolean always_trust);
86 gboolean        e_source_openpgp_get_encrypt_to_self
87                                                 (ESourceOpenPGP *extension);
88 void            e_source_openpgp_set_encrypt_to_self
89                                                 (ESourceOpenPGP *extension,
90                                                  gboolean encrypt_to_self);
91 const gchar *   e_source_openpgp_get_key_id     (ESourceOpenPGP *extension);
92 gchar *         e_source_openpgp_dup_key_id     (ESourceOpenPGP *extension);
93 void            e_source_openpgp_set_key_id     (ESourceOpenPGP *extension,
94                                                  const gchar *key_id);
95 const gchar *   e_source_openpgp_get_signing_algorithm
96                                                 (ESourceOpenPGP *extension);
97 gchar *         e_source_openpgp_dup_signing_algorithm
98                                                 (ESourceOpenPGP *extension);
99 void            e_source_openpgp_set_signing_algorithm
100                                                 (ESourceOpenPGP *extension,
101                                                  const gchar *signing_algorithm);
102 gboolean        e_source_openpgp_get_sign_by_default
103                                                 (ESourceOpenPGP *extension);
104 void            e_source_openpgp_set_sign_by_default
105                                                 (ESourceOpenPGP *extension,
106                                                  gboolean sign_by_default);
107
108 G_END_DECLS
109
110 #endif /* E_SOURCE_OPENPGP_H */
111