Class: Konmari::Routes::Configuration
- Inherits:
-
Object
- Object
- Konmari::Routes::Configuration
- Defined in:
- lib/konmari/routes/configuration.rb
Overview
The configuration object holding the necessary data for Loader to do its thing.
Instance Attribute Summary collapse
-
#application ⇒ Application
The application to build these routes for (defaults to
Rails.applicationif using Rails). -
#logger ⇒ Logger
The logger to use for debugging purposes (optional, defaults to
Rails.loggerif using Rails). -
#routes_path ⇒ Pathname
The folder containing the routing hierarchy to build.
Instance Attribute Details
#application ⇒ Application
Returns the application to build these routes for (defaults to Rails.application if using Rails).
16 17 18 |
# File 'lib/konmari/routes/configuration.rb', line 16 def application @application || (Object.const_defined?(:Rails) ? Rails.application : nil) end |
#logger ⇒ Logger
Returns the logger to use for debugging purposes (optional, defaults to Rails.logger if using Rails).
11 12 13 |
# File 'lib/konmari/routes/configuration.rb', line 11 def logger @logger || (Object.const_defined?(:Rails) ? Rails.logger : nil) end |
#routes_path ⇒ Pathname
Returns the folder containing the routing hierarchy to build.
7 8 9 |
# File 'lib/konmari/routes/configuration.rb', line 7 def routes_path @routes_path end |