/* * File: BufferedTextInputTest.java * * Buffered character stream input with BufferedReader classes * * Copyright: Northeast Parallel Architectures Center * */ import java.io.IOException; import java.io.FileReader; import java.io.BufferedReader; public class BufferedTextInputTest { public static void main( String args[] ) throws IOException { String line; // for input String filename = "API.list"; BufferedReader in = new BufferedReader( new FileReader( filename ) ); // a character stream System.out.println( "Reading..." ); while ( ( line = in.readLine() ) != null ) { System.out.println( line ); } in.close(); } }