Class: Byebug::RemoteInterface
Overview
Interface class for remote use of byebug.
Instance Attribute Summary collapse
Attributes inherited from Interface
#command_queue, #restart_file
Instance Method Summary
collapse
Methods inherited from Interface
#errmsg
Constructor Details
Returns a new instance of RemoteInterface.
10
11
12
13
14
|
# File 'lib/byebug/interfaces/remote_interface.rb', line 10
def initialize(socket)
super()
@socket = socket
@history = History.new
end
|
Instance Attribute Details
#history ⇒ Object
Returns the value of attribute history.
8
9
10
|
# File 'lib/byebug/interfaces/remote_interface.rb', line 8
def history
@history
end
|
Instance Method Details
#close ⇒ Object
16
17
18
19
|
# File 'lib/byebug/interfaces/remote_interface.rb', line 16
def close
@socket.close
rescue IOError
end
|
#confirm(prompt) ⇒ Object
21
22
23
|
# File 'lib/byebug/interfaces/remote_interface.rb', line 21
def confirm(prompt)
send_command "CONFIRM #{prompt}"
end
|
#puts(message) ⇒ Object
29
30
31
|
# File 'lib/byebug/interfaces/remote_interface.rb', line 29
def puts(message)
@socket.puts(message)
end
|
#read_command(prompt) ⇒ Object
25
26
27
|
# File 'lib/byebug/interfaces/remote_interface.rb', line 25
def read_command(prompt)
send_command "PROMPT #{prompt}"
end
|