Class: MultipleMan::Configuration
- Inherits:
-
Object
- Object
- MultipleMan::Configuration
- Defined in:
- lib/multiple_man/configuration.rb
Instance Attribute Summary collapse
-
#app_name ⇒ Object
Returns the value of attribute app_name.
-
#connection ⇒ Object
Returns the value of attribute connection.
-
#enabled ⇒ Object
Returns the value of attribute enabled.
-
#logger ⇒ Object
Returns the value of attribute logger.
-
#topic_name ⇒ Object
Returns the value of attribute topic_name.
Instance Method Summary collapse
-
#initialize ⇒ Configuration
constructor
A new instance of Configuration.
Constructor Details
#initialize ⇒ Configuration
Returns a new instance of Configuration.
4 5 6 7 8 |
# File 'lib/multiple_man/configuration.rb', line 4 def initialize self.topic_name = "multiple_man" self.app_name = Rails.application.class.parent.to_s if defined?(Rails) self.enabled = true end |
Instance Attribute Details
#app_name ⇒ Object
Returns the value of attribute app_name.
14 15 16 |
# File 'lib/multiple_man/configuration.rb', line 14 def app_name @app_name end |
#connection ⇒ Object
Returns the value of attribute connection.
14 15 16 |
# File 'lib/multiple_man/configuration.rb', line 14 def connection @connection end |
#enabled ⇒ Object
Returns the value of attribute enabled.
14 15 16 |
# File 'lib/multiple_man/configuration.rb', line 14 def enabled @enabled end |
#logger ⇒ Object
Returns the value of attribute logger.
10 11 12 |
# File 'lib/multiple_man/configuration.rb', line 10 def logger @logger ||= defined?(Rails) ? Rails.logger : Logger.new(STDOUT) end |
#topic_name ⇒ Object
Returns the value of attribute topic_name.
14 15 16 |
# File 'lib/multiple_man/configuration.rb', line 14 def topic_name @topic_name end |