Class: Wego::Configuration
- Inherits:
-
Object
- Object
- Wego::Configuration
- Defined in:
- lib/wego/configuration.rb
Instance Attribute Summary collapse
-
#api_code ⇒ Object
Returns the value of attribute api_code.
-
#api_host ⇒ Object
Returns the value of attribute api_host.
-
#api_key ⇒ Object
Returns the value of attribute api_key.
Instance Method Summary collapse
- #api_keys ⇒ Object
-
#initialize ⇒ Configuration
constructor
A new instance of Configuration.
Constructor Details
#initialize ⇒ Configuration
Returns a new instance of Configuration.
7 8 9 |
# File 'lib/wego/configuration.rb', line 7 def initialize @api_host = "http://api.wego.com/hotels/api" end |
Instance Attribute Details
#api_code ⇒ Object
Returns the value of attribute api_code.
5 6 7 |
# File 'lib/wego/configuration.rb', line 5 def api_code @api_code end |
#api_host ⇒ Object
Returns the value of attribute api_host.
3 4 5 |
# File 'lib/wego/configuration.rb', line 3 def api_host @api_host end |
#api_key ⇒ Object
Returns the value of attribute api_key.
4 5 6 |
# File 'lib/wego/configuration.rb', line 4 def api_key @api_key end |
Instance Method Details
#api_keys ⇒ Object
11 12 13 |
# File 'lib/wego/configuration.rb', line 11 def api_keys { key: api_key, ts_code: api_code } end |