Here you can find the source of readLineStringConcat(InputStream is)
private static String readLineStringConcat(InputStream is) throws Exception
//package com.java2s; //License from project: Open Source License import java.io.InputStream; public class Main { private static String readLineStringConcat(InputStream is) throws Exception { String res = ""; int temp = is.read(); while (temp != 0x0D) { res += (char) temp; temp = is.read();//from w w w. ja va 2 s . c o m } is.read(); // skip (char)0x0A return res; } }