public abstract class ParallelRunnable extends Object
Modifier | Constructor and Description |
---|---|
protected |
ParallelRunnable()
Subclass constructor.
|
Modifier and Type | Method and Description |
---|---|
abstract int |
getLength()
Get the length of the whole set to be run in parallel.
|
int |
getPreferredBatchSize()
Get the preferred batch size.
|
Runnable |
getRunnable(int startValue,
int length)
Get the Runnable object for the specified short stride.
|
Runnable |
getRunnable(long startValue,
long length)
Get the Runnable object for the specified long stride.
|
public abstract int getLength()
public Runnable getRunnable(int startValue, int length)
startValue
- The starting value for the stride.length
- The length of the stride.public Runnable getRunnable(long startValue, long length)
startValue
- The starting value for the stride.length
- The length of the stride.public int getPreferredBatchSize()