Node:Headers,
Next:Body,
Previous:Envelope,
Up:libmailbox
Headers
/* Prefix header_ is reserved */
#include <mailutils/header.h>
So far we plan support for RFC822 and plan for RFC1522. with RFC1522 non ASCII
characters will be encoded.
| int header_create (header_t *hdr, const char *blurb, size_t len, void *owner) | Function | 
| Initialize a hdr to a supported type.  If blurb is not NULL, it is
parsed. | 
| void header_destroy (header_t *hdr, void *owner) | Function | 
| The resources allocated for hdr are freed. | 
| int header_set_value (header_t hdr, const char *fn, const char *fv, size_t n, int replace) | Function | 
| Set the field-name fn to field-value fv of size n in
hdr.  If replace is non-zero the initial value is replaced, if zero
it is appended. Some basic macros are already provided for rfc822.
 
MU_HEADER_RETURN_PATHReturn-Path
MU_HEADER_RECEIVEDReceived
MU_HEADER_DATEDate
MU_HEADER_FROMFrom
MU_HEADER_RESENT_FROMResent-From
MU_HEADER_SUBJECTSubject
MU_HEADER_SENDERSender
MU_HEADER_RESENT_SENDERResent-SENDER
MU_HEADER_TOTo
MU_HEADER_RESENT_TOResent-To
MU_HEADER_CCCc
MU_HEADER_RESENT_CCResent-Cc
MU_HEADER_BCCBcc
MU_HEADER_RESENT_BCCResent-Bcc
MU_HEADER_REPLY_TOReply-To
MU_HEADER_RESENT_REPLY_TOResent-Reply-To
MU_HEADER_MESSAGE_IDMessage-ID
MU_HEADER_RESENT_MESSAGE_IDResent-Message-ID
MU_HEADER_IN_REPLY_TOIn-Reply-To
MU_HEADER_ENCRYPTEDEncrypted
MU_HEADER_PRECEDENCEPrecedence
MU_HEADER_STATUSStatus
MU_HEADER_CONTENT_LENGTHContent-Length
MU_HEADER_CONTENT_TYPEContent-Type
MU_HEADER_MIME_VERSIONMIME-Version
 | 
| int header_get_value (header_t hdr, const char *fn, char *fv, size_t len, size_t *n) | Function | 
| Value of field-name fn is returned in buffer fv of size len. 
The number of bytes written is put in n. | 
| int header_aget_value (header_t hdr, const char *fn, char **fv) | Function | 
| int header_get_stream (header_t hdr, stream_t *pstream) | Function | 
| int header_set_size (header_t hdr, size_t *size) | Function | 
| int header_set_lines (header_t hdr, size_t *lpines) | Function |