|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Object | +--gov.nist.antd.optical.Lambda
The lambda used in a fiber.
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.
| Field Summary | |
private boolean |
available
Indicates if the Lambda is available. |
private double |
bandwidth
This value represents the bandwidth of this lambda. |
private boolean |
control
Indicates if this lambda is used for the control plane. |
static double |
ERR
Constante value for the precision in computing the wavelength. |
private boolean |
failure
Indicates a failure of the Lambda. |
private Fiber |
fiber
The fiber the lambda is asigned to. |
private int |
id
The id of the lambda. |
protected boolean |
inConfiguration
Indicator if the class is in the configuration mode (true). |
private Lambda |
pair
The pair lambda assiociated to this lambda. |
private boolean |
protection
Indicates if this Lambda is used as a protection for an other Lambda. |
private int |
protectionMode
The mode of Protection ProtectionMode.NEVER, ProtectionMode.ONLY, or ProtectionMode.SHARED |
private boolean |
reserved
Indicates if the Lambda is already reserved for later use. |
private double |
snr
This attribute contains the signal to noise ratio. |
private double |
wavelength
The wavelength. |
| Constructor Summary | |
Lambda(Fiber fiber)
Constructs a lambda. |
|
Lambda(Fiber fiber,
int id)
Constructs a lambda. |
|
| Method Summary | |
boolean |
checkData()
This method checks the data of the object. |
boolean |
compareCharacteristics(Lambda otherLambda)
Compare the attribute wavelength of two lambda's. |
void |
config(com.renesys.raceway.DML.Configuration cfg)
Configure the Fiber. |
protected void |
configureBandwidth(java.lang.String value)
configures the bandwidth from the DML |
private void |
configureControl(java.lang.String value)
Configures the control status. |
private void |
configureID(java.lang.String value)
Configures the id. |
protected void |
configurePair(java.lang.String value)
configures the pairing. |
protected void |
configureWaveLength(java.lang.String value)
Configures the wavelength. |
double |
getBandwidth()
Get the bandwidth of this lambda. |
Fiber |
getFiber()
Get the Fiber this lambda is assigned. |
int |
getID()
Get the id of this lambda. |
Lambda |
getPair()
Get the pair lambda attached to this lambda. |
int |
getProtectionMode()
Returns the protection mode of the lambda. |
double |
getSNR()
Get the value of the signal to noise ratio. |
double |
getWavelength()
Get the value of the wavelength. |
boolean |
isAvailable()
Informs if this lambda is used. |
boolean |
isControl()
Indicates if the lambdas is used for control. |
boolean |
isDepthFailure()
Informs if lambda or one of the related components (fiber, link, and ONICS) are failed. |
boolean |
isFailure()
Informs is this lambda component is failed. |
boolean |
isProtection()
Informs if this lambda is used as a protection lambda. |
boolean |
isReserved()
Informs if the lambda is already reserved. |
private void |
notifyONIC()
Notifies the ONIC for a failed Lambda. |
protected void |
sendMessage(short messageType)
Checks if the Eventhandler has receivers and this object is not in the configuration mode, this message will send the specified event. |
void |
setAvailable(boolean available)
Set the attribute available. |
void |
setBandwidth(double bandwidth)
Define the bandwidth for this lambda. |
void |
setControl(boolean control)
Set the attribute control. |
void |
setFailure(boolean newValue)
Set the attribute failure. |
protected void |
setFiber(Fiber newFiber)
Set the fiber of this Lambda. |
void |
setID(int newID)
Set the id for this lambda. |
void |
setPair(Lambda pair)
Create a relation between two lambdas. |
void |
setProtection(boolean protection)
Set the attribute protection. |
void |
setProtectionMode(int newMode)
Set the protection mode. |
void |
setReserved(boolean reserved)
Set the attribute reserved. |
void |
setSNR(double newSnr)
Set the attribute signal to noise ratio. |
void |
setWavelength(double wavelength)
Set the wavelength value of this lambda in nm. |
java.lang.String |
toString()
Textual representation of the lambda. |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Field Detail |
public static double ERR
private boolean available
private boolean reserved
private boolean control
private boolean failure
private int id
private boolean protection
private int protectionMode
private double bandwidth
private double snr
private double wavelength
protected boolean inConfiguration
private Lambda pair
private Fiber fiber
| Constructor Detail |
public Lambda(Fiber fiber)
throws DataIntegrityException
fiber - The fiber that contains this lambda.
DataIntegrityException - The Lambda could not be created for the
link.
public Lambda(Fiber fiber,
int id)
throws DataIntegrityException
fiber - The fiber that contains this lambda.id - The id of the lambda. This id must be unique in the fiber.
DataIntegrityException - The Lambda could not be created for the
link.| Method Detail |
public boolean compareCharacteristics(Lambda otherLambda)
wavelength, protection, and signalType
otherLambda - The second lambda.
public Fiber getFiber()
public int getID()
getID in interface LambdaInterfacepublic Lambda getPair()
public double getBandwidth()
public double getSNR()
public double getWavelength()
public boolean isAvailable()
public boolean isReserved()
public boolean isControl()
public boolean isProtection()
public int getProtectionMode()
public void setAvailable(boolean available)
available - True if the lambda is not used.public void setReserved(boolean reserved)
reserved - True if the lambda is reserved.public void setControl(boolean control)
control - True if this lambda is used by control plane.
public void setID(int newID)
throws DuplicateIDException
newID - The new id.
DuplicateIDException - The ID is already used in the fiber.
public void setPair(Lambda pair)
throws DataIntegrityException
pair - The lambda attached to this one.
DataIntegrityException - If the dataintegrity is not given.public void setProtection(boolean protection)
protection - The new status.
public void setProtectionMode(int newMode)
throws IllegalDataException,
DataIntegrityException
newMode - the protection mode.
IllegalDataExcetion - The given mode is not known.
DataIntegrityException - The given mode and the protection value
is invalid (i.e. ProtectionMode.NEVER and
isProtection()==true.
IllegalDataExceptionpublic void setBandwidth(double bandwidth)
bandwidth - The new bandwidth.public void setSNR(double newSnr)
newSnr - The new value.
public void setWavelength(double wavelength)
throws IllegalDataException,
DataIntegrityException
wavelength - The value of the wavelength.
IllegalDataException
DataIntegrityExceptionpublic boolean isFailure()
isFailure in interface FailureInformationpublic boolean isDepthFailure()
public void setFailure(boolean newValue)
newValue - The new failure value.public java.lang.String toString()
toString in class java.lang.Object
protected void setFiber(Fiber newFiber)
throws DataIntegrityException
newFiber - The fiber the lambda is assigned to.
DataIntegrityException - will be thrown, if the data integrity
is not given anymore.
public boolean checkData()
throws DataIntegrityException
DataIntegrityException - This exception will be thrown only in
the case that stored data are damaging the data integrity.
public void config(com.renesys.raceway.DML.Configuration cfg)
throws com.renesys.raceway.DML.configException
cfg - The configuration object.
com.renesys.raceway.DML.configException - an Configuration Exception occured
private void configureID(java.lang.String value)
throws com.renesys.raceway.DML.configException,
DataIntegrityException
value - the id value.
com.renesys.raceway.DML.configException - an configException occured.
DataIntegrityException - an DataIntegrityException occured.
private void configureControl(java.lang.String value)
throws com.renesys.raceway.DML.configException,
DataIntegrityException
value - the control value.
com.renesys.raceway.DML.configException - an configException occured.
DataIntegrityException - an DataIntegrityException occured.
protected void configureWaveLength(java.lang.String value)
throws DataIntegrityException
value - the wavelength value.
DataIntegrityException - an DataIntegrityException occured.
protected void configurePair(java.lang.String value)
throws com.renesys.raceway.DML.configException,
DataIntegrityException
value - the pair value.
com.renesys.raceway.DML.configException - an configException occured.
DataIntegrityException - an DataIntegrityException occured.
protected void configureBandwidth(java.lang.String value)
throws IllegalDataException
value - the string representing the bandwidth from the DML
IllegalDataException - thrown if value is not a valid bandwidthprotected void sendMessage(short messageType)
messageType - the type of the message. The types are specified in the
class gov.nist.antd.optical.event.monitor.EventHandler.private void notifyONIC()
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||