public static String readOutput ( BufferedReader in ) throws IOException { StringBuffer output = new StringBuffer ( ) ; String line = "" ; while ( ( line = in . readLine ( ) ) != null ) { output . append ( line ) ; output . append ( "\n" ) ; } return output . toString ( ) ; }
Reads the output of the reader and delivers it at string .