class Sequel::Plugins::ValidationHelpersBlock::ValidationHelpersValidationsBlock

DSL class used inside attribute blocks. The only methods allowed inside the block are those supported by validation_helpers, and they specify the validations to run for the related attribute on the related object.

Constants

VALIDATION_HELPERS_1_ARG_METHODS

validation_helpers methods that require a leading argument

VALIDATION_HELPERS_NO_ARG_METHODS

validation_helpers methods that do not require a leading argument.

Public Class Methods

new(obj, attr, &block) click to toggle source

Store the object and attribute and instance_eval the block.

   # File lib/sequel/plugins/validation_helpers_block.rb
64 def initialize(obj, attr, &block)
65   @obj = obj
66   @attr = attr
67   instance_eval(&block)
68 end