public interface DatalinkLayer
An implementation of the datalink layer must implement this
interface, which itself extends StackLayer
.
StackLayer
Method Summary | |
---|---|
void |
init(int nodeNum,
NetworkLayer networkLayer,
PhysicalLayer physicalLayer)
Initialization passes in the layers above and below. |
void |
receivePacket(DatalinkPacket packet)
This is called by the layer below, in this case, the simulator. |
void |
sendPacket(DatalinkPacket packet)
This is called by the layer above. |
Methods inherited from interface edu.gwu.simplenetsim.StackLayer |
---|
timerBeep |
Method Detail |
---|
void init(int nodeNum, NetworkLayer networkLayer, PhysicalLayer physicalLayer)
nodeNum
- an int
valuenetworkLayer
- a NetworkLayer
valuephysicalLayer
- a PhysicalLayer
valuevoid sendPacket(DatalinkPacket packet)
packet
- a DatalinkPacket
valuevoid receivePacket(DatalinkPacket packet)
packet
- a DatalinkPacket
value