FileDocCategorySizeDatePackage
LineCat.javaAPI DocExample478Wed Feb 15 05:41:38 GMT 2006None

LineCat

public class LineCat extends Object

Fields Summary
Constructors Summary
Methods Summary
public static voidmain(java.lang.String[] args)

    String thisLine;
    for (int i=0; i < args.length; i++) {
     try {
       LineNumberReader br = new LineNumberReader(new FileReader(args[i]));
       while ((thisLine = br.readLine()) != null) {
         System.out.println(br.getLineNumber() + ": " + thisLine);
       } // end while 
     } // end try
     catch (IOException ex) {System.err.println(ex);}
   } // end for