Interface CommandElement.Flag
- All Superinterfaces:
CommandElement
- Enclosing interface:
- CommandElement
Represents a command flag, usually an optional named argument.
-
Nested Class Summary
Nested ClassesModifier and TypeInterfaceDescriptionstatic enumDetermines how a flag is parsed on a high level.static enumDetermines how many times a flag can be used.Nested classes/interfaces inherited from interface com.xpdustry.distributor.api.command.CommandElement
CommandElement.Argument, CommandElement.Flag -
Method Summary
Modifier and TypeMethodDescriptiongetKind()Returns the kind of this flag.getMode()Returns the mode of this flag.static CommandElement.Flagof(String name, DescriptionFacade description, Set<String> aliases, CommandElement.Flag.Kind kind, CommandElement.Flag.Mode mode) Creates a new command flag.Methods inherited from interface com.xpdustry.distributor.api.command.CommandElement
getAliases, getDescription, getName
-
Method Details
-
of
static CommandElement.Flag of(String name, DescriptionFacade description, Set<String> aliases, CommandElement.Flag.Kind kind, CommandElement.Flag.Mode mode) Creates a new command flag.- Parameters:
name- the name of the flagdescription- the description of the flagaliases- the aliases of the flagkind- the kind of the flagmode- the mode of the flag- Returns:
- the created flag
-
getKind
CommandElement.Flag.Kind getKind()Returns the kind of this flag. -
getMode
CommandElement.Flag.Mode getMode()Returns the mode of this flag.
-