本文整理汇总了Java中com.intellij.execution.remote.RemoteConfiguration类的典型用法代码示例。如果您正苦于以下问题:Java RemoteConfiguration类的具体用法?Java RemoteConfiguration怎么用?Java RemoteConfiguration使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。
RemoteConfiguration类属于com.intellij.execution.remote包,在下文中一共展示了RemoteConfiguration类的10个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的Java代码示例。
示例1: createRemoteDebug
import com.intellij.execution.remote.RemoteConfiguration; //导入依赖的package包/类
private void createRemoteDebug(
final RunManagerImpl runManager,
final HybrisProjectDescriptor hybrisProjectDescriptor
) {
final RemoteConfigurationType remoteConfigurationType = ConfigurationTypeUtil.findConfigurationType(
RemoteConfigurationType.class);
final ConfigurationFactory configurationFactory = remoteConfigurationType.getConfigurationFactories()[0];
final String debugName = HybrisI18NBundleUtils.message("hybris.project.import.run.configuration.remote.debug");
final RunnerAndConfigurationSettings runner = runManager.createRunConfiguration(
debugName,
configurationFactory
);
final RemoteConfiguration remoteConfiguration = (RemoteConfiguration) runner.getConfiguration();
remoteConfiguration.PORT = getDebugPort(hybrisProjectDescriptor);
ApplicationManager.getApplication().invokeLater(() -> ApplicationManager.getApplication().runWriteAction(() -> {
runner.setSingleton(true);
runner.setActivateToolWindowBeforeRun(true);
runManager.addConfiguration(runner, true);
runManager.setSelectedConfiguration(runner);
}));
}
开发者ID:AlexanderBartash,项目名称:hybris-integration-intellij-idea-plugin,代码行数:23,代码来源:DebugRunConfigurationConfigurator.java
示例2: createRunConfiguration
import com.intellij.execution.remote.RemoteConfiguration; //导入依赖的package包/类
/**
* Creates debugging settings for server
*
* @param project
* @param debugPort
* @param hostname
* @return
*/
private RunnerAndConfigurationSettings createRunConfiguration(Project project, String debugPort, String hostname) {
final RemoteConfigurationType remoteConfigurationType = RemoteConfigurationType.getInstance();
final ConfigurationFactory factory = remoteConfigurationType.getFactory();
final RunnerAndConfigurationSettings runSettings =
RunManager.getInstance(project).createRunConfiguration(getRunConfigurationName(debugPort), factory);
final RemoteConfiguration configuration = (RemoteConfiguration) runSettings.getConfiguration();
configuration.HOST = hostname;
configuration.PORT = debugPort;
configuration.USE_SOCKET_TRANSPORT = true;
configuration.SERVER_MODE = false;
return runSettings;
}
开发者ID:asebak,项目名称:embeddedlinux-jvmdebugger-intellij,代码行数:24,代码来源:AppCommandLineState.java
示例3: createRunConfiguration
import com.intellij.execution.remote.RemoteConfiguration; //导入依赖的package包/类
private static RunnerAndConfigurationSettings createRunConfiguration(
Project project, String debugPort) {
final RemoteConfigurationType remoteConfigurationType = RemoteConfigurationType.getInstance();
final ConfigurationFactory factory = remoteConfigurationType.getFactory();
final RunnerAndConfigurationSettings runSettings =
RunManager.getInstance(project)
.createRunConfiguration(getRunConfigurationName(debugPort), factory);
final RemoteConfiguration configuration = (RemoteConfiguration) runSettings.getConfiguration();
configuration.HOST = "localhost";
configuration.PORT = debugPort;
configuration.USE_SOCKET_TRANSPORT = true;
configuration.SERVER_MODE = false;
return runSettings;
}
开发者ID:facebook,项目名称:buck,代码行数:18,代码来源:AndroidDebugger.java
示例4: createRunConfiguration
import com.intellij.execution.remote.RemoteConfiguration; //导入依赖的package包/类
private static RunnerAndConfigurationSettings createRunConfiguration(Project project, String debugPort) {
final RemoteConfigurationType remoteConfigurationType = RemoteConfigurationType.getInstance();
final ConfigurationFactory factory = remoteConfigurationType.getFactory();
final RunnerAndConfigurationSettings runSettings =
RunManager.getInstance(project).createRunConfiguration(getRunConfigurationName(debugPort), factory);
final RemoteConfiguration configuration = (RemoteConfiguration)runSettings.getConfiguration();
configuration.HOST = "localhost";
configuration.PORT = debugPort;
configuration.USE_SOCKET_TRANSPORT = true;
configuration.SERVER_MODE = false;
return runSettings;
}
开发者ID:jskierbi,项目名称:intellij-ce-playground,代码行数:16,代码来源:AndroidProcessChooserDialog.java
示例5: connectInDebugMode
import com.intellij.execution.remote.RemoteConfiguration; //导入依赖的package包/类
public void connectInDebugMode(RunManagerEx runManager) {
ServerConfiguration serverConfiguration = selectionHandler.getCurrentConfiguration();
// Create Remote Connection to Server using the IntelliJ Run / Debug Connection
//AS TODO: It is working but the configuration is listed and made persistent. That is not too bad because
//AS TODO: after changes a reconnect will update the configuration.
RemoteConfigurationType remoteConfigurationType = new RemoteConfigurationType();
RunConfiguration runConfiguration = remoteConfigurationType.getFactory().createTemplateConfiguration(myProject);
RemoteConfiguration remoteConfiguration = (RemoteConfiguration) runConfiguration;
// Server means if you are listening. If not you are attaching.
remoteConfiguration.SERVER_MODE = false;
remoteConfiguration.USE_SOCKET_TRANSPORT = true;
remoteConfiguration.HOST = serverConfiguration.getHost();
remoteConfiguration.PORT = serverConfiguration.getConnectionDebugPort() + "";
// Set a Name of the Configuration so that it is properly listed.
remoteConfiguration.setName(serverConfiguration.getName());
RunnerAndConfigurationSettings configuration = new RunnerAndConfigurationSettingsImpl(
(RunManagerImpl) runManager,
runConfiguration,
false
);
runManager.setTemporaryConfiguration(configuration);
//AS TODO: Make sure that this is the proper way to obtain the DEBUG Executor
Executor executor = ExecutorRegistry.getInstance().getExecutorById(ToolWindowId.DEBUG);
ExecutionUtil.runConfiguration(configuration, executor);
// Update the Modules with the Remote Sling Server
OsgiClient osgiClient = obtainOSGiClient();
if(osgiClient != null) {
BundleStatus status = checkAndUpdateSupportBundle(false);
if(status != BundleStatus.failed) {
checkModules(osgiClient);
}
}
}
开发者ID:headwirecom,项目名称:aem-ide-tooling-4-intellij,代码行数:34,代码来源:ServerConnectionManager.java
示例6: launchDebugger
import com.intellij.execution.remote.RemoteConfiguration; //导入依赖的package包/类
private static void launchDebugger(final Project project, final GaugeDebugInfo debugInfo) {
Runnable runnable = () -> {
final long startTime = System.currentTimeMillis();
GenericDebuggerRunner basicProgramRunner = new GenericDebuggerRunner();
RunManagerImpl manager = new RunManagerImpl(project);
ConfigurationFactory configFactory = RemoteConfigurationType.getInstance().getConfigurationFactories()[0];
RemoteConfiguration remoteConfig = new RemoteConfiguration(project, configFactory);
remoteConfig.PORT = debugInfo.getPort();
remoteConfig.HOST = debugInfo.getHost();
remoteConfig.USE_SOCKET_TRANSPORT = true;
remoteConfig.SERVER_MODE = false;
RunnerAndConfigurationSettingsImpl configuration = new RunnerAndConfigurationSettingsImpl(manager, remoteConfig, false);
ExecutionEnvironment environment = new ExecutionEnvironment(new DefaultDebugExecutor(), basicProgramRunner, configuration, project);
boolean debuggerConnected = false;
// Trying to connect to gauge java for 25 secs. The sleep is because it may take a few seconds for gauge to launch the java process and the jvm to load after that
while (!debuggerConnected && ((System.currentTimeMillis() - startTime) < 25000)) {
try {
Thread.sleep(5000);
basicProgramRunner.execute(environment);
debuggerConnected = true;
} catch (Exception e) {
System.err.println("Failed to connect debugger. Retrying... : " + e.getMessage());
}
}
};
ApplicationManager.getApplication().invokeAndWait(runnable, ModalityState.any());
}
开发者ID:getgauge,项目名称:Intellij-Plugin,代码行数:30,代码来源:GaugeRunProcessHandler.java
示例7: shouldCreateTask
import com.intellij.execution.remote.RemoteConfiguration; //导入依赖的package包/类
static boolean shouldCreateTask(RunConfiguration configuration) {
return !(configuration instanceof RemoteConfiguration) && configuration instanceof RunProfileWithCompileBeforeLaunchOption;
}
开发者ID:jskierbi,项目名称:intellij-ce-playground,代码行数:4,代码来源:CompileStepBeforeRun.java
示例8: createTask
import com.intellij.execution.remote.RemoteConfiguration; //导入依赖的package包/类
public MakeProjectBeforeRunTask createTask(RunConfiguration runConfiguration) {
return !(runConfiguration instanceof RemoteConfiguration) && runConfiguration instanceof RunProfileWithCompileBeforeLaunchOption
? new MakeProjectBeforeRunTask()
: null;
}
开发者ID:jskierbi,项目名称:intellij-ce-playground,代码行数:6,代码来源:MakeProjectStepBeforeRun.java
示例9: createTask
import com.intellij.execution.remote.RemoteConfiguration; //导入依赖的package包/类
public MakeBeforeRunTask createTask(RunConfiguration runConfiguration) {
return !(runConfiguration instanceof RemoteConfiguration) && runConfiguration instanceof RunProfileWithCompileBeforeLaunchOption
? new MakeBeforeRunTask()
: null;
}
开发者ID:lshain-android-source,项目名称:tools-idea,代码行数:6,代码来源:CompileStepBeforeRun.java
示例10: createTask
import com.intellij.execution.remote.RemoteConfiguration; //导入依赖的package包/类
@Override
public MakeBeforeRunTaskNoErrorCheck createTask(RunConfiguration runConfiguration) {
return !(runConfiguration instanceof RemoteConfiguration) && runConfiguration instanceof RunProfileWithCompileBeforeLaunchOption
? new MakeBeforeRunTaskNoErrorCheck()
: null;
}
开发者ID:lshain-android-source,项目名称:tools-idea,代码行数:7,代码来源:CompileStepBeforeRunNoErrorCheck.java
注:本文中的com.intellij.execution.remote.RemoteConfiguration类示例整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。 |
请发表评论