Class: Sr71::HttpCheck::ConnectionTimer
- Inherits:
-
Object
- Object
- Sr71::HttpCheck::ConnectionTimer
- Defined in:
- lib/sr71/http_check.rb
Instance Attribute Summary collapse
-
#connect_time ⇒ Object
readonly
Returns the value of attribute connect_time.
Instance Method Summary collapse
-
#initialize(&block) ⇒ ConnectionTimer
constructor
A new instance of ConnectionTimer.
- #request(client, head, body) ⇒ Object
- #response(resp) ⇒ Object
Constructor Details
#initialize(&block) ⇒ ConnectionTimer
Returns a new instance of ConnectionTimer.
5 6 7 |
# File 'lib/sr71/http_check.rb', line 5 def initialize(&block) @callback = block end |
Instance Attribute Details
#connect_time ⇒ Object (readonly)
Returns the value of attribute connect_time.
4 5 6 |
# File 'lib/sr71/http_check.rb', line 4 def connect_time @connect_time end |
Instance Method Details
#request(client, head, body) ⇒ Object
9 10 11 12 |
# File 'lib/sr71/http_check.rb', line 9 def request(client, head, body) @callback.call [head, body] end |
#response(resp) ⇒ Object
14 15 |
# File 'lib/sr71/http_check.rb', line 14 def response(resp) end |