demo.repair
Class RepairDirectoryTest2.RepairResp

java.lang.Object
  |
  +--dd.api.DDRouteMsg
        |
        +--demo.repair.RepairDirectoryTest2.RepairResp
All Implemented Interfaces:
QueueElementIF, QuickSerializable
Enclosing class:
RepairDirectoryTest2

public static class RepairDirectoryTest2.RepairResp
extends DDRouteMsg

RepairResp is contains the nodes lifetime and is the response to the RepairReq. The node with the highest lifetime becomes the repair process leader; that is, node responsible for coordinating the repair of an object replicated on a set of nodes.


Field Summary
 
Fields inherited from class dd.api.DDRouteMsg
dd_intermediate_upcall, hopCount, inbound, one_hop, peer, recursive_route, TTL
 
Constructor Summary
RepairDirectoryTest2.RepairResp(InputBuffer buffer)
          Constructs a RepairResp from its serialized form.
RepairDirectoryTest2.RepairResp(SecureHash peer, long lifetime, SecureHash objguid, DDThresholdTag ttag, boolean recursive_route, boolean dd_intermediate_upcall, boolean one_hop)
          Construct according to the given fields.
 
Method Summary
 long getLifetime()
          getLifetime returns the lifetime of the node (in us).
 SecureHash getObjguid()
          getObjguid returns the guid of the originally requested obj specified in the RepairResp.
 DDThresholdTag getTag()
          getTag returns the DDThresholdTag associated with the objguid.
 void serialize(OutputBuffer buffer)
          Specified by ostore.util.QuickSerializable
 String toString()
          Specified by java.lang.Object
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

RepairDirectoryTest2.RepairResp

public RepairDirectoryTest2.RepairResp(SecureHash peer,
                                       long lifetime,
                                       SecureHash objguid,
                                       DDThresholdTag ttag,
                                       boolean recursive_route,
                                       boolean dd_intermediate_upcall,
                                       boolean one_hop)
Construct according to the given fields.


RepairDirectoryTest2.RepairResp

public RepairDirectoryTest2.RepairResp(InputBuffer buffer)
                                throws QSException
Constructs a RepairResp from its serialized form.

Parameters:
buffer - serialized form of object.
Method Detail

getLifetime

public final long getLifetime()
getLifetime returns the lifetime of the node (in us).

Returns:
the lifetime of the node (in us).

getObjguid

public final SecureHash getObjguid()
getObjguid returns the guid of the originally requested obj specified in the RepairResp.

Returns:
the guid specified in the RepairResp.

getTag

public final DDThresholdTag getTag()
getTag returns the DDThresholdTag associated with the objguid.

Returns:
the DDThresholdTag associated to the objguid.

serialize

public void serialize(OutputBuffer buffer)
Specified by ostore.util.QuickSerializable

Specified by:
serialize in interface QuickSerializable
Overrides:
serialize in class DDRouteMsg

toString

public String toString()
Specified by java.lang.Object

Overrides:
toString in class Object