/** * Get parameter value * * @param string $parameterName Parameter Name * * @return mixed Parameter value * * @throws DoppoNotCompiledException Container not compiled yet * @throws DoppoParameterNotExistsException Parameter not found */ public function getParameter($parameterName) { if (!$this->compiled) { throw new DoppoNotCompiledException('Container should be compiled before being used'); } if (!$this->parameters->has($parameterName)) { throw new DoppoParameterNotExistsException(sprintf('Parameter "%s" not found', $parameterName)); } return $this->parameters->get($parameterName)->getValue(); }