src/Container.php
public function registerServices(ServiceProviderInterface $serviceProvider)
    {
        $services = $serviceProvider->getServices();      
        foreach ($services as $id => $service) {
            if ($this->has($id) == false) {
                $this->set($id, $service);
            }
        }
    }
public function registerServices(ServiceProviderInterface $serviceProvider)
    {
        $services = $serviceProvider->getServices();      
        foreach ($services as $id => $service) {
            if ($this->has($id) == false) {
                $this->set($id, $service);
            }
        }
    }
public function registerServices ( ServiceProviderInterface $ serviceProvider ) { $ services = $ serviceProvider -> getServices ( ) ; foreach ( $ services as $ id => $ service ) { if ( $ this -> has ( $ id ) == false ) { $ this -> set ( $ id , $ service ) ; } } }
Add services to the container

@param ServiceProviderInterface $serviceProvider A service provider
Add services to the container