Sha256: 22e39211d6f2a6ab075f50da7c4c6765ef8f3f8f435b9fbc4fdb946fd0b08f0e
Contents?: true
Size: 434 Bytes
Versions: 2
Compression:
Stored size: 434 Bytes
Contents
# ******************************************************************************* # OpenStudio(R), Copyright (c) Alliance for Sustainable Energy, LLC. # See also https://openstudio.net/license # ******************************************************************************* class Hash def deep_find(key) key?(key) ? self[key] : values.reduce(nil) { |memo, v| memo ||= v.deep_find(key) if v.respond_to?(:deep_find) } end end
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
openstudio-analysis-1.3.5 | lib/openstudio/helpers/hash.rb |
openstudio-analysis-1.3.4 | lib/openstudio/helpers/hash.rb |