Class: Depsio::Configuration
- Inherits:
-
Object
- Object
- Depsio::Configuration
- Defined in:
- lib/depsio/configuration.rb
Overview
Used to set up and modify settings for the notifier.
Instance Attribute Summary collapse
-
#api_key ⇒ Object
Returns the value of attribute api_key.
-
#enabled_environments ⇒ Object
Returns the value of attribute enabled_environments.
-
#endpoint ⇒ Object
Returns the value of attribute endpoint.
-
#logger ⇒ Object
Returns the value of attribute logger.
Instance Method Summary collapse
- #enabled? ⇒ Boolean
-
#initialize ⇒ Configuration
constructor
A new instance of Configuration.
Constructor Details
#initialize ⇒ Configuration
Returns a new instance of Configuration.
6 7 8 |
# File 'lib/depsio/configuration.rb', line 6 def initialize @enabled_environments = %w(production) end |
Instance Attribute Details
#api_key ⇒ Object
Returns the value of attribute api_key.
4 5 6 |
# File 'lib/depsio/configuration.rb', line 4 def api_key @api_key end |
#enabled_environments ⇒ Object
Returns the value of attribute enabled_environments.
4 5 6 |
# File 'lib/depsio/configuration.rb', line 4 def enabled_environments @enabled_environments end |
#endpoint ⇒ Object
Returns the value of attribute endpoint.
4 5 6 |
# File 'lib/depsio/configuration.rb', line 4 def endpoint @endpoint end |
#logger ⇒ Object
Returns the value of attribute logger.
4 5 6 |
# File 'lib/depsio/configuration.rb', line 4 def logger @logger end |
Instance Method Details
#enabled? ⇒ Boolean
14 15 16 |
# File 'lib/depsio/configuration.rb', line 14 def enabled? enabled_environments.include?(::Rails.env) end |