protected JDIDebugTarget getContext() throws DebugException{ JDIDebugTarget target= getContextFromUI(); if (target == null) { target= getContextFromModel(); } if (target == null) { return null; } IThread[] threads= target.getThreads(); boolean threadSuspended= false; for (int i= 0; i < threads.length; i++) { IThread thread= threads[i]; if (thread.canResume()) { threadSuspended=true; break;
protected IJavaDebugTarget getContext() { IDebugElement context = DebugUITools.getDebugContext(); if (context != null) { context = context.getDebugTarget(); if (context instanceof IJavaDebugTarget) { return (IJavaDebugTarget)context;
	protected JDIDebugTarget getContext() throws DebugException{		JDIDebugTarget target= getContextFromUI();		if (target == null) {			target= getContextFromModel();		}		if (target == null) {			return null;		}		IThread[] threads= target.getThreads();		boolean threadSuspended= false;		for (int i= 0; i < threads.length; i++) {			IThread thread= threads[i];			if (thread.canResume()) {				threadSuspended=true;				break;			}		}		if (threadSuspended) {			return target;		}		return null;	}