|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Object
|
+--SSF.OS.ProtocolSession
|
+--gov.nist.antd.merlin.util.AbstractAddDropConfigurator
|
+--gov.nist.antd.merlin.util.AutoConfigCtrl
|
+--gov.nist.antd.merlin.protocol.discovery.OptNeighbour
This class implements a neighbour discovery. This protocol extends the DML setting of the class AutoConfigCtrl.class and adds the following DML attribute to the setup:
ProtocolSession[ ... DEBUG
# Enables debug information for this protocol in each # node it is installed in. debug # Enables debug information for this protocol only in # this node. initTime # The time the protocol needs to initialize before it # starts the discovery process. The default time value # is 0.01 seconds. ] This class was developed at the National Institute of Standards and Technology by employees of the Federal Government in the course of their official duties. Pursuant to title 17 Section 105 of the United States Code this software is not subject to copyright protection and is in the public domain. NIST assumes no responsibility whatsoever for its use by other parties, and makes no guarantees, expressed or implied, about its quality, reliability, or any other characteristic.
We would appreciate acknowledgement if the software is used.
NIST ALLOWS FREE USE OF THIS SOFTWARE IN ITS "AS IS" CONDITION AND DISCLAIM ANY LIABILITY OF ANY KIND FOR ANY DAMAGES WHATSOEVER RESULTING FROM THE USE OF THIS SOFTWARE.
VERSION CONTROL
-----------------------------------------------------------------------------
Name - YYYY/MM/DD - VERSION - ACTION
rouil - 2001/10/05 - 1.0 - Source created.
rouil - 2002/01/31 - 1.1 - Changed class name.
rouil - 2002/09/25 - 1.2 - Changed ID to NHI to identify node.
rouil - 2002/10/01 - 1.3 - Set the delay before sending messages to
0.1s.
borchert - 2002/12/01 - 1.4 - Added configurable initialization time.
- Added configurable debug mode.
- Added failure handling and error reports
by unseccesful execution of methods.
- Added method void debug(String).
- Added method void printTable().
borchert - 2002/12/11 - Set timestamp for new created OFH.
- Added method getInitTime().
- Added method get getTable().
| Field Summary | |
private boolean |
debug
Indicates if this instance produces debug information. |
static boolean |
DEBUG
Indicates if each instance of this protocol produces debug information. |
private double |
initTime
Initialisation time in seconds. |
java.util.Vector |
messages
The vector that contains the message forwarded. |
static java.lang.String |
SESSION_NAME
The name (oxcswitch) of this protocolsession in the network. |
NeighbourTable |
table
The neighbor table |
| Fields inherited from class gov.nist.antd.merlin.util.AbstractAddDropConfigurator |
addLambdaIDs, dropLambdaIDs, manuallyConfigured |
| Fields inherited from class SSF.OS.ProtocolSession |
name, use |
| Constructor Summary | |
OptNeighbour()
Default constructor. |
|
| Method Summary | |
void |
addIDRESP(OpticalFrameHeader message)
Add an entry in the neighbours table. |
void |
config(com.renesys.raceway.DML.Configuration cfg)
Configuration |
protected void |
debug(java.lang.String text)
prints the given text to the output screen when debug is enabled. |
void |
forwardIDRESP(OpticalFrameHeader message)
Forward an IDRESP to all neighbours. |
double |
getInitTime()
Returns the initialization time. |
java.lang.String |
getTable()
Returns the neighbour table as String. |
void |
init()
Initialization routine, called by the ProtocolGraph after instantiation. |
boolean |
isInVector(NeighbourHeader message)
Check if the message is in the vector of messages |
void |
printTable()
Prints the internal forwarding table. |
boolean |
push(ProtocolMessage message,
ProtocolSession fromSession)
Push method to send and receive messages. |
void |
sendIDRESP(OpticalFrameHeader inMessage)
Send an IDRESP to all neighbours. |
void |
sendIDSIG()
Neighbour discovery after the init or after a node is recovered. |
| Methods inherited from class gov.nist.antd.merlin.util.AutoConfigCtrl |
|
| Methods inherited from class gov.nist.antd.merlin.util.AbstractAddDropConfigurator |
configAddDrop, getAddLambdaIDs, getDropLambdaIDs, isManuallyConfigured, toDML |
| Methods inherited from class SSF.OS.ProtocolSession |
close, closed, debugIdentifier, inGraph, open, opened, pushAfterDelay, pushAfterDelayFailed, setGraph, version |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
public static final java.lang.String SESSION_NAME
public static boolean DEBUG
private boolean debug
private double initTime
public NeighbourTable table
public java.util.Vector messages
| Constructor Detail |
public OptNeighbour()
| Method Detail |
public void config(com.renesys.raceway.DML.Configuration cfg)
throws com.renesys.raceway.DML.configException
config in interface com.renesys.raceway.DML.Configurableconfig in class AbstractAddDropConfiguratorcfg - The DML configuration
if - a configuration error occurs
com.renesys.raceway.DML.configException
public void init()
throws ProtocolException
init in class AutoConfigCtrlProtocolException - if an error occured.
public boolean push(ProtocolMessage message,
ProtocolSession fromSession)
throws ProtocolException
push in class ProtocolSessionmessage - The message received.fromSession - The protocol session which sent the message.
ProtocolException - If a protocol session exception occurs.public void sendIDSIG()
public void sendIDRESP(OpticalFrameHeader inMessage)
inMessage - The Optical Frameheader that contains the received IDSIG
message.public void addIDRESP(OpticalFrameHeader message)
message - The IDRESP receivedpublic void forwardIDRESP(OpticalFrameHeader message)
message - The IDSIG receivedpublic boolean isInVector(NeighbourHeader message)
message - The message to test if already treated.
protected void debug(java.lang.String text)
text - The text that has to be printed out.public void printTable()
public double getInitTime()
public java.lang.String getTable()
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||