Running JDK Tools within a JShell Session


This blog post is about running tools provided by the Java Development Kit (JDK) in a JShell session. JShell was introduced in JDK 9 by JEP 222 - jshell: The Java Shell (Read-Eval-Print Loop) as an interactive tool to evaluate Java code. When using JShell for interactive development and code exploration, it is often desirable to run JDK tools, that are usually executed on the command-line, “in-shell”: for example to avoid starting a new operating system shell and also for feeding a just created class as an input to a JDK tool and evaluate its output ...

More at https://sormuras.github.io/blog/2023-03-09-jshell-tooling.html