3 use Symfony\Component\DependencyInjection\ContainerInterface;
4 use Symfony\Component\DependencyInjection\Container;
5 use Symfony\Component\DependencyInjection\Exception\InactiveScopeException;
6 use Symfony\Component\DependencyInjection\Exception\InvalidArgumentException;
7 use Symfony\Component\DependencyInjection\Exception\LogicException;
8 use Symfony\Component\DependencyInjection\Exception\RuntimeException;
9 use Symfony\Component\DependencyInjection\ParameterBag\FrozenParameterBag;
12 * ProjectServiceContainer.
14 * This class has been auto-generated
15 * by the Symfony Dependency Injection Component.
17 class ProjectServiceContainer extends Container
20 private $targetDirs = array();
25 public function __construct()
28 for ($i = 1; $i <= 5; ++$i) {
29 $this->targetDirs[$i] = $dir = dirname($dir);
31 $this->parameters = $this->getDefaultParameters();
34 $this->scopedServices =
35 $this->scopeStacks = array();
36 $this->scopes = array();
37 $this->scopeChildren = array();
38 $this->methodMap = array(
39 'test' => 'getTestService',
42 $this->aliases = array();
48 public function compile()
50 throw new LogicException('You cannot compile a dumped frozen container.');
56 public function isFrozen()
62 * Gets the 'test' service.
64 * This service is shared.
65 * This method always returns the same instance of the service.
67 * @return \stdClass A stdClass instance
69 protected function getTestService()
71 return $this->services['test'] = new \stdClass(('wiz'.$this->targetDirs[1]), array(('wiz'.$this->targetDirs[1]) => ($this->targetDirs[2].'/')));
77 public function getParameter($name)
79 $name = strtolower($name);
81 if (!(isset($this->parameters[$name]) || array_key_exists($name, $this->parameters))) {
82 throw new InvalidArgumentException(sprintf('The parameter "%s" must be defined.', $name));
85 return $this->parameters[$name];
91 public function hasParameter($name)
93 $name = strtolower($name);
95 return isset($this->parameters[$name]) || array_key_exists($name, $this->parameters);
101 public function setParameter($name, $value)
103 throw new LogicException('Impossible to call set() on a frozen ParameterBag.');
109 public function getParameterBag()
111 if (null === $this->parameterBag) {
112 $this->parameterBag = new FrozenParameterBag($this->parameters);
115 return $this->parameterBag;
119 * Gets the default parameters.
121 * @return array An array of the default parameters
123 protected function getDefaultParameters()
126 'foo' => ('wiz'.$this->targetDirs[1]),
128 'baz' => (__DIR__.'/PhpDumperTest.php'),
129 'buz' => $this->targetDirs[2],