You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@jena.apache.org by "Andy Seaborne (Commented) (JIRA)" <ji...@apache.org> on 2012/01/08 18:45:39 UTC
[jira] [Commented] (JENA-188) Warn javadoc readers about the TURTLE
writer's view of prefixes
[ https://issues.apache.org/jira/browse/JENA-188?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13182253#comment-13182253 ]
Andy Seaborne commented on JENA-188:
------------------------------------
Thanks.
What URI were you trying to abbreviate?
The Turtle shares the prefix mapping code with the XML writer.= and so inherits the stricter XML qname rules but it isn't just # that is a legal split. Also, the turtle de-facto spec use to have some unnecessary restrictions:
Consider:
@prefix : <http://example/> .
<http://example/abc> <http://example/12X3> <http://example/#foo> .
which writes:
:abc <http://example/12X3>
<http://example/999> .
showing the first URi is abbreviated, the second and third are not (Turtle did not allow a leading digit until very recently; a prefix name local part can't start #, which is the Turtle comment charcater).
Also, it's a bit random (hash tables are involved) about prefixes that overlap.
We ought to fix the javadoc - and also redo the prefix handling to be Turtle specific now Turtle is being formally standardized.
> Warn javadoc readers about the TURTLE writer's view of prefixes
> ---------------------------------------------------------------
>
> Key: JENA-188
> URL: https://issues.apache.org/jira/browse/JENA-188
> Project: Jena
> Issue Type: Improvement
> Components: Jena
> Affects Versions: Jena 2.7.0
> Reporter: Benson Margulies
> Priority: Minor
> Attachments: JENA-188.patch
>
>
> The turtle writer only applies prefixes that end with '#' when shortening URIs. Here's a javadoc patch to point this out to save other people the debugging that I just did.
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira