Details
Description
Testcase:
Model m = ModelFactory.createDefaultModel();
Resource b0 = m.createResource();
Resource b1 = m.createResource();// add 4 statements:
b0.addProperty(OWL.unionOf, b1).addProperty(RDF.type, OWL.Class);
b1.addProperty(RDF.first, b0).addProperty(RDF.rest, RDF.nil);m.write(System.out, "ttl");
m.write(System.out, "nt");
Output:
_:b0 <http://www.w3.org/1999/02/22-rdf-syntax-ns#first>
_:b1 ;
<http://www.w3.org/1999/02/22-rdf-syntax-ns#rest>
() .
_:B40396d1bX2D68d6X2D40b4X2DbbcdX2Dbe185973bfc1 <http://www.w3.org/1999/02/22-rdf-syntax-ns#rest> <http://www.w3.org/1999/02/22-rdf-syntax-ns#nil> .
_:B40396d1bX2D68d6X2D40b4X2DbbcdX2Dbe185973bfc1 <http://www.w3.org/1999/02/22-rdf-syntax-ns#first> _:B4da6d814X2Ddb64X2D4ff1X2Da5d4X2D4f71d5718fd9 .
_:B4da6d814X2Ddb64X2D4ff1X2Da5d4X2D4f71d5718fd9 <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://www.w3.org/2002/07/owl#Class> .
_:B4da6d814X2Ddb64X2D4ff1X2Da5d4X2D4f71d5718fd9 <http://www.w3.org/2002/07/owl#unionOf> _:B40396d1bX2D68d6X2D40b4X2DbbcdX2Dbe185973bfc1 .
So in turtle there are only 2 triples, while expected 4.