What is the main advantage of having an iterator with two seperate classes, passing objects by reference as parameters?

Is it better to create an iterator with inheritance, rather than the non stop reference using and foreign method calling?