docs: public ImageInputStream createInputStreamInstance(final Object pInput, final boolean pUseCache, final File pCacheDir) throws IOException {
          if (pInput instanceof URL) {
              URL url = (URL) pInput;
  
              // Special case for file protocol, a lot faster than FileCacheImageInputStream
              if ("file".equals(url.getProtocol())) {
                  try {
                      return new BufferedImageInputStream(new FileImageInputStream(new File(url.toURI())));
                  }
                  catch (URISyntaxException ignore) {
                      // This should never happen, but if it does, we'll fall back to using the stream  
                      ignore.printStackTrace();
                  }
              }
  
              // Otherwise revert to cached
              final InputStream stream = url.openStream();
              if (pUseCache) {
                  return new BufferedImageInputStream(new FileCacheImageInputStream(stream, pCacheDir) {
                      @Override
                      public void close() throws IOException {
                          try {
                              super.close();
                          }
                          finally {
                              stream.close(); // NOTE: If this line throws IOE, it will shadow the original..
                          }
                      }
                  });
              }
              else {
                  return new MemoryCacheImageInputStream(stream) {
                      @Override
                      public void close() throws IOException {
                          try {
                              super.close();
                          }
                          finally {
                              stream.close(); // NOTE: If this line throws IOE, it will shadow the original..
                          }
                      }
                  };
              }
          }
          else {
              throw new IllegalArgumentException("Expected input of type URL: " + pInput);
          }
      }