Introduce buffer_iterator to ease buffer parsing.