Module: Virtus::Attribute::Coercible

Defined in:
lib/virtus/attribute/coercible.rb

Overview

Attribute extension providing coercion when setting an attribute value

Instance Method Summary collapse

Instance Method Details

#set(instance, value) ⇒ Object

Coerce value before setting

See Also:



13
14
15
# File 'lib/virtus/attribute/coercible.rb', line 13

def set(instance, value)
  super(instance, coerce(value))
end