Module: Virtus::ValueObject::AllowedWriterMethods
- Defined in:
- lib/virtus/value_object.rb
Instance Method Summary collapse
-
#allowed_writer_methods ⇒ Set
private
The list of writer methods that can be mass-assigned to in #attributes=.
Instance Method Details
#allowed_writer_methods ⇒ 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.
The list of writer methods that can be mass-assigned to in #attributes=
89 90 91 92 93 94 95 96 |
# File 'lib/virtus/value_object.rb', line 89 def allowed_writer_methods @allowed_writer_methods ||= begin allowed_writer_methods = super allowed_writer_methods += attribute_set.map{|attr| "#{attr.name}="} allowed_writer_methods.to_set.freeze end end |