[Jslib] RDF data source release

jym moreofthis at skynet.be
Sun Mar 19 20:22:14 EST 2006


Pete Collins wrote:
> 
>>
>>
>> Any idea of a workaround?
> 
> You should be anle to just QI (Query Interface) into 
> nsIRDFCompositeDataSource and then remove it...
> 
> --pete
> 


Below you can see what I did:

/* 
==============================================================================================
Erases a datasource (linked to an RDF file) from memory.
*/
RDFFile.prototype.unload=function () {

var cds= 
Components.classes["@mozilla.org/rdf/datasource;1?name=composite-datasource"].createInstance(Components.interfaces.nsIRDFCompositeDataSource);
cds.RemoveDataSource(this.getDatasource());
}


There is no expected result out of this. When I check (using the 
debugger) the cds for included datasources, it shows that it is void, 
which seems quite normal to me since I have not added any datasource to it.

So far it looks like if I do not understand what you try to tell me! 
Where is my mistake?


More information about the Jslib mailing list