import java.io.File; public class MainClass { public static void main(String[] argv) { File f1 = new File("dirname"); File f2 = new File(f1, "filename"); } }