List of utility methods to do Text File Line Count
int | numberOfLines(File file) number Of Lines RandomAccessFile randFile = new RandomAccessFile(file, "r"); long lastRec = randFile.length(); randFile.close(); FileReader fileRead = new FileReader(file); LineNumberReader lineRead = new LineNumberReader(fileRead); lineRead.skip(lastRec); int count = lineRead.getLineNumber() - 1; fileRead.close(); ... |