Class: AlphaValidator

Inherits:
BaseValidator show all
Defined in:
lib/lite/validators/alpha_validator.rb

Direct Known Subclasses

AlphaNumericValidator

Constant Summary collapse

CASES =
{
  lower: 'a-z',
  upper: 'A-Z',
  any: 'A-Za-z'
}.freeze

Instance Method Summary collapse

Instance Method Details

#validate_each(record, attribute, value) ⇒ Object



11
12
13
14
# File 'lib/lite/validators/alpha_validator.rb', line 11

def validate_each(record, attribute, value)
  assert_valid_case!
  super
end