Here you can find the source of load(String file)
public static String load(String file) throws IOException
//package com.java2s; //License from project: Apache License import java.io.FileInputStream; import java.io.IOException; public class Main { public static String load(String file) throws IOException { FileInputStream fin = new FileInputStream(file); byte[] b = new byte[fin.available()]; fin.read(b);/* w ww . jav a 2s . c o m*/ String str = new String(b); fin.close(); return str; } }