If you use a FileReader and put that into a BufferedReader, you could use the BufferedReader's readLine method to read only one line of the file at a time.