Representation of an email header (envelope) More...
Go to the source code of this file.
Data Structures | |
struct | AutocryptHeader |
Parse Autocrypt header info. More... | |
struct | Envelope |
The header of an Email. More... | |
Macros | |
#define | MUTT_ENV_CHANGED_IRT (1 << 0) |
In-Reply-To changed to link/break threads. | |
#define | MUTT_ENV_CHANGED_REFS (1 << 1) |
References changed to break thread. | |
#define | MUTT_ENV_CHANGED_XLABEL (1 << 2) |
X-Label edited. | |
#define | MUTT_ENV_CHANGED_SUBJECT (1 << 3) |
Protected header update. | |
Enumerations | |
enum | ExpandoDataEnvelope { ED_ENV_CC_ALL = 1 , ED_ENV_FIRST_NAME , ED_ENV_FROM , ED_ENV_FROM_FULL , ED_ENV_INITIALS , ED_ENV_LIST_ADDRESS , ED_ENV_LIST_EMPTY , ED_ENV_MESSAGE_ID , ED_ENV_NAME , ED_ENV_NEWSGROUP , ED_ENV_ORGANIZATION , ED_ENV_REAL_NAME , ED_ENV_REPLY_TO , ED_ENV_SENDER , ED_ENV_SENDER_PLAIN , ED_ENV_SPAM , ED_ENV_SUBJECT , ED_ENV_THREAD_TREE , ED_ENV_THREAD_X_LABEL , ED_ENV_TO , ED_ENV_TO_ALL , ED_ENV_USERNAME , ED_ENV_USER_NAME , ED_ENV_X_COMMENT_TO , ED_ENV_X_LABEL } |
Expando UIDs for Envelopes. More... | |
enum | NotifyEnvelope { NT_ENVELOPE_BCC = 1 , NT_ENVELOPE_CC , NT_ENVELOPE_FCC , NT_ENVELOPE_FOLLOWUP_TO , NT_ENVELOPE_FROM , NT_ENVELOPE_NEWSGROUPS , NT_ENVELOPE_REPLY_TO , NT_ENVELOPE_SUBJECT , NT_ENVELOPE_TO , NT_ENVELOPE_X_COMMENT_TO } |
Types of Envelope Event. More... | |
Functions | |
bool | mutt_env_cmp_strict (const struct Envelope *e1, const struct Envelope *e2) |
Strictly compare two Envelopes. | |
void | mutt_env_free (struct Envelope **ptr) |
Free an Envelope. | |
void | mutt_env_merge (struct Envelope *base, struct Envelope **extra) |
Merge the headers of two Envelopes. | |
struct Envelope * | mutt_env_new (void) |
Create a new Envelope. | |
bool | mutt_env_notify_send (struct Email *e, enum NotifyEnvelope type) |
Send an Envelope change notification. | |
void | mutt_env_set_subject (struct Envelope *env, const char *subj) |
Set both subject and real_subj to subj. | |
int | mutt_env_to_intl (struct Envelope *env, const char **tag, char **err) |
Convert an Envelope's Address fields to Punycode format. | |
void | mutt_env_to_local (struct Envelope *env) |
Convert an Envelope's Address fields to local format. | |
struct AutocryptHeader * | mutt_autocrypthdr_new (void) |
Create a new AutocryptHeader. | |
void | mutt_autocrypthdr_free (struct AutocryptHeader **ptr) |
Free an AutocryptHeader. | |
Representation of an email header (envelope)
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 General Public License for more details.
You should have received a copy of the GNU General Public License along with this program. If not, see http://www.gnu.org/licenses/.
Definition in file envelope.h.
#define MUTT_ENV_CHANGED_IRT (1 << 0) |
In-Reply-To changed to link/break threads.
Definition at line 34 of file envelope.h.
#define MUTT_ENV_CHANGED_REFS (1 << 1) |
References changed to break thread.
Definition at line 35 of file envelope.h.
#define MUTT_ENV_CHANGED_XLABEL (1 << 2) |
X-Label edited.
Definition at line 36 of file envelope.h.
#define MUTT_ENV_CHANGED_SUBJECT (1 << 3) |
Protected header update.
Definition at line 37 of file envelope.h.
enum ExpandoDataEnvelope |
Expando UIDs for Envelopes.
Enumerator | |
---|---|
ED_ENV_CC_ALL | |
ED_ENV_FIRST_NAME | |
ED_ENV_FROM | Envelope.from (first) |
ED_ENV_FROM_FULL | Envelope.from (all) |
ED_ENV_INITIALS | Envelope.from (first) |
ED_ENV_LIST_ADDRESS | |
ED_ENV_LIST_EMPTY | |
ED_ENV_MESSAGE_ID | |
ED_ENV_NAME | Envelope.from (first) |
ED_ENV_NEWSGROUP | |
ED_ENV_ORGANIZATION | |
ED_ENV_REAL_NAME | Envelope.to (first) |
ED_ENV_REPLY_TO | |
ED_ENV_SENDER | |
ED_ENV_SENDER_PLAIN | |
ED_ENV_SPAM | |
ED_ENV_SUBJECT | |
ED_ENV_THREAD_TREE | |
ED_ENV_THREAD_X_LABEL | |
ED_ENV_TO | Envelope.to, Envelope.cc (first) |
ED_ENV_TO_ALL | Envelope.to (all) |
ED_ENV_USERNAME | |
ED_ENV_USER_NAME | Envelope.to (first) |
ED_ENV_X_COMMENT_TO | |
ED_ENV_X_LABEL |
Definition at line 98 of file envelope.h.
enum NotifyEnvelope |
Types of Envelope Event.
Observers of NT_ENVELOPE will not be passed any Event data.
Notifications that an Envelope field has changed. Envelope doesn't support notifications, so events will be passed to the Email.
Definition at line 135 of file envelope.h.
Strictly compare two Envelopes.
true | Envelopes are strictly identical |
Definition at line 285 of file envelope.c.
void mutt_env_free | ( | struct Envelope ** | ptr | ) |
Free an Envelope.
[out] | ptr | Envelope to free |
Definition at line 126 of file envelope.c.
Merge the headers of two Envelopes.
Any fields that are missing from base will be copied from extra. extra will be freed afterwards.
Definition at line 193 of file envelope.c.
struct Envelope * mutt_env_new | ( | void | ) |
Create a new Envelope.
ptr | New Envelope |
Definition at line 46 of file envelope.c.
bool mutt_env_notify_send | ( | struct Email * | e, |
enum NotifyEnvelope | type | ||
) |
Send an Envelope change notification.
e | |
type | Notification type, e.g. NT_ENVELOPE_SUBJECT |
true | Successfully sent |
Definition at line 179 of file envelope.c.
void mutt_env_set_subject | ( | struct Envelope * | env, |
const char * | subj | ||
) |
Set both subject and real_subj to subj.
env | Envelope |
subj | Subject |
Definition at line 69 of file envelope.c.
int mutt_env_to_intl | ( | struct Envelope * | env, |
const char ** | tag, | ||
char ** | err | ||
) |
Convert an Envelope's Address fields to Punycode format.
[in] | env | Envelope to modify |
[out] | tag | Name of the failed field |
[out] | err | Failed address |
0 | Success, all addresses converted |
1 | Error, tag and err will be set |
Run mutt_addrlist_to_intl() on each of the Address fields in the Envelope.
Definition at line 355 of file envelope.c.
void mutt_env_to_local | ( | struct Envelope * | env | ) |
Convert an Envelope's Address fields to local format.
env | Envelope to modify |
Run mutt_addrlist_to_local() on each of the Address fields in the Envelope.
Definition at line 317 of file envelope.c.
struct AutocryptHeader * mutt_autocrypthdr_new | ( | void | ) |
Create a new AutocryptHeader.
ptr | New AutocryptHeader |
Definition at line 95 of file envelope.c.
void mutt_autocrypthdr_free | ( | struct AutocryptHeader ** | ptr | ) |
Free an AutocryptHeader.
ptr | AutocryptHeader to free |
Definition at line 104 of file envelope.c.