2 // Open Service Platform
3 // Copyright (c) 2012 Samsung Electronics Co., Ltd.
5 // Licensed under the Apache License, Version 2.0 (the License);
6 // you may not use this file except in compliance with the License.
7 // You may obtain a copy of the License at
9 // http://www.apache.org/licenses/LICENSE-2.0
11 // Unless required by applicable law or agreed to in writing, software
12 // distributed under the License is distributed on an "AS IS" BASIS,
13 // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 // See the License for the specific language governing permissions and
15 // limitations under the License.
19 * @file FIo_ChannelServiceStub.h
20 * @brief This is the header file for the _ChannelServiceStub class.
22 * This file contains the declarations of _ChannelServiceStub.
26 #ifndef _FIO_INTERNAL_CHANNEL_SERVICE_STUB_H_
27 #define _FIO_INTERNAL_CHANNEL_SERVICE_STUB_H_
29 #include <FOspConfig.h>
30 #include <FBaseResult.h>
31 #include <FBaseObject.h>
32 #include <FBaseColArrayList.h>
33 #include <FBaseRt_ITask.h>
34 #include "FIo_IIpcServerEventListener.h"
35 #include "FIo_IChannelServiceStub.h"
42 namespace Tizen { namespace Io
46 class _ChannelService;
48 class _OSP_EXPORT_ _ChannelServiceStub
49 : public _IIpcServerEventListener
50 , public _IChannelServiceStub
51 , public Tizen::Base::Object
54 _ChannelServiceStub(void);
56 virtual ~_ChannelServiceStub(void);
58 virtual result Construct(void);
60 // _IChannelServiceStub
61 virtual result SendRequest(int clientId, const Tizen::Base::String& src,
62 const Tizen::Base::String& dest,
63 const Tizen::Base::Collection::ArrayList& args,
66 virtual result SendNullRequest(int clientId, const Tizen::Base::String& src,
67 const Tizen::Base::String& dest,
70 virtual result SendResponse(int clientId, const Tizen::Base::String& src,
71 const Tizen::Base::String& dest,
72 const Tizen::Base::Collection::ArrayList& args,
75 virtual result SendNullResponse(int clientId, const Tizen::Base::String& src,
76 const Tizen::Base::String& dest,
79 virtual void SetChannelService(_ChannelService& service);
83 bool OnRegisterChannelMessage(const Tizen::Base::String& appId, int* pResult);
85 bool OnSendRequestMessage(const Tizen::Base::String& src,
86 const Tizen::Base::String& dest,
87 const Tizen::Base::Collection::ArrayList& args,
91 bool OnSendNullRequestMessage(const Tizen::Base::String& src,
92 const Tizen::Base::String& dest,
96 bool OnSendResponseMessage(const Tizen::Base::String& src,
97 const Tizen::Base::String& dest,
98 const Tizen::Base::Collection::ArrayList& args,
102 bool OnSendNullResponseMessage(const Tizen::Base::String& src,
103 const Tizen::Base::String& dest,
107 virtual void OnIpcRequestReceived(_IpcServer& server, const IPC::Message& message);
109 virtual void OnIpcServerStarted(const _IpcServer& server);
111 virtual void OnIpcServerStopped(const _IpcServer& server);
113 virtual void OnIpcClientConnected(const _IpcServer& server, int clientId);
115 virtual void OnIpcClientDisconnected(const _IpcServer& server, int clientId);
117 _ChannelServiceStub(const _ChannelServiceStub& value);
118 _ChannelServiceStub& operator = (const _ChannelServiceStub& value);
120 _IpcServer* __pIpcServer;
121 _ChannelService* __pChannelService;
123 }; // _ChannelServiceStub
127 #endif // _FIO_INTERNAL_CHANNEL_SERVICE_STUB_H_