/** * Saves a Profile. * * @param Profile $profile A Profile instance * * @return Boolean */ public function saveProfile(Profile $profile) { if (!($ret = $this->storage->write($profile)) && null !== $this->logger) { $this->logger->warning('Unable to store the profiler information.'); } return $ret; }
/** * Saves a Profile. * * @param Profile $profile A Profile instance * * @return bool */ public function saveProfile(Profile $profile) { // late collect foreach ($profile->getCollectors() as $collector) { if ($collector instanceof LateDataCollectorInterface) { $collector->lateCollect(); } } if (!($ret = $this->storage->write($profile)) && null !== $this->logger) { $this->logger->warning('Unable to store the profiler information.', array('configured_storage' => get_class($this->storage))); } return $ret; }