private void doStep(int depth, SuspendPolicy suspendPolicy) throws DebuggerException { lock.lock(); try { clearSteps(); StepRequest request = getEventManager().createStepRequest(getCurrentThread(), StepRequest.STEP_LINE, depth); request.addCountFilter(1); request.setSuspendPolicy(toSuspendEventRequest(suspendPolicy)); request.enable(); resume(newDto(ResumeActionDto.class)); } finally { lock.unlock(); } }
private StepRequest createStep( ThreadReference eventThread, int depth ) { if( getEventRequestManager().stepRequests().size() > 0 ) { // Only one at a time return null; } StepRequest req = getEventRequestManager().createStepRequest( eventThread, StepRequest.STEP_LINE, depth ); req.addClassExclusionFilter( "sun.*" ); req.addClassExclusionFilter( "com.sun.*" ); //req.addClassExclusionFilter( "java.*" ); // we support dependency source now for java runtime debugging now req.addClassExclusionFilter( "gw.*" ); req.addCountFilter( 1 ); req.putProperty( FROM_LOCATION, _location ); req.enable(); return req; }
private void stepIntoThread(ThreadReference thread) { StepRequest request = DebugUtility.createStepIntoRequest(thread, this.context.getStepFilters().classNameFilters); currentDebugSession.getEventHub().stepEvents().filter(debugEvent -> request.equals(debugEvent.event.request())) .take(1).subscribe(debugEvent -> { debugEvent.shouldResume = false; // Have to send to events to keep the UI sync with the step in operations: context.getProtocolServer().sendEvent(new Events.StoppedEvent("step", thread.uniqueID())); context.getProtocolServer().sendEvent(new Events.ContinuedEvent(thread.uniqueID())); }); request.enable(); thread.resume(); }
private void stepInto(IDebugAdapterContext context, ThreadReference thread) { StepRequest request = DebugUtility.createStepIntoRequest(thread, context.getStepFilters().classNameFilters); context.getDebugSession().getEventHub().stepEvents().filter(debugEvent -> request.equals(debugEvent.event.request())).take(1).subscribe(debugEvent -> { debugEvent.shouldResume = false; // Have to send two events to keep the UI sync with the step in operations: context.getProtocolServer().sendEvent(new Events.ContinuedEvent(thread.uniqueID())); context.getProtocolServer().sendEvent(new Events.StoppedEvent("restartframe", thread.uniqueID())); }); request.enable(); thread.resume(); } }
context.getStepFilters().classNameFilters); threadState.pendingStepRequest.enable(); DebugUtility.resumeThread(thread);