class ActiveModel::BlockValidator

def initialize(options, &block)

:nodoc:
and call this block for each attribute being validated. +validates_each+ uses this validator.
+BlockValidator+ is a special +EachValidator+ which receives a block on initialization
def initialize(options, &block)
  @block = block
  super
end