Fix FSF address (Tobias Mueller, #470445)
[platform/upstream/evolution-data-server.git] / camel / providers / pop3 / camel-pop3-folder.h
1 /* -*- Mode: C; tab-width: 8; indent-tabs-mode: t; c-basic-offset: 8 -*- */
2 /* camel-pop3-folder.h : Class for a POP3 folder */
3
4 /* 
5  * Authors:
6  *   Dan Winship <danw@ximian.com>
7  *   Michael Zucchi <notzed@ximian.com>
8  *
9  * Copyright (C) 2002 Ximian, Inc. (www.ximian.com)
10  *
11  * This program is free software; you can redistribute it and/or 
12  * modify it under the terms of version 2 of the GNU Lesser General Public 
13  * License as published by the Free Software Foundation.
14  *
15  * This program is distributed in the hope that it will be useful,
16  * but WITHOUT ANY WARRANTY; without even the implied warranty of
17  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
18  * GNU Lesser General Public License for more details.
19  *
20  * You should have received a copy of the GNU Lesser General Public License
21  * along with this program; if not, write to the Free Software
22  * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301
23  * USA
24  */
25
26 #ifndef CAMEL_POP3_FOLDER_H
27 #define CAMEL_POP3_FOLDER_H 1
28
29 #include "camel-folder.h"
30
31 #define CAMEL_POP3_FOLDER_TYPE     (camel_pop3_folder_get_type ())
32 #define CAMEL_POP3_FOLDER(obj)     (CAMEL_CHECK_CAST((obj), CAMEL_POP3_FOLDER_TYPE, CamelPOP3Folder))
33 #define CAMEL_POP3_FOLDER_CLASS(k) (CAMEL_CHECK_CLASS_CAST ((k), CAMEL_POP3_FOLDER_TYPE, CamelPOP3FolderClass))
34 #define CAMEL_IS_POP3_FOLDER(o)    (CAMEL_CHECK_TYPE((o), CAMEL_POP3_FOLDER_TYPE))
35
36 G_BEGIN_DECLS
37
38 typedef struct {
39         guint32 id;
40         guint32 size;
41         guint32 flags;
42         guint32 index;          /* index of request */
43         char *uid;
44         int err;
45         struct _CamelPOP3Command *cmd;
46         struct _CamelStream *stream;
47 } CamelPOP3FolderInfo;
48
49 typedef struct {
50         CamelFolder parent_object;
51
52         GPtrArray *uids;
53         GHashTable *uids_uid;   /* messageinfo by uid */
54         GHashTable *uids_id;    /* messageinfo by id */
55 } CamelPOP3Folder;
56
57 typedef struct {
58         CamelFolderClass parent_class;
59
60         /* Virtual methods */   
61         
62 } CamelPOP3FolderClass;
63
64 /* public methods */
65 CamelFolder *camel_pop3_folder_new (CamelStore *parent, CamelException *ex);
66
67 /* Standard Camel function */
68 CamelType camel_pop3_folder_get_type (void);
69
70 int camel_pop3_delete_old(CamelFolder *folder, int days_to_delete, CamelException *ex);
71
72 G_END_DECLS
73
74 #endif /* CAMEL_POP3_FOLDER_H */