I need to read a file line by line using java.nio, but nio doesn\'t have a method like readline() to read one, complete line at a time
In support of EJP and others above, you might reference this article: http://www.javaworld.com/article/2078654/java-se/java-se-five-ways-to-maximize-java-nio-and-nio-2.html
In particular: "While NIO is often promoted for its performance advantages, it's more precise to say it is highly responsive. In some cases NIO actually performs worse than basic Java I/O. For simple sequential reads and writes of small files, for instance, a straightforward streams implementation might be two or three times faster than the corresponding event-oriented channel-based coding. Also, non-multiplexed channels -- that is, channels in separate threads -- can be much slower than channels that register their selectors in a single thread."
I would highlight the statement that NIO In some cases [...] performs worse than basic Java I/O. The author follows up with a list of questions to drive a quick analysis of whether NIO is the right choice. If you (or the next person to come along) still decides to pursue NIO there is a good explanation of its use with code example.