| java.lang.Object seda.sandStorm.core.MulticlassRateLimitingPredicate
MulticlassRateLimitingPredicate | public class MulticlassRateLimitingPredicate implements EnqueuePredicateIF(Code) | | This enqueue predicate implements multiclass input rate policing.
|
Constructor Summary | |
public | MulticlassRateLimitingPredicate(SinkIF sink, int numclasses, double targetRate, int depth) Create a new RateLimitingPredicate for the given sink,
targetRate, and token bucket depth. |
Method Summary | |
public boolean | accept(QueueElementIF qel) Returns true if the given element can be accepted into the queue. | public int | getBucketSize(int theclass) Return the number of tokens currently in the bucket. | public int | getDepth(int theclass) Return the current depth. | public double | getTargetRate(int theclass) Return the current rate limit. | public void | setDepth(int theclass, int depth) Set the bucket depth. | public void | setTargetRate(int theclass, double targetRate) Set the rate limit. |
MulticlassRateLimitingPredicate | public MulticlassRateLimitingPredicate(SinkIF sink, int numclasses, double targetRate, int depth)(Code) | | Create a new RateLimitingPredicate for the given sink,
targetRate, and token bucket depth. A rate of -1.0 indicates no rate limit.
|
accept | public boolean accept(QueueElementIF qel)(Code) | | Returns true if the given element can be accepted into the queue.
|
getBucketSize | public int getBucketSize(int theclass)(Code) | | Return the number of tokens currently in the bucket.
|
getDepth | public int getDepth(int theclass)(Code) | | Return the current depth.
|
getTargetRate | public double getTargetRate(int theclass)(Code) | | Return the current rate limit.
|
setDepth | public void setDepth(int theclass, int depth)(Code) | | Set the bucket depth.
|
setTargetRate | public void setTargetRate(int theclass, double targetRate)(Code) | | Set the rate limit. A limit of -1.0 indicates no rate limit.
|
|
|