cakephp/cakephp — pull request #5444 by lorenzo (2014-12-18 19:41:23+00:00)
Title: Implemented Collection::stopWhen()

This is useful when using collections for processing large files or infinite iterators/generators.

For example, a collection could be used to process values from a `yield` generator with no bound condition to it (like a stream of data). This allows the iterator to stop yielding results until certain condition is met.