Class: Browser::Platform::ChromeOS
- Inherits:
-
Base
- Object
- Base
- Browser::Platform::ChromeOS
show all
- Defined in:
- lib/browser/platform/chrome_os.rb
Instance Attribute Summary
Attributes inherited from Base
#ua
Instance Method Summary
collapse
Methods inherited from Base
#initialize
Instance Method Details
#id ⇒ Object
13
14
15
|
# File 'lib/browser/platform/chrome_os.rb', line 13
def id
:chrome_os
end
|
#match? ⇒ Boolean
5
6
7
|
# File 'lib/browser/platform/chrome_os.rb', line 5
def match?
ua =~ /CrOS/
end
|
#name ⇒ Object
9
10
11
|
# File 'lib/browser/platform/chrome_os.rb', line 9
def name
"Chrome OS"
end
|
#version ⇒ Object
17
18
19
|
# File 'lib/browser/platform/chrome_os.rb', line 17
def version
ua[/CrOS(?: x86_64)? ([\d.]+)/, 1]
end
|