IEventSubscriber.hpp 749 B

12345678910111213141516171819202122232425262728293031
  1. /*
  2. * Author: Patrick-Christopher Mattulat
  3. * Company: Lynar Studios
  4. * E-Mail: webmaster@lynarstudios.com
  5. * Created: 2020-11-27
  6. * Changed: 2021-05-01
  7. *
  8. * */
  9. #ifndef LS_STD_I_EVENT_SUBSCRIBER_HPP
  10. #define LS_STD_I_EVENT_SUBSCRIBER_HPP
  11. #include "EventTypes.hpp"
  12. #include <memory>
  13. #include <ls_std/logic/IListener.hpp>
  14. namespace ls_std
  15. {
  16. class IEventSubscriber
  17. {
  18. public:
  19. IEventSubscriber() = default;
  20. ~IEventSubscriber() = default;
  21. virtual void subscribe(const ls_std::event_id &_id, const std::shared_ptr<ls_std::IListener> &_listener) = 0;
  22. virtual void unsubscribe(const ls_std::event_id &_id, const std::shared_ptr<ls_std::IListener> &_listener) = 0;
  23. };
  24. }
  25. #endif