public static class ConfigDef.Range extends Object implements ConfigDef.Validator
Modifier and Type | Method and Description |
---|---|
static ConfigDef.Range |
atLeast(Number min)
A numeric range that checks only the lower bound
|
static ConfigDef.Range |
atMost(Number max)
A numeric range that checks only the upper (inclusive) bound
|
static ConfigDef.Range |
between(Number min,
Number max)
A numeric range that checks both the upper (inclusive) and lower bound
|
void |
ensureValid(String name,
Object o)
Perform single configuration validation.
|
String |
toString() |
public static ConfigDef.Range atLeast(Number min)
min
- The minimum acceptable valuepublic static ConfigDef.Range atMost(Number max)
max
- The minimum acceptable valuepublic static ConfigDef.Range between(Number min, Number max)
public void ensureValid(String name, Object o)
ConfigDef.Validator
ensureValid
in interface ConfigDef.Validator
name
- The name of the configurationo
- The value of the configuration