[ https://issues.apache.org/jira/browse/JENA-2169?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17429164#comment-17429164 ]
ASF subversion and git services commented on JENA-2169: ------------------------------------------------------- Commit b7bc72ee6c402a55c744e0567dc7b257a851dce5 in jena's branch refs/heads/main from Andy Seaborne [ https://gitbox.apache.org/repos/asf?p=jena.git;h=b7bc72e ] JENA-2169: Enable named Models with blank node name > Dataset interface should support blank node labels for graphs > ------------------------------------------------------------- > > Key: JENA-2169 > URL: https://issues.apache.org/jira/browse/JENA-2169 > Project: Apache Jena > Issue Type: Improvement > Reporter: Jan Martin Keil > Assignee: Andy Seaborne > Priority: Major > > The Recommendations [RDF 1.1 > TriG|https://www.w3.org/TR/trig/#sec-graph-statements] and [RDF 1.1 > N-Quads|https://www.w3.org/TR/n-quads/#simple-triples] permit blank nodes as > graph labels in datasets. However, this is not supported in Apache Jena. To > add support for blank node labels, the interface > {color:#0747a6}{{org.apache.jena.query.Dataset}}{color} and it's implementing > classes would need new methods corresponding to the following methods: > * {color:#0747a6}{{public Model getNamedModel(String uri)}}{color} -> e.g. > {color:#0747a6}{{public Model getLabeledModel(Resource label)}}{color} > * {color:#0747a6}{{public Dataset addNamedModel(String uri, Model > model);}}{color} -> e.g. {color:#0747a6}{{public Dataset > addLabeledModel(Resource label, Model model);}}{color} > * {color:#0747a6}{{public Dataset removeNamedModel(String uri);}}{color} -> > e.g. {color:#0747a6}{{public Dataset removeLabeledModel(Resource > label);}}{color} > * {color:#0747a6}{{public Dataset replaceNamedModel(String uri, Model > model);}}{color} -> e.g. {color:#0747a6}{{public Dataset > replaceLabeledModel(Resource label, Model model);}}{color} > * {color:#0747a6}{{public Iterator<String> listNames()}}{color} -> e.g. > {color:#0747a6}{{public Iterator<Resource> listGraphLabels()}}{color} > This has real *use cases*: If labeled graphs are used to track the provenance > of statements, as e.g. proposed in the Working Group Note [Data on the Web > Best Practices: Data Quality Vocabulary|https://www.w3.org/TR/vocab-dqv/], > minting an URL is not always appropriate. The current *workaround* is to mint > a IRI, e.g. based on an UUID. > However, there might also be *drawbacks*: The [SPARQL 1.1 > Recomendation|https://www.w3.org/TR/sparql11-query/#rGraphRef] permits only > IRIs as graph labels. Graphs with blank node labels might become inaccessible > within SPARQL. But that is probably (didn't test it yet) the same situation > as after importing TriG or N-Quads files with blank node graph labels. (A > shortcoming of SPARQL 1.1 worth to put on [https://github.com/w3c/sparql-12]?) -- This message was sent by Atlassian Jira (v8.3.4#803005)