feisty meow concerns codebase
2.140
|
Base class for routes on which letters are automatically delivered. More...
#include <mail_stop.h>
Classes | |
class | items_to_deliver |
Public Member Functions | |
virtual void | delivery_for_you (const structures::unique_int &id, letter *package)=0 |
the derived object must provide this function. More... | |
Public Member Functions inherited from processes::safe_callback | |
safe_callback () | |
construction signifies that the callback is now in operation. More... | |
void | end_availability () |
prepares to shut down this object. More... | |
virtual | ~safe_callback () |
actually destroys the object. More... | |
DEFINE_CLASS_NAME ("safe_callback") | |
bool | decoupled () const |
if true, then end_availability() was already invoked on the object. More... | |
bool | invoke_callback (callback_data_block &new_data) |
this function is invoked by a user of the safe_callback derived object. More... | |
global_live_objects & | _invocables () |
provides access to the program-wide list of healthy callback objects. More... | |
Protected Member Functions | |
virtual void | real_callback (callback_data_block &data) |
invoked by the safe callback machinery. More... | |
Base class for routes on which letters are automatically delivered.
The letters will show up for a particular unique id at this mail stop. They are delivered by the object serving as the post office.
Definition at line 33 of file mail_stop.h.
|
pure virtual |
the derived object must provide this function.
prompts the recipient with the "id" to accept delivery of a "package". the package can be modified as desired and MUST be recycled before returning from this function. IMPORTANT NOTE: the receiver MUST be thread-safe with respect to the objects that it uses to handle this delivery! this is because mail is delivered on a thread other than the main program thread.
Referenced by real_callback().
|
inlineprotectedvirtual |
invoked by the safe callback machinery.
this is implemented in this class and merely re-routes the call to the more specific delivery_for_you() method.
Implements processes::safe_callback.
Definition at line 61 of file mail_stop.h.
References processes::mail_stop::items_to_deliver::_id, processes::mail_stop::items_to_deliver::_package, and delivery_for_you().