blob: 06ebf7875e6eeb2a4707994665deffb35854b3b8 [file] [log] [blame]
Tor Norbyec1ace1f2013-07-08 11:26:24 -07001/*
Tor Norbye92584642014-04-17 08:39:25 -07002 * Copyright 2000-2014 JetBrains s.r.o.
Tor Norbyec1ace1f2013-07-08 11:26:24 -07003 *
4 * Licensed under the Apache License, Version 2.0 (the "License");
5 * you may not use this file except in compliance with the License.
6 * You may obtain a copy of the License at
7 *
8 * http://www.apache.org/licenses/LICENSE-2.0
9 *
10 * Unless required by applicable law or agreed to in writing, software
11 * distributed under the License is distributed on an "AS IS" BASIS,
12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 * See the License for the specific language governing permissions and
14 * limitations under the License.
15 */
16package com.intellij.debugger;
17
18import com.intellij.debugger.engine.DebugProcessImpl;
Tor Norbyec667c1f2014-05-28 17:06:51 -070019import com.intellij.debugger.engine.JavaDebugProcess;
Tor Norbyec1ace1f2013-07-08 11:26:24 -070020import com.intellij.debugger.engine.RemoteStateState;
21import com.intellij.debugger.engine.SuspendContextImpl;
22import com.intellij.debugger.engine.evaluation.EvaluateException;
23import com.intellij.debugger.engine.evaluation.EvaluationContextImpl;
24import com.intellij.debugger.engine.events.DebuggerCommandImpl;
25import com.intellij.debugger.impl.*;
26import com.intellij.debugger.jdi.StackFrameProxyImpl;
27import com.intellij.debugger.settings.DebuggerSettings;
28import com.intellij.debugger.settings.NodeRendererSettings;
29import com.intellij.debugger.ui.breakpoints.BreakpointManager;
30import com.intellij.execution.ExecutionException;
Tor Norbyec1ace1f2013-07-08 11:26:24 -070031import com.intellij.execution.Executor;
32import com.intellij.execution.configurations.*;
33import com.intellij.execution.executors.DefaultDebugExecutor;
34import com.intellij.execution.process.ProcessAdapter;
35import com.intellij.execution.process.ProcessEvent;
Tor Norbyee782c572014-09-18 11:43:07 -070036import com.intellij.execution.process.ProcessHandler;
Tor Norbyec1ace1f2013-07-08 11:26:24 -070037import com.intellij.execution.process.ProcessOutputTypes;
38import com.intellij.execution.runners.ExecutionEnvironment;
Tor Norbyec667c1f2014-05-28 17:06:51 -070039import com.intellij.execution.runners.ExecutionEnvironmentBuilder;
Tor Norbyec1ace1f2013-07-08 11:26:24 -070040import com.intellij.execution.runners.ProgramRunner;
41import com.intellij.openapi.application.ApplicationManager;
42import com.intellij.openapi.application.ModalityState;
43import com.intellij.openapi.editor.Document;
Tor Norbye92584642014-04-17 08:39:25 -070044import com.intellij.openapi.fileEditor.ex.FileEditorManagerEx;
Tor Norbyec1ace1f2013-07-08 11:26:24 -070045import com.intellij.openapi.module.Module;
46import com.intellij.openapi.options.SettingsEditor;
47import com.intellij.openapi.project.Project;
Tor Norbyee782c572014-09-18 11:43:07 -070048import com.intellij.openapi.util.Computable;
49import com.intellij.openapi.util.InvalidDataException;
50import com.intellij.openapi.util.Key;
51import com.intellij.openapi.util.WriteExternalException;
Tor Norbyec1ace1f2013-07-08 11:26:24 -070052import com.intellij.openapi.util.text.StringUtil;
53import com.intellij.psi.JavaPsiFacade;
54import com.intellij.psi.PsiClass;
55import com.intellij.psi.PsiDocumentManager;
Tor Norbyec3d3a90f2014-09-04 13:24:04 -070056import com.intellij.psi.PsiFile;
Tor Norbyec1ace1f2013-07-08 11:26:24 -070057import com.intellij.psi.search.GlobalSearchScope;
58import com.intellij.util.ui.UIUtil;
Tor Norbyec667c1f2014-05-28 17:06:51 -070059import com.intellij.xdebugger.XDebugProcess;
60import com.intellij.xdebugger.XDebugProcessStarter;
61import com.intellij.xdebugger.XDebugSession;
62import com.intellij.xdebugger.XDebuggerManager;
Tor Norbyec1ace1f2013-07-08 11:26:24 -070063import org.jdom.Element;
64import org.jetbrains.annotations.NotNull;
65
66import javax.swing.*;
67import java.lang.reflect.InvocationTargetException;
68import java.util.StringTokenizer;
69
70public abstract class DebuggerTestCase extends ExecutionWithDebuggerToolsTestCase {
71 protected DebuggerSession myDebuggerSession;
72 private StringBuffer myConsoleBuffer;
73
74 @Override
75 protected void setUp() throws Exception {
76 super.setUp();
77 }
78
79 @Override
80 protected void initApplication() throws Exception {
81 super.initApplication();
82 setTestJDK();
83 DebuggerSettings.getInstance().DEBUGGER_TRANSPORT = DebuggerSettings.SOCKET_TRANSPORT;
84 DebuggerSettings.getInstance().SKIP_CONSTRUCTORS = false;
85 DebuggerSettings.getInstance().SKIP_GETTERS = false;
86 NodeRendererSettings.getInstance().getClassRenderer().SHOW_DECLARED_TYPE = true;
87 }
88
89 @Override
90 protected void runTest() throws Throwable {
91 super.runTest();
92 if(getDebugProcess() != null) {
Tor Norbyee782c572014-09-18 11:43:07 -070093 getDebugProcess().getProcessHandler().startNotify();
94 waitProcess(getDebugProcess().getProcessHandler());
Tor Norbyec1ace1f2013-07-08 11:26:24 -070095 waitForCompleted();
Tor Norbyec667c1f2014-05-28 17:06:51 -070096 //disposeSession(myDebuggerSession);
Tor Norbyee782c572014-09-18 11:43:07 -070097 assertNull(DebuggerManagerEx.getInstanceEx(myProject).getDebugProcess(getDebugProcess().getProcessHandler()));
Tor Norbyec1ace1f2013-07-08 11:26:24 -070098 myDebuggerSession = null;
99 }
100 if(myConsoleBuffer != null) {
101 //println("", b);
102 //println("Console output:", b);
103 //println(myConsoleBuffer.toString(), b);
104 }
105 checkTestOutput();
106 }
107
108 protected void checkTestOutput() throws Exception {
109 getChecker().checkValid(getTestProjectJdk());
110 }
111
112 protected void disposeSession(final DebuggerSession debuggerSession) throws InterruptedException, InvocationTargetException {
113 UIUtil.invokeAndWaitIfNeeded(new Runnable() {
114 @Override
115 public void run() {
116 debuggerSession.dispose();
117 }
118 });
119 }
120
121 @Override
122 protected void tearDown() throws Exception {
Tor Norbye92584642014-04-17 08:39:25 -0700123 FileEditorManagerEx.getInstanceEx(getProject()).closeAllFiles();
Tor Norbyec1ace1f2013-07-08 11:26:24 -0700124 myConsoleBuffer = null;
Tor Norbye92584642014-04-17 08:39:25 -0700125 super.tearDown();
Tor Norbyec1ace1f2013-07-08 11:26:24 -0700126 }
127
128 protected void createLocalProcess(String className) throws ExecutionException, InterruptedException, InvocationTargetException {
129 LOG.assertTrue(myDebugProcess == null);
130 myDebuggerSession = createLocalProcess(DebuggerSettings.SOCKET_TRANSPORT, createJavaParameters(className));
131 myDebugProcess = myDebuggerSession.getProcess();
132 }
133
Tor Norbyee782c572014-09-18 11:43:07 -0700134 protected DebuggerSession createLocalSession(final JavaParameters javaParameters) throws ExecutionException, InterruptedException {
Tor Norbyec1ace1f2013-07-08 11:26:24 -0700135 createBreakpoints(javaParameters.getMainClass());
136 DebuggerSettings.getInstance().DEBUGGER_TRANSPORT = DebuggerSettings.SOCKET_TRANSPORT;
137
138 GenericDebuggerRunnerSettings debuggerRunnerSettings = new GenericDebuggerRunnerSettings();
Tor Norbye1aa2e092014-08-20 17:01:23 -0700139 debuggerRunnerSettings.LOCAL = true;
Tor Norbyec1ace1f2013-07-08 11:26:24 -0700140
141 final RemoteConnection debugParameters = DebuggerManagerImpl.createDebugParameters(javaParameters, debuggerRunnerSettings, false);
142
Tor Norbyec667c1f2014-05-28 17:06:51 -0700143 ExecutionEnvironment environment = new ExecutionEnvironmentBuilder(myProject, DefaultDebugExecutor.getDebugExecutorInstance())
Tor Norbye1aa2e092014-08-20 17:01:23 -0700144 .runnerSettings(debuggerRunnerSettings)
Tor Norbyee782c572014-09-18 11:43:07 -0700145 .runProfile(new MockConfiguration())
Tor Norbyec667c1f2014-05-28 17:06:51 -0700146 .build();
Tor Norbye6739a8f2013-08-07 11:11:08 -0700147 final JavaCommandLineState javaCommandLineState = new JavaCommandLineState(environment){
Tor Norbyec1ace1f2013-07-08 11:26:24 -0700148 @Override
149 protected JavaParameters createJavaParameters() {
150 return javaParameters;
151 }
152
153 @Override
154 protected GeneralCommandLine createCommandLine() throws ExecutionException {
155 return CommandLineBuilder.createFromJavaParameters(getJavaParameters());
156 }
157 };
158
Tor Norbyec1ace1f2013-07-08 11:26:24 -0700159 ApplicationManager.getApplication().invokeAndWait(new Runnable() {
160 @Override
161 public void run() {
162 try {
Tor Norbye1aa2e092014-08-20 17:01:23 -0700163 myDebuggerSession =
164 DebuggerManagerEx.getInstanceEx(myProject)
165 .attachVirtualMachine(new DefaultDebugEnvironment(new ExecutionEnvironmentBuilder(myProject, DefaultDebugExecutor.getDebugExecutorInstance())
166 .runProfile(new MockConfiguration())
167 .build(), javaCommandLineState, debugParameters, false));
168 XDebuggerManager.getInstance(myProject).startSession(javaCommandLineState.getEnvironment(), new XDebugProcessStarter() {
Tor Norbyec667c1f2014-05-28 17:06:51 -0700169 @Override
170 @NotNull
171 public XDebugProcess start(@NotNull XDebugSession session) {
172 return new JavaDebugProcess(session, myDebuggerSession);
173 }
174 });
Tor Norbyec1ace1f2013-07-08 11:26:24 -0700175 }
176 catch (ExecutionException e) {
177 LOG.error(e);
178 }
179 }
180 }, ModalityState.defaultModalityState());
181 myDebugProcess = myDebuggerSession.getProcess();
182
183 //myConsoleBuffer = new StringBuffer();
184
185 myDebugProcess.addProcessListener(new ProcessAdapter() {
186 @Override
187 public void onTextAvailable(ProcessEvent event, Key outputType) {
188 //myConsoleBuffer.append(event.getText());
189 print(event.getText(), outputType);
190 }
191 });
192
193 assertNotNull(myDebuggerSession);
194 assertNotNull(myDebugProcess);
195
196 return myDebuggerSession;
197 }
198
199
200 protected DebuggerSession createLocalProcess(int transport, final JavaParameters javaParameters) throws ExecutionException, InterruptedException, InvocationTargetException {
201 createBreakpoints(javaParameters.getMainClass());
202 final DebuggerSession[] debuggerSession = new DebuggerSession[]{null};
203
204 DebuggerSettings.getInstance().DEBUGGER_TRANSPORT = transport;
205
206 GenericDebuggerRunnerSettings debuggerRunnerSettings = new GenericDebuggerRunnerSettings();
207 debuggerRunnerSettings.LOCAL = true;
208 debuggerRunnerSettings.DEBUG_PORT = "3456";
209
Tor Norbyec667c1f2014-05-28 17:06:51 -0700210 ExecutionEnvironment environment = new ExecutionEnvironmentBuilder(myProject, DefaultDebugExecutor.getDebugExecutorInstance())
Tor Norbye1aa2e092014-08-20 17:01:23 -0700211 .runnerSettings(debuggerRunnerSettings)
212 .runProfile(new MockConfiguration())
Tor Norbyec667c1f2014-05-28 17:06:51 -0700213 .build();
Tor Norbye6739a8f2013-08-07 11:11:08 -0700214 final JavaCommandLineState javaCommandLineState = new JavaCommandLineState(environment) {
Tor Norbyec1ace1f2013-07-08 11:26:24 -0700215 @Override
216 protected JavaParameters createJavaParameters() {
217 return javaParameters;
218 }
219
220 @Override
221 protected GeneralCommandLine createCommandLine() throws ExecutionException {
222 return CommandLineBuilder.createFromJavaParameters(getJavaParameters());
223 }
224 };
225
226 final RemoteConnection debugParameters =
227 DebuggerManagerImpl.createDebugParameters(javaCommandLineState.getJavaParameters(), debuggerRunnerSettings, true);
228
229 UIUtil.invokeAndWaitIfNeeded(new Runnable() {
230 @Override
231 public void run() {
232 try {
Tor Norbye1aa2e092014-08-20 17:01:23 -0700233 debuggerSession[0] = attachVirtualMachine(javaCommandLineState, javaCommandLineState.getEnvironment(), debugParameters, false);
Tor Norbyec1ace1f2013-07-08 11:26:24 -0700234 }
235 catch (ExecutionException e) {
236 fail(e.getMessage());
237 }
238 }
239 });
240
Tor Norbyee782c572014-09-18 11:43:07 -0700241 final ProcessHandler processHandler = debuggerSession[0].getProcess().getProcessHandler();
Tor Norbyec1ace1f2013-07-08 11:26:24 -0700242 debuggerSession[0].getProcess().addProcessListener(new ProcessAdapter() {
243 @Override
244 public void onTextAvailable(ProcessEvent event, Key outputType) {
245 print(event.getText(), outputType);
246 }
247 });
248
249 DebugProcessImpl process =
Tor Norbyee782c572014-09-18 11:43:07 -0700250 (DebugProcessImpl)DebuggerManagerEx.getInstanceEx(myProject).getDebugProcess(processHandler);
Tor Norbyec1ace1f2013-07-08 11:26:24 -0700251 assertNotNull(process);
252 return debuggerSession[0];
253 }
254
255
256 protected DebuggerSession createRemoteProcess(final int transport, final boolean serverMode, JavaParameters javaParameters)
257 throws ExecutionException, InterruptedException, InvocationTargetException {
258 boolean useSockets = transport == DebuggerSettings.SOCKET_TRANSPORT;
259
260 RemoteConnection remoteConnection = new RemoteConnection(
261 useSockets,
262 "127.0.0.1",
263 "3456",
264 serverMode);
265
266 String launchCommandLine = remoteConnection.getLaunchCommandLine();
267
268 launchCommandLine = StringUtil.replace(launchCommandLine, RemoteConnection.ONTHROW, "");
269 launchCommandLine = StringUtil.replace(launchCommandLine, RemoteConnection.ONUNCAUGHT, "");
270
271 launchCommandLine = StringUtil.replace(launchCommandLine, "suspend=n", "suspend=y");
272
273 println(launchCommandLine, ProcessOutputTypes.SYSTEM);
274
Tor Norbyec1ace1f2013-07-08 11:26:24 -0700275 for(StringTokenizer tokenizer = new StringTokenizer(launchCommandLine);tokenizer.hasMoreTokens();) {
276 String token = tokenizer.nextToken();
Tor Norbye1aa2e092014-08-20 17:01:23 -0700277 javaParameters.getVMParametersList().add(token);
Tor Norbyec1ace1f2013-07-08 11:26:24 -0700278 }
279
Tor Norbye1aa2e092014-08-20 17:01:23 -0700280 GeneralCommandLine commandLine = CommandLineBuilder.createFromJavaParameters(javaParameters);
Tor Norbyec1ace1f2013-07-08 11:26:24 -0700281
282
283 DebuggerSession debuggerSession;
284
285 if(serverMode) {
286 debuggerSession = attachVM(remoteConnection, false);
287 commandLine.createProcess();
288 } else {
289 commandLine.createProcess();
290 debuggerSession = attachVM(remoteConnection, true);
291 }
292
Tor Norbyee782c572014-09-18 11:43:07 -0700293 ProcessHandler processHandler = debuggerSession.getProcess().getProcessHandler();
Tor Norbyec1ace1f2013-07-08 11:26:24 -0700294 DebugProcessImpl process = (DebugProcessImpl)DebuggerManagerEx.getInstanceEx(myProject)
Tor Norbyee782c572014-09-18 11:43:07 -0700295 .getDebugProcess(processHandler);
Tor Norbyec1ace1f2013-07-08 11:26:24 -0700296
297 assertNotNull(process);
298 return debuggerSession;
299 }
300
301 protected DebuggerSession attachVM(final RemoteConnection remoteConnection, final boolean pollConnection)
302 throws InvocationTargetException, InterruptedException {
Tor Norbye6739a8f2013-08-07 11:11:08 -0700303 final RemoteState remoteState = new RemoteStateState(myProject, remoteConnection);
Tor Norbyec1ace1f2013-07-08 11:26:24 -0700304
305 final DebuggerSession[] debuggerSession = new DebuggerSession[1];
306 UIUtil.invokeAndWaitIfNeeded(new Runnable() {
307 @Override
308 public void run() {
309 try {
Tor Norbye1aa2e092014-08-20 17:01:23 -0700310 debuggerSession[0] = attachVirtualMachine(remoteState, new ExecutionEnvironmentBuilder(myProject, DefaultDebugExecutor.getDebugExecutorInstance())
311 .runProfile(new MockConfiguration())
312 .build(), remoteConnection, pollConnection);
Tor Norbyec1ace1f2013-07-08 11:26:24 -0700313 }
314 catch (ExecutionException e) {
315 fail(e.getMessage());
316 }
317 }
318 });
Tor Norbyee782c572014-09-18 11:43:07 -0700319 debuggerSession[0].getProcess().getProcessHandler().addProcessListener(new ProcessAdapter() {
Tor Norbyec1ace1f2013-07-08 11:26:24 -0700320 @Override
321 public void onTextAvailable(ProcessEvent event, Key outputType) {
322 print(event.getText(), outputType);
323 }
324 });
325 return debuggerSession[0];
326 }
327
328 protected void createBreakpoints(final String className) {
Tor Norbyec3d3a90f2014-09-04 13:24:04 -0700329 final PsiFile psiFile = ApplicationManager.getApplication().runReadAction(new Computable<PsiFile>() {
Tor Norbyec1ace1f2013-07-08 11:26:24 -0700330 @Override
Tor Norbyec3d3a90f2014-09-04 13:24:04 -0700331 public PsiFile compute() {
332 PsiClass psiClass = JavaPsiFacade.getInstance(myProject).findClass(className, GlobalSearchScope.allScope(myProject));
333 return psiClass.getContainingFile();
Tor Norbyec1ace1f2013-07-08 11:26:24 -0700334 }
335 });
336
Tor Norbyec3d3a90f2014-09-04 13:24:04 -0700337 createBreakpoints(psiFile);
Tor Norbyec1ace1f2013-07-08 11:26:24 -0700338 }
339
340 protected EvaluationContextImpl createEvaluationContext(final SuspendContextImpl suspendContext) {
341 try {
342 return new EvaluationContextImpl(
343 suspendContext,
344 suspendContext.getFrameProxy(),
345 suspendContext.getFrameProxy().thisObject());
346 }
347 catch (EvaluateException e) {
348 error(e);
349 return null;
350 }
351 }
352
353 protected void waitForCompleted() {
354 final SynchronizationBasedSemaphore s = new SynchronizationBasedSemaphore();
355 s.down();
356
357 final InvokeThread.WorkerThreadRequest request = getDebugProcess().getManagerThread().getCurrentRequest();
358 final Thread thread = new Thread("Joining "+request) {
359 @Override
360 public void run() {
361 try {
362 request.join();
363 }
Tor Norbye1aa2e092014-08-20 17:01:23 -0700364 catch (Exception ignored) {
Tor Norbyec1ace1f2013-07-08 11:26:24 -0700365 }
366 }
367 };
368 thread.start();
369 if(request.isDone()) {
370 thread.interrupt();
371 }
372 waitFor(new Runnable() {
373 @Override
374 public void run() {
375 try {
376 thread.join();
377 }
Tor Norbye1aa2e092014-08-20 17:01:23 -0700378 catch (InterruptedException ignored) {
Tor Norbyec1ace1f2013-07-08 11:26:24 -0700379 }
380 }
381 });
382
383 invokeRatherLater(new DebuggerCommandImpl() {
384 @Override
385 protected void action() throws Exception {
386 LOG.assertTrue(false);
387 }
388
389 @Override
390 protected void commandCancelled() {
391 //We wait for invokeRatherLater's
392 invokeRatherLater(new DebuggerCommandImpl() {
393 @Override
394 protected void action() throws Exception {
395 LOG.assertTrue(false);
396 }
397
398 @Override
399 protected void commandCancelled() {
400 s.up();
401 }
402 });
403 }
404 });
405
406 waitFor(new Runnable() {
407 @Override
408 public void run() {
409 s.waitFor();
410 }
411 });
412 }
413
414 public DebuggerContextImpl createDebuggerContext(final SuspendContextImpl suspendContext, StackFrameProxyImpl stackFrame) {
415 final DebuggerSession[] session = new DebuggerSession[1];
416
417 UIUtil.invokeAndWaitIfNeeded(new Runnable() {
418 @Override
419 public void run() {
420 session[0] = DebuggerManagerEx.getInstanceEx(myProject).getSession(suspendContext.getDebugProcess());
421 }
422 });
423
424 DebuggerContextImpl debuggerContext = DebuggerContextImpl.createDebuggerContext(
425 session[0],
426 suspendContext,
427 stackFrame != null ? stackFrame.threadProxy() : null,
428 stackFrame);
429 debuggerContext.initCaches();
430 return debuggerContext;
431 }
432
433 public DebuggerContextImpl createDebuggerContext(final SuspendContextImpl suspendContext) {
434 return createDebuggerContext(suspendContext, suspendContext.getFrameProxy());
435 }
436
437 protected void createBreakpointInHelloWorld() {
438 DebuggerInvocationUtil.invokeAndWait(myProject, new Runnable() {
439 @Override
440 public void run() {
441 BreakpointManager breakpointManager = DebuggerManagerEx.getInstanceEx(myProject).getBreakpointManager();
442 PsiClass psiClass = JavaPsiFacade.getInstance(myProject).findClass("HelloWorld", GlobalSearchScope.allScope(myProject));
443 Document document = PsiDocumentManager.getInstance(myProject).getDocument(psiClass.getContainingFile());
444 breakpointManager.addLineBreakpoint(document, 3);
445 }
446 }, ApplicationManager.getApplication().getDefaultModalityState());
447 }
448
449 protected void createHelloWorldProcessWithBreakpoint() throws ExecutionException, InterruptedException, InvocationTargetException {
450 createLocalProcess("HelloWorld");
451
452 createBreakpointInHelloWorld();
453 }
454
455 @Override
456 protected DebugProcessImpl getDebugProcess() {
457 return myDebuggerSession != null ? myDebuggerSession.getProcess() : null;
458 }
459
460 public DebuggerSession getDebuggerSession() {
461 return myDebuggerSession;
462 }
463
Tor Norbye1aa2e092014-08-20 17:01:23 -0700464 protected DebuggerSession attachVirtualMachine(RunProfileState state,
Tor Norbyec667c1f2014-05-28 17:06:51 -0700465 ExecutionEnvironment environment,
466 RemoteConnection remoteConnection,
467 boolean pollConnection) throws ExecutionException {
468 final DebuggerSession debuggerSession =
Tor Norbye1aa2e092014-08-20 17:01:23 -0700469 DebuggerManagerEx.getInstanceEx(myProject).attachVirtualMachine(new DefaultDebugEnvironment(environment, state, remoteConnection, pollConnection));
470 XDebuggerManager.getInstance(myProject).startSession(environment, new XDebugProcessStarter() {
Tor Norbyec667c1f2014-05-28 17:06:51 -0700471 @Override
472 @NotNull
473 public XDebugProcess start(@NotNull XDebugSession session) {
474 return new JavaDebugProcess(session, debuggerSession);
475 }
476 });
477 return debuggerSession;
Tor Norbyec1ace1f2013-07-08 11:26:24 -0700478 }
479
Tor Norbye65f60eb2014-07-16 18:07:37 -0700480 public static class MockConfiguration implements ModuleRunConfiguration {
Tor Norbyec1ace1f2013-07-08 11:26:24 -0700481 @Override
482 @NotNull
483 public Module[] getModules() {
484 return Module.EMPTY_ARRAY; //To change body of implemented methods use File | Settings | File Templates.
485 }
486
487 @Override
488 public Icon getIcon() {
489 return null; //To change body of implemented methods use File | Settings | File Templates.
490 }
491
492 @Override
493 public ConfigurationFactory getFactory() {
494 return null; //To change body of implemented methods use File | Settings | File Templates.
495 }
496
497 @Override
498 public void setName(final String name) {
499 //To change body of implemented methods use File | Settings | File Templates.
500 }
501
Tor Norbye6739a8f2013-08-07 11:11:08 -0700502 @NotNull
Tor Norbyec1ace1f2013-07-08 11:26:24 -0700503 @Override
504 public SettingsEditor<? extends RunConfiguration> getConfigurationEditor() {
505 return null; //To change body of implemented methods use File | Settings | File Templates.
506 }
507
508 @Override
509 public Project getProject() {
510 return null; //To change body of implemented methods use File | Settings | File Templates.
511 }
512
513 @Override
514 @NotNull
515 public ConfigurationType getType() {
Tor Norbye65f60eb2014-07-16 18:07:37 -0700516 return UnknownConfigurationType.INSTANCE;
Tor Norbyec1ace1f2013-07-08 11:26:24 -0700517 }
518
519 @Override
Tor Norbye6739a8f2013-08-07 11:11:08 -0700520 public ConfigurationPerRunnerSettings createRunnerSettings(final ConfigurationInfoProvider provider) {
Tor Norbyec1ace1f2013-07-08 11:26:24 -0700521 return null; //To change body of implemented methods use File | Settings | File Templates.
522 }
523
524 @Override
Tor Norbye6739a8f2013-08-07 11:11:08 -0700525 public SettingsEditor<ConfigurationPerRunnerSettings> getRunnerSettingsEditor(final ProgramRunner runner) {
Tor Norbyec1ace1f2013-07-08 11:26:24 -0700526 return null; //To change body of implemented methods use File | Settings | File Templates.
527 }
528
529 @Override
530 public RunConfiguration clone() {
531 return null; //To change body of implemented methods use File | Settings | File Templates.
532 }
533
534 @Override
535 public int getUniqueID() {
536 return 0;
537 }
538
539 @Override
540 public RunProfileState getState(@NotNull final Executor executor, @NotNull final ExecutionEnvironment env) throws ExecutionException {
541 return null; //To change body of implemented methods use File | Settings | File Templates.
542 }
543
544 @Override
545 public String getName() {
Tor Norbyec667c1f2014-05-28 17:06:51 -0700546 return ""; //To change body of implemented methods use File | Settings | File Templates.
Tor Norbyec1ace1f2013-07-08 11:26:24 -0700547 }
548
549 @Override
550 public void checkConfiguration() throws RuntimeConfigurationException {
551 //To change body of implemented methods use File | Settings | File Templates.
552 }
553
554 @Override
555 public void readExternal(final Element element) throws InvalidDataException {
556 //To change body of implemented methods use File | Settings | File Templates.
557 }
558
559 @Override
560 public void writeExternal(final Element element) throws WriteExternalException {
561 //To change body of implemented methods use File | Settings | File Templates.
562 }
563 }
Tor Norbyec1ace1f2013-07-08 11:26:24 -0700564}