Implemented all methods, bugs found in the next() method though.