Module: Chronatog::Client

Defined in:
lib/chronatog/client.rb,
lib/chronatog/client/version.rb

Defined Under Namespace

Classes: Connection, Fake

Constant Summary collapse

VERSION =
"0.2.0"

Class Method Summary collapse

Class Method Details

.connectionObject



14
15
16
# File 'lib/chronatog/client.rb', line 14

def self.connection
  @connection or raise "connection not setup! yet"
end

.setup!(service_url, auth_username, auth_password) ⇒ Object



6
7
8
9
10
11
12
# File 'lib/chronatog/client.rb', line 6

def self.setup!(service_url, auth_username, auth_password)
  if service_url == "in-memory"
    @connection = Fake.new
  else
    @connection = Connection.new(service_url, auth_username, auth_password)
  end
end