| Class | Object |
| In: |
lib/sequel_core/core_ext.rb
|
| Parent: | Object |
Helpers from Metaid and a bit more
Objects are blank if they respond true to empty?
# File lib/sequel_core/core_ext.rb, line 108
108: def blank?
109: respond_to?(:empty?) && empty?
110: end
Returns true if the object is an instance of one of the classes
# File lib/sequel_core/core_ext.rb, line 113
113: def is_one_of?(*classes)
114: !!classes.find{|c| is_a?(c)}
115: end