/** * Returns a shared utility Java debug model presentation. Clients should not * dispose the presentation. * * @return a Java debug model presentation */ public IDebugModelPresentation getModelPresentation() { if (fUtilPresentation == null) { fUtilPresentation = DebugUITools.newDebugModelPresentation(JDIDebugModel.getPluginIdentifier()); } return fUtilPresentation; }
/** * Returns a debug model presentation (creating one * if necessary). * * @return debug model presentation */ protected IDebugModelPresentation getDebugModelPresentation() { if (fPresentation == null) { fPresentation = DebugUITools.newDebugModelPresentation(JDIDebugModel.getPluginIdentifier()); } return fPresentation; }
@Override protected IBreakpoint[] getBreakpoints(ILaunchConfiguration configuration) { IBreakpointManager breakpointManager = DebugPlugin.getDefault().getBreakpointManager(); if (!breakpointManager.isEnabled()) { // no need to check breakpoints individually. return null; } return breakpointManager.getBreakpoints(JDIDebugModel.getPluginIdentifier()); }
/** * Returns any existing watchpoint for the given field, or <code>null</code> if none. * * @param typeName fully qualified type name on which watchpoint may exist * @param fieldName field name * @return any existing watchpoint for the given field, or <code>null</code> if none * @throws CoreException */ private IJavaWatchpoint getWatchpoint(String typeName, String fieldName) throws CoreException { IBreakpointManager breakpointManager = DebugPlugin.getDefault().getBreakpointManager(); IBreakpoint[] breakpoints = breakpointManager.getBreakpoints(JDIDebugModel.getPluginIdentifier()); for (int i = 0; i < breakpoints.length; i++) { IBreakpoint breakpoint = breakpoints[i]; if (breakpoint instanceof IJavaWatchpoint) { IJavaWatchpoint watchpoint = (IJavaWatchpoint) breakpoint; if (typeName.equals(watchpoint.getTypeName()) && fieldName.equals(watchpoint.getFieldName())) { return watchpoint; } } } return null; }
@Override protected IBreakpoint[] getBreakpoints(ILaunchConfiguration configuration) { IBreakpointManager breakpointManager = DebugPlugin.getDefault().getBreakpointManager(); if (!breakpointManager.isEnabled()) { // no need to check breakpoints individually. return null; } return breakpointManager.getBreakpoints(JDIDebugModel.getPluginIdentifier()); }
/** * Returns the class load breakpoint for the specified type or null if none found * @param type the type to search for a class load breakpoint for * @return the existing class load breakpoint, or null if none * @throws CoreException * @since 3.3 */ protected IBreakpoint getClassLoadBreakpoint(IType type) throws CoreException { IBreakpoint[] breakpoints = DebugPlugin.getDefault().getBreakpointManager().getBreakpoints(JDIDebugModel.getPluginIdentifier()); IBreakpoint existing = null; IJavaBreakpoint breakpoint = null; for (int i = 0; i < breakpoints.length; i++) { breakpoint = (IJavaBreakpoint) breakpoints[i]; if (breakpoint instanceof IJavaClassPrepareBreakpoint && createQualifiedTypeName(type).equals(breakpoint.getTypeName())) { existing = breakpoint; break; } } return existing; }
/** * @see org.eclipse.debug.ui.console.IConsoleHyperlink#linkActivated() */ public void linkActivated() { try { // check for an existing breakpoint IBreakpoint[] breakpoints = DebugPlugin.getDefault() .getBreakpointManager().getBreakpoints( JDIDebugModel.getPluginIdentifier()); for (int i = 0; i < breakpoints.length; i++) { IBreakpoint breakpoint = breakpoints[i]; if (breakpoint instanceof IJavaExceptionBreakpoint) { IJavaExceptionBreakpoint exceptionBreakpoint = (IJavaExceptionBreakpoint) breakpoint; if (fExceptionName .equals(exceptionBreakpoint.getTypeName())) { showProperties(exceptionBreakpoint); return; } } } // create a new exception breakpoint startSourceSearch(fExceptionName, -1); } catch (CoreException e) { JDIDebugUIPlugin.statusDialog(e.getStatus()); return; } }
BreakpointUtils.addJavaBreakpointAttributes(map, type); IBreakpoint[] breakpoints = DebugPlugin.getDefault().getBreakpointManager().getBreakpoints( JDIDebugModel.getPluginIdentifier()); boolean exists = false; for (int j = 0; j < breakpoints.length; j++) {
public void run(IAction action) { IStructuredSelection ss = (IStructuredSelection)fSelection; Iterator iterator = ss.iterator(); IBreakpoint[] breakpoints = DebugPlugin.getDefault().getBreakpointManager().getBreakpoints(JDIDebugModel.getPluginIdentifier()); while (iterator.hasNext()) { IType type = (IType) iterator.next();
kind = IJavaClassPrepareBreakpoint.TYPE_INTERFACE; IBreakpoint[] breakpoints = DebugPlugin.getDefault().getBreakpointManager().getBreakpoints(JDIDebugModel.getPluginIdentifier()); boolean exists = false; for (int j = 0; j < breakpoints.length; j++) {
public void run(IAction action) { final StructuredViewer viewer = getStructuredViewer(); IDebugView view = (IDebugView)getView().getAdapter(IDebugView.class); if (view != null) { IDebugModelPresentation pres = view.getPresentation(JDIDebugModel.getPluginIdentifier()); if (pres != null) { pres.setAttribute(JDIModelPresentation.DISPLAY_QUALIFIED_NAMES, (getValue() ? Boolean.TRUE : Boolean.FALSE)); BusyIndicator.showWhile(viewer.getControl().getDisplay(), new Runnable() { public void run() { viewer.refresh(); IPreferenceStore store = getPreferenceStore(); String key = getView().getSite().getId() + "." + getPreferenceKey(); //$NON-NLS-1$ store.setValue(key, getValue()); } }); } } } }
IBreakpoint[] breakpoints = breakpointManager.getBreakpoints(JDIDebugModel.getPluginIdentifier()); if (element instanceof IMethod) { IMethod method = (IMethod) element;