Sha256: e237101267a2a655ff22198ebc31ea72c66105d85d54e044cbf6d5c0d42f470c

Contents?: true

Size: 355 Bytes

Versions: 61

Compression:

Stored size: 355 Bytes

Contents

# encoding: UTF-8
module MongoMapper
  module Plugins
    module Inspect
      module InstanceMethods
        def inspect
          attributes_as_nice_string = key_names.collect do |name|
            "#{name}: #{self[name].inspect}"
          end.join(", ")
          "#<#{self.class} #{attributes_as_nice_string}>"
        end
      end
    end
  end
end

Version data entries

61 entries across 61 versions & 8 rubygems

Version Path
jonbell-mongo_mapper-0.8.6 lib/mongo_mapper/plugins/inspect.rb
ssherman-mongo_mapper-0.8.6 lib/mongo_mapper/plugins/inspect.rb
mongo_mapper-0.8.6 lib/mongo_mapper/plugins/inspect.rb
mongo_mapper-0.8.5 lib/mongo_mapper/plugins/inspect.rb
honkster-mongo_mapper-0.8.4 lib/mongo_mapper/plugins/inspect.rb
mongo_mapper-0.8.4 lib/mongo_mapper/plugins/inspect.rb
mongo_mapper-unstable-2010.08.19 lib/mongo_mapper/plugins/inspect.rb
mongo_mapper-unstable-2010.08.18 lib/mongo_mapper/plugins/inspect.rb
mongo_mapper-unstable-2010.08.17 lib/mongo_mapper/plugins/inspect.rb
mongo_mapper-unstable-2010.08.16 lib/mongo_mapper/plugins/inspect.rb
mongo_mapper-unstable-2010.08.15 lib/mongo_mapper/plugins/inspect.rb
mongo_mapper-unstable-2010.08.14 lib/mongo_mapper/plugins/inspect.rb
mongo_mapper-unstable-2010.08.13 lib/mongo_mapper/plugins/inspect.rb
mongo_mapper-unstable-2010.08.12 lib/mongo_mapper/plugins/inspect.rb
mongo_mapper-unstable-2010.08.11 lib/mongo_mapper/plugins/inspect.rb
mongo_mapper-unstable-2010.08.10 lib/mongo_mapper/plugins/inspect.rb
mongo_mapper-unstable-2010.08.09 lib/mongo_mapper/plugins/inspect.rb
mongo_mapper-0.8.3 lib/mongo_mapper/plugins/inspect.rb
mongo_mapper-unstable-2010.08.08 lib/mongo_mapper/plugins/inspect.rb
mongo_mapper-unstable-2010.08.06 lib/mongo_mapper/plugins/inspect.rb