Back to project page mobile-android.
The source code is released under:
MIT License
If you think the Android project mobile-android listed in this page is inappropriate, such as containing malicious code/tools or violating the copyright, please email info at java2s dot com, thanks.
package com.manyconf.conference; /*from w ww . jav a 2 s.c o m*/ import java.io.File; import java.io.FileReader; import java.io.IOException; /** * http://rosettacode.org/wiki/Read_entire_file#Java */ public class ReadFile { public static String readEntireFile(File file) throws IOException { FileReader in = new FileReader(file); StringBuilder contents = new StringBuilder(); char[] buffer = new char[4096]; int read = 0; do { contents.append(buffer, 0, read); read = in.read(buffer); } while (read >= 0); return contents.toString(); } }