method
select
v4.2.7 -
Show latest stable
- Class:
ActiveRecord::LazyAttributeHash
select()public
No documentation available.
# File activerecord/lib/active_record/attribute_set/builder.rb, line 59
def select
keys = types.keys | values.keys | delegate_hash.keys
keys.each_with_object({}) do |key, hash|
attribute = self[key]
if yield(key, attribute)
hash[key] = attribute
end
end
end