I want to read the last n lines of a very big file without reading the whole file into any buffer/memory area using Java.
I looked around the JDK APIs and Apache Com
The ReversedLinesFileReader can be found in the Apache Commons IO java library.
ReversedLinesFileReader
int n_lines = 1000; ReversedLinesFileReader object = new ReversedLinesFileReader(new File(path)); String result=""; for(int i=0;i