Here you can find the source of exists(String parent, String fileName)
public static boolean exists(String parent, String fileName)
//package com.java2s; //License from project: Apache License import java.io.*; public class Main { public static boolean exists(String parent, String fileName) { return new File(parent, fileName).exists(); }/*ww w . j a v a 2 s . c om*/ public static boolean exists(String fileName) { return new File(fileName).exists(); } }