Class: Zenlight::Configuration
- Inherits:
-
Object
- Object
- Zenlight::Configuration
- Defined in:
- lib/zenlight/configuration.rb
Instance Attribute Summary collapse
-
#api_path ⇒ Object
Returns the value of attribute api_path.
-
#email ⇒ Object
Returns the value of attribute email.
-
#password ⇒ Object
Returns the value of attribute password.
-
#rpm ⇒ Object
Returns the value of attribute rpm.
-
#subdomain ⇒ Object
Returns the value of attribute subdomain.
-
#token ⇒ Object
Returns the value of attribute token.
-
#uri ⇒ Object
readonly
Returns the value of attribute uri.
Instance Method Summary collapse
- #[](value) ⇒ Object
-
#initialize ⇒ Configuration
constructor
A new instance of Configuration.
Constructor Details
#initialize ⇒ Configuration
Returns a new instance of Configuration.
14 15 16 17 18 19 20 21 |
# File 'lib/zenlight/configuration.rb', line 14 def initialize self.rpm = 700 self.api_path = "/api/v2" self.subdomain = ENV['ZENLIGHT_SUBDOMAIN'] self.email = ENV['ZENLIGHT_EMAIL'] self.password = ENV['ZENLIGHT_PASSWORD'] self.token = ENV['ZENLIGHT_TOKEN'] end |
Instance Attribute Details
#api_path ⇒ Object
Returns the value of attribute api_path.
6 7 8 |
# File 'lib/zenlight/configuration.rb', line 6 def api_path @api_path end |
#email ⇒ Object
Returns the value of attribute email.
11 12 13 |
# File 'lib/zenlight/configuration.rb', line 11 def email @email end |
#password ⇒ Object
Returns the value of attribute password.
12 13 14 |
# File 'lib/zenlight/configuration.rb', line 12 def password @password end |
#rpm ⇒ Object
Returns the value of attribute rpm.
5 6 7 |
# File 'lib/zenlight/configuration.rb', line 5 def rpm @rpm end |
#subdomain ⇒ Object
Returns the value of attribute subdomain.
4 5 6 |
# File 'lib/zenlight/configuration.rb', line 4 def subdomain @subdomain end |
#token ⇒ Object
Returns the value of attribute token.
13 14 15 |
# File 'lib/zenlight/configuration.rb', line 13 def token @token end |
#uri ⇒ Object (readonly)
Returns the value of attribute uri.
3 4 5 |
# File 'lib/zenlight/configuration.rb', line 3 def uri @uri end |
Instance Method Details
#[](value) ⇒ Object
22 23 24 |
# File 'lib/zenlight/configuration.rb', line 22 def [](value) self.public_send(value) end |