EngineRuntimeData.cpp 1.6 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061
  1. /*
  2. * author: Patrick-Christopher Mattulat
  3. * e-mail: webmaster@lynarstudios.com
  4. */
  5. #include <cycle/EngineRuntimeData.hpp>
  6. #include <ls-std/core/evaluator/NullPointerArgumentEvaluator.hpp>
  7. using ls::atlantis::cycle::EngineRuntimeData;
  8. using ls::atlantis::interfaces::IKeyboard;
  9. using ls::atlantis::interfaces::IWindowApi;
  10. using ls::atlantis::interfaces::IWindowApiEventManager;
  11. using ls::std::core::NullPointerArgumentEvaluator;
  12. using ::std::shared_ptr;
  13. EngineRuntimeData::EngineRuntimeData() = default;
  14. EngineRuntimeData::~EngineRuntimeData() = default;
  15. shared_ptr<IKeyboard> EngineRuntimeData::getKeyboard() const
  16. {
  17. return this->keyboard;
  18. }
  19. bool EngineRuntimeData::getIsUp() const
  20. {
  21. return this->isUp;
  22. }
  23. shared_ptr<IWindowApi> EngineRuntimeData::getWindowApi() const
  24. {
  25. return this->windowApi;
  26. }
  27. shared_ptr<IWindowApiEventManager> EngineRuntimeData::getWindowApiEventManager() const
  28. {
  29. return this->windowApiEventManager;
  30. }
  31. void EngineRuntimeData::setIsUp(const bool _isUp)
  32. {
  33. this->isUp = _isUp;
  34. }
  35. void EngineRuntimeData::setKeyboard(const shared_ptr<IKeyboard> &_keyboard)
  36. {
  37. NullPointerArgumentEvaluator(_keyboard).evaluate();
  38. this->keyboard = _keyboard;
  39. }
  40. void EngineRuntimeData::setWindowApi(const shared_ptr<IWindowApi> &_windowApi)
  41. {
  42. NullPointerArgumentEvaluator(_windowApi).evaluate();
  43. this->windowApi = _windowApi;
  44. }
  45. void EngineRuntimeData::setWindowApiEventManager(const shared_ptr<IWindowApiEventManager> &_windowApiEventManager)
  46. {
  47. NullPointerArgumentEvaluator(_windowApiEventManager).evaluate();
  48. this->windowApiEventManager = _windowApiEventManager;
  49. }