Uploaded image for project: 'Apache Commons RDF'
  1. Apache Commons RDF
  2. COMMONSRDF-15

Clarify if foreign BlankNode impls can be used with .contains() and .getTriples()

VotersWatch issueWatchersLinkCloneUpdate Comment AuthorReplace String in CommentUpdate Comment VisibilityDelete Comments
    XMLWordPrintableJSON

Details

    • Improvement
    • Status: Closed
    • Minor
    • Resolution: Not A Problem
    • None
    • None
    • None
    • None

    Description

      What happens if I add a 'foreign' `BlankNode` to a Graph (either directly with `Graph.add(s,t,o)` or within a foreign `Triple` to `Graph.add()` – will I be able to match using that original blank node object "later" in other calls like `.contains()` and `.getTriples()`?

      This is of course straight-forward for IRI and Literal, but trickier for BlankNode.

      e.g. pseudocode:

      impl1 = new Impl1TermFactory();
      b1 = impl1.createBlankNode();
      knows = impl1.createIRI("http://xmlns.com/foaf/0.1/knows");
      alice = impl1.createIRI("http://example.com/alice");
      
      impl2 = new Impl2TermFactory();
      g2 = impl2.createGraph();
      g2.add(b1, knows, alice);
      assertTrue(g2.contains(b1, knows, alice));
      

      As discussed under COMMONSRDF-8 and pull request 7 https://github.com/apache/incubator-commonsrdf/pull/7

      Attachments

        Issue Links

        Activity

          This comment will be Viewable by All Users Viewable by All Users
          Cancel

          People

            stain Stian Soiland-Reyes
            soilandreyes Stian Soiland-Reyes (old) (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Slack

                Issue deployment