Class: Puppeteer::Browser::Version
- Inherits:
-
Object
- Object
- Puppeteer::Browser::Version
- Defined in:
- lib/puppeteer/browser.rb,
sig/puppeteer/browser.rbs
Instance Attribute Summary collapse
-
#js_version ⇒ Object
readonly
Returns the value of attribute js_version.
-
#product ⇒ Object
readonly
Returns the value of attribute product.
-
#protocol_version ⇒ Object
readonly
Returns the value of attribute protocol_version.
-
#revision ⇒ Object
readonly
Returns the value of attribute revision.
-
#user_agent ⇒ Object
readonly
Returns the value of attribute user_agent.
Class Method Summary collapse
Instance Method Summary collapse
-
#initialize(hash) ⇒ Version
constructor
A new instance of Version.
Constructor Details
#initialize(hash) ⇒ Version
Returns a new instance of Version.
579 580 581 582 583 584 585 |
# File 'lib/puppeteer/browser.rb', line 579 def initialize(hash) @protocol_version = hash['protocolVersion'] @product = hash['product'] @revision = hash['revision'] @user_agent = hash['userAgent'] @js_version = hash['jsVersion'] end |
Instance Attribute Details
#js_version ⇒ Object (readonly)
Returns the value of attribute js_version.
587 588 589 |
# File 'lib/puppeteer/browser.rb', line 587 def js_version @js_version end |
#product ⇒ Object (readonly)
Returns the value of attribute product.
587 588 589 |
# File 'lib/puppeteer/browser.rb', line 587 def product @product end |
#protocol_version ⇒ Object (readonly)
Returns the value of attribute protocol_version.
587 588 589 |
# File 'lib/puppeteer/browser.rb', line 587 def protocol_version @protocol_version end |
#revision ⇒ Object (readonly)
Returns the value of attribute revision.
587 588 589 |
# File 'lib/puppeteer/browser.rb', line 587 def revision @revision end |
#user_agent ⇒ Object (readonly)
Returns the value of attribute user_agent.
587 588 589 |
# File 'lib/puppeteer/browser.rb', line 587 def user_agent @user_agent end |
Class Method Details
.fetch(connection) ⇒ Puppeteer::Browser::Version
573 574 575 |
# File 'lib/puppeteer/browser.rb', line 573 def self.fetch(connection) new(connection.('Browser.getVersion')) end |