Interface Option.Flag

All Superinterfaces:
Option
All Known Implementing Classes:
VerboseOption
Enclosing interface:
Option

public static interface Option.Flag extends Option
A boolean option that is either not present or true or false.
  • Nested Class Summary

    Nested classes/interfaces inherited from interface com.github.sormuras.bach.command.Option

    Option.Flag, Option.Value<T>, Option.Values<T>
  • Method Summary

    Modifier and Type
    Method
    Description
    default boolean
    Returns true iff the backing value is present and true, else false.
    Returns the state of this flag.
  • Method Details

    • value

      Returns the state of this flag.
      Returns:
      the state of this flag
    • isTrue

      default boolean isTrue()
      Returns true iff the backing value is present and true, else false.
      Returns:
      true iff the backing value is present and true, else false