Here you can find the source of openStream(InputStream in)
public static BufferedReader openStream(InputStream in) throws IOException
//package com.java2s; // This file is part of MarMoT, which is licensed under GPLv3. import java.io.BufferedReader; import java.io.IOException; import java.io.InputStream; import java.io.InputStreamReader; public class Main { public static BufferedReader openStream(InputStream in) throws IOException { return new BufferedReader(new InputStreamReader(in, "UTF-8")); }/*from w w w .ja v a2s . c o m*/ }