Re: datasource verification

"rvj" <[email protected]> Sat, 25 Jun 2005 20:16:58 +0100
Newsgroups gmane.comp.mozilla.devel.rdf
Organization Another Netscape Collabra Server User
Message-ID <[email protected]>
PPS the current datasource is returned provided that a single literal is
used in the about field

           <RDF:Description about="abc" />

so querying the resource returns the  truncated datasource path plus "/abc"


"rvj" <[email protected]> wrote in message
news:[email protected]...
>
> Is there a simple way (QI) to determine the current  datasource if the
> resource has a urn style value?
>
> ********************************************************
>
> for example if a resource (about)  has no value then and a user clicks on
a
> tree item
> with a click event code  (flags="dont-build-content")
>
>       var object =
> widget.builderView.getResourceAtIndex(widget.currentIndex)
>       var
> urn=object.QueryInterface(Components.interfaces.nsIRDFResource).Value;
>
> then the current datasource is returned
>
> BUT if resource has a valid urn such as
>
>            <RDF:Description about="urn:abc" />
>
> then only the urn is returned
>
> *****************************************************************
>
> PS I did think about work arounds such as deleting the urn , then QI the
> resource then
> restore the urn - but this seems a bit crude (even it would work)
>
>
>