Module: Virtus::Attribute::Collection::MemberCoercion
Overview
Default coercion method for collection members used by Array and Set
Instance Method Summary collapse
-
#coerce_and_append_member(collection, entry) ⇒ Array, Set
private
Coerce a member of a source collection and append it to the target collection.
Instance Method Details
#coerce_and_append_member(collection, entry) ⇒ Array, Set
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
Coerce a member of a source collection and append it to the target collection
109 110 111 |
# File 'lib/virtus/attribute/collection.rb', line 109 def coerce_and_append_member(collection, entry) collection << @member_type_instance.coerce(entry) end |