|
TRex
the Technology Rex
|
|
Message Sending and Receiving
The data storage module is an abstraction presented to the core module (or
anyone interfacing with it) to manage the message handling with the
outer world (a.k.a. sending and receiving)
First sight
The main actions that send/receive protocols allow us to do are, simply:
connection/login and sending/receiving.
Based on these generic assumptions, the next methods will be used:
- open: initiates the relationship between the program and the
send/receive mechanism
- close: closes the relationship
- read: reads messages from inbox
- delete: deletes messages from inbox
- send: send messages
Follow up notes
- The first protocols to compatibilize (just the API, not the implementation)
are POP3,
SMTP,
IMAP,
NNTP and
Yahoo! Messenger
- It would be nice to add a list method to list all the incoming messages. Only
a list, not all the messages at once
- Add the UIDL retrieval in ``retrieve'' to allow messages not to be deleted after
retrieval
- Very useful: a list fo capabilities can be returned for each implementation
(take a look at IMAP capabilities).
(e.g. very useful in POP3 when you need to keep the message in the server BUT do
not know if uidl is supported)
- The login method to be used for sending and retrieving, and
the corresponding credentials, differ witihin each protocol and between them.
Remember that IMAP/POP3 have more than one authentication method.
- API splitting: Compatibilization for protocols that offers send and receive
(e.g. Instant Messaging) vs. protocols for single send or receiving (e.g. POP3 and SMTP)
- Adding for multiple protocol handling, e.g.
open()
is for the default protocol, and opening
for Yahoo! IM open('YIM')
|
TRex
the Technology Rex
|