Here you can find the source of fileExists(String fname)
public static boolean fileExists(String fname)
//package com.java2s; import java.io.File; public class Main { public static boolean fileExists(String fname) { return new File(fname).exists(); }//from w w w . java 2 s.c om }