EventHandler.hpp 969 B

12345678910111213141516171819202122232425262728293031323334353637383940414243444546
  1. /*
  2. * Author: Patrick-Christopher Mattulat
  3. * Company: Lynar Studios
  4. * E-Mail: webmaster@lynarstudios.com
  5. * Created: 2020-11-27
  6. * Changed: 2022-07-03
  7. *
  8. * */
  9. #ifndef LS_STD_EVENT_HANDLER_HPP
  10. #define LS_STD_EVENT_HANDLER_HPP
  11. #include <ls_std/core/Class.hpp>
  12. #include <list>
  13. #include <memory>
  14. #include <ls_std/core/interface/IListener.hpp>
  15. #include <ls_std/os/dynamic_goal.hpp>
  16. #include "Event.hpp"
  17. #include "Narrator.hpp"
  18. namespace ls
  19. {
  20. namespace std
  21. {
  22. namespace event
  23. {
  24. class LS_STD_DYNAMIC_GOAL EventHandler : public ls::std::event::Narrator
  25. {
  26. public:
  27. explicit EventHandler(const ls::std::core::type::event_id &_id);
  28. ~EventHandler() override = default;
  29. ls::std::core::type::event_id getId();
  30. private:
  31. ls::std::core::type::event_id id{};
  32. void _assignId(const ls::std::core::type::event_id &_id);
  33. };
  34. }
  35. }
  36. }
  37. #endif