Annotation Interface Suggest


@Target(PARAMETER) @Retention(RUNTIME) public @interface Suggest
Annotation to provide autocomplete suggestions for command arguments.
  • Required Element Summary

    Required Elements
    Modifier and Type
    Required Element
    Description
    Sources of suggestions for autocomplete.
  • Optional Element Summary

    Optional Elements
    Modifier and Type
    Optional Element
    Description
    Names of arguments whose parsed values should be available when generating suggestions.
    boolean
    Whether permission is required to display suggestions.
  • Element Details

    • value

      String[] value
      Sources of suggestions for autocomplete. Can contain method names, special arguments, static lists, or combined sources.
      Returns:
      the suggestion sources
    • permission

      boolean permission
      Whether permission is required to display suggestions. If true, permission will be checked for each suggestion.
      Returns:
      true if permission is required for suggestions
      Default:
      false
    • contextArgs

      String[] contextArgs
      Names of arguments whose parsed values should be available when generating suggestions. These arguments must appear before the current argument in the command signature.
      Returns:
      array of argument names
      Default:
      {}