public static List<String> readFile(final File argFile) throws IOException {
  final BufferedReader br=new BufferedReader(new FileReader(argFile));
  String line;
  List<String> lines=new ArrayList<String>();
  while ((line=br.readLine()) != null) {
    lines.add(line);
  }
  br.close();
  return lines;
}

public static List < String > readFile ( final File argFile ) throws IOException { final BufferedReader br = new BufferedReader ( new FileReader ( argFile ) ) ; String line ; List < String > lines = new ArrayList < String > ( ) ; while ( ( line = br . readLine ( ) ) != null ) { lines . add ( line ) ; } br . close ( ) ; return lines ; }
return a list of strings , one per line of the file .
