Annotation Interface ShellMethod
Used to mark a method as invokable via Spring Shell.
-
Optional Element Summary
Modifier and TypeOptional ElementDescriptionThe command group which this command belongs to.Defines interaction mode for a command as a hint when command should be available.String[]
The name(s) by which this method can be invoked via Spring Shell.The prefix to use for assigning parameters by name.A description for the command. -
Field Summary
-
Field Details
-
INHERITED
The default value forgroup()
, meaning that the group will be inherited from the explicit value set on the containing element (class then package) or ultimately inferred.- See Also:
-
-
Element Details
-
key
String[] keyThe name(s) by which this method can be invoked via Spring Shell. If not specified, the actual method name will be used (turning camelCase humps into "-").- Returns:
- explicit command name(s) to use
- Default:
- {}
-
value
String valueA description for the command. Should not contain any formatting (e.g. html) characters and would typically start with a capital letter and end with a dot.- Returns:
- short description of what the command does
- Default:
- ""
-
prefix
String prefixThe prefix to use for assigning parameters by name.- Returns:
- prefix to use when not specified as part of the parameter annotation
- Default:
- "--"
-
group
String groupThe command group which this command belongs to. The command group is used when printing a list of commands to group related commands. By default, group is first looked up from owning class then package, and if not explicitly set, is inferred from class name.- Returns:
- name of the command group
- Default:
- ""
-
interactionMode
InteractionMode interactionModeDefines interaction mode for a command as a hint when command should be available. For example presense of some commands doesn't make sense if shell is running as non-interactive mode and vice versa. Defaults toInteractionMode.ALL
- Returns:
- interaction mode
- Default:
- ALL
-