Sha256: db448b36ae8619e27da2e6a8bf0298d7e0fcad13acaaf75c45b9474a6d475789

Contents?: true

Size: 385 Bytes

Versions: 1

Compression:

Stored size: 385 Bytes

Contents

module Yapper::Config
  COLLECTION = '_config'
  extend self

  mattr_accessor :db_version

  def self.get(key)
    Yapper::DB.instance.execute do |txn|
      txn.objectForKey(key.to_s, inCollection: '_config') 
    end
  end

  def self.set(key, value)
      Yapper::DB.instance.execute do |txn|
        txn.setObject(value, forKey: key, inCollection: COLLECTION)
      end
  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
motion-yapper-0.0.1 lib/yapper/config.rb