public class Throttle
extends java.lang.Object
Modifier and Type | Class and Description |
---|---|
static interface |
Throttle.ThroughputFunction |
Constructor and Description |
---|
Throttle(java.lang.String name,
Throttle.ThroughputFunction fun) |
Modifier and Type | Method and Description |
---|---|
void |
throttle(long currentBytes) |
void |
throttleDelta(long bytesDelta) |
java.lang.String |
toString() |
public Throttle(java.lang.String name, Throttle.ThroughputFunction fun)
public void throttle(long currentBytes)
currentBytes
- Bytes of throughput since the beginning of the task.public void throttleDelta(long bytesDelta)
bytesDelta
- Bytes of throughput since the last call to throttle*()public java.lang.String toString()
toString
in class java.lang.Object
Copyright © 2013 The Apache Software Foundation