code: protected final Scheme validateScheme(URI uri) {
          requireNonNull(uri, "uri");
  
          final String scheme = uri.getScheme();
          if (scheme == null) {
              throw new IllegalArgumentException("URI with missing scheme: " + uri);
          }
  
          if (uri.getAuthority() == null) {
              throw new IllegalArgumentException("URI with missing authority: " + uri);
          }
  
          final Optional<Scheme> parsedSchemeOpt = Scheme.tryParse(scheme);
          if (!parsedSchemeOpt.isPresent()) {
              throw new IllegalArgumentException("URI with unknown scheme: " + uri);
          }
  
          final Scheme parsedScheme = parsedSchemeOpt.get();
          final Set<Scheme> supportedSchemes = supportedSchemes();
          if (!supportedSchemes.contains(parsedScheme)) {
              throw new IllegalArgumentException(
                      "URI with unsupported scheme: " + uri + " (expected: " + supportedSchemes + ')');
          }
  
          return parsedScheme;
      }
docs: Makes sure the scheme of the specified {@link URI} is supported by this {@link ClientFactory}.
  
  @param uri the {@link URI} of the server endpoint
  @return the parsed {@link Scheme}
  
  @throws IllegalArgumentException if the scheme of the specified {@link URI} is not supported by this
  {@link ClientFactory}