|
||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--Bridge
Model of a network bridge.
Constructor Summary | |
Bridge(int numPorts)
Constructor for objects of class Bridge |
Method Summary | |
static void |
allTick()
invoke the tick() method on each Bridge |
void |
connect(int portNumber,
Port peer)
connects a specified port number of this Bridge to another Port |
void |
disconnect(int portNumber)
disconnects a specified port number of this Bridge |
int |
getBridgeNumber()
returns a unique identifying number for the Bridge |
Port |
getPort(int portNum)
returns a specified port of the Bridge |
void |
tick()
do any housekeeping that needs doing each time interval |
Methods inherited from class java.lang.Object |
|
Constructor Detail |
public Bridge(int numPorts)
numPorts
- how many Ports the Bridge should haveMethod Detail |
public static void allTick()
public void connect(int portNumber, Port peer)
portNumber
- specifies which port of this Bridgepeer
- specifies the other Port to connect topublic void disconnect(int portNumber)
portNumber
- specifies which port of this Bridgepublic int getBridgeNumber()
public Port getPort(int portNum)
portNum
- specifies which portpublic void tick()
|
||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |