Added validation class and rules

validation and rules