public class RangeParser extends ConfigurationParser<SampleRange>
Constructor and Description |
---|
RangeParser() |
Modifier and Type | Method and Description |
---|---|
SampleRange |
parse(org.bukkit.configuration.ConfigurationSection input,
java.lang.String key)
Transforms a configuration object, represented by a key, into an object.
|
SampleRange |
parse(org.bukkit.configuration.ConfigurationSection input,
java.lang.String key,
SampleRange defaultValue)
Transform a configuration object, represented by a key, into a range.
|
SampleRange |
parseString(java.lang.String text,
SampleRange defaultValue) |
public SampleRange parse(org.bukkit.configuration.ConfigurationSection input, java.lang.String key) throws ParsingException
ConfigurationParser
parse
in class ConfigurationParser<SampleRange>
input
- - the configuration section in which the object is stored.key
- - the key of the configuration object.ParsingException
- An error occurred during the parsing.public SampleRange parse(org.bukkit.configuration.ConfigurationSection input, java.lang.String key, SampleRange defaultValue)
input
- - the configuration section in which the key to the object is stored.key
- - the key of the object.defaultValue
- - value to return if parsing failed.public SampleRange parseString(java.lang.String text, SampleRange defaultValue)