Пример #1
0
 protected function doValidate($columns = null)
 {
     if (!$this->alreadyInValidation) {
         $this->alreadyInValidation = true;
         $retval = null;
         $failureMap = array();
         if ($this->aTestApplicant !== null) {
             if (!$this->aTestApplicant->validate($columns)) {
                 $failureMap = array_merge($failureMap, $this->aTestApplicant->getValidationFailures());
             }
         }
         if ($this->aRegionRelatedByPob !== null) {
             if (!$this->aRegionRelatedByPob->validate($columns)) {
                 $failureMap = array_merge($failureMap, $this->aRegionRelatedByPob->getValidationFailures());
             }
         }
         if ($this->aReligion !== null) {
             if (!$this->aReligion->validate($columns)) {
                 $failureMap = array_merge($failureMap, $this->aReligion->getValidationFailures());
             }
         }
         if ($this->aCountry !== null) {
             if (!$this->aCountry->validate($columns)) {
                 $failureMap = array_merge($failureMap, $this->aCountry->getValidationFailures());
             }
         }
         if ($this->aDegree !== null) {
             if (!$this->aDegree->validate($columns)) {
                 $failureMap = array_merge($failureMap, $this->aDegree->getValidationFailures());
             }
         }
         if ($this->aRegionRelatedByRegionId !== null) {
             if (!$this->aRegionRelatedByRegionId->validate($columns)) {
                 $failureMap = array_merge($failureMap, $this->aRegionRelatedByRegionId->getValidationFailures());
             }
         }
         if (($retval = TestApplicantParentsPeer::doValidate($this, $columns)) !== true) {
             $failureMap = array_merge($failureMap, $retval);
         }
         $this->alreadyInValidation = false;
     }
     return !empty($failureMap) ? $failureMap : true;
 }