Class: FmStore::Connection
- Inherits:
-
Object
- Object
- FmStore::Connection
- Defined in:
- lib/fm_store/connection.rb
Class Method Summary collapse
-
.establish_connection(layout) ⇒ Object
Returns an Rfm::Layout which further data request can begin.
Class Method Details
.establish_connection(layout) ⇒ Object
Returns an Rfm::Layout which further data request can begin
5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 |
# File 'lib/fm_store/connection.rb', line 5 def self.establish_connection(layout) layout_name = layout.layout database_name = layout.database # Get the config from fm_store.yml config = FmStore::Config.instance server = Rfm::Server.new({ :host => config.host, :account_name => config.account_name, :password => config.password, :ssl => config.ssl, :log_actions => config.log_actions }) server[database_name][layout_name] end |