You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@jena.apache.org by "Benson Margulies (Created) (JIRA)" <ji...@apache.org> on 2012/01/08 18:23:39 UTC

[jira] [Created] (JENA-188) Warn javadoc readers about the TURTLE writer's view of prefixes

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

        

[jira] [Resolved] (JENA-188) Warn javadoc readers about the TURTLE writer's view of prefixes

Posted by "Andy Seaborne (Resolved) (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/JENA-188?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Andy Seaborne resolved JENA-188.
--------------------------------

       Resolution: Fixed
    Fix Version/s: Jena 2.7.1
         Assignee: Andy Seaborne

The problem is that an NCName can't include a # in the local part. javadoc updated to note this.

                
> 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
>            Assignee: Andy Seaborne
>            Priority: Minor
>             Fix For: Jena 2.7.1
>
>         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

        

[jira] [Commented] (JENA-188) Warn javadoc readers about the TURTLE writer's view of prefixes

Posted by "Andy Seaborne (Commented) (JIRA)" <ji...@apache.org>.
    [ 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

        

[jira] [Closed] (JENA-188) Warn javadoc readers about the TURTLE writer's view of prefixes

Posted by "Andy Seaborne (Closed) (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/JENA-188?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Andy Seaborne closed JENA-188.
------------------------------

    
> 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
>            Assignee: Andy Seaborne
>            Priority: Minor
>             Fix For: Jena 2.7.1
>
>         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

        

[jira] [Updated] (JENA-188) Warn javadoc readers about the TURTLE writer's view of prefixes

Posted by "Benson Margulies (Updated) (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/JENA-188?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Benson Margulies updated JENA-188:
----------------------------------

    Attachment: JENA-188.patch
    
> 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

        

[jira] [Commented] (JENA-188) Warn javadoc readers about the TURTLE writer's view of prefixes

Posted by "Benson Margulies (Commented) (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/JENA-188?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13182254#comment-13182254 ] 

Benson Margulies commented on JENA-188:
---------------------------------------

Andy,

I'm using 2.6.4, since I am too cowardly to update since there's no new TDB release to go with.

In the source for 2.6.4, the relevant code is in N3JenaWriterCommon, and the variable prefix code is all commented out. By experiment, I found (as per the email to the user list) that a prefix of "urn:jug:c" would not be applied to a URI of "urn:jug:c#c1000". I suffered some additional confusion due to the exclusion of "." as a valid character in the tail.

If this is just old news, of course feel free to close as such.

--benson

                
> 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