OverSim
RpcMacros.h File Reference

This file declares some macros for RPC implementation. More...

Go to the source code of this file.

Macros

#define RPC_SWITCH_START(message)
 Marks the beginning of a Remote-Procedure-Call Switch block.
#define RPC_SWITCH_END()   } while (false);
 Marks the end of a Remote-Procedure-Call Switch block.
#define IF_RPC_HANDLED   if (rpcHandled)
#define RPC_HANDLED   rpcHandled
#define RPC_DELEGATE(name, method)
 Declares a RPC method delegation.
The message name of the RPC

Declares an if-statement for a specific response

#define RPC_ON_CALL(name)
#define RPC_ON_RESPONSE(name)

Detailed Description

This file declares some macros for RPC implementation.

Author
Sebastian Mies

Definition in file RpcMacros.h.

Macro Definition Documentation

#define IF_RPC_HANDLED   if (rpcHandled)

Definition at line 44 of file RpcMacros.h.

#define RPC_DELEGATE (   name,
  method 
)
Value:
name##Call* _##name##Call = dynamic_cast<name##Call*>(___msg); \
if (_##name##Call != NULL) { rpcHandled = true; method(_##name##Call); \
break; }

Declares a RPC method delegation.

Parameters
nameThe message Name of the RPC
methodThe method to call

Definition at line 56 of file RpcMacros.h.

Referenced by PubSubMMOG::handleRpcCall(), PubSubLobby::handleRpcCall(), NTree::handleRpcCall(), Broose::handleRpcCall(), Pastry::handleRpcCall(), P2pns::handleRpcCall(), CBRDHT::handleRpcCall(), DHT::handleRpcCall(), Scribe::handleRpcCall(), TreeManagement::handleRpcCall(), KBRTestApp::handleRpcCall(), Nps::handleRpcCall(), GlobalViewBuilder::handleRpcCall(), oversim::Koorde::handleRpcCall(), BasePastry::handleRpcCall(), oversim::Chord::handleRpcCall(), BaseRpc::internalHandleRpcCall(), and BaseOverlay::internalHandleRpcCall().

#define RPC_SWITCH_END ( )    } while (false);

Marks the end of a Remote-Procedure-Call Switch block.

Definition at line 41 of file RpcMacros.h.

Referenced by PubSubMMOG::handleRpcCall(), PubSubLobby::handleRpcCall(), NTree::handleRpcCall(), Broose::handleRpcCall(), Pastry::handleRpcCall(), P2pns::handleRpcCall(), CBRDHT::handleRpcCall(), MyOverlay::handleRpcCall(), DHT::handleRpcCall(), Scribe::handleRpcCall(), TreeManagement::handleRpcCall(), KBRTestApp::handleRpcCall(), Nps::handleRpcCall(), Kademlia::handleRpcCall(), GlobalViewBuilder::handleRpcCall(), oversim::Koorde::handleRpcCall(), BasePastry::handleRpcCall(), oversim::Chord::handleRpcCall(), PubSubMMOG::handleRpcResponse(), PubSubLobby::handleRpcResponse(), NTree::handleRpcResponse(), Bamboo::handleRpcResponse(), P2pns::handleRpcResponse(), CBRDHT::handleRpcResponse(), Pastry::handleRpcResponse(), MyOverlay::handleRpcResponse(), DHT::handleRpcResponse(), Scribe::handleRpcResponse(), KBRTestApp::handleRpcResponse(), GlobalViewBuilder::handleRpcResponse(), oversim::Koorde::handleRpcResponse(), Kademlia::handleRpcResponse(), DHTTestApp::handleRpcResponse(), BootstrapList::handleRpcResponse(), XmlRpcInterface::handleRpcResponse(), Nps::handleRpcResponse(), BasePastry::handleRpcResponse(), Broose::handleRpcResponse(), TreeManagement::handleRpcResponse(), oversim::Chord::handleRpcResponse(), PubSubMMOG::handleRpcTimeout(), PubSubLobby::handleRpcTimeout(), NTree::handleRpcTimeout(), CBRDHT::handleRpcTimeout(), MyOverlay::handleRpcTimeout(), DHT::handleRpcTimeout(), TreeManagement::handleRpcTimeout(), KBRTestApp::handleRpcTimeout(), oversim::Koorde::handleRpcTimeout(), Kademlia::handleRpcTimeout(), Nps::handleRpcTimeout(), Broose::handleRpcTimeout(), oversim::Chord::handleRpcTimeout(), BaseRpc::internalHandleRpcCall(), BaseOverlay::internalHandleRpcCall(), BaseRpc::internalHandleRpcResponse(), BaseRpc::internalHandleRpcTimeout(), and BaseOverlay::internalHandleRpcTimeout().

#define RPC_SWITCH_START (   message)
Value:
bool rpcHandled = false;\
do { \
BaseRpcMessage* ___msg = dynamic_cast<BaseRpcMessage*>(message);

Marks the beginning of a Remote-Procedure-Call Switch block.

RPC_CALL, RPC_ON_CALL, RPC_ON_RESPONSE are allowed inside this block.

Definition at line 33 of file RpcMacros.h.

Referenced by PubSubMMOG::handleRpcCall(), PubSubLobby::handleRpcCall(), NTree::handleRpcCall(), Broose::handleRpcCall(), Pastry::handleRpcCall(), P2pns::handleRpcCall(), CBRDHT::handleRpcCall(), MyOverlay::handleRpcCall(), DHT::handleRpcCall(), Scribe::handleRpcCall(), TreeManagement::handleRpcCall(), KBRTestApp::handleRpcCall(), Nps::handleRpcCall(), Kademlia::handleRpcCall(), GlobalViewBuilder::handleRpcCall(), oversim::Koorde::handleRpcCall(), BasePastry::handleRpcCall(), oversim::Chord::handleRpcCall(), PubSubMMOG::handleRpcResponse(), PubSubLobby::handleRpcResponse(), NTree::handleRpcResponse(), Bamboo::handleRpcResponse(), P2pns::handleRpcResponse(), CBRDHT::handleRpcResponse(), Pastry::handleRpcResponse(), MyOverlay::handleRpcResponse(), DHT::handleRpcResponse(), Scribe::handleRpcResponse(), KBRTestApp::handleRpcResponse(), GlobalViewBuilder::handleRpcResponse(), oversim::Koorde::handleRpcResponse(), Kademlia::handleRpcResponse(), DHTTestApp::handleRpcResponse(), BootstrapList::handleRpcResponse(), XmlRpcInterface::handleRpcResponse(), Nps::handleRpcResponse(), BasePastry::handleRpcResponse(), Broose::handleRpcResponse(), TreeManagement::handleRpcResponse(), oversim::Chord::handleRpcResponse(), PubSubMMOG::handleRpcTimeout(), PubSubLobby::handleRpcTimeout(), NTree::handleRpcTimeout(), CBRDHT::handleRpcTimeout(), MyOverlay::handleRpcTimeout(), DHT::handleRpcTimeout(), TreeManagement::handleRpcTimeout(), KBRTestApp::handleRpcTimeout(), oversim::Koorde::handleRpcTimeout(), Kademlia::handleRpcTimeout(), Nps::handleRpcTimeout(), Broose::handleRpcTimeout(), oversim::Chord::handleRpcTimeout(), BaseRpc::internalHandleRpcCall(), BaseOverlay::internalHandleRpcCall(), BaseRpc::internalHandleRpcResponse(), BaseRpc::internalHandleRpcTimeout(), and BaseOverlay::internalHandleRpcTimeout().