Search in sources :

Example 6 with BreakpointActivatedEventImpl

use of org.eclipse.che.api.debug.shared.model.impl.event.BreakpointActivatedEventImpl in project che by eclipse.

the class NodeJsDebugger method start.

@Override
public void start(StartAction action) throws DebuggerException {
    try {
        for (Breakpoint breakpoint : action.getBreakpoints()) {
            Location location = breakpoint.getLocation();
            library.setBreakpoint(location.getTarget(), location.getLineNumber());
            debuggerCallback.onEvent(new BreakpointActivatedEventImpl(breakpoint));
        }
        library.backtrace();
    } catch (NodeJsDebuggerTerminatedException e) {
        disconnect();
        throw e;
    } catch (NodeJsDebuggerException e) {
        throw new DebuggerException("Start error. " + e.getMessage(), e);
    }
}
Also used : Breakpoint(org.eclipse.che.api.debug.shared.model.Breakpoint) NodeJsDebuggerException(org.eclipse.che.plugin.nodejsdbg.server.exception.NodeJsDebuggerException) DebuggerException(org.eclipse.che.api.debugger.server.exceptions.DebuggerException) NodeJsDebuggerException(org.eclipse.che.plugin.nodejsdbg.server.exception.NodeJsDebuggerException) BreakpointActivatedEventImpl(org.eclipse.che.api.debug.shared.model.impl.event.BreakpointActivatedEventImpl) NodeJsDebuggerTerminatedException(org.eclipse.che.plugin.nodejsdbg.server.exception.NodeJsDebuggerTerminatedException) Location(org.eclipse.che.api.debug.shared.model.Location)

Aggregations

BreakpointActivatedEventImpl (org.eclipse.che.api.debug.shared.model.impl.event.BreakpointActivatedEventImpl)6 Location (org.eclipse.che.api.debug.shared.model.Location)4 DebuggerException (org.eclipse.che.api.debugger.server.exceptions.DebuggerException)4 Breakpoint (org.eclipse.che.api.debug.shared.model.Breakpoint)2 NodeJsDebuggerException (org.eclipse.che.plugin.nodejsdbg.server.exception.NodeJsDebuggerException)2 NodeJsDebuggerTerminatedException (org.eclipse.che.plugin.nodejsdbg.server.exception.NodeJsDebuggerTerminatedException)2 AddBreakpointRequest (org.eclipse.che.plugin.zdb.server.connection.ZendDbgClientMessages.AddBreakpointRequest)2 AddBreakpointResponse (org.eclipse.che.plugin.zdb.server.connection.ZendDbgEngineMessages.AddBreakpointResponse)2 AbsentInformationException (com.sun.jdi.AbsentInformationException)1 ClassNotPreparedException (com.sun.jdi.ClassNotPreparedException)1 NativeMethodException (com.sun.jdi.NativeMethodException)1 ReferenceType (com.sun.jdi.ReferenceType)1 BreakpointRequest (com.sun.jdi.request.BreakpointRequest)1 EventRequest (com.sun.jdi.request.EventRequest)1 EventRequestManager (com.sun.jdi.request.EventRequestManager)1 InvalidRequestStateException (com.sun.jdi.request.InvalidRequestStateException)1 IOException (java.io.IOException)1 ArrayList (java.util.ArrayList)1 BreakpointImpl (org.eclipse.che.api.debug.shared.model.impl.BreakpointImpl)1 GdbParseException (org.eclipse.che.plugin.gdb.server.exception.GdbParseException)1