|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.aelitis.azureus.core.networkmanager.impl.ByteBucketST
public class ByteBucketST
Constructor Summary | |
---|---|
ByteBucketST(int rate_bytes_per_sec)
Create a new byte-bucket with the given byte fill (guaranteed) rate. |
Method Summary | |
---|---|
int |
getAvailableByteCount()
Get the number of bytes currently available for use. |
int |
getBurstRate()
Get the configured burst rate. |
int |
getRate()
Get the configured fill rate. |
void |
setBytesUsed(int bytes_used)
Update the bucket with the number of bytes just used. |
void |
setFrozen(boolean f)
|
void |
setRate(int rate_bytes_per_sec)
Set the current fill/guaranteed rate, with a burst rate of 1.2X the given rate. |
void |
setRate(int rate_bytes_per_sec,
int burst_rate)
Set the current fill/guaranteed rate, along with the burst rate. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public ByteBucketST(int rate_bytes_per_sec)
rate_bytes_per_sec
- fill rateMethod Detail |
---|
public int getAvailableByteCount()
getAvailableByteCount
in interface ByteBucket
public void setBytesUsed(int bytes_used)
setBytesUsed
in interface ByteBucket
bytes_used
- public int getRate()
getRate
in interface ByteBucket
public int getBurstRate()
public void setRate(int rate_bytes_per_sec)
setRate
in interface ByteBucket
rate_bytes_per_sec
- public void setRate(int rate_bytes_per_sec, int burst_rate)
rate_bytes_per_sec
- burst_rate
- public void setFrozen(boolean f)
setFrozen
in interface ByteBucket
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |