Methods

AppConfig::Storage::Mongo

Mongo storage method.

Constants

DEFAULTS

Public Class Methods

new(options) click to toggle source
# File lib/app_config/storage/mongo.rb, line 18
def initialize(options)
  @connected = false
  @options = DEFAULTS.merge(options)
  setup_connection
  fetch_data!
end

Public Instance Methods

[](key) click to toggle source
# File lib/app_config/storage/mongo.rb, line 25
def [](key)
  @data[key]
end
[]=(key, value) click to toggle source
# File lib/app_config/storage/mongo.rb, line 29
def []=(key, value)
  @data[key] = value
  save!
end
empty?() click to toggle source
# File lib/app_config/storage/mongo.rb, line 34
def empty?
  @data.empty?
end

[Validate]

Generated with the Darkfish Rdoc Generator 2.