inMemRDF

View: New views
4 Messages — Rating Filter:   Alert me  

inMemRDF

by ptvnga :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Hi all I am new in jslib
i am stuck I apologize to ask such a question

I try to use th inMemRDF

var gRDF = null;
 var rdfFileURL = "chrome://project/content/local.rdf";
 fileUtils = new FileUtils( );
 path = fileUtils.chrome_to_path(rdfFileURL);
 if(navigator.platform == "Win32") {
      alert(path);
     path = path.replace(/\//g,"\\");
    // Only needed on Windows, until JSLib is fixed
 }
 gRDF = new RDFFile(path,null,"http://www.project.org/fs-rdf#",null);
var gRDF = initRDF();
var node = searchNode(getTreeCellId(treename),gRDF);
var root = "urn:fs:root";
var MRDF = new inMemRDF(root, "http://www.project.org/fs-rdf#");


it throw an exception component return failure code
0x80004005(NS_ERROR_FAILURE) [nsIRDFContainer.Init]

what's wrong thanks in advance

_______________________________________________
Jslib mailing list
Jslib@...
https://www.mozdev.org/mailman/listinfo/jslib

Re: inMemRDF

by Pete Collins :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

I would recommend staying away from RDF if possible.

This lib is quite old now and hasn't been maintained.

If you really need it fixed, please post a bug and I'll try to look at it.

Thanks

--pete

patrice truong van nga wrote:

> Hi all I am new in jslib
> i am stuck I apologize to ask such a question
>
> I try to use th inMemRDF
>
> var gRDF = null;
>  var rdfFileURL = "chrome://project/content/local.rdf";
>  fileUtils = new FileUtils( );
>  path = fileUtils.chrome_to_path(rdfFileURL);
>  if(navigator.platform == "Win32") {
>       alert(path);
>      path = path.replace(/\//g,"\\");
>     // Only needed on Windows, until JSLib is fixed
>  }
>  gRDF = new RDFFile(path,null,"http://www.project.org/fs-rdf#",null);
> var gRDF = initRDF();
> var node = searchNode(getTreeCellId(treename),gRDF);
> var root = "urn:fs:root";
> var MRDF = new inMemRDF(root, "http://www.project.org/fs-rdf#");
>
>
> it throw an exception component return failure code
> 0x80004005(NS_ERROR_FAILURE) [nsIRDFContainer.Init]
>
> what's wrong thanks in advance
> ------------------------------------------------------------------------
>
> _______________________________________________
> Jslib mailing list
> Jslib@...
> https://www.mozdev.org/mailman/listinfo/jslib
>  

--
Pete Collins - Founder, Mozdev Group Inc.
www.mozdevgroup.com
Mozilla Software Development Solutions
tel: 1-719-302-5811
fax: 1-719-302-5813

_______________________________________________
Jslib mailing list
Jslib@...
https://www.mozdev.org/mailman/listinfo/jslib

Re: inMemRDF

by ptvnga :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Thanks fro your honesty
Do I need to call directly Mozilla interface or
can I use another javascript lib?


2008/11/8 Pete Collins <pete@...>
I would recommend staying away from RDF if possible.

This lib is quite old now and hasn't been maintained.

If you really need it fixed, please post a bug and I'll try to look at it.

Thanks

--pete


patrice truong van nga wrote:
Hi all I am new in jslib
i am stuck I apologize to ask such a question

I try to use th inMemRDF

var gRDF = null;
 var rdfFileURL = "chrome://project/content/local.rdf";
 fileUtils = new FileUtils( );
 path = fileUtils.chrome_to_path(rdfFileURL);
 if(navigator.platform == "Win32") {
     alert(path);
    path = path.replace(/\//g,"\\");
   // Only needed on Windows, until JSLib is fixed
 }
 gRDF = new RDFFile(path,null,"http://www.project.org/fs-rdf#",null);
var gRDF = initRDF();
var node = searchNode(getTreeCellId(treename),gRDF);
var root = "urn:fs:root";
var MRDF = new inMemRDF(root, "http://www.project.org/fs-rdf#");


it throw an exception component return failure code
0x80004005(NS_ERROR_FAILURE) [nsIRDFContainer.Init]

what's wrong thanks in advance
------------------------------------------------------------------------

_______________________________________________
Jslib mailing list
Jslib@...
https://www.mozdev.org/mailman/listinfo/jslib
 

--
Pete Collins - Founder, Mozdev Group Inc.
www.mozdevgroup.com
Mozilla Software Development Solutions
tel: 1-719-302-5811
fax: 1-719-302-5813

_______________________________________________
Jslib mailing list
Jslib@...
https://www.mozdev.org/mailman/listinfo/jslib


_______________________________________________
Jslib mailing list
Jslib@...
https://www.mozdev.org/mailman/listinfo/jslib

Re: inMemRDF

by Pete Collins :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message



patrice truong van nga wrote:
> Thanks fro your honesty
> Do I need to call directly Mozilla interface or
> can I use another javascript lib?
>

The jsLib RDF library wraps the mozilla RDF stuff. I think some
interfaces might have changed and that's why jsLib is not working
properly for you.

You can search around the mozilla codebase to see if there is js code
rdf consumers that do what you are looking to do.

Or if you feel inspired you can fix the jsLib RDF code.  :-)

--pete

--
Pete Collins - Founder, Mozdev Group Inc.
www.mozdevgroup.com
Mozilla Software Development Solutions
tel: 1-719-302-5811
fax: 1-719-302-5813

_______________________________________________
Jslib mailing list
Jslib@...
https://www.mozdev.org/mailman/listinfo/jslib