7 #ifndef SERVERCHANNEL_H_
8 #define SERVERCHANNEL_H_
10 #include <pv/destroyable.h>
11 #include <pv/remote.h>
12 #include <pv/security.h>
13 #include <pv/baseChannelRequester.h>
18 class BaseChannelRequester;
23 POINTER_DEFINITIONS(ServerChannel);
25 static size_t num_instances;
34 ServerChannel(Channel::shared_pointer
const & channel,
35 const ChannelRequester::shared_pointer& requester,
36 pvAccessID cid, pvAccessID sid);
39 const Channel::shared_pointer& getChannel()
const {
return _channel; }
41 pvAccessID getCID()
const {
return _cid; }
43 pvAccessID getSID()
const {
return _sid; }
45 void registerRequest(pvAccessID
id,
const std::tr1::shared_ptr<BaseChannelRequester>& request);
47 void unregisterRequest(pvAccessID
id);
49 void installGetField(
const GetFieldRequester::shared_pointer& gf);
50 void completeGetField(GetFieldRequester *req);
53 std::tr1::shared_ptr<BaseChannelRequester> getRequest(pvAccessID
id);
57 void printInfo()
const;
59 void printInfo(FILE *fd)
const;
61 const Channel::shared_pointer _channel;
63 const ChannelRequester::shared_pointer _requester;
65 const pvAccessID _cid, _sid;
68 GetFieldRequester::shared_pointer _active_requester;
71 _requests_t _requests;
75 mutable epics::pvData::Mutex _mutex;