class SourceService implements ISourceService {

   @Override
   public boolean updateSource(Source source)
   {
      if (source.getId() < 0)
      {
         throw new IllegalArgumentException("Invalid source id");
      }
      if (source.getUrl() == null || source.getUrl().isEmpty())
      {
         throw new IllegalArgumentException("url must not be null or empty");
      }
      if (source.getMaxDownload() > LIMIT_MAX_DOWNLOADS)
      {
         throw new IllegalArgumentException(
               "max concurrent download must be less or equals than " + LIMIT_MAX_DOWNLOADS);
      }
      return configurationManager.getSourceManager().updateSource(source);
   }

}