|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.ObjectSim.Routing.GPSR.Header.Broadcast
public class Broadcast
This is a broadcast header that tells other nodes who this is and what their location is.
| Field Summary | |
|---|---|
PacketId |
id
|
| Constructor Summary | |
|---|---|
Broadcast(PacketId pid,
int fromAddress,
Location fromLocation)
The constructor to create a new frame for broadcasting to other nodes my current location and address. |
|
| Method Summary | |
|---|---|
int |
getFromAddress()
The address of the node that sent this header. |
Location |
getFromLocation()
The location of the node that sent this header. |
int |
getSize()
Returns the "serialized" size of this portion of the packet. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
public PacketId id
| Constructor Detail |
|---|
public Broadcast(PacketId pid,
int fromAddress,
Location fromLocation)
fromAddress - the address of node this was sent from, purely for updating neighbors.fromLocation - the location of the sender node, purely for updating neighbors.| Method Detail |
|---|
public int getSize()
getSize in interface ProtocolFramepublic int getFromAddress()
getFromAddress in interface Basepublic Location getFromLocation()
getFromLocation in interface Base
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||