public static final class LinearTracker.Builder
extends java.lang.Object
LinearTracker object.| Constructor and Description |
|---|
Builder() |
| Modifier and Type | Method and Description |
|---|---|
LinearTracker |
build()
Builds a
LinearTracker block. |
LinearTracker.Builder |
optMaxUpdates(int maxUpdates)
Sets the maximum number of updates after which the value should remain constant.
|
LinearTracker.Builder |
optMaxValue(float max)
Sets the maximum value for a positive slope.
|
LinearTracker.Builder |
optMinValue(float min)
Sets the minimum value for a negative slope.
|
LinearTracker.Builder |
optSlope(float slope)
Sets the value of the linear slope.
|
LinearTracker.Builder |
setBaseValue(float baseValue)
Sets the initial value after no steps.
|
public LinearTracker.Builder setBaseValue(float baseValue)
baseValue - the initial valueBuilderpublic LinearTracker.Builder optSlope(float slope)
Use a positive number for an increasing value and negative for decreasing.
slope - the value of the linear slopeBuilderpublic LinearTracker.Builder optMaxValue(float max)
This is equivalent to the max updates. Only one can be set.
max - the max valueBuilderpublic LinearTracker.Builder optMinValue(float min)
This is equivalent to the max updates. Only one can be set.
min - the minimum valueBuilderpublic LinearTracker.Builder optMaxUpdates(int maxUpdates)
maxUpdates - the maximum number of updates after which the value should remain
constantBuilderpublic LinearTracker build()
LinearTracker block.LinearTracker block