/** * Returns the singleton instance of the launch manager * @return the singleton instance of the launch manager * @since 3.3 */ private LaunchManager getLaunchManager() { return (LaunchManager) DebugPlugin.getDefault().getLaunchManager(); }
/** * Convenience method to return the launch manager. * * @return the launch manager */ protected ILaunchManager getLaunchManager() { return DebugPlugin.getDefault().getLaunchManager(); }
/** * Returns the source container type identified by the given id, * or <code>null</code> if none. * * @param id source container type identifier * @return source container type or <code>null</code> */ protected ISourceContainerType getSourceContainerType(String id) { return DebugPlugin.getDefault().getLaunchManager().getSourceContainerType(id); } }
/** * Returns an array of environment variables to be used when * launching the given configuration or <code>null</code> if unspecified. * * @param configuration launch configuration * @return the environment variables to be used when launching or <code>null</code> * @throws CoreException if unable to access associated attribute or if * unable to resolve a variable in an environment variable's value */ public String[] getEnvironment(ILaunchConfiguration configuration) throws CoreException { return DebugPlugin.getDefault().getLaunchManager().getEnvironment(configuration); }
public void removeListener() { if (fLaunchConfigurationListener != null) { DebugPlugin.getDefault().getLaunchManager() .removeLaunchConfigurationListener( fLaunchConfigurationListener); fLaunchConfigurationListener = null; } } }
@Override public Object[] getElements(Object inputElement) { return DebugPlugin.getDefault().getLaunchManager().getLaunchConfigurationTypes(); } @Override
/** * Creates a new launch history for the given launch group */ public LaunchHistory(ILaunchGroup group) { fGroup = group; ILaunchManager manager = DebugPlugin.getDefault().getLaunchManager(); manager.addLaunchListener(this); manager.addLaunchConfigurationListener(this); fgLaunchHistoryInstances.add(this); }
@Override public void launchConfigurationRemoved(ILaunchConfiguration configuration) { if (configuration.equals(getLaunchConfiguration())) { if (DebugPlugin.getDefault().getLaunchManager().getMovedTo(configuration) == null) { fConfig = null; } } }
/** * Disposes this history */ public void dispose() { ILaunchManager manager = DebugPlugin.getDefault().getLaunchManager(); manager.removeLaunchListener(this); manager.removeLaunchConfigurationListener(this); fgLaunchHistoryInstances.remove(this); }
/** * Fires a model delta to indicate that the launch manager should be refreshed. * Subclasses should override individual handle events to provide deltas that * better reflect the actual change in the model. * * @param event the event that triggered the root refresh */ protected void refreshRoot(DebugEvent event) { ModelDelta delta = new ModelDelta(DebugPlugin.getDefault().getLaunchManager(), IModelDelta.CONTENT); fireDelta(delta); }
/** * Notifies all targets of current filter specifications. */ protected void notifyTargetsOfFilters() { IDebugTarget[] targets = DebugPlugin.getDefault().getLaunchManager().getDebugTargets(); for (int i = 0; i < targets.length; i++) { if (targets[i] instanceof IJavaDebugTarget) { IJavaDebugTarget target = (IJavaDebugTarget)targets[i]; notifyTargetOfFilters(target); } } }
/** * @see ILaunchListener#launchChanged(ILaunch) */ public void launchChanged(ILaunch launch) { activate(); DebugPlugin.getDefault().getLaunchManager().removeLaunchListener(this); }
@Override protected boolean isEnabled() { ILaunch[] launches = DebugPlugin.getDefault().getLaunchManager().getLaunches(); if (launches != null) { for (int i= 0; i < launches.length; i++) { if (launches[i].isTerminated()) { return true; } } } return false; }
@Override public boolean close() { if (!isSafeToClose()) { return false; } DebugPlugin.getDefault().getLaunchManager().removeLaunchConfigurationListener(this); return super.close(); }
public void launch(ILaunchConfiguration configuration, String mode, ILaunch launch, IProgressMonitor monitor) throws CoreException { ApiUseScanJob job = new ApiUseScanJob(configuration); job.schedule(); DebugPlugin.getDefault().getLaunchManager().removeLaunch(launch); }
public static DefaultExternalLaunchConfigurationManager createAndRegister() { DefaultExternalLaunchConfigurationManager manager = new DefaultExternalLaunchConfigurationManager(); DebugPlugin.getDefault().getLaunchManager().addLaunchConfigurationListener(manager.launchConfigurationListener); CorePlugin.listenerRegistry().addEventListener(manager.launchConfigurationListener); return manager; }
/** * Called at startup by the Java debug ui plug-in */ public void startup() { // lazy initialization will occur on the first launch DebugPlugin debugPlugin = DebugPlugin.getDefault(); debugPlugin.getLaunchManager().addLaunchListener(this); debugPlugin.getBreakpointManager().addBreakpointListener(this); EvaluationContextManager.startup(); }
/** * Called by the debug ui plug-in on startup. * The perspective manager starts listening for * launches to be registered. */ public void startup() { DebugUIPlugin.getDefault().addSaveParticipant(this); DebugPlugin.getDefault().getLaunchManager().addLaunchListener(this); initPerspectives(); }
private void notifyTestRunSessionRemoved(TestRunSession testRunSession) { testRunSession.stopTestRun(); ILaunch launch= testRunSession.getLaunch(); if (launch != null) { ILaunchManager launchManager= DebugPlugin.getDefault().getLaunchManager(); launchManager.removeLaunch(launch); } Object[] listeners = fTestRunSessionListeners.getListeners(); for (int i = 0; i < listeners.length; ++i) { ((ITestRunSessionListener) listeners[i]).sessionRemoved(testRunSession); } }
private void fireDelta(IDebugTarget target, int flags) { ModelDelta root = new ModelDelta(DebugPlugin.getDefault().getLaunchManager(), IModelDelta.NO_CHANGE); ModelDelta delta = root.addNode(target.getLaunch(), IModelDelta.NO_CHANGE); delta.addNode(target, flags); fireDelta(root); }