Here you can find the source of readLine(BufferedReader br)
public static String readLine(BufferedReader br) throws IOException
//package com.java2s; import java.io.BufferedReader; import java.io.IOException; public class Main { public static final String EOF = "__EOF__"; public static String readLine(BufferedReader br) throws IOException { String str = null;//from w ww .j a v a2s . co m str = br.readLine(); if (str == null) { str = EOF; } return str; } }