Sha256: 39cd9567d50d3ed2fd9472d23b8d451f4946fd92fd98e19abc8e2f5b79db2bdc

Contents?: true

Size: 715 Bytes

Versions: 1

Compression:

Stored size: 715 Bytes

Contents

$:.unshift(File.dirname(__FILE__)) unless
  $:.include?(File.dirname(__FILE__)) || $:.include?(File.expand_path(File.dirname(__FILE__)))

require 'mongo'
require 'set'
require 'uuidtools'

require 'magent/utils'
require 'magent/generic_channel'
require 'magent/channel'
require 'magent/push'
require 'magent/actor'
require 'magent/processor'

module Magent
  VERSION = '0.2'

  def self.connection
    @@connection ||= Mongo::Connection.new(nil, nil, :auto_reconnect => true)
  end

  def self.connection=(new_connection)
    @@connection = new_connection
  end

  def self.database=(name)
    @@database = Magent.connection.db(name)
  end

  def self.database
    @@database
  end
end

Magent.database = 'magent'

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
magent-0.2 lib/magent.rb