Class: Headhunter::LocalResponse
- Inherits:
-
Object
- Object
- Headhunter::LocalResponse
- Defined in:
- lib/headhunter/css_validator.rb
Instance Attribute Summary collapse
-
#body ⇒ Object
readonly
Returns the value of attribute body.
Instance Method Summary collapse
- #[](key) ⇒ Object
-
#initialize(body) ⇒ LocalResponse
constructor
A new instance of LocalResponse.
Constructor Details
#initialize(body) ⇒ LocalResponse
8 9 10 11 |
# File 'lib/headhunter/css_validator.rb', line 8 def initialize(body) @body = body @headers = {'x-w3c-validator-status' => valid?(body)} end |
Instance Attribute Details
#body ⇒ Object (readonly)
Returns the value of attribute body.
6 7 8 |
# File 'lib/headhunter/css_validator.rb', line 6 def body @body end |
Instance Method Details
#[](key) ⇒ Object
13 14 15 |
# File 'lib/headhunter/css_validator.rb', line 13 def [](key) @headers[key] end |