protected function ProjectServiceContainer::getConfiguratorServiceService in Service Container 7.2
Same name and namespace in other branches
- 7 modules/providers/service_container_symfony/lib/Symfony/Component/DependencyInjection/Tests/Fixtures/php/services9.php \ProjectServiceContainer::getConfiguratorServiceService()
Gets the 'configurator_service' service.
This service is shared. This method always returns the same instance of the service.
This service is private. If you want to be able to request this service from the container directly, make it public, otherwise you might end up with broken code.
Return value
\ConfClass A ConfClass instance.
File
- modules/
providers/ service_container_symfony/ lib/ Symfony/ Component/ DependencyInjection/ Tests/ Fixtures/ php/ services9.php, line 311
Class
- ProjectServiceContainer
- ProjectServiceContainer.
Code
protected function getConfiguratorServiceService() {
$this->services['configurator_service'] = $instance = new \ConfClass();
$instance
->setFoo($this
->get('baz'));
return $instance;
}