GoF Design Patterns – Iterator Design Pattern
The Iterator design pattern is a behavioral pattern that provides a way to access elements of an aggregate object sequentially without exposing underlying representation. Here an aggregate is understood as an object that holds collections of other objects. …