Example #1
0
  public static Image getResourceOutIcon(String icon) throws MalformedURLException {
    File iconFile = new File(ICON_OUT_FOLDER + File.separator + icon);
    if (!iconFile.exists()) {
      return getResourceIcon("user_m.png");
    }

    return new Image(iconFile.toURI().toURL().toString());
  }
Example #2
0
 public static boolean fileExists(File file) {
   if (file != null) {
     if (file.exists() && file.isFile()) {
       return true;
     }
   }
   return false;
 }