created on | January 28, 2022 |
JShell comes with four built-in feedback modes, listed in the table below
Mode | Value snippets | Declaration | Updates | Commands | Prompt |
---|---|---|---|---|---|
verbose | name == > value (and description) | Yes | Yes | Yes | \njshell> |
normal | name == > value | Yes | No | Yes | \njshell> |
concise | name == > value (only expressions) | No | No | No | jshell> |
silent | No | No | No | No | - > |
The default feedback mode is ‘normal’.
The feedback mode can be set with the command, i.e.:
without parameter displays the current feedback mode and the list of available feedback modes:
It is possible to define a custom feedback mode by copying a built-in feedback mode and editing the copied feedback mode to ones personal taste. For those interested, see Robert Field’s JShell Tutorial, April 15, 2017. The link is in the section ‘references’.