Whitespace cleanups.
[platform/upstream/evolution-data-server.git] / camel / camel-imapx-summary.h
1 /*
2  *  Copyright (C) 1999-2008 Novell, Inc. (www.novell.com)
3  *
4  *  Authors:
5  *    Michael Zucchi <notzed@ximian.com>
6  *    Dan Winship <danw@ximian.com>
7  *
8  * This program is free software; you can redistribute it and/or
9  * modify it under the terms of version 2 of the GNU Lesser General Public
10  * License as published by the Free Software Foundation.
11  *
12  * This program is distributed in the hope that it will be useful,
13  * but WITHOUT ANY WARRANTY; without even the implied warranty of
14  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
15  * General Public License for more details.
16  *
17  * You should have received a copy of the GNU Lesser General Public
18  * License along with this program; if not, write to the
19  * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
20  * Boston, MA 02110-1301, USA.
21  */
22
23 #if !defined (__CAMEL_H_INSIDE__) && !defined (CAMEL_COMPILATION)
24 #error "Only <camel/camel.h> can be included directly."
25 #endif
26
27 #ifndef CAMEL_IMAPX_SUMMARY_H
28 #define CAMEL_IMAPX_SUMMARY_H
29
30 #include <camel/camel-folder-summary.h>
31 #include <camel/camel-folder.h>
32
33 /* Standard GObject macros */
34 #define CAMEL_TYPE_IMAPX_SUMMARY \
35         (camel_imapx_summary_get_type ())
36 #define CAMEL_IMAPX_SUMMARY(obj) \
37         (G_TYPE_CHECK_INSTANCE_CAST \
38         ((obj), CAMEL_TYPE_IMAPX_SUMMARY, CamelIMAPXSummary))
39 #define CAMEL_IMAPX_SUMMARY_CLASS(cls) \
40         (G_TYPE_CHECK_CLASS_CAST \
41         ((cls), CAMEL_TYPE_IMAPX_SUMMARY, CamelIMAPXSummaryClass))
42 #define CAMEL_IS_IMAPX_SUMMARY(obj) \
43         (G_TYPE_CHECK_INSTANCE_TYPE \
44         ((obj), CAMEL_TYPE_IMAPX_SUMMARY))
45 #define CAMEL_IS_IMAPX_SUMMARY_CLASS(cls) \
46         (G_TYPE_CHECK_CLASS_TYPE \
47         ((cls), CAMEL_TYPE_IMAPX_SUMMARY))
48 #define CAMEL_IMAPX_SUMMARY_GET_CLASS(obj) \
49         (G_TYPE_INSTANCE_GET_CLASS \
50         ((obj), CAMEL_TYPE_IMAPX_SUMMARY, CamelIMAPXSummaryClass))
51
52 #define CAMEL_IMAPX_SERVER_FLAGS \
53         (CAMEL_MESSAGE_ANSWERED | CAMEL_MESSAGE_DELETED | \
54          CAMEL_MESSAGE_DRAFT | CAMEL_MESSAGE_FLAGGED | \
55          CAMEL_MESSAGE_JUNK | CAMEL_MESSAGE_NOTJUNK | \
56          CAMEL_MESSAGE_SEEN)
57
58 G_BEGIN_DECLS
59
60 typedef struct _CamelIMAPXSummary CamelIMAPXSummary;
61 typedef struct _CamelIMAPXSummaryClass CamelIMAPXSummaryClass;
62
63 typedef struct _CamelIMAPXMessageInfo CamelIMAPXMessageInfo;
64 typedef struct _CamelIMAPXMessageContentInfo CamelIMAPXMessageContentInfo;
65
66 struct _CamelIMAPXMessageContentInfo {
67         CamelMessageContentInfo info;
68 };
69
70 struct _CamelIMAPXMessageInfo {
71         CamelMessageInfoBase info;
72
73         guint32 server_flags;
74         CamelFlag *server_user_flags;
75 };
76
77 struct _CamelIMAPXSummary {
78         CamelFolderSummary parent;
79
80         guint32 version;
81         guint32 uidnext;
82         guint64 validity;
83         guint64 modseq;
84 };
85
86 struct _CamelIMAPXSummaryClass {
87         CamelFolderSummaryClass parent_class;
88 };
89
90 GType           camel_imapx_summary_get_type    (void);
91 CamelFolderSummary *
92                 camel_imapx_summary_new         (CamelFolder *folder);
93 void            camel_imapx_summary_add_offline (CamelFolderSummary *summary,
94                                                  const gchar *uid,
95                                                  CamelMimeMessage *message,
96                                                  const CamelMessageInfo *info);
97 void            camel_imapx_summary_add_offline_uncached
98                                                 (CamelFolderSummary *summary,
99                                                  const gchar *uid,
100                                                  const CamelMessageInfo *info);
101
102 G_END_DECLS
103
104 #endif /* CAMEL_IMAPX_SUMMARY_H */