xref: /haiku/docs/apps/mail/Programming Notes/ChainRunner Overview.txt (revision 2600324b57fa31cdea1627d584d314f2a579c4a8)
1NathanW wrote on June 30 2003:
2
3Here's the overview:
4
5ChainRunner:
6	It's now a BLooper and it goes like this: Running the chain
7triggers an 'INIT' message, which causes it to begin to load add-ons.
8The constructor of the producer add-on calls ChainRunner's
9GetMessages() routine with a list of unique ids to fetch. It then runs
10through the list, passing in those, then calls any registered process
11callbacks after the list is exhausted. Note that finishing the list *
12does not* cause the connection to be terminated and the add-ons to be
13destructed. Single pass add-ons (e.g. POP and Outbox) register a
14process callback that calls ChainRunner::Stop().
15
16MailProtocol/MailFilter:
17	No longer sets the unique id, because it's passed in. Calls
18GetMessages(), and uses ReportProgress() and ShowError() methods of
19ChainRunner instead of using the functions in status.h. Also sets SIZE
20attribute in out_headers that contains the final downloaded size of the
21message. Also now passed a ChainRunner instead of a StatusView.
22
23That's about it, really.
24-Nathan
25