On 7/2/2012 18:47, Stephen Allen wrote:
On Mon, Jul 2, 2012 at 12:36 AM, Holger Knublauch <hol...@knublauch.com> wrote:
Hi all,

I am aware of Graph.isIsomorphicWith, but I need a function that tests
whether Graph A is a sub-set of Graph B, including the ability to map bnodes
into each other. Does that exist in Jena?

How about:

ask {
   graph <A> { ?s ?p ?o }
   minus { graph <B> { ?s ?p ?o } }
}

That may work for named nodes, but what about bnode structures such as complex OWL class expressions? The bnode identity may be different in both graphs, yet their patterns of co-existence need to be compared. A triple-by-triple comparison will not be able to handle this correctly.

Holger

Reply via email to