Modifier and Type | Class and Description |
---|---|
static class |
WindowedLimit.Builder |
Modifier and Type | Method and Description |
---|---|
int |
getLimit() |
static WindowedLimit.Builder |
newBuilder() |
void |
notifyOnChange(java.util.function.Consumer<java.lang.Integer> consumer)
Register a callback to receive notification whenever the limit is updated to a new value
|
void |
onSample(long startTime,
long rtt,
int inflight,
boolean didDrop)
Update the limiter with a sample
|
public static WindowedLimit.Builder newBuilder()
public void notifyOnChange(java.util.function.Consumer<java.lang.Integer> consumer)
Limit
notifyOnChange
in interface Limit
public void onSample(long startTime, long rtt, int inflight, boolean didDrop)
Limit