|
DelegateMQ
|
A base class for a delegate enabled execution thread. Implemented by application code if asynchronous delegates are used. More...
#include <IThread.h>
Public Member Functions | |
| virtual | ~IThread ()=default |
| Destructor. | |
| virtual void | DispatchDelegate (std::shared_ptr< DelegateMsg > msg)=0 |
A base class for a delegate enabled execution thread. Implemented by application code if asynchronous delegates are used.
@TODO Implement the IThread interface if necessary.
Each platform specific implementation must inherit from IThread and provide an implementation for DispatchDelegate(). The DispatchDelegate() function is called by the source thread to initiate an asynchronous function call onto the destination thread of control.
|
virtualdefault |
Destructor.
|
pure virtual |
Dispatch a DelegateMsg onto this thread. The implementer is responsible for getting the DelegateMsg into an OS message queue. Once DelegateMsg is on the destination thread of control, the IInvoker::Invoke() function must be called to execute the target function.
| [in] | msg | A shared pointer to the message. |
IThreadInvoker::Invoke() when DelegateMsg is received.