Here you can find the source of loadProperties()
private static Properties loadProperties()
//package com.java2s; /*/* ww w . j ava 2s .c o m*/ * License GNU LGPL * Copyright (C) 2012 Amrullah <amrullah@panemu.com>. */ import java.io.File; import java.io.FileInputStream; import java.io.IOException; import java.util.Properties; public class Main { private static String applicationId = ".tiwulfx"; private static Properties loadProperties() { Properties p = new Properties(); try { FileInputStream in = new FileInputStream(getConfigurationPath()); p.load(in); in.close(); } catch (IOException ex) { ex.printStackTrace(); } return p; } private static String getConfigurationPath() throws IOException { String home = System.getProperty("user.home"); String confPath = home + File.separator + applicationId; File confFile = new File(confPath); if (!confFile.exists()) { confFile.mkdirs(); } confPath = home + File.separator + applicationId + File.separator + "conf.properties"; confFile = new File(confPath); if (!confFile.exists()) { confFile.createNewFile(); } return confPath; } }