Re: Imap Backend Propsal
| From: | Stefan Neufeind | Date: | Mon, 02 Feb 2004 13:07:21 +0000 |
| Subject: | Re: Imap Backend Propsal | ||
| References: | 1 2 | Groups: | php.pear.dev |
| Request: | Send a blank email to pear-dev+get-25417@lists.php.net to get a copy of this message | ||
On Mon, 2 Feb 2004 at 13:57:43, Cipriano Groenendal wrote:
> > >Also, I don't see the point to call your methods imapSomething. Just get
> rid of the imap
> > >prefix and we might be able to later have a Mail_POP3 class with the same
> API.
> > --This class mostly just wraps IMAP functions, thus I thought it helpful
> to name the
> > functions after what they were wrapping. But again, point taken.
> Abstraction is
> > always good!
> I've written my own webmail client with similar functions in the backend as
> this class proposes, and as such, I'm highly interrested in it.
> As you may or may not know, PHP's imap module can connect to IMAP, POP and
> NNTP via the same functions. Even the data returned will be nearly
> identical. There will be no need at all for a seperate Mail_POP3 class,
> since the Mail_IMAP package will access it just as easily as it would with
> IMAP. That said, I agree with Bertrand about the class name and function
> names. I'd suggest calling it Mail_Message, since it deals with parsing and
> reading of a message.
Since you're parsing mainly the headers and MIME-structure of a message,
wouldn't it be a good idea to integrate this into Mail_Mime? No more class
would be needed, and since Mail_Mime currently handeles generation of a MIME-
message it might then also support parsing as well as "parse, modify and sent
our again" or something. Just a thought ...
Stefan