protected function doValidate($columns = null) { if (!$this->alreadyInValidation) { $this->alreadyInValidation = true; $retval = null; $failureMap = array(); if ($this->aCatTemplate !== null) { if (!$this->aCatTemplate->validate($columns)) { $failureMap = array_merge($failureMap, $this->aCatTemplate->getValidationFailures()); } } if (($retval = CatCategoryPeer::doValidate($this, $columns)) !== true) { $failureMap = array_merge($failureMap, $retval); } if ($this->collCatalogs !== null) { foreach ($this->collCatalogs as $referrerFK) { if (!$referrerFK->validate($columns)) { $failureMap = array_merge($failureMap, $referrerFK->getValidationFailures()); } } } if ($this->collCirRegulations !== null) { foreach ($this->collCirRegulations as $referrerFK) { if (!$referrerFK->validate($columns)) { $failureMap = array_merge($failureMap, $referrerFK->getValidationFailures()); } } } $this->alreadyInValidation = false; } return !empty($failureMap) ? $failureMap : true; }