|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectp2p.simulator.message.MessageBody
p2p.simulator.message.LookupResponse
public class LookupResponse
This class creates a special lookup response message body. This special message is used to extract statistics regarding the protocol's lookup algorithm.
| Constructor Summary | |
|---|---|
LookupResponse(long key,
boolean exist,
Message msg)
Creates the body message of a lookup response message. |
|
| Method Summary | |
|---|---|
int |
getHops()
Returns the number of peers that the lookup request message visited. |
int |
getType()
Returns the message's type. |
java.lang.String |
toString()
|
| Methods inherited from class p2p.simulator.message.MessageBody |
|---|
clone |
| Methods inherited from class java.lang.Object |
|---|
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
|---|
public LookupResponse(long key,
boolean exist,
Message msg)
key - The key of the lookup request.exist - If the key is found is true, otherwise false.msg - The initial lookup request message.| Method Detail |
|---|
public int getHops()
public int getType()
getType in class MessageBodypublic java.lang.String toString()
toString in class java.lang.Object
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||