Java Code Examples for org.eclipse.debug.core.DebugPlugin#getDefault()
The following examples show how to use
org.eclipse.debug.core.DebugPlugin#getDefault() .
You can vote up the ones you like or vote down the ones you don't like,
and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example 1
Source File: SimpleRunner.java From Pydev with Eclipse Public License 1.0 | 6 votes |
private static String[] createEnvWithPythonpath(String pythonPathEnvStr, IPythonNature nature, IInterpreterManager manager) throws CoreException { if (SharedCorePlugin.inTestMode()) { return null; } DebugPlugin defaultPlugin = DebugPlugin.getDefault(); Map<String, String> env = getDefaultSystemEnv(defaultPlugin, nature); //no need to remove as it'll be updated env.put("PYTHONPATH", pythonPathEnvStr); //put the environment switch (manager.getInterpreterType()) { case IPythonNature.INTERPRETER_TYPE_JYTHON: env.put("CLASSPATH", pythonPathEnvStr); //put the environment env.put("JYTHONPATH", pythonPathEnvStr); //put the environment break; case IPythonNature.INTERPRETER_TYPE_IRONPYTHON: env.put("IRONPYTHONPATH", pythonPathEnvStr); //put the environment break; } return getMapEnvAsArray(env); }
Example 2
Source File: GenerateUml2Solidity.java From uml2solidity with Eclipse Public License 1.0 | 5 votes |
/** * Fires the given debug event. * * @param event debug event to fire */ protected void fireEvent(DebugEvent event) { DebugPlugin manager= DebugPlugin.getDefault(); if (manager != null) { manager.fireDebugEventSet(new DebugEvent[]{event}); } }
Example 3
Source File: SimpleRunner.java From Pydev with Eclipse Public License 1.0 | 5 votes |
/** * @return a map with the env variables for the system */ public static Map<String, String> getDefaultSystemEnv(IPythonNature nature) throws CoreException { if (SharedCorePlugin.inTestMode()) { return new HashMap<String, String>(); } DebugPlugin defaultPlugin = DebugPlugin.getDefault(); return getDefaultSystemEnv(defaultPlugin, nature); }
Example 4
Source File: BaseDebugView.java From Pydev with Eclipse Public License 1.0 | 5 votes |
@Override public void createPartControl(Composite parent) { IViewSite viewSite = getViewSite(); if (viewSite != null) { configureToolBar(viewSite); } parent.setLayout(new GridLayout(1, true)); viewer = new TreeViewer(parent); provider = createContentProvider(); viewer.setContentProvider(provider); viewer.setLabelProvider(new PyDebugModelPresentation(false)); GridDataFactory.fillDefaults().grab(true, true).applyTo(viewer.getTree()); MenuManager menuManager = new MenuManager(); Menu menu = menuManager.createContextMenu(viewer.getTree()); viewer.getTree().setMenu(menu); IWorkbenchPartSite site = getSite(); site.registerContextMenu(menuManager, viewer); site.setSelectionProvider(viewer); this.parent = parent; listener = createListener(); if (listener != null) { DebugPlugin plugin = DebugPlugin.getDefault(); ILaunchManager launchManager = plugin.getLaunchManager(); launchManager.addLaunchListener(listener); plugin.addDebugEventListener(listener); } }
Example 5
Source File: BaseDebugView.java From Pydev with Eclipse Public License 1.0 | 5 votes |
@Override public void dispose() { super.dispose(); if (listener != null) { DebugPlugin plugin = DebugPlugin.getDefault(); ILaunchManager launchManager = plugin.getLaunchManager(); launchManager.removeLaunchListener(listener); plugin.removeDebugEventListener(listener); } this.clear(); }
Example 6
Source File: ScriptLineBreakpoint.java From birt with Eclipse Public License 1.0 | 4 votes |
public boolean shouldSkipBreakpoint() throws CoreException { DebugPlugin plugin = DebugPlugin.getDefault(); return plugin != null && isRegistered() && !plugin.getBreakpointManager().isEnabled(); }
Example 7
Source File: AbstractDebugTarget.java From Pydev with Eclipse Public License 1.0 | 4 votes |
/** * @return true if all the breakpoints should be skipped. Patch from bug: * http://sourceforge.net/tracker/index.php?func=detail&aid=1960983&group_id=85796&atid=577329 */ private boolean shouldSkipBreakpoints() { DebugPlugin manager = DebugPlugin.getDefault(); return manager != null && !manager.getBreakpointManager().isEnabled(); }
Example 8
Source File: AbstractDebugTarget.java From Pydev with Eclipse Public License 1.0 | 4 votes |
public void fireEvent(DebugEvent event) { DebugPlugin manager = DebugPlugin.getDefault(); if (manager != null) { manager.fireDebugEventSet(new DebugEvent[] { event }); } }