Sha256: dbbd4181992f088938176946486b04b1c53c070229cb439a3b026dbe87368c67

Contents?: true

Size: 1.15 KB

Versions: 9

Compression:

Stored size: 1.15 KB

Contents

 require 'ruby-debug/xml_printer'
 module Debugger
   
   class EventProcessor
   
     attr_accessor :line, :file, :context
    
     def initialize(interface)
       @printer = XmlPrinter.new(interface)
       @line = nil
       @file = nil
     end
    
     def at_breakpoint(context, breakpoint)
       n = Debugger.breakpoints.index(breakpoint) + 1
       @printer.print_breakpoint n, breakpoint
     end
     
     def at_catchpoint(context, excpt)
       @printer.print_catchpoint(excpt)
     end
     
     def at_tracing(context, file, line)
       @printer.print_trace(context, file, line)
     end
     
     def at_line(context, file, line)
       @printer.print_at_line(file, line) if context.nil? || context.stop_reason == :step
       @line=line
       @file =file
       @context = context
       @printer.print_debug("Stopping Thread %s", context.thread.to_s)
       @printer.print_debug("Threads equal: %s", Thread.current == context.thread)
       Thread.stop
       @printer.print_debug("Resumed Thread %s", context.thread.to_s)
       @line=nil
       @file = nil
       @context = nil
     end

     def at_line?
        @line
     end     
   end
 end

Version data entries

9 entries across 9 versions & 1 rubygems

Version Path
ruby-debug-ide-0.1.2 lib/ruby-debug/event_processor.rb
ruby-debug-ide-0.1.3 lib/ruby-debug/event_processor.rb
ruby-debug-ide-0.1.6 lib/ruby-debug/event_processor.rb
ruby-debug-ide-0.1.5 lib/ruby-debug/event_processor.rb
ruby-debug-ide-0.1.10 lib/ruby-debug/event_processor.rb
ruby-debug-ide-0.1.4 lib/ruby-debug/event_processor.rb
ruby-debug-ide-0.1.9 lib/ruby-debug/event_processor.rb
ruby-debug-ide-0.1.7 lib/ruby-debug/event_processor.rb
ruby-debug-ide-0.1.8 lib/ruby-debug/event_processor.rb