| 
    OverSim
    
   | 
 
#include <RecursiveLookup.h>
  
 Public Member Functions | |
| RecursiveLookup (BaseOverlay *overlay, RoutingType routingType, const RecursiveLookupConfiguration &config, bool appLookup) | |
| virtual | ~RecursiveLookup () | 
| Virtual destructor.   | |
| virtual void | lookup (const OverlayKey &key, int numSiblings=1, int hopCountMax=0, int retries=0, LookupListener *listener=NULL) | 
| Lookup siblings for a key.   | |
| virtual const NodeVector & | getResult () const | 
| Returns the result of the lookup.   | |
| virtual bool | isValid () const | 
| Returns true, if the lookup was successful.   | |
| virtual void | abortLookup () | 
| Aborts a running lookup.   | |
| virtual uint32_t | getAccumulatedHops () const | 
| Returns the total number of hops for all lookup paths.   | |
| void | handleRpcTimeout (BaseCallMessage *msg, const TransportAddress &dest, cPolymorphic *context, int rpcId, const OverlayKey &destKey) | 
| This method is called if an RPC timeout has been reached.   | |
| void | handleRpcResponse (BaseResponseMessage *msg, cPolymorphic *context, int rpcId, simtime_t rtt) | 
| This method is called if an RPC response has been received.   | |
  Public Member Functions inherited from RpcListener | |
| virtual | ~RpcListener () | 
| destructor   | |
  Public Member Functions inherited from AbstractLookup | |
| virtual | ~AbstractLookup () | 
| Virtual destructor.   | |
Private Attributes | |
| BaseOverlay * | overlay | 
| LookupListener * | listener | 
| uint32_t | nonce | 
| bool | valid | 
| NodeVector | siblings | 
| RoutingType | routingType | 
| int | redundantNodes | 
| int | numRetries | 
| bool | appLookup | 
Additional Inherited Members | |
  Protected Member Functions inherited from RpcListener | |
| virtual void | handleRpcResponse (BaseResponseMessage *msg, const RpcState &rpcState, simtime_t rtt) | 
| This method is called if an RPC response has been received.   | |
| virtual void | handleRpcTimeout (const RpcState &rpcState) | 
| This method is called if an RPC timeout has been reached.   | |
Definition at line 48 of file RecursiveLookup.h.
| RecursiveLookup::RecursiveLookup | ( | BaseOverlay * | overlay, | 
| RoutingType | routingType, | ||
| const RecursiveLookupConfiguration & | config, | ||
| bool | appLookup | ||
| ) | 
Definition at line 31 of file RecursiveLookup.cc.
      
  | 
  virtual | 
Virtual destructor.
Definition at line 44 of file RecursiveLookup.cc.
      
  | 
  virtual | 
Aborts a running lookup.
This method aborts a running lookup without calling the listener and delete the lookup object.
Implements AbstractLookup.
Definition at line 82 of file RecursiveLookup.cc.
      
  | 
  virtual | 
Returns the total number of hops for all lookup paths.
Implements AbstractLookup.
Definition at line 89 of file RecursiveLookup.cc.
      
  | 
  virtual | 
Returns the result of the lookup.
Implements AbstractLookup.
Definition at line 72 of file RecursiveLookup.cc.
      
  | 
  virtual | 
This method is called if an RPC response has been received.
| msg | The response message. | 
| context | Pointer to an optional state object. The object has to be handled/deleted by the handleRpcResponse() code | 
| rpcId | The RPC id. | 
| rtt | The Round-Trip-Time of this RPC | 
Reimplemented from RpcListener.
Definition at line 112 of file RecursiveLookup.cc.
      
  | 
  virtual | 
This method is called if an RPC timeout has been reached.
| msg | The original RPC message. | 
| dest | The destination node | 
| context | Pointer to an optional state object. The object has to be handled/deleted by the handleRpcResponse() code | 
| rpcId | The RPC id. | 
| destKey | the destination OverlayKey | 
Reimplemented from RpcListener.
Definition at line 95 of file RecursiveLookup.cc.
      
  | 
  virtual | 
Returns true, if the lookup was successful.
Implements AbstractLookup.
Definition at line 77 of file RecursiveLookup.cc.
      
  | 
  virtual | 
Lookup siblings for a key.
| key | The key to lookup | 
| numSiblings | Number of siblings to lookup | 
| hopCountMax | Maximum hop count | 
| retries | Number of retries if lookup fails | 
| listener | Listener to inform, when the lookup is done | 
Implements AbstractLookup.
Definition at line 54 of file RecursiveLookup.cc.
      
  | 
  private | 
Definition at line 110 of file RecursiveLookup.h.
Referenced by lookup().
      
  | 
  private | 
Definition at line 103 of file RecursiveLookup.h.
Referenced by handleRpcResponse(), handleRpcTimeout(), lookup(), and ~RecursiveLookup().
      
  | 
  private | 
Definition at line 104 of file RecursiveLookup.h.
Referenced by abortLookup(), and lookup().
      
  | 
  private | 
Definition at line 109 of file RecursiveLookup.h.
      
  | 
  private | 
Definition at line 102 of file RecursiveLookup.h.
Referenced by abortLookup(), lookup(), and ~RecursiveLookup().
      
  | 
  private | 
Definition at line 108 of file RecursiveLookup.h.
Referenced by lookup().
      
  | 
  private | 
Definition at line 107 of file RecursiveLookup.h.
Referenced by lookup().
      
  | 
  private | 
Definition at line 106 of file RecursiveLookup.h.
Referenced by getResult(), and handleRpcResponse().
      
  | 
  private | 
Definition at line 105 of file RecursiveLookup.h.
Referenced by handleRpcResponse(), handleRpcTimeout(), isValid(), and RecursiveLookup().