Class: Debugger::Xml::Ide::Processor

Inherits:
Processor
  • Object
show all
Defined in:
lib/debugger/xml/ide/processor.rb

Direct Known Subclasses

Vim::Processor

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(interface) ⇒ Processor

Returns a new instance of Processor.



9
10
11
12
13
# File 'lib/debugger/xml/ide/processor.rb', line 9

def initialize(interface)
  @mutex = Mutex.new
  @interface = interface
  @display = []
end

Instance Attribute Details

#contextObject (readonly)

Returns the value of attribute context.



8
9
10
# File 'lib/debugger/xml/ide/processor.rb', line 8

def context
  @context
end

#displayObject (readonly)

Returns the value of attribute display.



8
9
10
# File 'lib/debugger/xml/ide/processor.rb', line 8

def display
  @display
end

#fileObject (readonly)

Returns the value of attribute file.



8
9
10
# File 'lib/debugger/xml/ide/processor.rb', line 8

def file
  @file
end

#lineObject (readonly)

Returns the value of attribute line.



8
9
10
# File 'lib/debugger/xml/ide/processor.rb', line 8

def line
  @line
end

Instance Method Details

#at_breakpoint(context, breakpoint) ⇒ Object



15
16
17
18
19
# File 'lib/debugger/xml/ide/processor.rb', line 15

def at_breakpoint(context, breakpoint)
  raise "@last_breakpoint supposed to be nil. is #{@last_breakpoint}" if @last_breakpoint
  # at_breakpoint is immediately followed by #at_line event. So postpone breakpoint printing until #at_line.
  @last_breakpoint = breakpoint
end

#at_catchpoint(context, excpt) ⇒ Object

TODO: Catching exceptions doesn’t work so far, need to fix



23
24
# File 'lib/debugger/xml/ide/processor.rb', line 23

def at_catchpoint(context, excpt)
end

#at_line(context, file, line) ⇒ Object



30
31
32
33
34
35
# File 'lib/debugger/xml/ide/processor.rb', line 30

def at_line(context, file, line)
  if context.nil? || context.stop_reason == :step
    print_file_line(context, file, line)
  end
  line_event(context, file, line)
end

#at_line?Boolean

Returns:

  • (Boolean)


44
45
46
# File 'lib/debugger/xml/ide/processor.rb', line 44

def at_line?
  !!@line
end

#at_return(context, file, line) ⇒ Object



38
39
40
41
42
# File 'lib/debugger/xml/ide/processor.rb', line 38

def at_return(context, file, line)
  print_file_line(context, file, line)
  context.stop_frame = -1
  line_event(context, file, line)
end

#at_tracing(*args) ⇒ Object

We don’t have tracing for IDE



27
28
# File 'lib/debugger/xml/ide/processor.rb', line 27

def at_tracing(*args)
end