lib/toy.rb in toystore-0.8.1 vs lib/toy.rb in toystore-0.8.2

- old
+ new

@@ -40,16 +40,35 @@ model.store.clear if model.has_store? model.identity_map.clear if model.identity_map_on? end end + def logger + @logger + end + + def logger? + @logger.present? + end + + def logger=(logger) + @logger = logger + end + + def key_factory=(key_factory) + @key_factory = key_factory + end + + def key_factory + @key_factory ||= Toy::Identity::UUIDKeyFactory.new + end + module Middleware autoload 'IdentityMap', 'toy/middleware/identity_map' end end require 'toy/exceptions' -require 'toy/connection' require 'toy/attribute' require 'toy/attributes' require 'toy/callbacks' require 'toy/dirty' require 'toy/dolly'