Hi Andy!

07.12.2013 23:13, Andy Seaborne wrote:
Comments? Any chances of getting this merged?

Tests! Excellent!

Did you mean that it's excellent that I had a sort of manual test procedure embedded in my message, or was this a reminder to write unit tests as well? :)

Anyway, I can try to write some unit tests for the code. I already modified the existing tests so they don't break due to the new argument EntityDefinition constructors now take.

To make sure it does not get lost:

https://issues.apache.org/jira/browse/JENA-605

and added the files from your email.

Great!

Looks good - a couple of small questions:

1/ Blank node graphs - how about using the pseudo URI _:label rather
than use g.getBlankNodeLabel()?

So you mean
  String graph = (g.isURI() ) ? g.getURI() : "_:" + g.getBlankNodeLabel() ;
instead of the current
  String graph = (g.isURI() ) ? g.getURI() : g.getBlankNodeLabel() ;
or did I misunderstand?

I don't think I've tested this code at all with blank node graphs, I just copied the approach used for entity URIs on the preceding line, assuming it would work the same for graphs.

How can I create a blank node graph with Fuseki? I've usually just put data into named graphs using s-put, but that requires an explicit graph URI. Or do I have to test this from Java code?

2/ Did I get it right that the default graph is
Quad.defaultGraphNodeGenerated?  Maybe

In my tests the default graph seems to have the URI "urn:x-arq:DefaultGraph", so it's probably this one from Quad.java: public static final Node defaultGraphIRI = NodeFactory.createURI("urn:x-arq:DefaultGraph") ;

Since it's just another URI to the index, indexing works fine here as well. Though it would make sense to add a unit test for indexing the default graph just in case.

How much of the documentation needs to change?  Just another section?

Basically it's just another section for the text-query.html page. Also the the Configuration by Code section currently shows how to use EntityDefinition, it needs to be updated with the new constructor argument.

Where is the documentation kept? Do you take documentation patches as well or what is the preferred way of contributing to the docs?

-Osma

--
Osma Suominen
D.Sc. (Tech), Information Systems Specialist
National Library of Finland
P.O. Box 26 (Teollisuuskatu 23)
00014 HELSINGIN YLIOPISTO
Tel. +358 50 3199529
[email protected]
http://www.nationallibrary.fi

Reply via email to