RSB  0.7.0
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
rsb::patterns::Server::Callback< RequestType, ReplyType > Class Template Reference

Callback object used to register one method for a server. More...

#include <Server.h>

Inheritance diagram for rsb::patterns::Server::Callback< RequestType, ReplyType >:
Inheritance graph
Collaboration diagram for rsb::patterns::Server::Callback< RequestType, ReplyType >:
Collaboration graph

Public Member Functions

 Callback (const std::string &requestType=rsc::runtime::typeName(typeid(RequestType)), const std::string &replyType=rsc::runtime::typeName(typeid(ReplyType)))
virtual boost::shared_ptr
< ReplyType > 
call (const std::string &methodName, boost::shared_ptr< RequestType > input)=0
 Implement this method to perform actions.
- Public Member Functions inherited from rsb::patterns::Server::CallbackBase
virtual std::string getRequestType () const
virtual std::string getReplyType () const
- Public Member Functions inherited from rsb::patterns::Server::IntlCallback
virtual ~IntlCallback ()
virtual AnnotatedData intlCall (const std::string &methodName, boost::shared_ptr< void > input)=0

Private Member Functions

AnnotatedData intlCall (const std::string &methodName, boost::shared_ptr< void > input)

Additional Inherited Members

- Protected Member Functions inherited from rsb::patterns::Server::CallbackBase
 CallbackBase (const std::string &requestType, const std::string &replyType)
- Protected Attributes inherited from rsb::patterns::Server::CallbackBase
std::string requestType
std::string replyType

Detailed Description

template<class RequestType, class ReplyType>
class rsb::patterns::Server::Callback< RequestType, ReplyType >

Callback object used to register one method for a server.

Template Parameters
RequestTypethe data type of the request payload
ReplyTypethe data type of the reply payload
Author
jwienke

Definition at line 137 of file Server.h.

Constructor & Destructor Documentation

template<class RequestType , class ReplyType >
rsb::patterns::Server::Callback< RequestType, ReplyType >::Callback ( const std::string &  requestType = rsc::runtime::typeName(typeid(RequestType)),
const std::string &  replyType = rsc::runtime::typeName(typeid(ReplyType)) 
)
inline

Definition at line 140 of file Server.h.

Member Function Documentation

template<class RequestType , class ReplyType >
virtual boost::shared_ptr<ReplyType> rsb::patterns::Server::Callback< RequestType, ReplyType >::call ( const std::string &  methodName,
boost::shared_ptr< RequestType >  input 
)
pure virtual

Implement this method to perform actions.

Parameters
methodNamecalled method
inputinput data for the method
Returns
result data for the method
Exceptions
std::exceptionall exceptions based on this type are automatically caught and delivered to the remote server
template<class RequestType , class ReplyType >
AnnotatedData rsb::patterns::Server::Callback< RequestType, ReplyType >::intlCall ( const std::string &  methodName,
boost::shared_ptr< void >  input 
)
inlineprivate

Definition at line 160 of file Server.h.


The documentation for this class was generated from the following file: