Yeah... this class is pretty much an iterator. Except it sort of caches a value. When you call next() it returns a local, stored value, then calls incrementValue() so it is ready the next time you call next(). Check the IncrementValue() method; sometimes the CSVLineReader can return null. In that case, this class needs to have a buffer so it can always be 1 step ahead of any next() or hasNext() calls made to it so it never returns null.