in reply to Re^4: Iterator as a Class or Object Method
in thread Iterator as a Class or Object Method

Re: Are you looking at XML processing the right way? (merge) says it far better than I could.

That's tye (quite correctly) saying that callbacks are less flexible than iterators. That's not an argument for throwing the former away. C style for loops are more flexible that Perl style foreach loops - but I wouldn't want to do without the latter :-)

If your iterating over everything in a Feed object 30 times in your code why not abstract that loop out?

Iterators and callbacks are both useful interfaces. I wouldn't want to do without either.

  • Comment on Re^5: Iterator as a Class or Object Method