Class DefaultInputPrompt

java.lang.Object
org.jline.prompt.impl.DefaultPrompt
org.jline.prompt.impl.DefaultInputPrompt
All Implemented Interfaces:
InputPrompt, Prompt
Direct Known Subclasses:
DefaultNumberPrompt, DefaultPasswordPrompt

public class DefaultInputPrompt extends DefaultPrompt implements InputPrompt
Default implementation of InputPrompt interface. This is now the native implementation that doesn't depend on console-ui.
  • Constructor Details

  • Method Details

    • getDefaultValue

      public String getDefaultValue()
      Description copied from interface: InputPrompt
      Get the default value.
      Specified by:
      getDefaultValue in interface InputPrompt
      Returns:
      the default value
    • getMask

      public Character getMask()
      Description copied from interface: InputPrompt
      Get the mask character for the input.
      Specified by:
      getMask in interface InputPrompt
      Returns:
      the mask character, or null if masking is disabled
    • getCompleter

      public org.jline.reader.Completer getCompleter()
      Description copied from interface: InputPrompt
      Get the completer.
      Specified by:
      getCompleter in interface InputPrompt
      Returns:
      the completer
    • getLineReader

      public org.jline.reader.LineReader getLineReader()
      Description copied from interface: InputPrompt
      Get the line reader.
      Specified by:
      getLineReader in interface InputPrompt
      Returns:
      the line reader
    • getValidator

      public Function<String,Boolean> getValidator()
      Description copied from interface: InputPrompt
      Get the validator.
      Specified by:
      getValidator in interface InputPrompt
      Returns:
      the validator