If your Web application has finished performing operations on the target virtual machine, or you otherwise want to close the connection, you can use the disconnect() API method to terminate the connection to the remote host. Disconnecting the VMRC browser plug-in from the target virtual machine terminates any active device connections. You can use an advanced configuration option to ensure that virtual device connections remain persistent after you call
disconnect().
The disconnect() method accepts no parameters and does not return a value. If a failure occurs, an exception is generated. If the call to
disconnect() is successful, the VMRC browser plug-in will generate an
onConnectionStateChange() event. An example call to the
disconnect() method might appear as follows:
You can shut down the VMRC browser plug-in by invoking the shutdown() method. Shutting down the VMRC browser plug-in stops the corresponding VMRC peer processes within the plug-in, and terminates any active connections.
The shutdown() method accepts no parameters and does not return a value. An exception is generated if the call to
shutdown() fails or encounters an error. An example call to the
shutdown() method is as follows: