code: public void addValidator(Validator validator, String errorKey) {
          if(!errors.containsKey(errorKey))
              errors.addValidator(errorKey, validator);
      }
docs: Binds a validator to an attribute if validation fails.
  
  @param errorKey key of error in errors map. Usually this is a name of attribute,
  but not limited to that, can be anything.
  
  @param validator -validator that failed validation.