Package io.neatify.cli.ui
Interface Console
- All Known Implementing Classes:
SystemConsole
public interface Console
Abstraction over interactive console input.
Introduced so the interactive flows (InteractiveCLI, FileOrganizer,
RulesFileCreator) no longer depend on a process-wide static Scanner.
The production implementation is SystemConsole; tests can supply a fake that scripts
answers, making the interactive paths unit-testable.
-
Method Summary
Modifier and TypeMethodDescriptionPrintspromptthen returns the trimmed line read from input.Printsprompt(annotated withdefaultValue) then returns the trimmed line, substitutingdefaultValuewhen the user enters nothing.voidBlocks until the user presses Enter.
-
Method Details
-
readInput
Printspromptthen returns the trimmed line read from input. -
readInput
Printsprompt(annotated withdefaultValue) then returns the trimmed line, substitutingdefaultValuewhen the user enters nothing. -
waitForEnter
void waitForEnter()Blocks until the user presses Enter.
-