Lines Matching refs:iterator
129 php_dom_iterator *iterator = (php_dom_iterator *)iter; in php_dom_iterator_dtor() local
131 zval_ptr_dtor(&iterator->intern.data); in php_dom_iterator_dtor()
132 zval_ptr_dtor(&iterator->curobj); in php_dom_iterator_dtor()
139 php_dom_iterator *iterator = (php_dom_iterator *)iter; in php_dom_iterator_valid() local
141 if (Z_TYPE(iterator->curobj) != IS_UNDEF) { in php_dom_iterator_valid()
151 php_dom_iterator *iterator = (php_dom_iterator *)iter; in php_dom_iterator_current_data() local
153 return &iterator->curobj; in php_dom_iterator_current_data()
159 php_dom_iterator *iterator = (php_dom_iterator *)iter; in php_dom_iterator_current_key() local
160 zval *object = &iterator->intern.data; in php_dom_iterator_current_key()
165 dom_object *intern = Z_DOMOBJ_P(&iterator->curobj); in php_dom_iterator_current_key()
189 php_dom_iterator *iterator = (php_dom_iterator *)iter; in php_dom_iterator_move_forward() local
191 object = &iterator->intern.data; in php_dom_iterator_move_forward()
195 intern = Z_DOMOBJ_P(&iterator->curobj); in php_dom_iterator_move_forward()
202 zend_hash_move_forward_ex(nodeht, &iterator->pos); in php_dom_iterator_move_forward()
203 if ((entry = zend_hash_get_current_data_ex(nodeht, &iterator->pos))) { in php_dom_iterator_move_forward()
204 zval_ptr_dtor(&iterator->curobj); in php_dom_iterator_move_forward()
205 ZVAL_UNDEF(&iterator->curobj); in php_dom_iterator_move_forward()
206 ZVAL_COPY(&iterator->curobj, entry); in php_dom_iterator_move_forward()
239 zval_ptr_dtor(&iterator->curobj); in php_dom_iterator_move_forward()
240 ZVAL_UNDEF(&iterator->curobj); in php_dom_iterator_move_forward()
243 php_dom_create_object(curnode, &iterator->curobj, objmap->baseobj); in php_dom_iterator_move_forward()
266 php_dom_iterator *iterator; in php_dom_get_iterator() local
272 iterator = emalloc(sizeof(php_dom_iterator)); in php_dom_get_iterator()
273 zend_iterator_init(&iterator->intern); in php_dom_get_iterator()
275 ZVAL_COPY(&iterator->intern.data, object); in php_dom_get_iterator()
276 iterator->intern.funcs = &php_dom_iterator_funcs; in php_dom_get_iterator()
278 ZVAL_UNDEF(&iterator->curobj); in php_dom_get_iterator()
287 zend_hash_internal_pointer_reset_ex(nodeht, &iterator->pos); in php_dom_get_iterator()
288 if ((entry = zend_hash_get_current_data_ex(nodeht, &iterator->pos))) { in php_dom_get_iterator()
289 ZVAL_COPY(&iterator->curobj, entry); in php_dom_get_iterator()
322 php_dom_create_object(curnode, &iterator->curobj, objmap->baseobj); in php_dom_get_iterator()
325 return &iterator->intern; in php_dom_get_iterator()