Package org.kendar.cli
Class CommandOption
java.lang.Object
org.kendar.cli.CommandOption
- All Implemented Interfaces:
CommandItem
-
Method Summary
Modifier and TypeMethodDescriptionbooleanbooleanbooleanbooleanbooleanbooleanbooleanbooleanstatic CommandOptionvoidparseInternal(List<MainArg> mainArgs) voidvoidsetParent(CommandItem parent) voidvoidsetValues(String value, CommandOptions subChoice) voidtoString()withCallback(Consumer<String> callback) withCommandOptions(CommandOption... subOptionsList) withMultiCallback(Consumer<List<String>> callback) withSubChoices(CommandOptions... subChoices) withSubChoicesDescription(String subChoicesDescription)
-
Method Details
-
of
-
asMultiple
-
isPresent
public boolean isPresent() -
isMultipleSubChoices
public boolean isMultipleSubChoices() -
getSubChoicesValues
-
hasSubChoices
public boolean hasSubChoices() -
toString
-
getShortCommand
-
getDescription
-
isHasParameter
public boolean isHasParameter() -
isMandatoryParameter
public boolean isMandatoryParameter() -
getLongCommand
-
getSubChoices
-
withParameter
-
withMandatoryParameter
-
withLong
-
withSubChoices
-
getLongShortCommandsChild
-
getLongShortCommands
-
getValues
-
setValues
-
withMultipleSubChoices
-
setValues
-
setPresent
public void setPresent() -
hasOption
-
getOptionValues
-
withCallback
-
withMultiCallback
-
getSubChoicesDescription
-
withSubChoicesDescription
-
getCommandOption
-
withCommandOptions
-
hasSubOptions
public boolean hasSubOptions() -
parseInternal
-
getCommandOptions
- Specified by:
getCommandOptionsin interfaceCommandItem
-
printHelp
-
getParent
- Specified by:
getParentin interfaceCommandItem
-
setParent
- Specified by:
setParentin interfaceCommandItem
-
isMultiple
public boolean isMultiple()
-