Re: [xml] Locking and unlocking a part of the xml tree



On 10/24/07, Daniel Veillard <veillard redhat com> wrote:
On Wed, Oct 24, 2007 at 09:10:19PM +0530, Senthil Nathan wrote:

   Hi All,

   I  was  reading through the api's for locking the xml tree and checked
   that,



   xmlMutexLock() is used to lock a libxml2 token.

   xmlMutexUnlock() is used to unlock a libxml2 token.

   xmlNewMutex()  is  used  to allocate a libxml2 token struct for use in
   synchronizing access to data.



   Would  like  to  know, is there a way to lock and unlock a node in the
   xmlDocPtr.

   Or anyother means to do this?

 No. There is no locking in place in libxml2 for shared trees. One tree
per thread or you manage your own locking.

Daniel

--


So, this api xmlMutexLock, locks the whole tree??
And, if there are multiple trees, how do we specify which tree to be locked.

Could you please give more information.

Thanks
Senthil Nathan R



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]