perllib suggestion: change datasource API

Hi Eric,

I've been looking at with an eye to dropping in
alternate backend database implementations, like we discussed recently.
I've also got a wrapper for the Squish RDF query language that I'll
contrib when I've got some tests implemented to be sure it works properly.

Anyway, a suggestion: It seems the way currently works, one needs
a class that implements W3C::RDF::RdfDB that can be constructed afresh by
the query engine, ie. the method W3C::RDF::Algae::checkForDBSpec() wants
to be passed a class name plus a bunch of initialisation parameters,
which'll allow it to create a new instance of some species of RDF database.

Often one's application code will *already* have its hands on a reference
to such a database object, so it'd be nice if this could just be passed
to the query engine instead.

Currently you do: eval "require $dbSpec; \$\$pDb = new $dbSpec(\$parms);";

...could you hack it to take a Perl reference instead? Would this break
anything else? That way I can create RDF database instances and initialise
them without having to have Algae do that work...



Received on Tuesday, 26 June 2001 18:01:06 UTC