public function provideSymfonyService($name, $symfonyName = null)
    {
        if (null === $symfonyName) {
            $symfonyName = $name;
        }

        if (parent::offsetExists($name)) {
            throw new \LogicException(sprintf('Service %s has already been defined.', $name));
        }

        $this->delegates[$name] = $symfonyName;
    }
public function provideSymfonyService($name, $symfonyName = null)
    {
        if (null === $symfonyName) {
            $symfonyName = $name;
        }

        if (parent::offsetExists($name)) {
            throw new \LogicException(sprintf('Service %s has already been defined.', $name));
        }

        $this->delegates[$name] = $symfonyName;
    }
public function provideSymfonyService ( $ name , $ symfonyName = null ) { if ( null === $ symfonyName ) { $ symfonyName = $ name ; } if ( parent :: offsetExists ( $ name ) ) { throw new \ LogicException ( sprintf ( 'Service %s has already been defined.' , $ name ) ) ; } $ this -> delegates [ $ name ] = $ symfonyName ; }
Provide a symfony service in this container.

@param string      $name        The name of the service.
@param null|string $symfonyName The name of the service in the symfony container (if not equal).

@return void

@throws \LogicException When the service being set is already contained in the DIC.
Provide a symfony service in this container .