Module: AMEE::Rails

Defined in:
lib/amee/rails.rb

Defined Under Namespace

Modules: ClassMethods, InstanceMethods

Class Method Summary collapse

Class Method Details

.establish_connection(server, username, password) ⇒ Object



4
5
6
7
8
9
# File 'lib/amee/rails.rb', line 4

def self.establish_connection(server, username, password)
  # Connect
  $amee = AMEE::Connection.new(server, username, password)
  # Authenticate now to get it out of the way and to check settings
  $amee.authenticate
end

.included(base) ⇒ Object



11
12
13
# File 'lib/amee/rails.rb', line 11

def self.included(base)
  base.extend ClassMethods
end