aboutsummaryrefslogtreecommitdiffstats
path: root/mail/mail-folder-cache.h
blob: d685e5a5ad8e14851e51c0024d2dcd24638e4395 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
/*
 * This program is free software; you can redistribute it and/or
 * modify it under the terms of the GNU Lesser General Public
 * License as published by the Free Software Foundation; either
 * version 2 of the License, or (at your option) version 3.
 *
 * This program is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
 * Lesser General Public License for more details.
 *
 * You should have received a copy of the GNU Lesser General Public
 * License along with the program; if not, see <http://www.gnu.org/licenses/>  
 *
 *
 * Authors:
 *      Peter Williams <peterw@ximian.com>
 *      Michael Zucchi <notzed@ximian.com>
 *
 * Copyright (C) 1999-2008 Novell, Inc. (www.novell.com)
 *
 */

/* mail-folder-cache.h: Stores information about open folders */

#ifndef _MAIL_FOLDER_CACHE_H
#define _MAIL_FOLDER_CACHE_H

#include <camel/camel-store.h>
#include <shell/e-shell-module.h>

/* Add a store whose folders should appear in the shell
   The folders are scanned from the store, and/or added at
   runtime via the folder_created event.
   The 'done' function returns if we can free folder info. */
void
mail_note_store (EShellModule *shell_module, CamelStore *store, CamelOperation *op,
         gboolean (*done) (CamelStore *store, CamelFolderInfo *info, void *data),
         void *data);

/* de-note a store */
void mail_note_store_remove (CamelStore *store);

/* When a folder has been opened, notify it for watching.
   The folder must have already been created on the store (which has already been noted)
   before the folder can be opened
 */
void mail_note_folder (CamelFolder *folder);

/* Returns true if a folder is available (yet), and also sets *folderp (if supplied)
   to a (referenced) copy of the folder if it has already been opened */
int mail_note_get_folder_from_uri (const char *uri, CamelFolder **folderp);
gboolean mail_folder_cache_get_folder_info_flags (CamelFolder *folder, int *flags);

#endif