Mail.app in 10.4 stores each message in its own file. The first line has an ASCII integer on it, the length in bytes of the message; then comes the message; then an XML "plist" blob with a few key/value pairs like "sender" and "subject". One of those properties is "flags", holding an integer, presumably bits indicating "unread", "replied", etc. But there are a lot of bits set in there -- some otherwise-uncomplicated messages seem to make use of up to 30 bits. What are they?
Update: Please, people, I asked a very straightfoward question. I'm not interested in your guesses. I can guess too. I'm looking for facts. I can also reverse-engineer at least some of it, if I have to. But I'd rather not, if it's actually documented somewhere. Which is why I asked. If you don't know, put your hand down.
Update: An anonymous benefactor has the goods:
0 | read | 1 << 0 |
1 | deleted | 1 << 1 |
2 | answered | 1 << 2 |
3 | encrypted | 1 << 3 |
4 | flagged | 1 << 4 |
5 | recent | 1 << 5 |
6 | draft | 1 << 6 |
7 | initial (no longer used) | 1 << 7 |
8 | forwarded | 1 << 8 |
9 | redirected | 1 << 9 |
10-15 | attachment count | 3F << 10 (6 bits) |
16-22 | priority level | 7F << 16 (7 bits) |
23 | signed | 1 << 23 |
24 | is junk | 1 << 24 |
25 | is not junk | 1 << 25 |
26-28 | font size delta | 7 << 26 (3 bits) |
29 | junk mail level recorded | 1 << 29 |
30 | highlight text in toc | 1 << 30 |
31 | (unused) |
Thank you Mask Man!
Update, 7 Aug 2005: I've posted my Perl code to parse these files: emlx.pl. Using this code you can, e.g., ssh in to your mac and see what messages Mail.app has downloaded while you were away.