|
DRCL J-Sim API | ||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
java.lang.Objectdrcl.DrclObj
drcl.comp.queue.QLogic
drcl.inet.core.queue.RED
The Random Early Detection (RED) queue logic.
| Field Summary | |
static java.lang.String |
EVENT_AVG_QSIZE
Name of the average queue size change event. |
static boolean |
RED_EWMA
|
static boolean |
RED_HOLT_WINTERS
|
| Fields inherited from class drcl.comp.queue.QLogic |
capacity, EVENT_QSIZE, qlen, qsize |
| Constructor Summary | |
RED()
|
|
RED(Component host_,
java.lang.String avgpid_)
|
|
RED(Component host_,
java.lang.String avgpid_,
java.lang.String qpid_)
|
|
| Method Summary | |
java.lang.String |
adviceOn(java.lang.Object obj_,
int psize_)
Returns advice (in String) on whether or not to drop the packet. |
void |
dequeueHandler(java.lang.Object obj_,
int psize_)
Handles the event of dequeuing the object of the given size. |
void |
duplicate(java.lang.Object source_)
Duplicates the content of the source object to this object. |
void |
enqueueHandler(java.lang.Object obj_,
int psize_)
Handles the event of enqueuing the object of the given size. |
double |
getBandwidth()
|
double |
getInvProb()
|
double |
getMaxThresh()
|
int |
getMeanPacketSize()
|
double |
getMinThresh()
|
long |
getSeed()
|
double |
getWeight()
|
java.lang.String |
info(java.lang.String prefix_)
Prints the content (states) of this queue management instance. |
boolean |
isMarkEnabled()
|
boolean |
isWait()
|
void |
reset()
Resets this object to the initial state. |
void |
setAvgQSizePort(java.lang.String avgqspid_)
|
void |
setBandwidth(double bw_)
|
void |
setInvProb(double value)
|
void |
setMarkEnabled(boolean enabled_)
If enabled, RED marks the congestion bit of, instead of advising to drop, packets. |
void |
setMaxThresh(double max)
|
void |
setMeanPacketSize(int size_)
|
void |
setMinThresh(double min)
|
void |
setRandomNumberGenerator(RandomNumberGenerator ug_)
|
void |
setRandomNumberGenerator(RandomNumberGenerator ug_,
long seed_)
|
void |
setREDParam(int psize_,
double bw_,
double th_max_,
double th_min_,
double inv_max_p_,
double qw_)
Sets up all RED parameters. |
void |
setSeed(long seed_)
|
void |
setWait(boolean enabled_)
|
void |
setWeight(double weight)
|
| Methods inherited from class drcl.comp.queue.QLogic |
dropHandler, getCapacity, getCurrentQLength, getCurrentQSize, getHost, info, isEmpty, isFull, set, setCapacity, setHost, setQSizePort |
| Methods inherited from class drcl.DrclObj |
clone, toString |
| Methods inherited from class java.lang.Object |
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Field Detail |
public static boolean RED_EWMA
public static boolean RED_HOLT_WINTERS
public static final java.lang.String EVENT_AVG_QSIZE
| Constructor Detail |
public RED()
public RED(Component host_,
java.lang.String avgpid_)
avgpid_ - ID of the average queue size change event port that will be created at
the host component.
public RED(Component host_,
java.lang.String avgpid_,
java.lang.String qpid_)
avgpid_ - ID of the average queue size change event port that will be created at
the host component.qpid_ - ID of the instant queue size change event port that will be created at
the host component.| Method Detail |
public void reset()
QLogicsuper.reset() when
overriding this method.
reset in class QLogicpublic void duplicate(java.lang.Object source_)
QLogicsource_.
Subclasses must call super.duplicate() when
overriding this method.
duplicate in interface ObjectDuplicableduplicate in class QLogicpublic java.lang.String info(java.lang.String prefix_)
QLogic
info in class QLogicprefix_ - prefix of each line in the printout.
public java.lang.String adviceOn(java.lang.Object obj_,
int psize_)
adviceOn in class QLogic
public void enqueueHandler(java.lang.Object obj_,
int psize_)
QLogic
enqueueHandler in class QLogic
public void dequeueHandler(java.lang.Object obj_,
int psize_)
QLogic
dequeueHandler in class QLogicpublic void setWait(boolean enabled_)
public boolean isWait()
public void setMarkEnabled(boolean enabled_)
public boolean isMarkEnabled()
public void setMeanPacketSize(int size_)
public int getMeanPacketSize()
public void setMaxThresh(double max)
public double getMaxThresh()
public void setMinThresh(double min)
public double getMinThresh()
public void setInvProb(double value)
public double getInvProb()
public void setWeight(double weight)
public double getWeight()
public double getBandwidth()
public void setBandwidth(double bw_)
public void setREDParam(int psize_,
double bw_,
double th_max_,
double th_min_,
double inv_max_p_,
double qw_)
public void setSeed(long seed_)
public long getSeed()
public void setRandomNumberGenerator(RandomNumberGenerator ug_)
public void setRandomNumberGenerator(RandomNumberGenerator ug_,
long seed_)
public void setAvgQSizePort(java.lang.String avgqspid_)
|
DRCL J-Sim API | ||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||