Java URL Value Check isJarURL(URL url)

Here you can find the source of isJarURL(URL url)

Description

is Jar URL

License

Apache License

Declaration

public static boolean isJarURL(URL url) 

Method Source Code

//package com.java2s;
//License from project: Apache License 

import java.net.URL;

public class Main {
    public static final String URL_PROTOCOL_JAR = "jar";
    public static final String URL_PROTOCOL_ZIP = "zip";
    public static final String URL_PROTOCOL_WSJAR = "wsjar";
    public static final String URL_PROTOCOL_VFSZIP = "vfszip";

    public static boolean isJarURL(URL url) {
        String protocol = url.getProtocol();
        return (URL_PROTOCOL_JAR.equals(protocol) || URL_PROTOCOL_ZIP.equals(protocol)
                || URL_PROTOCOL_VFSZIP.equals(protocol) || URL_PROTOCOL_WSJAR.equals(protocol));
    }//from   w  ww .  ja  v  a  2 s .  c  om
}

Related

  1. isJarURL(URL url)
  2. isJarURL(URL url)
  3. isJarURL(URL url)
  4. isJarURL(URL url)
  5. isJarURL(URL url)
  6. isJBoss5Url(URL fileUrl)
  7. isLegalURL(final String url)
  8. isLocal(URL aURL)
  9. isLocalFile(URL url)