Class: Bestchange::Api
- Inherits:
-
Object
- Object
- Bestchange::Api
- Defined in:
- lib/bestchange/api.rb
Constant Summary collapse
- BASE_URI =
'http://api.bestchange.ru/info.zip'
Instance Attribute Summary collapse
-
#conn ⇒ Object
readonly
Returns the value of attribute conn.
Instance Method Summary collapse
-
#initialize(conn = default_conn) ⇒ Api
constructor
A new instance of Api.
- #request(request = default_request) ⇒ Object
Constructor Details
#initialize(conn = default_conn) ⇒ Api
Returns a new instance of Api.
13 14 15 |
# File 'lib/bestchange/api.rb', line 13 def initialize(conn = default_conn) @conn = conn end |
Instance Attribute Details
#conn ⇒ Object (readonly)
Returns the value of attribute conn.
17 18 19 |
# File 'lib/bestchange/api.rb', line 17 def conn @conn end |
Instance Method Details
#request(request = default_request) ⇒ Object
19 20 21 |
# File 'lib/bestchange/api.rb', line 19 def request(request = default_request) conn.request(request) end |