AutoCloseable, ExecutionControlpublic class JdiDefaultExecutionControl extends JdiExecutionControl
ExecutionControl that the
JShell-core uses by default.
Launches a remote process -- the "remote agent".
Interfaces to the remote agent over a socket and via JDI.
Designed to work with RemoteExecutionControl.ExecutionControl.ClassBytecodes, ExecutionControl.ClassInstallException, ExecutionControl.EngineTerminationException, ExecutionControl.ExecutionControlException, ExecutionControl.InternalException, ExecutionControl.NotImplementedException, ExecutionControl.ResolutionException, ExecutionControl.RunException, ExecutionControl.StoppedException, ExecutionControl.UserException| Modifier and Type | Method | Description |
|---|---|---|
void |
close() |
Closes the execution engine.
|
String |
invoke(String classname,
String methodname) |
Invokes an executable Snippet by calling a method on the specified
wrapper class.
|
void |
stop() |
Interrupts a running remote invoke by manipulating remote variables
and sending a stop via JDI.
|
protected com.sun.jdi.VirtualMachine |
vm() |
Returns the JDI
VirtualMachine instance. |
addToClasspath, extensionCommand, generate, generate, load, varValueredefine, referenceTypeclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitaddToClasspath, extensionCommand, load, varValuepublic String invoke(String classname, String methodname) throws ExecutionControl.RunException, ExecutionControl.EngineTerminationException, ExecutionControl.InternalException
ExecutionControlinvoke in interface ExecutionControlinvoke in class StreamingExecutionControlclassname - the class whose method should be invokedmethodname - the name of method to invokeExecutionControl.UserException - the invoke raised a user exceptionExecutionControl.ResolutionException - the invoke attempted to directly or
indirectly invoke an unresolved snippetExecutionControl.StoppedException - if the invoke() was canceled by
ExecutionControl.stop()ExecutionControl.EngineTerminationException - the execution engine has terminatedExecutionControl.InternalException - an internal problem occurredExecutionControl.RunExceptionpublic void stop()
throws ExecutionControl.EngineTerminationException,
ExecutionControl.InternalException
stop in interface ExecutionControlstop in class StreamingExecutionControlExecutionControl.EngineTerminationException - the execution engine has terminatedExecutionControl.InternalException - an internal problem occurredpublic void close()
StreamingExecutionControlclose in interface AutoCloseableclose in interface ExecutionControlclose in class StreamingExecutionControlprotected com.sun.jdi.VirtualMachine vm()
throws ExecutionControl.EngineTerminationException
JdiExecutionControlVirtualMachine instance.vm in class JdiExecutionControlExecutionControl.EngineTerminationException - if the VM is dead/disconnected Submit a bug or feature
Java is a trademark or registered trademark of Oracle and/or its affiliates in the US and other countries.
Copyright © 2015, 2017, Oracle and/or its affiliates. 500 Oracle Parkway
Redwood Shores, CA 94065 USA. All rights reserved.
DRAFT 9-Debian+0-9b153-2