/TGame/TServerMS/Service/ServiceImpDB.h

http://awoe.googlecode.com/ · C Header · 44 lines · 24 code · 10 blank · 10 comment · 0 complexity · cce9462e04112ce838c162d1f8ea148c MD5 · raw file

  1. #ifndef __WOE_SERVICE_IMP_DB___
  2. #define __WOE_SERVICE_IMP_DB___
  3. #include "Service/ServiceImp.h"
  4. #include "ServiceDataSMS.h"
  5. #include "Entity/EntityManagerIf.h"
  6. #include "Database/CacheMsgHandler.h"
  7. #include "Database/DBMessageHandler.h"
  8. //
  9. // Database Service
  10. //
  11. //
  12. class ServiceImpDB : public ServiceImp
  13. {
  14. public:
  15. ServiceImpDB();
  16. virtual void init(ServiceData& data);
  17. protected:
  18. virtual void onStart();
  19. virtual void onStop();
  20. //
  21. // callbacks
  22. //
  23. virtual void onTimer();
  24. virtual void onDispatchMsg(IMsg* pMsg);
  25. protected:
  26. Service* m_wpSvcLgc;
  27. CacheMsgHandler m_CacheMsgHandler;
  28. DBMessageHandler m_PersistMsgHandler;
  29. //
  30. // configurations from properties file
  31. //
  32. MsgHandlerInitDataDB m_initData;
  33. };
  34. #endif