|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectde.uniba.wiai.lspi.chord.service.impl.References
public final class References
Stores all remote references of nodes the local node is connected to and provides methods for querying and manipulating these references. Makes use of one finger table, one successor list, and one predecessor reference.
Constructor Summary | |
---|---|
References(Floor floor,
ID locID,
URL locURL,
int numberOfEntriesInSuccessorList,
Entries entries)
Creates an References object which contains no references. |
Method Summary | |
---|---|
java.util.List<Node> |
getFirstFingerTableEntries(int i)
Determines the first i entries in the finger table. |
URL |
getPredecessorURL()
|
Node |
getSuccessor()
Determines this node's direct successor and returns it. |
URL |
getSuccessorURL()
|
java.lang.String |
toString()
Returns a formatted string of the IDs of all references stored on this node. |
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
---|
public References(Floor floor, ID locID, URL locURL, int numberOfEntriesInSuccessorList, Entries entries)
locID
- ID of local node. Must not be null
.numberOfEntriesInSuccessorList
- Length of successor list to be created. Must be greater or
equal 1!entries
- Reference on this nodes' entries which is passed to creation
of the successor list. Must not be null
.
java.lang.IllegalArgumentException
- If any parameters is null
or
if number of entries in successor list is less than 1.Method Detail |
---|
public final Node getSuccessor()
null
is returned.
null
if no
successor is known.public java.lang.String toString()
toString
in class java.lang.Object
public final URL getPredecessorURL()
public final URL getSuccessorURL()
public java.util.List<Node> getFirstFingerTableEntries(int i)
i
-
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |