N3 / TURTLE serializers ignore relative URI
-------------------------------------------

                 Key: JENA-132
                 URL: https://issues.apache.org/jira/browse/JENA-132
             Project: Jena
          Issue Type: Bug
          Components: Jena, RDF API
            Reporter: Alexandre Bertails


Unlike RDF/XML* serializers, N3 and TURTLE ignore the base URI in their output.

  val turtle =
"""
@prefix foaf:    <http://xmlns.com/foaf/0.1/> .
@prefix rdf:     <http://www.w3.org/1999/02/22-rdf-syntax-ns#> .

<#JL>
      a       foaf:Person ;
      foaf:homepage </2007/wiki/people/JoeLambda> ;
      foaf:img <images/me.jpg> ;
      foaf:name "Joe Lambda" .
"""

  val base = "http://w3.org/People/Joe";

  val model = {
    val m = ModelFactory.createDefaultModel()
    m.getReader("TURTLE").read(m, new StringReader(turtle), base)
    m
  }

  model.getWriter("TTL").write(model, System.out, base) // doesn't work as 
expected

  model.getWriter("RDF/XML-ABBREV").write(model, System.out, base) // this one 
is ok

--
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

        

Reply via email to