Rice Pastry API

rice.pastry
Class LocalNode

java.lang.Object
  extended byrice.pastry.LocalNode
All Implemented Interfaces:
LocalNodeI, java.io.Serializable

public abstract class LocalNode
extends java.lang.Object
implements LocalNodeI

Implementation of the LocalNodeI interface that some Serializable classes (such as Certificate) extend, if they want to be kept informed of what node they're on. If a class cannot use this provided implementation (for reasons such as multiple inheritance), it should implement the method provided in the LocalNode interface in the same manner as these.

Version:
$Id: LocalNode.java,v 1.8 2005/06/14 19:48:33 jeffh Exp $
Author:
Sitaram Iyer, Alan Mislove
See Also:
Serialized Form

Constructor Summary
LocalNode()
          Constructor for LocalNode.
 
Method Summary
 void afterSetLocalNode()
          Method that can be overridden by handle to set isLocal, etc.
 void assertLocalNode()
          May be called from handle etc methods to ensure that local node has been set, either on construction or on deserialization/receivemsg.
 PastryNode getLocalNode()
          Accessor method.
 void setLocalNode(PastryNode pn)
          Accessor method.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

LocalNode

public LocalNode()
Constructor for LocalNode.

Method Detail

getLocalNode

public final PastryNode getLocalNode()
Accessor method.

Specified by:
getLocalNode in interface LocalNodeI
Returns:
The LocalNode value

setLocalNode

public final void setLocalNode(PastryNode pn)
Accessor method. Notifies the overridable afterSetLocalNode.

Specified by:
setLocalNode in interface LocalNodeI
Parameters:
pn - The new LocalNode value

afterSetLocalNode

public void afterSetLocalNode()
Method that can be overridden by handle to set isLocal, etc.


assertLocalNode

public final void assertLocalNode()
May be called from handle etc methods to ensure that local node has been set, either on construction or on deserialization/receivemsg.

Specified by:
assertLocalNode in interface LocalNodeI

Rice Pastry API

Copyright © 2001-2005 - Rice Pastry.


Imprint-Dataprotection