Module: Pickle::Adapter::Base

Included in:
ActiveRecord::Base::PickleAdapter, DataMapper::Resource::PickleAdapter, Mongoid::Document::PickleAdapter
Defined in:
lib/pickle/adapter.rb

Overview

Include this module into your ORM adapter this will register the adapter with pickle and it will be picked up for you To create an adapter you should create an inner constant “PickleAdapter”

e.g. ActiveRecord::Base::PickleAdapter

See Also:

Class Method Summary (collapse)

Class Method Details

+ (Object) adapters

A collection of registered adapters



43
44
45
# File 'lib/pickle/adapter.rb', line 43

def self.adapters
  @@adapters ||= []
end

+ (Object) included(base)



38
39
40
# File 'lib/pickle/adapter.rb', line 38

def self.included(base)
  adapters << base
end