15 #define epicsExportSharedSymbols 30 operation_type::shared_pointer
op;
36 pvd::PVStructure::const_shared_pointer args;
41 const pvd::PVStructure::const_shared_pointer& args) :
started(
false), cb(cb), args(args)
42 {REFTRACE_INCREMENT(num_instances);}
47 REFTRACE_DECREMENT(num_instances);
63 }
catch(std::exception& e){
64 LOG(
pva::logLevelError,
"Unhandled exception in ClientChannel::RPCCallback::requestDone(): %s", e.what());
71 return op ? op->getChannel()->getChannelName() :
"<dead>";
79 if(started && op) op->cancel();
86 return op ? op->getChannel()->getRequesterName() :
"<dead>";
95 if(!cb || started)
return;
100 event.message.clear();
106 operation->request(std::tr1::const_pointer_cast<pvd::PVStructure>(args));
116 event.message =
"Disconnect";
123 pva::ChannelRPC::shared_pointer
const & operation,
124 epics::pvData::PVStructure::shared_pointer
const & pvResponse)
OVERRIDE FINAL 133 event.message.clear();
135 event.value = pvResponse;
145 strm <<
"Operation(RPC" 146 "\"" <<
name() <<
"\"" 151 size_t RPCer::num_instances;
159 const epics::pvData::PVStructure::const_shared_pointer& arguments,
160 epics::pvData::PVStructure::const_shared_pointer pvRequest)
162 if(!impl)
throw std::logic_error(
"Dead Channel");
166 std::tr1::shared_ptr<RPCer> ret(RPCer::build(cb, arguments));
170 ret->op = getChannel()->createChannelRPC(ret->internal_shared_from_this(),
virtual void getDone(const GetEvent &evt)=0
get or rpc operation is complete
Information on get/rpc completion.
virtual std::string name() const =0
callback for get() and rpc()
const std::string & getMessage() const
PVStructure::shared_pointer createRequest(std::string const &request)
const std::tr1::weak_ptr< Process2PutProxy > operation
Handle for in-progress get/put/rpc operation.
virtual void show(std::ostream &) const =0
#define LOG(level, format,...)
virtual void channelDisconnect(bool destroy)
std::tr1::shared_ptr< Derived > internal_shared_from_this()
APIs for the epicsMutex mutual exclusion semaphore.
virtual void channelRPCConnect(const epics::pvData::Status &status, ChannelRPC::shared_pointer const &operation)=0
static size_t num_instances
Data interface for a structure,.
virtual void requestDone(const epics::pvData::Status &status, ChannelRPC::shared_pointer const &operation, epics::pvData::PVStructure::shared_pointer const &pvResponse)=0
void registerRefCounter(const char *name, const size_t *counter)
request cancelled before completion
APIs for the epicsEvent binary semaphore.
request ends in failure. Check message
std::tr1::shared_ptr< BitSet > BitSetPtr
ChannelPut::shared_pointer op
void registerRefTrackRPC()
shared_ptr< T > const_pointer_cast(shared_ptr< U > const &r) BOOST_NOEXCEPT
C++ and C descriptions for a thread.