Varuna, There is a processing difference in a multi-threaded environment. If you are using an iterator, you are using a structure that is allocated and attached to the tree. So if two threads are operating at the same point in the same tree at the same time, they will be using the one iterator and one thread will process one child, then the other thread might process the next child. This is usually not what you want to do in a multi-threaded environment.
Bill Mitchell -----Original Message----- From: Dinesh Premalal [mailto:[EMAIL PROTECTED] On Behalf Of Dinesh Premalal Sent: Wednesday, April 30, 2008 6:48 AM To: axis-c-dev@ws.apache.org Subject: Re: Axiom Varuna, "Varuna Jayasiri" <[EMAIL PROTECTED]> writes: > What's the difference between children iterator and the > axiom_node_get_next_sibling? Is there a difference in the way they are > processed? I couldn't recall where is used children iterator last time :), If you look into children iterator implementation , you would see <snip> axiom_children_iterator_next( ... if (iterator->current_child) { iterator->last_child = iterator->current_child; iterator->current_child = axiom_node_get_next_sibling(iterator->current_child, env); return iterator->last_child; } ... </snip> I would say there is no difference in a way they are processing. But you could modification to iterator while processing where as you couldn't do it with axiom_node_get_next_sibling function. > > When we navigate using get_first_child, get next sibling, etc. is the parsing > done when these methods are called? I think yes. >If so are the parsed data cached so that > it's not parsed again if the functions are called twice? Agree, If you going to cache those data, In order to cache them there is a cost, in memory, processing etc.After considering those costs there may not be a considerable gain. thanks, Dinesh -- http://nethu.org --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]