convert validations into simple classes