Class: Validic::Extra

Inherits:
Object
  • Object
show all
Defined in:
lib/validic/extra.rb

Instance Method Summary collapse

Constructor Details

#initialize(attrs = {}) ⇒ Extra

Returns a new instance of Extra.



3
4
5
6
7
8
# File 'lib/validic/extra.rb', line 3

def initialize(attrs = {})
  attrs.each do |k, v|
    instance_variable_set("@#{k}", v)
    self.class.send(:attr_reader, k)
  end
end