Class: Janus::DbConsoleConfig

Inherits:
Object
  • Object
show all
Defined in:
lib/janus-ar/db_console_config.rb

Instance Method Summary collapse

Constructor Details

#initialize(config) ⇒ DbConsoleConfig

Returns a new instance of DbConsoleConfig.



5
6
7
# File 'lib/janus-ar/db_console_config.rb', line 5

def initialize(config)
  @_config = config.configuration_hash
end

Instance Method Details

#configuration_hashObject



9
10
11
# File 'lib/janus-ar/db_console_config.rb', line 9

def configuration_hash
  @_config[:janus]['replica'].symbolize_keys
end

#databaseObject



13
14
15
# File 'lib/janus-ar/db_console_config.rb', line 13

def database
  @_config[:database]
end