|
Bifrost SDK
Bifrost SDK documentation
|
Base class for a ITaskObserver that forwards notifications to a given TaskNotifier. More...
#include <TaskObserver.h>
Protected Member Functions | |
| ForwardTaskObserver (TaskNotifier notifier) | |
| Constructor. More... | |
| ~ForwardTaskObserver () override | |
| Destructor. More... | |
| void | onStart () noexcept override |
| Forwards the onStart notification to its notifier. More... | |
| void | onProgress (StringView const &title, unsigned num, unsigned denum) noexcept override |
| Forwards the onProgress notification to its notifier. More... | |
| void | onMessage (Message const &message) noexcept override |
| Forwards the onMessage notification to its notifier. More... | |
| void | onDone (TaskStatus status) noexcept override |
| Forwards the onDone notification to its notifier. More... | |
| virtual void | onStart () noexcept |
| Called when the task starts (defaults to noop). More... | |
| virtual void | onProgress (StringView const &title, unsigned num, unsigned denum) noexcept |
| Called when the task makes progress (defaults to noop). More... | |
| virtual void | onMessage (Message const &message) noexcept |
| Called when the task reports a message (defaults to noop). More... | |
| virtual void | onDone (TaskStatus status) noexcept=0 |
| Called when the task completed (must be overridden). More... | |
Additional Inherited Members | |
Public Types inherited from Amino::ITaskObserver | |
| using | TaskStatus = TaskStatus |
| using | Message = Message |
Public Member Functions inherited from Amino::ITaskObserver | |
| ITaskObserver ()=default | |
| Constructor. More... | |
| virtual | ~ITaskObserver () |
| Destructor. More... | |
Protected Attributes inherited from Amino::ITaskObserver | |
| friend | TaskNotifier |
Base class for a ITaskObserver that forwards notifications to a given TaskNotifier.
Bear in mind that forwarding notifications does entail some overhead due to the double virtual calls, so ForwardTaskObserver should be used sparingly, if really necessary.
Definition at line 563 of file TaskObserver.h.
|
inlineexplicitprotected |
Constructor.
Definition at line 568 of file TaskObserver.h.
|
overrideprotected |
Destructor.
|
overrideprotectedvirtualnoexcept |
Forwards the onDone notification to its notifier.
Implements Amino::ITaskObserver.
|
overrideprotectedvirtualnoexcept |
Forwards the onMessage notification to its notifier.
Reimplemented from Amino::ITaskObserver.
|
overrideprotectedvirtualnoexcept |
Forwards the onProgress notification to its notifier.
Reimplemented from Amino::ITaskObserver.
|
overrideprotectedvirtualnoexcept |
Forwards the onStart notification to its notifier.
Reimplemented from Amino::ITaskObserver.