RuntimeDispatcher.hpp
1 #pragma once
2 #include <score_lib_base_export.h>
3 namespace score
4 {
5 class Command;
6 struct SCORE_LIB_BASE_EXPORT Dispatcher
7 {
8  virtual ~Dispatcher();
9  virtual void submit(score::Command*) = 0;
10 };
11 
12 template <typename T>
13 struct Dispatcher_T final : Dispatcher
14 {
15  explicit Dispatcher_T(T& t)
16  : impl{t}
17  {
18  }
19  T& impl;
20  void submit(score::Command* c) override { impl.submit(c); }
21 };
22 }
The Command class.
Definition: Command.hpp:34
Base toolkit upon which the software is built.
Definition: Application.cpp:90
Definition: RuntimeDispatcher.hpp:14
Definition: RuntimeDispatcher.hpp:7