* Fix an error in compilation when Alpine is not built with S/MIME
[alpine.git] / pith / remtype.h
bloba4e983bc6e565722de4005c6e6e1c16dab5a8991
1 /*
2 * $Id: remtype.h 764 2007-10-23 23:44:49Z hubert@u.washington.edu $
4 * ========================================================================
5 * Copyright 2006 University of Washington
7 * Licensed under the Apache License, Version 2.0 (the "License");
8 * you may not use this file except in compliance with the License.
9 * You may obtain a copy of the License at
11 * http://www.apache.org/licenses/LICENSE-2.0
13 * ========================================================================
16 #ifndef PITH_REMTYPE_INCLUDED
17 #define PITH_REMTYPE_INCLUDED
19 #include "../pith/store.h"
22 typedef enum {Loc, RemImap} RemType;
25 typedef enum {ReadOnly, ReadWrite, MaybeRorW, NoAccess, NoExists} AccessType;
28 /* Remote data folder bookkeeping */
29 typedef struct remote_data {
30 RemType type;
31 char *rn; /* remote name (name of folder) */
32 char *lf; /* name of local file */
33 STORE_S *sonofile; /* storage object which takes place of lf */
34 AccessType access; /* of remote folder */
35 time_t last_use; /* when remote was last accessed */
36 time_t last_valid_chk;/* when remote valid check was done */
37 time_t last_local_valid_chk;
38 STORE_S *so; /* storage object to use */
39 char read_status; /* R for readonly */
40 unsigned long flags;
41 unsigned long cookie;
42 union type_specific_data {
43 struct imap_remote_data {
44 char *special_hdr; /* header name for this type folder */
45 MAILSTREAM *stream; /* stream to use for remote folder */
46 char *chk_date; /* Date of last message */
47 unsigned long chk_nmsgs; /* Number of messages in folder */
48 unsigned long shouldbe_nmsgs; /* Number which should be in folder */
49 imapuid_t uidvalidity; /* UIDVALIDITY of folder */
50 imapuid_t uidnext; /* UIDNEXT of folder */
51 imapuid_t uid; /* UID of last message in folder */
52 }i;
53 }t;
54 } REMDATA_S;
57 /* exported protoypes */
60 #endif /* PITH_REMTYPE_INCLUDED */