Re: [xml] tracking libxml's internal node creation / destruction?

Hi Lukas,

On Mon, 2002-12-30 at 10:04, Lukas Schroeder wrote:
how do other libxml2 language bindings handle these cases?

in gdome2 (DOM C binding for libxml2) we keep track of node allocation
by means of external ref counters. Before forwarding any operation that
deallocates libxml2 nodes, we traverse the affected subtree and
deallocate any extra data (wrappers) that might be allocated, and then
call the corresponding libxml2 function. It's kind of awkward, and
there's also some code duplication (the subtree must be traversed twice:
at the libxml2 level and at the gdome2 level) but there aren't many
choices with the current API of libxml2. We also proposed to add similar
callback functions, but if I remember correctly the position against
them was to preserve API compatibility.

Is libxml3 sort of coming soon? 

-- luca

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