bamboo.vivaldi
Class LocateNodeResp

java.lang.Object
  extended by ostore.network.NetworkMessage
      extended by bamboo.vivaldi.LocateNodeResp
All Implemented Interfaces:
Cloneable, ostore.util.QuickSerializable, QueueElementIF

public class LocateNodeResp
extends ostore.network.NetworkMessage

A response for finding a random node in the bamboo overlay. This message is sent directly from the located node to the sender of the request. The located node includes its nodeid and current virtual coordinate.

Version:
$Id: LocateNodeResp.java,v 1.1 2004/03/04 21:22:20 czerwin Exp $
Author:
Steven Czerwinski

Field Summary
 
Fields inherited from class ostore.network.NetworkMessage
comp_q, est_rtt_ms, inbound, peer, sender, timeout_sec, user_data, wait_ms
 
Constructor Summary
LocateNodeResp(ostore.util.InputBuffer buffer)
           
LocateNodeResp(ostore.util.NodeId requestor, ostore.util.NodeId locatedId, VirtualCoordinate locatedCoordinate)
          Constructs a response from the located node to be sent to the requestor.
 
Method Summary
 Object clone()
           
 VirtualCoordinate getLocatedCoordinate()
          Returns the virtual coordinate of the discovered noded.
 ostore.util.NodeId getLocatedId()
          Returns the node id of the discovered node.
 void serialize(ostore.util.OutputBuffer buffer)
           
 String toString()
           
 
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

LocateNodeResp

public LocateNodeResp(ostore.util.NodeId requestor,
                      ostore.util.NodeId locatedId,
                      VirtualCoordinate locatedCoordinate)
Constructs a response from the located node to be sent to the requestor.

Parameters:
requestor - The node which sent the original message.
locatedId - The node that was discovered.
locatedCoordinate - The discovered node's virtual coordinate.

LocateNodeResp

public LocateNodeResp(ostore.util.InputBuffer buffer)
               throws ostore.util.QSException
Throws:
ostore.util.QSException
Method Detail

serialize

public void serialize(ostore.util.OutputBuffer buffer)
Specified by:
serialize in interface ostore.util.QuickSerializable
Overrides:
serialize in class ostore.network.NetworkMessage

clone

public Object clone()
             throws CloneNotSupportedException
Overrides:
clone in class ostore.network.NetworkMessage
Throws:
CloneNotSupportedException

getLocatedId

public ostore.util.NodeId getLocatedId()
Returns the node id of the discovered node.


getLocatedCoordinate

public VirtualCoordinate getLocatedCoordinate()
Returns the virtual coordinate of the discovered noded.


toString

public String toString()
Overrides:
toString in class ostore.network.NetworkMessage