File file = new File(this.getClass().getProtectionDomain().getCodeSource().getLocation().getPath());
return file.isFile();