text-io icon indicating copy to clipboard operation
text-io copied to clipboard

How to change the prompt for a EnumInputReader?

Open fe-sak opened this issue 1 year ago • 0 comments

  private static Operacao escolherUmaOperacao() {
      return IO.getTextIO().newEnumInputReader(Operacao.class)
              .withInvalidIndexErrorMessagesProvider((s, s1, i, i1) ->
                      Collections.singletonList("Opção inválida. Digite um número de " + i + " até " + i1))
              .withValueFormatter(Operacao::getNome)
              .read("Escolha uma operação: ");
  }

I'd like to change this text right here: image

I've tried accessing the method printPrompt which is inherited from org.beryx.textio.InputReader but it cannot be accessed.

3.4.1 version is installed

fe-sak avatar Jun 26 '24 00:06 fe-sak