Sometimes it is useful to poke inside JShell internals when in a notebook (e.g. SpencerPark/IJava#128) :
JJava.getKernelInstance().getShell().snippets();
So let's add a public method to the JavaKernel class:
public JShell getShell() {
return evaluator.getShell();
}