More on: Should information be merged from several RDF files?

I am writing a program.

I read RDF files while executing my program.

After each RDF loaded, my program does some actions (and probably terminates).

It is not predictable which RDF file will be loaded next, because in intervals between loading RDF files my program does some computations and the next loaded RDF file depends on these computation.

As such, I cannot first load all RDF files and merge information in them. Instead of this I need to load RDF files one-by-one and update my program data structure after reading each RDF file.

If I would read all RDF files at once I would be able just to merge data from all RDF files. But I cannot do that.

Upon reading each RDF file, I update internal data structures of my program based on RDF triples loaded.

I cannot base building these internal data structures of my program on the result of set-theoretic union of all RDF triples loaded till the moment. The reason for this is that loading an additional RDF may render my data inconsistent (if it has two or more different objects for a predicate which should have no more than on value, as in an example below). So this would require removal of some data from my program data structures, what would aimlessly complicate the code. I want only to add new data structures, not remove them, to make my program easier.

So the only remaining option is to load RDF one-by-one and construct new internal data structures of my program based only on the last loaded RDF file (not all loaded RDF files together).

A question remains:

# file-1.rdf
<> <#property-which-can-have-only-one-value> 1 .

# file-2.rdf
<> <#property-which-can-have-only-one-value> 2 .

Let we load first file-1.rdf and then later file-2.rdf. Should the triple from file-2.rdf be ignored? Or should I construct a new data structure from the data of both files, as if the subject URLs in these files would be different?

Here is my project, by the way:

Victor Porton -

Received on Monday, 7 July 2014 21:18:04 UTC