libcyrus and the imap proto

Patrick Welche prlw1 at newn.cam.ac.uk
Thu Feb 27 08:29:23 EST 2003


Overall I see that you send commands to the imap server using imclient_send,
the last argument of which is essentially the text of the imap command.
You register callbacks based on keyword, so that when the server sends you
a reply, the function registered gets called. I suspect I am getting confused
between "tagged" and "untagged". The following is fine, and I think that

. capability                       <- sent with imclient_send
* CAPABILITY IMAP4 IMAP4rev1 ...   -> untagged? capability response
                                      picked up by callback based on
                                      keyword "CAPABILITY"
. OK Completed                     -> tagged? ok response picked up by
                                      imclient_send's finishproc


but now for the problem

. examine inbox                    <- sent with imclient_send
* FLAGS (\Answered \Flagged ...    -> untaged flags response, callback_flags
* OK [PERMANENTFLAGS ()]           -> untagged ok response, callback_ok
* 13 EXISTS             ********* What about these two?
* 1 RECENT              ********* untagged responses with no keyword?
* OK [UNSEEN 13]                   -> untagged ok response, callback_ok
* OK [UIDVALIDITY 1043953684]      -> untagged ok response, callback_ok
* OK [UIDNEXT 15]                  -> untagged ok response, callback_ok
. OK [READ-ONLY] Completed         -> tagged? ok response picked up by
                                      imclient_send's finishproc

same for eg
. fetch 1 (internaldate)
* 1 FETCH (INTERNALDATE "30-Jan-2003 19:23:41 +0000")
. OK Completed

How can I see the result of fetch?

Cheers,

Patrick




More information about the Info-cyrus mailing list