From 42657326fdf8db194013094537d9386830fe5876 Mon Sep 17 00:00:00 2001 From: Jiri Moskovcak Date: Wed, 1 Apr 2009 09:36:46 +0200 Subject: Added commlayer to make dbus optional --- lib/CommLayer/CommLayerServer.cpp | 30 ++++++++++++++++++++++++++++++ 1 file changed, 30 insertions(+) create mode 100644 lib/CommLayer/CommLayerServer.cpp (limited to 'lib/CommLayer/CommLayerServer.cpp') diff --git a/lib/CommLayer/CommLayerServer.cpp b/lib/CommLayer/CommLayerServer.cpp new file mode 100644 index 0000000..1ebae6d --- /dev/null +++ b/lib/CommLayer/CommLayerServer.cpp @@ -0,0 +1,30 @@ +#include "CommLayerServer.h" +#include + +CCommLayerServer::CCommLayerServer(CMiddleWare *pMW) +{ + m_pMW = pMW; + std::cerr << "CCommLayerServer init.." << std::endl; +} + +CCommLayerServer::~CCommLayerServer() +{ + std::cout << "CCommLayerServer::Cleaning up.." << std::endl; +} + +void CCommLayerServer::Attach(CObserver *pObs) +{ + std::cerr << "CCommLayerServer::Attach" << std::endl; + m_pObserver = pObs; +} +void CCommLayerServer::Detach(CObserver *pObs) +{ + std::cerr << "CCommLayerServer::Detach" << std::endl; + m_pObserver = NULL; +} +void CCommLayerServer::Notify(const std::string& pMessage) +{ + std::cerr << "CCommLayerServer::Notify" << std::endl; + if(m_pObserver) + m_pObserver->Update(pMessage); +} -- cgit