NeoMutt  2020-06-26-250-g349c94
Teaching an old dog new tricks
Go to the documentation of this file.
23 #ifndef MUTT_EMAIL_BODY_H
24 #define MUTT_EMAIL_BODY_H
26 #include "config.h"
27 #include <stdbool.h>
28 #include <time.h>
29 #include "parameter.h"
34 struct Body
35 {
36  char *xtype;
37  char *subtype;
38  char *language;
39  struct ParameterList parameter;
40  char *description;
41  char *form_name;
42  long hdr_offset;
43  LOFF_T offset;
45  LOFF_T length;
46  char *filename;
47  char *d_filename;
48  char *charset;
50  struct Content *content;
52  struct Body *next;
54  struct Body *parts;
55  struct Email *email;
57  struct AttachPtr *aptr;
59  signed short attach_count;
61  time_t stamp;
65  unsigned int type : 4;
66  unsigned int encoding : 3;
67  unsigned int disposition : 2;
68  bool use_disp : 1;
69  bool unlink : 1;
70  bool tagged : 1;
71  bool deleted : 1;
73  bool noconv : 1;
74  bool force_charset : 1;
75  bool goodsig : 1;
76  bool warnsig : 1;
77  bool badsig : 1;
79  bool is_autocrypt : 1;
80 #endif
82  bool collapsed : 1;
83  bool attach_qualifies : 1;
84 };
86 bool mutt_body_cmp_strict(const struct Body *b1, const struct Body *b2);
87 void mutt_body_free (struct Body **ptr);
88 char * mutt_body_get_charset(struct Body *b, char *buf, size_t buflen);
89 struct Body *mutt_body_new (void);
91 #endif /* MUTT_EMAIL_BODY_H */
char * filename
when sending a message, this is the file to which this structure refers
Definition: body.h:46
An email to which things will be attached.
Definition: attach.h:34
struct Envelope * mime_headers
Memory hole protected headers.
Definition: body.h:63
The envelope/body of an email.
Definition: email.h:37
struct Content * content
Detailed info about the content of the attachment.
Definition: body.h:51
bool noconv
Don&#39;t do character set conversion.
Definition: body.h:73
char * mutt_body_get_charset(struct Body *b, char *buf, size_t buflen)
Get a body&#39;s character set.
Definition: body.c:131
LOFF_T offset
offset where the actual data begins
Definition: body.h:44
bool is_autocrypt
Flag autocrypt-decrypted messages for replying.
Definition: body.h:79
struct Body * next
next attachment in the list
Definition: body.h:53
char * form_name
Content-Disposition form-data name param.
Definition: body.h:41
The body of an email.
Definition: body.h:34
unsigned int disposition
content-disposition, ContentDisposition
Definition: body.h:67
bool attach_qualifies
This attachment should be counted.
Definition: body.h:83
bool mutt_body_cmp_strict(const struct Body *b1, const struct Body *b2)
Strictly compare two email Body&#39;s.
Definition: body.c:108
bool force_charset
Send mode: don&#39;t adjust the character set when in send-mode.
Definition: body.h:74
bool badsig
Bad cryptographic signature (needed to check encrypted s/mime-signatures)
Definition: body.h:77
signed short attach_count
Number of attachments.
Definition: body.h:59
bool tagged
This attachment is tagged.
Definition: body.h:70
unsigned int encoding
content-transfer-encoding, ContentEncoding
Definition: body.h:66
bool collapsed
Used by recvattach.
Definition: body.h:82
char * subtype
content-type subtype
Definition: body.h:37
Info about an attachment.
Definition: content.h:33
bool goodsig
Good cryptographic signature.
Definition: body.h:75
LOFF_T length
length (in bytes) of attachment
Definition: body.h:45
struct AttachPtr * aptr
Menu information, used in recvattach.c.
Definition: body.h:57
char * xtype
content-type if x-unknown
Definition: body.h:36
void mutt_body_free(struct Body **ptr)
Free a Body.
Definition: body.c:57
struct Body * parts
parts of a multipart or message/rfc822
Definition: body.h:54
char * charset
Send mode: charset of attached file as stored on disk.
Definition: body.h:49
char * description
Definition: body.h:40
unsigned int type
content-type primary type, ContentType
Definition: body.h:65
bool deleted
Attachment marked for deletion.
Definition: body.h:71
bool use_disp
Content-Disposition uses filename= ?
Definition: body.h:68
time_t stamp
Time stamp of last encoding update.
Definition: body.h:61
bool unlink
If true, filename should be unlink()ed before free()ing this structure.
Definition: body.h:69
char * language
content-language (RFC8255)
Definition: body.h:38
char * d_filename
filename to be used for the content-disposition header.
Definition: body.h:47
long hdr_offset
Offset in stream where the headers begin.
Definition: body.h:42
struct ParameterList parameter
parameters of the content-type
Definition: body.h:39
struct Email * email
header information for message/rfc822
Definition: body.h:55
struct Body * mutt_body_new(void)
Create a new Body.
Definition: body.c:43
Store attributes associated with a MIME part.
The header of an Email.
Definition: envelope.h:54
bool warnsig
Maybe good signature.
Definition: body.h:76