Class: Concourse::Http::Request
- Inherits:
-
Object
- Object
- Concourse::Http::Request
- Defined in:
- lib/concourse/http.rb
Instance Attribute Summary collapse
-
#body ⇒ Object
readonly
Returns the value of attribute body.
-
#headers ⇒ Object
readonly
Returns the value of attribute headers.
-
#url ⇒ Object
readonly
Returns the value of attribute url.
Instance Method Summary collapse
- #==(other) ⇒ Object
- #eql?(other) ⇒ Boolean
- #hash ⇒ Object
-
#initialize(url, headers = {}, body = nil) ⇒ Request
constructor
A new instance of Request.
Constructor Details
#initialize(url, headers = {}, body = nil) ⇒ Request
Returns a new instance of Request.
8 9 10 11 12 |
# File 'lib/concourse/http.rb', line 8 def initialize(url, headers = {}, body = nil) @url = url @headers = headers @body = body end |
Instance Attribute Details
#body ⇒ Object (readonly)
Returns the value of attribute body.
6 7 8 |
# File 'lib/concourse/http.rb', line 6 def body @body end |
#headers ⇒ Object (readonly)
Returns the value of attribute headers.
6 7 8 |
# File 'lib/concourse/http.rb', line 6 def headers @headers end |
#url ⇒ Object (readonly)
Returns the value of attribute url.
6 7 8 |
# File 'lib/concourse/http.rb', line 6 def url @url end |
Instance Method Details
#==(other) ⇒ Object
14 15 16 |
# File 'lib/concourse/http.rb', line 14 def ==(other) other.class == self.class && other.state == state end |
#eql?(other) ⇒ Boolean
18 19 20 |
# File 'lib/concourse/http.rb', line 18 def eql?(other) self == other end |
#hash ⇒ Object
22 23 24 |
# File 'lib/concourse/http.rb', line 22 def hash state.hash end |