Here you can find the source of getRootDir()
public static File getRootDir()
//package com.java2s; //License from project: Open Source License import java.io.File; public class Main { public static File getRootDir() { String os = System.getProperty("os.name").toUpperCase(); if (os.contains("WIN")) { return new File(System.getenv("APPDATA"), "routeKIT"); } else if (os.contains("MAC")) { return new File(new File(new File(System.getProperty("user.home"), "Library"), "Application Support"), "routeKIT"); } else if (os.matches(".*N[IU]X.*")) { return new File(new File(System.getProperty("user.home"), ".config"), "routeKIT"); } else {//w w w .ja v a2 s .com throw new RuntimeException("Unknown operating system " + os); } } }