Class AllowedEnumValuesRestriction
java.lang.Object
com.github.rvesse.airline.restrictions.AbstractCommonRestriction
com.github.rvesse.airline.restrictions.common.AbstractAllowedValuesRestriction
com.github.rvesse.airline.restrictions.common.AllowedEnumValuesRestriction
- All Implemented Interfaces:
HelpHint, ArgumentsRestriction, OptionRestriction
-
Field Summary
Fields inherited from class AbstractAllowedValuesRestriction
CASE_INSENSITIVE, CASE_SENSITIVE, caseInsensitive, rawValues -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprivate Collection<String> <T> voidpreValidate(ParseState<T> state, ArgumentsMetadata arguments, String value) Method that is called before Airline attempts to convert a string argument received into a strongly typed Java value<T> voidpreValidate(ParseState<T> state, OptionMetadata option, String value) Method that is called before Airline attempts to convert a string argument received into a strongly typed Java valueMethods inherited from class AbstractAllowedValuesRestriction
asObjects, getAllowedValues, getContentBlock, getFormat, getPreamble, numContentBlocksMethods inherited from class AbstractCommonRestriction
finalValidate, finalValidate, getArgumentTitle, getArgumentTitle, getOptionTitle, postValidate, postValidate
-
Constructor Details
-
AllowedEnumValuesRestriction
-
-
Method Details
-
getValues
-
preValidate
Description copied from interface:OptionRestrictionMethod that is called before Airline attempts to convert a string argument received into a strongly typed Java value- Specified by:
preValidatein interfaceOptionRestriction- Overrides:
preValidatein classAbstractCommonRestriction- Parameters:
state- Parser stateoption- Option meta-datavalue- String value
-
preValidate
Description copied from interface:ArgumentsRestrictionMethod that is called before Airline attempts to convert a string argument received into a strongly typed Java value- Specified by:
preValidatein interfaceArgumentsRestriction- Overrides:
preValidatein classAbstractCommonRestriction- Parameters:
state- Parser statearguments- Arguments meta-datavalue- String value
-