Sha256: ebd0fe10b7f9ab6d2043e182b480004b73f346057c56f96d612aeb3f5a4943fe

Contents?: true

Size: 483 Bytes

Versions: 2

Compression:

Stored size: 483 Bytes

Contents

require 'representable/hash_methods'

module Representable::JSON
  module Hash
    include Representable::JSON
    include HashMethods
    
    def self.included(base)
      base.class_eval do
        include Representable
        extend ClassMethods
      end
    end
    
    
    module ClassMethods
      def values(options)
        hash :_self, options
      end
    end
    
    
    def definition_opts
      [:_self, :hash => true, :use_attributes => true]
    end
  end
end

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
representable-1.2.3 lib/representable/json/hash.rb
representable-1.2.2 lib/representable/json/hash.rb