|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectedu.colorado.cs.ns2.sim.Link
public class Link
This class implements the NS2 notion of a Link. A Link provides a means by which to physically connect two nodes. Links are defined by the nodes that they connect, a queuing model, a bandwidth, latency, and optional queue arguments.
Field Summary | |
---|---|
private java.lang.String |
args
The queue's arguments. |
private double |
bandwidth
The bandwidth (Mb/s). |
private ConnectionList |
connectionList
A list of connections on this link. |
private ExtendedLinkProperties |
elp
The extended link properties for this link. |
private double |
latency
The latency (ms). |
private NsNode |
node1
The NS2 node at endpoint 1. |
private NsNode |
node2
The NS2 node at endpoint 2. |
private java.lang.String |
queueType
The queuing model. |
private static long |
serialVersionUID
Generated serial version UID. |
Constructor Summary | |
---|---|
Link()
Default constructor. |
|
Link(NsNode n1,
NsNode n2,
double bw,
double lat,
java.lang.String qType,
java.lang.String args)
Six-argument constructor. |
Method Summary | |
---|---|
java.lang.String |
getArgs()
Returns the queue's arguments. |
double |
getBandwidth()
Returns the link's bandwdith. |
ConnectionList |
getConnections()
Returns the connection list for this link. |
ExtendedLinkProperties |
getExtendedLinkProperties()
Returns the extended link properties for this link. |
double |
getLatency()
Returns the link's latency value. |
NsNode |
getNode1()
Returns the node at endpoint 1. |
NsNode |
getNode2()
Returns the node at endpoint 2. |
java.lang.String |
getQueueType()
Returns the queue type. |
void |
setArgs(java.lang.String args)
Sets the queue's arguments. |
void |
setBandwidth(double bandwidth)
Sets the link's bandwidth. |
void |
setConnections(ConnectionList c)
Set the connection list for this link. |
void |
setExtendedLinkProperties(ExtendedLinkProperties elp)
Sets the extended properties for this link. |
void |
setLatency(double latency)
Sets the link's latency value. |
void |
setNode1(NsNode node1)
Sets the node at endpoint 1. |
void |
setNode2(NsNode node2)
Sets the node at endpoint 2. |
void |
setQueueType(java.lang.String queueType)
Sets the queue type. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
private static final long serialVersionUID
private NsNode node1
private NsNode node2
private java.lang.String queueType
private double bandwidth
private double latency
private java.lang.String args
private ConnectionList connectionList
private ExtendedLinkProperties elp
Constructor Detail |
---|
public Link()
public Link(NsNode n1, NsNode n2, double bw, double lat, java.lang.String qType, java.lang.String args)
n1
- The node at endpoint 1.n2
- The node at endpoint 2.bw
- The link's bandwidth.lat
- The link's latency.qType
- The queuing model.args
- The queue's arguments.Method Detail |
---|
public void setConnections(ConnectionList c)
c
- public ConnectionList getConnections()
public java.lang.String getArgs()
public void setArgs(java.lang.String args)
args
- The queue's arguments.public double getBandwidth()
public void setBandwidth(double bandwidth)
bandwidth
- The link's new bandwidth value.public double getLatency()
public void setLatency(double latency)
latency
- A new latency value.public NsNode getNode1()
public void setNode1(NsNode node1)
node1
- Sets the node at endpoint 1.public NsNode getNode2()
public void setNode2(NsNode node2)
node2
- A new node at endpoint 2.public java.lang.String getQueueType()
public void setQueueType(java.lang.String queueType)
queueType
- A new queue type.public ExtendedLinkProperties getExtendedLinkProperties()
public void setExtendedLinkProperties(ExtendedLinkProperties elp)
elp
- New extended properties for this link.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |