Version 11 (modified by yy, 15 years ago)

--

Hey yy, did you see my page StateOfPerlAndRdf? You could integrate this page into it. Also, in the next version, RDF::Trine will allow defining namespaces to appear in the rdf:RDF tag, I've exchanged some mails with the author. -- Thomas (tkappler)

Yeah, I read your page, but I had difficulty in integrating, since aspects are different. I'd be glad if you'd integrate :-). Thanks for your input. -- YY (Yasunori)

Perl modules concerning RDF serialization

I (yy) tried the following modules.

RDF::Simple is literally "simple", so IMO it is useful only for understanding how serialization works, but not for a practical use. As the module page says, it doesn't care the node type. You cannot declare whether a node is a URI or literal. On the other hand, a serialized output (RDF/XML) is better organized (more nested and size is smaller) than RDF::Trine and RDF::Redland.

RDF::Trine doesn't provide a sufficient document, and I have a bit difficulty in making a code. A serialized output (RDF/XML) has some redundancies. This module groups statements that share a same subject, and embraces them by "<rdf:Description>" tags. It's OK, but declaration of user-defined namespaces is not at the first "<rdf:RDF>" tag, but at each rdf-description tag. Also, nest level is one, and you cannot define a QNAME of a name space as "foaf" or "rdfs", but the module defines arbitrarily. Even so, it's more compact than that of REF::Redland.

RDF::Redland uses a compilation (i.e., not a pure Perl module), and you may have troubles on some platforms / environments. In my case the cpan command didn't work because of the "make test" failure. The reason is that the test script assumes that libraries generated by swig are in the shared library paths. After taking care of it, no problem occurred. To make the test script work, the following paths need to be added to LD_LIBRARY_PATH.

Redland-1.0.5.4/redland/rasqal/src/.libs
Redland-1.0.5.4/redland/raptor/src/.libs

RDF::Core is a bit old and cannot handle a blank node (rdf:nodeID), but a serialized output (RDF/XML) is better organized than the others. As with RDF::Trine, you cannot define a QNAME of a name space.