Class IntegerFlag<F extends NumberFlag<Integer,F>>
java.lang.Object
com.plotsquared.core.plot.flag.PlotFlag<N,F>
com.plotsquared.core.plot.flag.types.NumberFlag<Integer,F>
com.plotsquared.core.plot.flag.types.IntegerFlag<F>
- Direct Known Subclasses:
NonNegativeIntegerFlag
-
Field Summary
Fields inherited from class com.plotsquared.core.plot.flag.types.NumberFlag
maximum, minimum
-
Constructor Summary
ModifierConstructorDescriptionprotected
IntegerFlag
(int value, int minimum, int maximum, @NonNull Caption flagDescription) protected
IntegerFlag
(@NonNull Caption flagDescription) -
Method Summary
Modifier and TypeMethodDescriptionAn example of a string that would parse into a valid flag value.Merge this flag's value with another value and return an instance holding the merged value.parseNumber
(String input) Parse the raw string input to the number type.toString()
Returns a string representation of the flag instance, that when passed throughPlotFlag.parse(String)
will result in an equivalent instance of the flag.Methods inherited from class com.plotsquared.core.plot.flag.types.NumberFlag
parse
Methods inherited from class com.plotsquared.core.plot.flag.PlotFlag
canEqual, createFlagInstance, equals, flagOf, getFlagCategory, getFlagDescription, getFlagName, getName, getTabCompletions, getValue, hashCode, isValuedPermission
-
Constructor Details
-
Method Details
-
merge
Description copied from class:PlotFlag
Merge this flag's value with another value and return an instance holding the merged value. -
toString
Description copied from class:PlotFlag
Returns a string representation of the flag instance, that when passed throughPlotFlag.parse(String)
will result in an equivalent instance of the flag. -
getExample
Description copied from class:PlotFlag
An example of a string that would parse into a valid flag value.- Specified by:
getExample
in classPlotFlag<Integer,
F extends NumberFlag<Integer, F>> - Returns:
- An example flag value.
-
parseNumber
Description copied from class:NumberFlag
Parse the raw string input to the number type.- Specified by:
parseNumber
in classNumberFlag<Integer,
F extends NumberFlag<Integer, F>> - Parameters:
input
- the string to parse the number from.- Returns:
- the parsed number.
- Throws:
FlagParseException
- if the number couldn't be parsed.
-