Module: Veto::Validator::ClassMethods
- Defined in:
- lib/veto/validator.rb
Instance Method Summary collapse
- #check_with(val) ⇒ Object
- #checker ⇒ Object
- #validate(*args) ⇒ Object
- #validates(*args) ⇒ Object
- #with_options(*args, &block) ⇒ Object
Instance Method Details
#check_with(val) ⇒ Object
20 21 22 |
# File 'lib/veto/validator.rb', line 20 def check_with(val) @checker = val end |
#checker ⇒ Object
24 25 26 |
# File 'lib/veto/validator.rb', line 24 def checker @checker ||= build_checker end |
#validate(*args) ⇒ Object
16 17 18 |
# File 'lib/veto/validator.rb', line 16 def validate(*args) checker.validate(*args) end |
#validates(*args) ⇒ Object
12 13 14 |
# File 'lib/veto/validator.rb', line 12 def validates(*args) checker.validates(*args) end |
#with_options(*args, &block) ⇒ Object
8 9 10 |
# File 'lib/veto/validator.rb', line 8 def (*args, &block) checker.(*args, &block) end |