add iterator pattern