Class: Pingdom::ServerTime
Instance Attribute Summary collapse
-
#servertime ⇒ Object
Returns the value of attribute servertime.
Attributes inherited from Base
Class Method Summary collapse
Methods inherited from Base
#add, all, body, client, collection, collection_type, error?, find, #get, #initialize, limited, params, params=, parse, permit, status, total, update_client
Constructor Details
This class inherits a constructor from Pingdom::Base
Instance Attribute Details
#servertime ⇒ Object
Returns the value of attribute servertime.
29 30 31 |
# File 'lib/pingdom/server_time.rb', line 29 def servertime @servertime end |
Class Method Details
.get ⇒ Object
11 12 13 14 15 16 17 18 19 20 |
# File 'lib/pingdom/server_time.rb', line 11 def get parse client.get( path: path ) if body.include?('servertime') server_time=self.new body end server_time end |
.path ⇒ Object
7 8 9 |
# File 'lib/pingdom/server_time.rb', line 7 def path '/servertime' end |
.time ⇒ Object
22 23 24 |
# File 'lib/pingdom/server_time.rb', line 22 def time get.servertime end |