On 1/9/07, Stefano Bagnara <[EMAIL PROTECTED]> wrote:
robert burrell donkin wrote:

<snip>

> IMAP as a protocol has some commands which are naturally stateful and
> some which are more naturally stateless. superficially at least, it
> seems more natural to me to think about a stateful session layering
> above a lower level stateless API.
>
> but these are just ideas

Can you make an example? I'm not sure I understand.

drilling down from the general: perhaps a client wants to know which
emails in a mailbox have meta-data matching certain criteria. for
example, all messages which have not been answered and have not been
read.

when using IMAP, one way to do this is by issuing a SEARCH command
specifying mailbox and the criteria. AFIAK this command does not
depend on which mailbox has been selected or the current client state,
just the data.

this is basically an atomic, stateless operation. there should be no
need to open a heavyweight session to execute it.

querying meta-data about an email (headers and so on) to find URIs for
all emails matching these criteria sounds like an operation which is
generic and suitable for a high level API.

- robert

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to