[Jslib] RDF getRootBag

Jean-Yves Mertès jym at skynet.be
Sat Mar 4 07:55:32 EST 2006


After a little investigation I discovered that the getRootBag() method 
only constructs and returns a bag container. This latter has nothing to 
do with the RDF source which the method is attached to. Well, it might 
be useful sometimes but I think the name get...() is quite misleading. 
As I understand it got inspired by the getResource method of the Mozilla 
code it uses. Hence I think JSlib would need a method that checks if a 
resource is actually already in the graph of the RDF source. I built 
such a method. Would you be interested in it I could send it to you.

Pete Collins wrote:
>
>
> jym wrote:
>
>> I am trying to determine when a certain container already exists in a 
>> loaded datasource. To do this I am using the getRootBag() method 
>> exposed by the RDFFile object that points to my loaded datasource.
>> Whatever the container actually exists or not, the method always 
>> returns the same valid RDFContainer object. Hence I am not able to 
>> guess if it is in or not. Is there any means to differentiate from an 
>> existing/non-existing container? Or is it simply a bug?
>>
>> Any help would be appreciated.
>>
>
> It could be a bug. Like I've stated before, the jsLib RDF library is 
> old, and probably fairly buggy at this point. It is in need of a long 
> overdue overhaul.
>
> --pete
>


More information about the Jslib mailing list