Module: WebkitRemote::Client::Console
- Included in:
- WebkitRemote::Client
- Defined in:
- lib/webkit_remote/client/console.rb
Overview
API for the Console domain.
Instance Attribute Summary collapse
-
#console_events ⇒ Boolean
True if the debugger generates Console.* events.
- #console_messages ⇒ Array<WebkitRemote::Client::ConsoleMessage> readonly
Instance Method Summary collapse
-
#clear_console ⇒ WebkitRemote::Client
Removes all the messages in the console.
- #console_add_message(message) ⇒ Object
- #console_cleared ⇒ Object
- #initialize_console ⇒ Object
Instance Attribute Details
#console_events ⇒ Boolean
Returns true if the debugger generates Console.* events.
30 31 32 |
# File 'lib/webkit_remote/client/console.rb', line 30 def console_events @console_events end |
#console_messages ⇒ Array<WebkitRemote::Client::ConsoleMessage> (readonly)
33 34 35 |
# File 'lib/webkit_remote/client/console.rb', line 33 def @console_messages end |
Instance Method Details
#clear_console ⇒ WebkitRemote::Client
Removes all the messages in the console.
23 24 25 26 27 |
# File 'lib/webkit_remote/client/console.rb', line 23 def clear_console @rpc.call 'Console.clearMessages' console_cleared self end |
#console_add_message(message) ⇒ Object
36 37 38 |
# File 'lib/webkit_remote/client/console.rb', line 36 def () @console_messages << end |
#console_cleared ⇒ Object
41 42 43 44 |
# File 'lib/webkit_remote/client/console.rb', line 41 def console_cleared @console_messages.each(&:release_params) @console_messages.clear end |
#initialize_console ⇒ Object
47 48 49 50 |
# File 'lib/webkit_remote/client/console.rb', line 47 def initialize_console @console_events = false @console_messages = [] end |