クラスJdiInitiator

java.lang.Object
jdk.jshell.execution.JdiInitiator

public class JdiInitiator extends Object
JDI接続を設定し、結果のJDI VirtualMachineおよびリモート・エージェントが実行されているProcessを指定します。
導入されたバージョン:
9
  • コンストラクタの詳細

    • JdiInitiator

      public JdiInitiator(int port, List<String> remoteVMOptions, String remoteAgent, boolean isLaunch, String host, int timeout, Map<String,String> customConnectorArgs)
      リモート・エージェントを起動し、それに対するJDI接続を確立します。
      パラメータ:
      port - (non-JDI)コマンドのソケット・ポート
      remoteVMOptions - 任意のユーザーがVMコマンドライン・オプションをリクエストしました
      remoteAgent - 起動するリモート・エージェントのフル・クラス名
      isLaunch - JDIは打ち上げをしますか? つまり、LaunchingConnectorです。それ以外の場合は、明示的に起動し、ListeningConnectorを使用
      host - 使用する明示的なホスト名(nullで検出されたホスト名が使用されている場合)は、(!isLaunch)のリスニングのみに適用されます
      timeout - 起動タイムアウト(ミリ秒)。 ゼロまたは負の場合、待機しないため、まだ起動していない場合はすぐにタイムアウトします。
      customConnectorArgs - カスタム引数がコネクタに渡されました。 これらはJDI com.sun.jdi.connect.Connector引数です。 vmexec引数はサポートされていません。
  • メソッドの詳細

    • vm

      public VirtualMachine vm()
      結果のVirtualMachineインスタンスを返します。
      戻り値:
      仮想マシン
    • process

      public Process process()
      起動されたプロセスを返します。
      戻り値:
      リモート・エージェント・プロセス
    • runListenProcess

      protected void runListenProcess(String jdiAddress, int jshellControlPort, List<String> remoteVMOptions, JdiInitiator.ProcessStarted setupVM)
      指定されたアドレスに添付するプロセスを作成します。
      パラメータ:
      jdiAddress - JDIサーバーが接続を待機しているアドレス
      jshellControlPort - リモート・エージェントが接続するポート
      remoteVMOptions - リモート・エージェントVMのVMオプション
      setupVM - コールバックを呼び出すと、リモート・エージェント・プロセスが作成されます。 コールバックによって、JDIのVirtualMachineが設定されます。
      導入されたバージョン:
      22