Re: New mailbox interface and gmime messages



On Fri, 28 Feb 2003 22:40:28 Magick wrote:
> 

> 
> So there should be a function to retrief header(s) of all the messages in 
> a mailbox, and a function to get a set of headers of a message.
> And of course a function to get all of the message text, are there other 
> places that need special handling?

it goes pretty much like this, you scan the mailbox and that gets you a list
of messages. gmime Message includes from, recipients, subject and date.
you can also get arbitrary headers from an hash gmime creates while it's
scanning the message, we can cache those we need for threading. 

at this moment i'm not sure if we should have libbalsa_message_get_header 
specific function or if we should just go ahead and peek at gmime
structures - much like we do with libmutt now at some points.
i'm pending towards macros such as 
SUBJECT(message)
this can be expanded to message.subject or message.gmime.subject 
or libbalsa_message_get_subject - whatever we need now or in the
future.

please note you always have to scan the full header while reading
in the mailbox so you get all the headers for free. the access penalty
for local stores or even nfs is negligable
in the imap case you can ask the server for specific headers, or 
read in the header in bulk - which is better, depends :)

-- 
Carlos Morgado - chbm(at)chbm(dot)nu - http://chbm.nu/ -- gpgkey: 0x1FC57F0A 
http://wwwkeys.pgp.net/ FP:0A27 35D3 C448 3641 0573 6876 2A37 4BB2 1FC5 7F0A



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]