Module: EncryptedStore

Defined in:
lib/encrypted_store.rb,
lib/encrypted_store/config.rb,
lib/encrypted_store/errors.rb,
lib/encrypted_store/railtie.rb,
lib/encrypted_store/version.rb,
lib/encrypted_store/instance.rb,
lib/encrypted_store/crypto_hash.rb,
lib/encrypted_store/active_record.rb,
lib/encrypted_store/active_record/mixin.rb,
lib/encrypted_store/active_record/encryption_key.rb,
lib/encrypted_store/active_record/encryption_key_salt.rb,
lib/generators/encrypted_store/install/install_generator.rb,
lib/generators/encrypted_store/encrypt_table/encrypt_table_generator.rb,
lib/generators/encrypted_store/upgrade/ZeroOneFive/zero_one_five_generator.rb

Defined Under Namespace

Modules: ActiveRecord, Errors, Generators Classes: Config, CryptoHash, Instance, Railtie

Constant Summary collapse

VERSION =
'0.2.8'

Class Method Summary collapse

Class Method Details

.included(base) ⇒ Object



12
13
14
15
16
17
18
# File 'lib/encrypted_store.rb', line 12

def included(base)
  if defined?(::ActiveRecord) && base < ::ActiveRecord::Base
    base.send(:include, ActiveRecord::Mixin)
  else
    fail Errors::UnsupportedModelError
  end
end

.instanceObject



24
25
26
# File 'lib/encrypted_store.rb', line 24

def instance
  @__instance ||= Instance.new
end

.method_missing(meth, *args, &block) ⇒ Object



20
21
22
# File 'lib/encrypted_store.rb', line 20

def method_missing(meth, *args, &block)
  instance.send(meth, *args, &block)
end