protected function addFormValidators()
 {
     $this->form->addValidator(new CoreFormValidatorNotEmpty('userPassword'));
     $this->form->addValidator(new CoreFormValidatorPasswordPattern('userPassword'));
     $this->form->addValidator(new CoreFormValidatorNotEmpty('userPasswordConfirm'));
     $this->form->addValidator(new CoreFormValidatorFieldsEqual(array('userPassword', 'userPasswordConfirm')));
 }
 protected function addLoginFormValidators()
 {
     $this->loginForm->addValidator(new CoreFormValidatorNotEmpty('userEmail'));
     $this->loginForm->addValidator(new CoreFormValidatorMaxTextLength('userEmail', 40));
     $this->loginForm->addValidator(new CoreFormValidatorNotEmpty('userPassword'));
     $this->loginForm->addValidator(new CoreFormValidatorMaxTextLength('userPassword', 40));
 }
 protected function checkBasicValidation()
 {
     $fileCategory = $this->form->getField('fileCategory')->getValue();
     $this->form->addValidator(new CoreFormValidatorFileBasicCheck('_fileUpload', null, $fileCategory));
     $this->form->addValidator(new CoreFormValidatorNotEmptyFieldset(array('id', '_tmpId')));
     $this->form->addValidator(new CoreFormValidatorFieldsetXOr(array('id', '_tmpId')));
     $this->messageManager = $this->form->getValidationResults();
 }