docs: public static Object fromURL(java.net.URL url, CloseableHttpClient httpClient)
              throws JsonParseException, IOException {
          final String protocol = url.getProtocol();
          // We can only use the Apache HTTPClient for HTTP/HTTPS, so use the
          // native java client for the others
          CloseableHttpResponse response = null;
          InputStream in = null;
          try {
              if (!protocol.equalsIgnoreCase("http") && !protocol.equalsIgnoreCase("https")) {
                  // Can't use the HTTP client for those!
                  // Fallback to Java's built-in JsonLdUrl handler. No need for
                  // Accept headers as it's likely to be file: or jar:
                  in = url.openStream();
              } else {
                  final HttpUriRequest request = new HttpGet(url.toExternalForm());
                  // We prefer application/ld+json, but fallback to
                  // application/json
                  // or whatever is available
                  request.addHeader("Accept", ACCEPT_HEADER);
  
                  response = httpClient.execute(request);
                  final int status = response.getStatusLine().getStatusCode();
                  if (status != 200 && status != 203) {
                      throw new IOException("Can't retrieve " + url + ", status code: " + status);
                  }
                  in = response.getEntity().getContent();
              }
              return fromInputStream(in);
          } finally {
              try {
                  if (in != null) {
                      in.close();
                  }
              } finally {
                  if (response != null) {
                      response.close();
                  }
              }
          }
      }