public static boolean containsEntry(File file,String entryPath){
  if (file.canRead()) {
    try {
      JarFile jarFile=new JarFile(file);
      try {
        return jarFile.getEntry(entryPath) != null;
      }
  finally {
        jarFile.close();
      }
    }
 catch (    IOException ignored) {
    }
  }
  return false;
}

public static boolean containsEntry ( File file , String entryPath ) { if ( file . canRead ( ) ) { try { JarFile jarFile = new JarFile ( file ) ; try { return jarFile . getEntry ( entryPath ) != null ; } finally { jarFile . close ( ) ; } } catch ( IOException ignored ) { } } return false ; }
returns true if the given . jar file exists and contains the entry .
