Class CliBuilder<C>
java.lang.Object
com.github.rvesse.airline.builder.AbstractBuilder<Cli<C>>
com.github.rvesse.airline.builder.CliBuilder<C>
- Type Parameters:
C- Command type
Builder for CLIs
-
Field Summary
FieldsModifier and TypeFieldDescriptionprotected final Map<String, HelpSection> protected Stringprotected final Map<String, GroupBuilder<C>> protected final Stringprotected Stringprotected final ParserBuilder<C> protected final List<GlobalRestriction> -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbuild()Builds the typewithCommand(Class<? extends C> command) withCommands(Class<? extends C> command, Class<? extends C>... moreCommands) withCommands(Iterable<Class<? extends C>> commands) withDefaultCommand(Class<? extends C> defaultCommand) withDescription(String description) withHelpSection(HelpSection section) withRestriction(GlobalRestriction restriction) withRestrictions(GlobalRestriction... restrictions) Methods inherited from class AbstractBuilder
checkNotBlank, checkNotEmpty, checkNotNull
-
Field Details
-
name
-
description
-
optionSeparators
-
defaultCommand
-
defaultCommandGroupCommands
-
groups
-
restrictions
-
parserBuilder
-
baseHelpSections
-
-
Constructor Details
-
CliBuilder
-
-
Method Details
-
withDescription
-
withDefaultCommand
-
withCommand
-
withCommands
-
withCommands
-
withGroup
-
getGroup
-
withRestriction
-
withRestrictions
-
withNoRestrictions
-
withDefaultRestrictions
-
withOnlyDefaultRestrictions
-
withParser
-
withHelpSection
-
build
Description copied from class:AbstractBuilderBuilds the type- Specified by:
buildin classAbstractBuilder<Cli<C>>- Returns:
- Type instance
-