Class: WebkitRemote::Browser::Tab
- Inherits:
-
Object
- Object
- WebkitRemote::Browser::Tab
- Defined in:
- lib/webkit_remote/browser.rb
Overview
References a tab open in a Webkit process with a remote debugging server.
Instance Attribute Summary collapse
-
#browser ⇒ Webkit::Remote
readonly
Connection to the browser that this tab belongs to.
-
#debug_url ⇒ String
readonly
URL of the tab’s remote debugging endpoint.
-
#title ⇒ String?
readonly
Title of the Web page open in the browser tab.
-
#url ⇒ String?
readonly
URL of the Web page open in the browser tab.
Instance Method Summary collapse
-
#initialize(browser, debug_url, metadata) ⇒ Tab
constructor
Creates a tab reference.
Constructor Details
#initialize(browser, debug_url, metadata) ⇒ Tab
Creates a tab reference.
144 145 146 147 148 149 |
# File 'lib/webkit_remote/browser.rb', line 144 def initialize(browser, debug_url, ) @browser = browser @debug_url = debug_url @title = [:title] @url = [:url] end |
Instance Attribute Details
#browser ⇒ Webkit::Remote (readonly)
Returns connection to the browser that this tab belongs to.
124 125 126 |
# File 'lib/webkit_remote/browser.rb', line 124 def browser @browser end |
#debug_url ⇒ String (readonly)
Returns URL of the tab’s remote debugging endpoint.
127 128 129 |
# File 'lib/webkit_remote/browser.rb', line 127 def debug_url @debug_url end |
#title ⇒ String? (readonly)
Returns title of the Web page open in the browser tab.
130 131 132 |
# File 'lib/webkit_remote/browser.rb', line 130 def title @title end |
#url ⇒ String? (readonly)
Returns URL of the Web page open in the browser tab.
133 134 135 |
# File 'lib/webkit_remote/browser.rb', line 133 def url @url end |