module Abstract::Extensions::Object
Object
extensions
Public Instance Methods
blank?()
click to toggle source
Check if object is blank @return [Trueclass, FalseClass] - is object nil or empty
# File lib/abstracts.rb, line 9 def blank? respond_to?(:empty?) && empty? || !self end
default_hash()
click to toggle source
Add default proc to Hash @return [Hash] - Hash with default proc
# File lib/abstracts.rb, line 15 def default_hash Hash.new do |hash, key| hash[key] = Hash.new(&hash.default_proc) end end