code: public function addService(Service $service)
      {
          if (array_key_exists($service->getName(), $this->services)) {
              throw new KeyTakenInSetException($service->getName(), 'services');
          }
  
          $this->services[$service->getName()] = $service;
  
          return $this;
      }
docs: Adds service.
  
  @param Service $service
  
  @return $this
  
  @throws KeyTakenInSetException