Yii2 port of Yii 1.1 CDataProviderIterator