Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 2 of 2 for guessContentTypeFromName (0.27 sec)

  1. src/main/java/org/codelibs/core/net/MimeTypeUtil.java

            try {
                final String mimetype = URLConnection.guessContentTypeFromStream(is);
                if (mimetype != null) {
                    return mimetype;
                }
                return URLConnection.guessContentTypeFromName(path);
            } catch (final IOException e) {
                throw new IORuntimeException(e);
            } finally {
                CloseableUtil.close(is);
            }
        }
    
    Registered: Fri Nov 01 20:58:10 UTC 2024
    - Last Modified: Thu Mar 07 01:59:08 UTC 2024
    - 1.8K bytes
    - Viewed (0)
  2. src/main/java/jcifs/http/NetworkExplorer.java

            try ( SmbFileInputStream in = new SmbFileInputStream(file) ) {
                url = file.getLocator().getPath();
                resp.setContentType("text/plain");
                resp.setContentType(URLConnection.guessContentTypeFromName(url));
                resp.setHeader("Content-Length", file.length() + "");
                resp.setHeader("Accept-Ranges", "Bytes");
    
                while ( ( n = in.read(buf) ) != -1 ) {
    Registered: Sun Nov 03 00:10:13 UTC 2024
    - Last Modified: Sun Jul 01 13:12:10 UTC 2018
    - 21.3K bytes
    - Viewed (0)
Back to top