Sha256: 1b521c69e0e36cb59927449af263c30deaa250a4042d1a6c531ad8fc7abc002d

Contents?: true

Size: 373 Bytes

Versions: 1

Compression:

Stored size: 373 Bytes

Contents

module MongoMapper
  module Plugins
    module Inspect
      extend ActiveSupport::Concern
      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

1 entries across 1 versions & 1 rubygems

Version Path
mongo_mapper-rails3-0.7.0.1 lib/mongo_mapper/plugins/inspect.rb