Sha256: 438719f9e0e1c782c95c80f8fbeb617c01ef42a5c8e82082c6e2dd607f9cca71

Contents?: true

Size: 249 Bytes

Versions: 21

Compression:

Stored size: 249 Bytes

Contents

class Hash
  def to_hash_map
    hm = java.util.HashMap.new
    if block_given?
      each do |key, value|
        hm.put(*yield(key, value))
      end
    else
      each do |key, value|
        hm.put key, value
      end
    end
    hm
  end
end

Version data entries

21 entries across 21 versions & 1 rubygems

Version Path
pacer-2.0.24-java lib/pacer/support/hash.rb
pacer-2.0.22-java lib/pacer/support/hash.rb
pacer-2.0.20-java lib/pacer/support/hash.rb
pacer-2.0.19-java lib/pacer/support/hash.rb
pacer-2.0.18-java lib/pacer/support/hash.rb
pacer-2.0.17-java lib/pacer/support/hash.rb
pacer-2.0.16-java lib/pacer/support/hash.rb
pacer-2.0.15-java lib/pacer/support/hash.rb
pacer-2.0.14-java lib/pacer/support/hash.rb
pacer-2.0.13-java lib/pacer/support/hash.rb
pacer-2.0.12-java lib/pacer/support/hash.rb
pacer-2.0.10-java lib/pacer/support/hash.rb
pacer-2.0.10.pre-java lib/pacer/support/hash.rb
pacer-2.0.8-java lib/pacer/support/hash.rb
pacer-2.0.6-java lib/pacer/support/hash.rb
pacer-2.0.4.pre-java lib/pacer/support/hash.rb
pacer-2.0.0.pre-java lib/pacer/support/hash.rb
pacer-1.6.0-java lib/pacer/support/hash.rb
pacer-1.5.4-java lib/pacer/support/hash.rb
pacer-1.5.3-java lib/pacer/support/hash.rb