method
select
v6.0.0 -
Show latest stable
- Class:
ActiveModel::LazyAttributeHash
select()public
No documentation available.
# File activemodel/lib/active_model/attribute_set/builder.rb, line 60
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