An RDFa API Diagram and some questions...

So, I spent some time today trying to get my head around the mutual dependencies of the current interfaces. I am of a visual type, so I created a diagram. I attach this diagram; I am _not_ saying that this has to be put into the document, but it certainly helped me to grasp the dependencies and maybe it is useful for others.

This is not a formal UML diagram. I have also started to put up all dependencies but it soon became spaghetti like, mainly due to the dependencies on interfaces like IRI or RDF Triple. So I decided to remove those and just keep the ones that are really central. For the sake of completeness, I have also kept the figures for the 'fundamental' interfaces that are used by many of the others, ie, PropertyGroup, IRI, BlankNode, PlainLiteral, TypedLiteral, RDFTriple, and RDFTripleFilter. The arrows on the diagram simply denote a (loose) dependency.

Looking through the structure I also discovered two issues/questions.

- The DataIterator interface is fairly 'isolated' on the diagram; at the moment it is used only by the Parser (unless I missed something). First of all, I am not sure what the role of the 'iterator' method is on the parser interface (I have asked that before). Also, looking at other interfaces I realized that the DataStore.filter method returns a DataStore. Wouldn't it be more logical if filter returned an iterator instead (my understanding is that the DataIterator.next() can be used to get to the next triple)?

- I wonder about the rdfa interface (section 5.3.4). While there is a fairly logical relationship now with 

    Document->DocumentData->{store,context, etc}

I am not even sure how the rda interface comes into that picture, who creates it and when... I can see the value of, say, containsRDFa, but why isn't that one just part of the Document interface?

That is it. I hope it may be helpful for others

Ivan

----
Ivan Herman, W3C Semantic Web Activity Lead
Home: http://www.w3.org/People/Ivan/
mobile: +31-641044153
PGP Key: http://www.ivan-herman.net/pgpkey.html
FOAF: http://www.ivan-herman.net/foaf.rdf

Received on Tuesday, 1 June 2010 13:53:34 UTC