mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-09-27 10:03:11 +07:00
extracted base interface in order to enable client to query debug port
This commit is contained in:
@@ -0,0 +1,14 @@
|
||||
/*
|
||||
* Copyright (c) 2000-2004 by JetBrains s.r.o. All Rights Reserved.
|
||||
* Use is subject to license terms.
|
||||
*/
|
||||
package com.intellij.execution.configurations;
|
||||
|
||||
public interface DebuggingRunnerData {
|
||||
/**
|
||||
* @return a string denoting debug port. In case of socket transport this is a number, in case of shared memory transport this is a string
|
||||
*/
|
||||
String getDebugPort();
|
||||
|
||||
boolean isRemote();
|
||||
}
|
||||
@@ -5,6 +5,7 @@ import com.intellij.debugger.impl.DebuggerManagerImpl;
|
||||
import com.intellij.execution.ExecutionException;
|
||||
import com.intellij.execution.configurations.JavaParameters;
|
||||
import com.intellij.execution.configurations.RemoteConnection;
|
||||
import com.intellij.execution.configurations.DebuggingRunnerData;
|
||||
import com.intellij.openapi.util.DefaultJDOMExternalizer;
|
||||
import com.intellij.openapi.util.InvalidDataException;
|
||||
import com.intellij.openapi.util.JDOMExternalizable;
|
||||
@@ -16,7 +17,7 @@ import org.jdom.Element;
|
||||
* Use is subject to license terms.
|
||||
*/
|
||||
|
||||
public class GenericDebuggerRunnerSettings implements JDOMExternalizable {
|
||||
public class GenericDebuggerRunnerSettings implements JDOMExternalizable, DebuggingRunnerData {
|
||||
public String DEBUG_PORT = "";
|
||||
public int TRANSPORT = DebuggerSettings.SOCKET_TRANSPORT;
|
||||
public boolean LOCAL = true;
|
||||
@@ -24,6 +25,14 @@ public class GenericDebuggerRunnerSettings implements JDOMExternalizable {
|
||||
public GenericDebuggerRunnerSettings() {
|
||||
}
|
||||
|
||||
public String getDebugPort() {
|
||||
return DEBUG_PORT;
|
||||
}
|
||||
|
||||
public boolean isRemote() {
|
||||
return !LOCAL;
|
||||
}
|
||||
|
||||
private void updateDefaultAddress() {
|
||||
boolean useDefaultPort = "".equals(DEBUG_PORT);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user