Here you can find the source of loadApiProperties(InputStream inputStream)
public static Properties loadApiProperties(InputStream inputStream) throws IOException
//package com.java2s; //License from project: Open Source License import java.io.File; import java.io.FileInputStream; import java.io.IOException; import java.io.InputStream; import java.util.Properties; public class Main { public static Properties loadApiProperties(InputStream inputStream) throws IOException { Properties properties = new Properties(); properties.load(inputStream);//from w ww .ja v a2s. c o m return properties; } /** * load the OAuth API Key and secret from the soup_api.properties file in * the home directory of the current user * * @return * @throws IOException */ public static Properties loadApiProperties() throws IOException { Properties properties = new Properties(); properties.load(new FileInputStream(new File(System .getProperty("user.home"), "soup_api.properties"))); return properties; } }