本文整理匯總了Java中com.intellij.execution.configurations.RunConfiguration.getProject方法的典型用法代碼示例。如果您正苦於以下問題:Java RunConfiguration.getProject方法的具體用法?Java RunConfiguration.getProject怎麽用?Java RunConfiguration.getProject使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在類com.intellij.execution.configurations.RunConfiguration
的用法示例。
在下文中一共展示了RunConfiguration.getProject方法的3個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Java代碼示例。
示例1: getAvailableConfigurations
import com.intellij.execution.configurations.RunConfiguration; //導入方法依賴的package包/類
@NotNull
private static List<RunnerAndConfigurationSettings> getAvailableConfigurations(@NotNull RunConfiguration runConfiguration) {
Project project = runConfiguration.getProject();
if (project == null || !project.isInitialized()) {
return Collections.emptyList();
}
List<RunnerAndConfigurationSettings> configurations = new ArrayList<RunnerAndConfigurationSettings>(RunManagerImpl.getInstanceImpl(project).getSortedConfigurations());
String executorId = DefaultRunExecutor.getRunExecutorInstance().getId();
for (Iterator<RunnerAndConfigurationSettings> iterator = configurations.iterator(); iterator.hasNext();) {
RunnerAndConfigurationSettings settings = iterator.next();
ProgramRunner runner = ProgramRunnerUtil.getRunner(executorId, settings);
if (runner == null || settings.getConfiguration() == runConfiguration) {
iterator.remove();
}
}
return configurations;
}
示例2: configureTask
import com.intellij.execution.configurations.RunConfiguration; //導入方法依賴的package包/類
@Override
public boolean configureTask(RunConfiguration runConfiguration, T task) {
final ToolSelectDialog dialog = new ToolSelectDialog(runConfiguration.getProject(), task.getToolActionId(), createToolsPanel());
if (!dialog.showAndGet()) {
return false;
}
boolean isModified = dialog.isModified();
Tool selectedTool = dialog.getSelectedTool();
LOG.assertTrue(selectedTool != null);
String selectedToolId = selectedTool.getActionId();
String oldToolId = task.getToolActionId();
if (oldToolId != null && oldToolId.equals(selectedToolId)) {
return isModified;
}
task.setToolActionId(selectedToolId);
return true;
}
示例3: SMTRunnerConsoleProperties
import com.intellij.execution.configurations.RunConfiguration; //導入方法依賴的package包/類
/**
* @param config
* @param testFrameworkName Prefix for storage which keeps runner settings. E.g. "RubyTestUnit"
* @param executor
*/
public SMTRunnerConsoleProperties(@NotNull RunConfiguration config, @NotNull String testFrameworkName, @NotNull Executor executor) {
this(config.getProject(), config, testFrameworkName, executor);
}