Module: Linodians
- Defined in:
- lib/linodians.rb,
lib/linodians/group.rb,
lib/linodians/version.rb,
lib/linodians/employee.rb
Overview
Define the version
Defined Under Namespace
Constant Summary collapse
- DATA_URL =
'https://www.linode.com/employees'- PHOTO_URL =
'https://www.linode.com/media/images/employees/%s.png'- VERSION =
'0.0.4'
Class Method Summary collapse
- .download_data ⇒ Object
-
.new(*args) ⇒ Object
Insert a helper .new() method for creating a new Group object.
Class Method Details
.download_data ⇒ Object
17 18 19 20 21 22 |
# File 'lib/linodians.rb', line 17 def download_data Nokogiri::HTML(open(DATA_URL)).css('.employee-display').map do |block| data = parse_user(block).merge (block) Employee.new data end end |
.new(*args) ⇒ Object
Insert a helper .new() method for creating a new Group object
13 14 15 |
# File 'lib/linodians.rb', line 13 def new(*args) self::Group.new(*args) end |