Annotation Type Option


  • @Documented
    @Retention(RUNTIME)
    @Target(FIELD)
    public @interface Option
    A command-line option.
    Since:
    2.5
    Author:
    Martin Desruisseaux
    • Optional Element Summary

      Optional Elements 
      Modifier and Type Optional Element Description
      String description
      A description of this option to be printed when the --help option is provided.
      boolean mandatory
      true if this option is mandatory.
      String name
      The argument name.
    • Element Detail

      • name

        String name
        The argument name. The default is the same name than the field.
        Returns:
        The argument name, or "" for the default.
        Default:
        ""
      • mandatory

        boolean mandatory
        true if this option is mandatory. Options are optional by default.
        Returns:
        Whatever this option is mandatory or optional.
        Default:
        false
      • description

        String description
        A description of this option to be printed when the --help option is provided.
        Returns:
        The description, or "" for none.
        Default:
        ""