You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@commons.apache.org by gg...@apache.org on 2017/10/30 14:57:07 UTC

[07/22] commons-rdf git commit: Module names, directory names, and artifact names should match.

http://git-wip-us.apache.org/repos/asf/commons-rdf/blob/d59203ce/integration-tests/src/test/java/org/apache/commons/rdf/integrationtests/JSONLDParsingTest.java
----------------------------------------------------------------------
diff --git a/integration-tests/src/test/java/org/apache/commons/rdf/integrationtests/JSONLDParsingTest.java b/integration-tests/src/test/java/org/apache/commons/rdf/integrationtests/JSONLDParsingTest.java
deleted file mode 100644
index 3bd406a..0000000
--- a/integration-tests/src/test/java/org/apache/commons/rdf/integrationtests/JSONLDParsingTest.java
+++ /dev/null
@@ -1,164 +0,0 @@
-/**
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements.  See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership.  The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.apache.commons.rdf.integrationtests;
-
-import static org.junit.Assert.assertTrue;
-
-import java.io.IOException;
-import java.io.InputStream;
-import java.net.URL;
-
-import org.apache.commons.rdf.api.Graph;
-import org.apache.commons.rdf.api.IRI;
-import org.apache.commons.rdf.api.Literal;
-import org.apache.commons.rdf.api.RDF;
-import org.apache.commons.rdf.jena.JenaDataset;
-import org.apache.commons.rdf.jena.JenaRDF;
-import org.apache.commons.rdf.jsonldjava.JsonLdGraph;
-import org.apache.commons.rdf.jsonldjava.JsonLdRDF;
-import org.apache.commons.rdf.rdf4j.RDF4J;
-import org.apache.commons.rdf.rdf4j.RDF4JGraph;
-import org.apache.commons.rdf.simple.SimpleRDF;
-import org.apache.jena.riot.RDFDataMgr;
-import org.eclipse.rdf4j.model.Model;
-import org.eclipse.rdf4j.rio.RDFFormat;
-import org.eclipse.rdf4j.rio.Rio;
-import org.junit.Before;
-import org.junit.Test;
-
-import com.fasterxml.jackson.core.JsonParseException;
-import com.github.jsonldjava.core.JsonLdError;
-import com.github.jsonldjava.core.JsonLdOptions;
-import com.github.jsonldjava.core.JsonLdProcessor;
-import com.github.jsonldjava.core.RDFDataset;
-import com.github.jsonldjava.utils.JsonUtils;
-
-/**
- * COMMONSRDF-57 etc: For upgrades, ensure JSONLD-Java parses well in all
- * implementations even if they might have slightly incompatible versions of
- * their dependencies.
- * <p>
- * The <code>*Embedded</code> tests parse <code>alice-embedded.jsonld</code>
- * from the test classpath through Jena, RDF4J and JSONLD-Java and verifies it
- * contains the expected triples using {@link #checkGraph(Graph)}. This ensures
- * that the versions of JSONLD-Java and Jackson are compatible with Jena and
- * RDF4J.
- * <p>
- * The <code>*Cached</code> tests parse <code>alice-cached.jsonld</code>, which
- * references an external <code>@context</code> of http://example.com/context -
- * but using the <a href=
- * "https://github.com/jsonld-java/jsonld-java#loading-contexts-from-classpathjar">jarcache.json</a>
- * mechanism of JSONLD-Java, this context will be loaded from
- * <code>contexts/example.jsonld</code> on the test classpath instead. This
- * ensures that the versions of HTTPClient is compatible with JSONLD-Java
- * (however it does not check that it is compatible with Jena and
- * RDF4J's external fetching of RDF documents).
- * 
- */
-public class JSONLDParsingTest {
-
-    static RDF rdf = new SimpleRDF();
-    static IRI alice = rdf.createIRI("http://example.com/Alice");
-    static IRI name = rdf.createIRI("http://schema.org/name");
-    static IRI type = rdf.createIRI("http://www.w3.org/1999/02/22-rdf-syntax-ns#type");
-    static IRI person = rdf.createIRI("http://schema.org/Person");
-    static Literal aliceWLand = rdf.createLiteral("Alice W. Land");
-
-    URL aliceCached = getClass().getResource("/alice-cached.jsonld");
-    URL aliceEmbedded = getClass().getResource("/alice-embedded.jsonld");
-
-    /**
-     * Pre-test that src/test/resources files are on the classpath
-     * 
-     */
-    @Before
-    public void checkTestResources() throws Exception {
-        aliceCached.openStream().close();
-        aliceEmbedded.openStream().close();
-        // Used by JSONLD-Java to avoid external dependencies. See
-        // https://github.com/jsonld-java/jsonld-java#loading-contexts-from-classpathjar
-        getClass().getResourceAsStream("/jarcache.json").close();
-        getClass().getResourceAsStream("/contexts/example.jsonld").close();
-        // (We'll use these to ensure our HTTPClient dependency works)
-    }
-
-    private void checkGraph(Graph g) {
-        assertTrue(g.contains(alice, name, aliceWLand));
-        assertTrue(g.contains(alice, type, person));
-    }
-
-    @Test
-    public void jenaParseEmbedded() throws Exception {
-        jenaParse(aliceEmbedded);
-    }
-
-    @Test
-    public void jenaParseCached() throws Exception {
-        // Check if HTTPClient cache is used from 
-        // jarcache.json
-        jenaParse(aliceCached);
-    }
-
-    private void jenaParse(URL url) {
-        JenaDataset dataset = new JenaRDF().createDataset();
-        RDFDataMgr.read(dataset.asJenaDatasetGraph(), url.toExternalForm());
-        checkGraph(dataset.getGraph());
-    }
-
-    @Test
-    public void rdf4jParseEmbedded() throws Exception {
-        rdf4jParse(aliceEmbedded);
-    }
-
-    @Test
-    public void rdf4jParseCached() throws Exception {
-        // Check if HTTPClient cache is used from 
-        // jarcache.json
-        rdf4jParse(aliceCached);
-    }
-
-    private void rdf4jParse(URL url) throws IOException {
-        Model model;
-        try (InputStream in = url.openStream()) {
-            model = Rio.parse(in, url.toExternalForm(), RDFFormat.JSONLD);
-        }
-        RDF4JGraph graph = new RDF4J().asGraph(model);
-        checkGraph(graph);
-    }
-
-    @Test
-    public void jsonldParseEmbedded() throws Exception {
-        jsonldParse(aliceEmbedded);
-    }
-
-    @Test
-    public void jsonldParseCached() throws Exception {
-        // Check if HTTPClient cache is used from 
-        // jarcache.json
-        jsonldParse(aliceCached);
-    }
-
-    private void jsonldParse(URL url) throws JsonParseException, IOException, JsonLdError {
-        Object aliceJson = JsonUtils.fromURL(url, JsonUtils.getDefaultHttpClient());
-        JsonLdOptions options = new JsonLdOptions();
-        options.setBase(url.toExternalForm());
-        RDFDataset ds = (RDFDataset) JsonLdProcessor.toRDF(aliceJson);
-        JsonLdGraph graph = new JsonLdRDF().asGraph(ds);
-        checkGraph(graph);
-    }
-}

http://git-wip-us.apache.org/repos/asf/commons-rdf/blob/d59203ce/integration-tests/src/test/resources/alice-cached.jsonld
----------------------------------------------------------------------
diff --git a/integration-tests/src/test/resources/alice-cached.jsonld b/integration-tests/src/test/resources/alice-cached.jsonld
deleted file mode 100644
index 494d20e..0000000
--- a/integration-tests/src/test/resources/alice-cached.jsonld
+++ /dev/null
@@ -1,9 +0,0 @@
-{ "http://purl.org/dc/terms/license" :
-   "Licensed to the Apache Software Foundation (ASF) under one or more\n contributor license agreements.  See the NOTICE file distributed with\n this work for additional information regarding copyright ownership.\n The ASF licenses this file to You under the Apache License, Version 2.0\n (the \"License\"); you may not use this file except in compliance with\n the License.  You may obtain a copy of the License at\n \n http://www.apache.org/licenses/LICENSE-2.0\n \n Unless required by applicable law or agreed to in writing, software\n distributed under the License is distributed on an \"AS IS\" BASIS,\n WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n See the License for the specific language governing permissions and\n limitations under the License.\n",
-  
-  "@context": "http://example.com/context",
-  "@id": "ex:Alice",
-  "@type": "Person",
-  "name": "Alice W. Land"
-}
-

http://git-wip-us.apache.org/repos/asf/commons-rdf/blob/d59203ce/integration-tests/src/test/resources/alice-embedded.jsonld
----------------------------------------------------------------------
diff --git a/integration-tests/src/test/resources/alice-embedded.jsonld b/integration-tests/src/test/resources/alice-embedded.jsonld
deleted file mode 100644
index 7c8ca85..0000000
--- a/integration-tests/src/test/resources/alice-embedded.jsonld
+++ /dev/null
@@ -1,16 +0,0 @@
-{ "http://purl.org/dc/terms/license" :
-   "Licensed to the Apache Software Foundation (ASF) under one or more\n contributor license agreements.  See the NOTICE file distributed with\n this work for additional information regarding copyright ownership.\n The ASF licenses this file to You under the Apache License, Version 2.0\n (the \"License\"); you may not use this file except in compliance with\n the License.  You may obtain a copy of the License at\n \n http://www.apache.org/licenses/LICENSE-2.0\n \n Unless required by applicable law or agreed to in writing, software\n distributed under the License is distributed on an \"AS IS\" BASIS,\n WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n See the License for the specific language governing permissions and\n limitations under the License.\n",
-   
-  "@context": {
-    "xsd": "http://www.w3.org/2001/XMLSchema#",
-    "schema": "http://schema.org/",
-    "ex": "http://example.com/",
-    "name": "schema:name",
-    "Person": "schema:Person"
-  },
-
-  "@id": "ex:Alice",
-  "@type": "Person",
-  "name": "Alice W. Land"
-}
-

http://git-wip-us.apache.org/repos/asf/commons-rdf/blob/d59203ce/integration-tests/src/test/resources/contexts/example.jsonld
----------------------------------------------------------------------
diff --git a/integration-tests/src/test/resources/contexts/example.jsonld b/integration-tests/src/test/resources/contexts/example.jsonld
deleted file mode 100644
index 0e58a65..0000000
--- a/integration-tests/src/test/resources/contexts/example.jsonld
+++ /dev/null
@@ -1,11 +0,0 @@
-{ "http://purl.org/dc/terms/license" :
-   "Licensed to the Apache Software Foundation (ASF) under one or more\n contributor license agreements.  See the NOTICE file distributed with\n this work for additional information regarding copyright ownership.\n The ASF licenses this file to You under the Apache License, Version 2.0\n (the \"License\"); you may not use this file except in compliance with\n the License.  You may obtain a copy of the License at\n \n http://www.apache.org/licenses/LICENSE-2.0\n \n Unless required by applicable law or agreed to in writing, software\n distributed under the License is distributed on an \"AS IS\" BASIS,\n WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n See the License for the specific language governing permissions and\n limitations under the License.\n",
-
-  "@context": {
-    "xsd": "http://www.w3.org/2001/XMLSchema#",
-    "schema": "http://schema.org/",
-    "ex": "http://example.com/",
-    "name": "schema:name",
-    "Person": "schema:Person"
-  }
-}

http://git-wip-us.apache.org/repos/asf/commons-rdf/blob/d59203ce/integration-tests/src/test/resources/jarcache.json
----------------------------------------------------------------------
diff --git a/integration-tests/src/test/resources/jarcache.json b/integration-tests/src/test/resources/jarcache.json
deleted file mode 100644
index 05eb13c..0000000
--- a/integration-tests/src/test/resources/jarcache.json
+++ /dev/null
@@ -1,10 +0,0 @@
-[
- {
-   "X-License":
-     "Licensed to the Apache Software Foundation (ASF) under one or more\n contributor license agreements.  See the NOTICE file distributed with\n this work for additional information regarding copyright ownership.\n The ASF licenses this file to You under the Apache License, Version 2.0\n (the \"License\"); you may not use this file except in compliance with\n the License.  You may obtain a copy of the License at\n \n http://www.apache.org/licenses/LICENSE-2.0\n \n Unless required by applicable law or agreed to in writing, software\n distributed under the License is distributed on an \"AS IS\" BASIS,\n WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n See the License for the specific language governing permissions and\n limitations under the License.\n", 
-     
-    "Content-Location": "http://example.com/context",
-    "X-Classpath": "contexts/example.jsonld",
-    "Content-Type": "application/ld+json"
-  }
-]
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/commons-rdf/blob/d59203ce/jena/pom.xml
----------------------------------------------------------------------
diff --git a/jena/pom.xml b/jena/pom.xml
deleted file mode 100644
index c518cdf..0000000
--- a/jena/pom.xml
+++ /dev/null
@@ -1,112 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!--
-
-    Licensed to the Apache Software Foundation (ASF) under one
-    or more contributor license agreements. See the NOTICE file
-    distributed with this work for additional information
-    regarding copyright ownership. The ASF licenses this file
-    to you under the Apache License, Version 2.0 (the
-    "License"); you may not use this file except in compliance
-    with the License.  You may obtain a copy of the License at
-
-        http://www.apache.org/licenses/LICENSE-2.0
-
-    Unless required by applicable law or agreed to in writing, software
-    distributed under the License is distributed on an "AS IS" BASIS,
-    WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-    See the License for the specific language governing permissions and
-    limitations under the License.
-
--->
-<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
-	<modelVersion>4.0.0</modelVersion>
-
-	<parent>
-		<groupId>org.apache.commons</groupId>
-		<artifactId>commons-rdf-parent</artifactId>
-		<version>0.5.0-SNAPSHOT</version>
-	</parent>
-
-	<artifactId>commons-rdf-jena</artifactId>
-	<packaging>jar</packaging>
-
-	<name>Commons RDF impl: Jena</name>
-	<description>Apache Jena implementation of Commons RDF API</description>
-
-    <distributionManagement>
-      <site>
-        <id>commonsrdf-api-site</id>
-        <url>scm:svn:${commons.scmPubUrl}/jena/</url>
-      </site>
-    </distributionManagement>
-
-	<dependencies>
-		<dependency>
-			<groupId>${project.parent.groupId}</groupId>
-			<artifactId>commons-rdf-api</artifactId>
-			<version>${project.version}</version>
-		</dependency>
-		<dependency>
-			<groupId>${project.parent.groupId}</groupId>
-			<artifactId>commons-rdf-simple</artifactId>
-			<version>${project.version}</version>
-		</dependency>
-		<!-- Uncomment below and disable jena-osgi to access the regular non-osgi 
-			 Jena dependencies (e.g. for debugging) -->
-		<!-- 
-	
-		<dependency>
-			<groupId>org.apache.jena</groupId>
-			<artifactId>apache-jena-libs</artifactId>
-			<version>${jena.version}</version>
-			<type>pom</type>
-			<scope>optional</scope>
-		</dependency>
-				--> 
-
-		<!-- As commons-rdf-jena is an OSGi bundle, we'll use the Jena OSGi bundle -->
-		<dependency>
-			<groupId>org.apache.jena</groupId>
-			<artifactId>jena-osgi</artifactId>
-			<version>${jena.version}</version>
-		</dependency>
-
-		<!-- Additional bundles needed by jena-osgi -->
-		<dependency>
-			<groupId>org.apache.servicemix.bundles</groupId>
-			<artifactId>org.apache.servicemix.bundles.xerces</artifactId>
-			<version>${servicemix.xerces.version}</version>
-		</dependency>
-		<dependency>
-			<groupId>com.github.andrewoma.dexx</groupId>
-			<artifactId>collection</artifactId>
-			<version>${dexx.collection.version}</version>
-		</dependency>
-
-
-		<dependency>
-			<groupId>${project.parent.groupId}</groupId>
-			<artifactId>commons-rdf-api</artifactId>
-			<version>${project.version}</version>
-			<classifier>tests</classifier>
-			<scope>test</scope>
-		</dependency>
-	</dependencies>
-
-  <build>
-    <plugins>
-      <plugin>
-        <groupId>org.apache.felix</groupId>
-        <artifactId>maven-bundle-plugin</artifactId>
-        <configuration>
-          <instructions>
-            <Bundle-SymbolicName>org.apache.commons.rdf.jena</Bundle-SymbolicName>
-            <Automatic-Module-Name>org.apache.commons.rdf.jena</Automatic-Module-Name>
-            <Require-Capability>osgi.extender; filter:="(osgi.extender=osgi.serviceloader.registrar)";resolution:=optional</Require-Capability>
-            <Provide-Capability>osgi.serviceloader; osgi.serviceloader=org.apache.commons.rdf.api.RDF</Provide-Capability>
-          </instructions>
-        </configuration>
-      </plugin>
-    </plugins>
-  </build>
-</project>

http://git-wip-us.apache.org/repos/asf/commons-rdf/blob/d59203ce/jena/src/main/java/org/apache/commons/rdf/jena/ConversionException.java
----------------------------------------------------------------------
diff --git a/jena/src/main/java/org/apache/commons/rdf/jena/ConversionException.java b/jena/src/main/java/org/apache/commons/rdf/jena/ConversionException.java
deleted file mode 100644
index 6800c30..0000000
--- a/jena/src/main/java/org/apache/commons/rdf/jena/ConversionException.java
+++ /dev/null
@@ -1,48 +0,0 @@
-/**
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements.  See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership.  The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.apache.commons.rdf.jena;
-
-/**
- * Exception thrown when a problem arises across the Jena-CommonRDF boundary.
- * <p>
- * This should not happen in well-formed RDF data but, for example, Jena triples
- * allow
- * <a href="http://www.w3.org/TR/rdf11-concepts/#section-generalized-rdf" >
- * generalized RDF</a>.
- */
-
-public class ConversionException extends RuntimeException {
-    private static final long serialVersionUID = -898179977312382568L;
-
-    public ConversionException() {
-        super();
-    }
-
-    public ConversionException(final String message) {
-        super(message);
-    }
-
-    public ConversionException(final Throwable cause) {
-        super(cause);
-    }
-
-    public ConversionException(final String message, final Throwable cause) {
-        super(message, cause);
-    }
-}

http://git-wip-us.apache.org/repos/asf/commons-rdf/blob/d59203ce/jena/src/main/java/org/apache/commons/rdf/jena/JenaBlankNode.java
----------------------------------------------------------------------
diff --git a/jena/src/main/java/org/apache/commons/rdf/jena/JenaBlankNode.java b/jena/src/main/java/org/apache/commons/rdf/jena/JenaBlankNode.java
deleted file mode 100644
index ef12951..0000000
--- a/jena/src/main/java/org/apache/commons/rdf/jena/JenaBlankNode.java
+++ /dev/null
@@ -1,33 +0,0 @@
-/**
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements.  See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership.  The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.apache.commons.rdf.jena;
-
-import org.apache.commons.rdf.api.BlankNode;
-import org.apache.jena.graph.Node;
-
-/**
- * A Jena-backed {@link BlankNode}.
- * <p>
- * The underlying Jena {@link Node} can be accessed from {@link #asJenaNode()}.
- * 
- * @see Node#isBlank()
- */
-public interface JenaBlankNode extends JenaRDFTerm, BlankNode {
-
-}

http://git-wip-us.apache.org/repos/asf/commons-rdf/blob/d59203ce/jena/src/main/java/org/apache/commons/rdf/jena/JenaDataset.java
----------------------------------------------------------------------
diff --git a/jena/src/main/java/org/apache/commons/rdf/jena/JenaDataset.java b/jena/src/main/java/org/apache/commons/rdf/jena/JenaDataset.java
deleted file mode 100644
index bb8e39c..0000000
--- a/jena/src/main/java/org/apache/commons/rdf/jena/JenaDataset.java
+++ /dev/null
@@ -1,56 +0,0 @@
-/**
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements.  See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership.  The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.apache.commons.rdf.jena;
-
-import org.apache.commons.rdf.api.Dataset;
-import org.apache.commons.rdf.api.Graph;
-import org.apache.jena.sparql.core.DatasetGraph;
-
-/**
- * A Jena-backed {@link Dataset}.
- * <p>
- * The underlying Jena {@link DatasetGraph} can be accessed with
- * {@link #asJenaDatasetGraph()}.
- */
-public interface JenaDataset extends org.apache.commons.rdf.api.Dataset {
-
-    /**
-     * Return the underlying Jena {@link DatasetGraph}.
-     * <p>
-     * Changes to the Jena <em>dataset graph</em> are reflected in the Commons
-     * RDF dataset and vice versa.
-     * 
-     * @return A Jena {@link DatasetGraph}
-     */
-    public DatasetGraph asJenaDatasetGraph();
-
-    /**
-     * Return a union graph view of this dataset.
-     * <p>
-     * The <em>union graph</em> contains triples in any graph (including the
-     * default graph).
-     * <p>
-     * Changes in the union graph are reflected in the Commons RDF dataset and
-     * vice versa. Triples added to the graph are added to the default graph.
-     * 
-     * @return A union {@link Graph}
-     */
-    public JenaGraph getUnionGraph();
-
-}

http://git-wip-us.apache.org/repos/asf/commons-rdf/blob/d59203ce/jena/src/main/java/org/apache/commons/rdf/jena/JenaGeneralizedQuadLike.java
----------------------------------------------------------------------
diff --git a/jena/src/main/java/org/apache/commons/rdf/jena/JenaGeneralizedQuadLike.java b/jena/src/main/java/org/apache/commons/rdf/jena/JenaGeneralizedQuadLike.java
deleted file mode 100644
index a73d92c..0000000
--- a/jena/src/main/java/org/apache/commons/rdf/jena/JenaGeneralizedQuadLike.java
+++ /dev/null
@@ -1,38 +0,0 @@
-/**
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements.  See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership.  The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.apache.commons.rdf.jena;
-
-import org.apache.commons.rdf.api.Quad;
-import org.apache.commons.rdf.api.RDFTerm;
-
-/**
- * A generalized quad representation.
- * <p>
- * A <em>generalized quad</em> is a quad-like object which allow any
- * {@link RDFTerm} type for its {@link #getSubject()}, {@link #getPredicate()}
- * {@link #getObject()} and {@link #getGraphName()}. This might be useful with
- * some serializations like JSON-LD.
- * <p>
- * Note that unlike {@link Quad}, this type does not have fixed semantics for
- * {@link Object#equals(Object)} or {@link Object#hashCode()} beyond object
- * identity.
- * 
- * @see JenaGeneralizedTripleLike
- */
-public interface JenaGeneralizedQuadLike extends JenaQuadLike<RDFTerm> {
-}

http://git-wip-us.apache.org/repos/asf/commons-rdf/blob/d59203ce/jena/src/main/java/org/apache/commons/rdf/jena/JenaGeneralizedTripleLike.java
----------------------------------------------------------------------
diff --git a/jena/src/main/java/org/apache/commons/rdf/jena/JenaGeneralizedTripleLike.java b/jena/src/main/java/org/apache/commons/rdf/jena/JenaGeneralizedTripleLike.java
deleted file mode 100644
index f65ed35..0000000
--- a/jena/src/main/java/org/apache/commons/rdf/jena/JenaGeneralizedTripleLike.java
+++ /dev/null
@@ -1,38 +0,0 @@
-/**
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements.  See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership.  The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.apache.commons.rdf.jena;
-
-import org.apache.commons.rdf.api.RDFTerm;
-import org.apache.commons.rdf.api.Triple;
-
-/**
- * A generalized triple representation.
- * <p>
- * A <em>generalized triple</em> is a triple-like object which allow any
- * {@link RDFTerm} type for its {@link #getSubject()}, {@link #getPredicate()}
- * and {@link #getObject()}. This might be useful with some serializations like
- * JSON-LD.
- * <p>
- * Note that unlike {@link Triple}, this type does not have fixed semantics for
- * {@link Object#equals(Object)} or {@link Object#hashCode()} beyond object
- * identity.
- * 
- * @see JenaGeneralizedQuadLike
- */
-public interface JenaGeneralizedTripleLike extends JenaTripleLike {
-}

http://git-wip-us.apache.org/repos/asf/commons-rdf/blob/d59203ce/jena/src/main/java/org/apache/commons/rdf/jena/JenaGraph.java
----------------------------------------------------------------------
diff --git a/jena/src/main/java/org/apache/commons/rdf/jena/JenaGraph.java b/jena/src/main/java/org/apache/commons/rdf/jena/JenaGraph.java
deleted file mode 100644
index b605b4b..0000000
--- a/jena/src/main/java/org/apache/commons/rdf/jena/JenaGraph.java
+++ /dev/null
@@ -1,56 +0,0 @@
-/**
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements.  See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership.  The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.apache.commons.rdf.jena;
-
-// NOTE: To avoid confusion, don't import Graph as it exists in both APIs
-import org.apache.jena.rdf.model.Model;
-// 
-
-/**
- * A Jena-backed {@link org.apache.commons.rdf.api.Graph}.
- * <p>
- * The underlying Jena {@link org.apache.jena.graph.Graph} can be accessed with
- * {@link #asJenaGraph()}.
- */
-public interface JenaGraph extends org.apache.commons.rdf.api.Graph {
-
-    /**
-     * Return the underlying Jena {@link org.apache.jena.graph.Graph}.
-     * <p>
-     * Changes to the Jena graph are reflected in the Commons RDF graph and vice
-     * versa.
-     * 
-     * @return A Jena {@link org.apache.jena.graph.Graph}
-     */
-    public org.apache.jena.graph.Graph asJenaGraph();
-
-    /**
-     * Return the graph as a Jena {@link Model}.
-     * <p>
-     * Changes to the Jena model are reflected in the Commons RDF graph and vice
-     * versa.
-     * <p>
-     * Note that in some cases there is no underlying Jena {@link Model}, in
-     * which case this method will create one. Subsequent calls should return
-     * the same model.
-     * 
-     * @return A Jena {@link Model}
-     */
-    public Model asJenaModel();
-}

http://git-wip-us.apache.org/repos/asf/commons-rdf/blob/d59203ce/jena/src/main/java/org/apache/commons/rdf/jena/JenaIRI.java
----------------------------------------------------------------------
diff --git a/jena/src/main/java/org/apache/commons/rdf/jena/JenaIRI.java b/jena/src/main/java/org/apache/commons/rdf/jena/JenaIRI.java
deleted file mode 100644
index 0edd1b5..0000000
--- a/jena/src/main/java/org/apache/commons/rdf/jena/JenaIRI.java
+++ /dev/null
@@ -1,32 +0,0 @@
-/**
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements.  See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership.  The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.apache.commons.rdf.jena;
-
-import org.apache.commons.rdf.api.IRI;
-import org.apache.jena.graph.Node;
-
-/**
- * A Jena-backed {@link IRI}.
- * <p>
- * The underlying Jena {@link Node} can be accessed from {@link #asJenaNode()}.
- * 
- * @see Node#isURI()
- */
-public interface JenaIRI extends JenaRDFTerm, IRI {
-
-}

http://git-wip-us.apache.org/repos/asf/commons-rdf/blob/d59203ce/jena/src/main/java/org/apache/commons/rdf/jena/JenaLiteral.java
----------------------------------------------------------------------
diff --git a/jena/src/main/java/org/apache/commons/rdf/jena/JenaLiteral.java b/jena/src/main/java/org/apache/commons/rdf/jena/JenaLiteral.java
deleted file mode 100644
index 96bf530..0000000
--- a/jena/src/main/java/org/apache/commons/rdf/jena/JenaLiteral.java
+++ /dev/null
@@ -1,32 +0,0 @@
-/**
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements.  See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership.  The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.apache.commons.rdf.jena;
-
-import org.apache.commons.rdf.api.Literal;
-import org.apache.jena.graph.Node;
-
-/**
- * A Jena-backed {@link Literal}
- *
- * The underlying Jena {@link Node} can be accessed from {@link #asJenaNode()}.
- * 
- * @see Node#isLiteral()
- */
-public interface JenaLiteral extends JenaRDFTerm, Literal {
-
-}

http://git-wip-us.apache.org/repos/asf/commons-rdf/blob/d59203ce/jena/src/main/java/org/apache/commons/rdf/jena/JenaQuad.java
----------------------------------------------------------------------
diff --git a/jena/src/main/java/org/apache/commons/rdf/jena/JenaQuad.java b/jena/src/main/java/org/apache/commons/rdf/jena/JenaQuad.java
deleted file mode 100644
index 0004017..0000000
--- a/jena/src/main/java/org/apache/commons/rdf/jena/JenaQuad.java
+++ /dev/null
@@ -1,29 +0,0 @@
-/**
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements.  See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership.  The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.apache.commons.rdf.jena;
-
-import org.apache.commons.rdf.api.BlankNodeOrIRI;
-
-/**
- * A Jena-backed {@link org.apache.commons.rdf.api.Quad}.
- * <p>
- * The underlying Jena {@link org.apache.jena.sparql.core.Quad} can be accessed
- * with {@link #asJenaQuad()}.
- */
-public interface JenaQuad extends org.apache.commons.rdf.api.Quad, JenaQuadLike<BlankNodeOrIRI> {
-}

http://git-wip-us.apache.org/repos/asf/commons-rdf/blob/d59203ce/jena/src/main/java/org/apache/commons/rdf/jena/JenaQuadLike.java
----------------------------------------------------------------------
diff --git a/jena/src/main/java/org/apache/commons/rdf/jena/JenaQuadLike.java b/jena/src/main/java/org/apache/commons/rdf/jena/JenaQuadLike.java
deleted file mode 100644
index 480bdb9..0000000
--- a/jena/src/main/java/org/apache/commons/rdf/jena/JenaQuadLike.java
+++ /dev/null
@@ -1,43 +0,0 @@
-/**
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements.  See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership.  The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.apache.commons.rdf.jena;
-
-import org.apache.commons.rdf.api.QuadLike;
-import org.apache.commons.rdf.api.RDFTerm;
-import org.apache.jena.sparql.core.Quad;
-
-/**
- * A {@link QuadLike} wrapper of a Jena {@link Quad}.
- * <p>
- * This is a marker interface common to its specializations {@link JenaQuad} and
- * {@link JenaGeneralizedQuadLike}.
- * 
- * @see JenaQuad
- * @see JenaGeneralizedQuadLike
- * 
- */
-public interface JenaQuadLike<G extends RDFTerm> extends JenaTripleLike, QuadLike<G> {
-
-    /**
-     * Return the adapted Jena quad
-     * 
-     * @return Adapted Jena {@link Quad}.
-     */
-    public Quad asJenaQuad();
-}

http://git-wip-us.apache.org/repos/asf/commons-rdf/blob/d59203ce/jena/src/main/java/org/apache/commons/rdf/jena/JenaRDF.java
----------------------------------------------------------------------
diff --git a/jena/src/main/java/org/apache/commons/rdf/jena/JenaRDF.java b/jena/src/main/java/org/apache/commons/rdf/jena/JenaRDF.java
deleted file mode 100644
index 68cedb4..0000000
--- a/jena/src/main/java/org/apache/commons/rdf/jena/JenaRDF.java
+++ /dev/null
@@ -1,799 +0,0 @@
-/**
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements.  See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership.  The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.apache.commons.rdf.jena;
-
-import java.util.Optional;
-import java.util.UUID;
-import java.util.function.Consumer;
-
-import org.apache.commons.rdf.api.BlankNode;
-import org.apache.commons.rdf.api.BlankNodeOrIRI;
-import org.apache.commons.rdf.api.Dataset;
-import org.apache.commons.rdf.api.Graph;
-import org.apache.commons.rdf.api.IRI;
-import org.apache.commons.rdf.api.Literal;
-import org.apache.commons.rdf.api.Quad;
-import org.apache.commons.rdf.api.QuadLike;
-import org.apache.commons.rdf.api.RDFSyntax;
-import org.apache.commons.rdf.api.RDFTerm;
-import org.apache.commons.rdf.api.RDF;
-import org.apache.commons.rdf.api.Triple;
-import org.apache.commons.rdf.api.TripleLike;
-import org.apache.commons.rdf.jena.impl.InternalJenaFactory;
-import org.apache.jena.datatypes.RDFDatatype;
-import org.apache.jena.datatypes.xsd.XSDDatatype;
-import org.apache.jena.graph.Node;
-import org.apache.jena.graph.NodeFactory;
-import org.apache.jena.riot.Lang;
-import org.apache.jena.riot.RDFDataMgr;
-import org.apache.jena.riot.RDFLanguages;
-import org.apache.jena.riot.system.StreamRDF;
-import org.apache.jena.riot.system.StreamRDFBase;
-import org.apache.jena.sparql.core.DatasetGraph;
-import org.apache.jena.sparql.graph.GraphFactory;
-
-/**
- * Apache Jena RDF implementation.
- * <p>
- * Instances of JenaRDF can also convert existing objects from Jena with methods
- * like {@link #asRDFTerm(Node)} and
- * {@link #asGraph(org.apache.jena.graph.Graph)}, and vice versa from any
- * Commons RDF object to Jena with the <code>asJena*</code> methods like
- * {@link #asJenaNode(RDFTerm)} and {@link #asJenaGraph(Graph)}.
- * <p>
- * Note that Commons RDF objects created by this class implement the
- * specializations interfaces like {@link JenaRDFTerm}, {@link JenaGraph} and
- * {@link JenaTriple}, which provide access to the underlying Jena objects, e.g.
- * with {@link JenaRDFTerm#asJenaNode()}.
- * <p>
- * For the purpose of {@link BlankNode} identity when using
- * {@link #createBlankNode(String)} (see {@link BlankNode#equals(Object)} and
- * {@link BlankNode#uniqueReference()}), each instance of JenaRDF uses an
- * internal random state. If for some reason consistent/reproducible BlankNode
- * identity is desired, it is possible to retrieve the state as a UUID using
- * {@link #salt()} for subsequent use with {@link JenaRDF#JenaRDF(UUID)} - note
- * that such consistency is only guaranteed within the same minor version of
- * Commons RDF.
- * 
- * @see RDF
- */
-public final class JenaRDF implements RDF {
-
-    private static InternalJenaFactory internalJenaFactory = new InternalJenaFactory() {
-    };
-
-    private final UUID salt;
-
-    /**
-     * Create a JenaRDF.
-     * <p>
-     * This constructor will use a randomly generated {@link UUID} as a salt for
-     * the purposes of {@link BlankNode} identity, see {@link #salt()}.
-     */
-    public JenaRDF() {
-        this.salt = UUID.randomUUID();
-    }
-
-    /**
-     * Create a JenaRDF.
-     * <p>
-     * This constructor will use the specified {@link UUID} as a salt for the
-     * purposes of {@link BlankNode} identity, and should only be used in cases
-     * where predictable and consistent {@link BlankNode#uniqueReference()} are
-     * important.
-     * 
-     * @param salt
-     *            {@link UUID} to use as salt for {@link BlankNode} equality
-     */
-    public JenaRDF(final UUID salt) {
-        this.salt = salt;
-    }
-
-    @Override
-    public JenaBlankNode createBlankNode() {
-        return internalJenaFactory.createBlankNode(salt());
-    }
-
-    @Override
-    public JenaBlankNode createBlankNode(final String name) {
-        return internalJenaFactory.createBlankNode(name, salt());
-    }
-
-    @Override
-    public JenaDataset createDataset() {
-        return internalJenaFactory.createDataset(salt());
-    }
-
-    @Override
-    public JenaGraph createGraph() {
-        return internalJenaFactory.createGraph(salt());
-    }
-
-    @Override
-    public JenaIRI createIRI(final String iri) {
-        validateIRI(iri);
-        return internalJenaFactory.createIRI(iri);
-    }
-
-    @Override
-    public JenaLiteral createLiteral(final String lexicalForm) {
-        return internalJenaFactory.createLiteral(lexicalForm);
-    }
-
-    @Override
-    public JenaLiteral createLiteral(final String lexicalForm, final IRI dataType) {
-        return internalJenaFactory.createLiteralDT(lexicalForm, dataType.getIRIString());
-    }
-
-    @Override
-    public JenaLiteral createLiteral(final String lexicalForm, final String languageTag) {
-        validateLang(languageTag);
-        return internalJenaFactory.createLiteralLang(lexicalForm, languageTag);
-    }
-
-    @Override
-    public JenaTriple createTriple(final BlankNodeOrIRI subject, final IRI predicate, final RDFTerm object) {
-        return internalJenaFactory.createTriple(subject, predicate, object);
-    }
-
-    /**
-     * {@inheritDoc}
-     * <p>
-     * In addition to supporting a <code>graphName</code> of <code>null</code>
-     * for representing a triple in the <em>default graph</em>, this method also
-     * recognize a {@link JenaIRI} which {@link JenaRDFTerm#asJenaNode()}
-     * represent the default graph according to
-     * {@link org.apache.jena.sparql.core.Quad#isDefaultGraph(Node)}, in which
-     * case the returned JenaQuad will have a {@link Quad#getGraphName()} of
-     * {@link Optional#empty()} rather than the provided IRI.
-     * 
-     */
-    @Override
-    public JenaQuad createQuad(final BlankNodeOrIRI graphName, final BlankNodeOrIRI subject, final IRI predicate, final RDFTerm object)
-            throws IllegalArgumentException, UnsupportedOperationException {
-        return internalJenaFactory.createQuad(subject, predicate, object, graphName);
-    }
-
-    /**
-     * Create a generalized Jena triple.
-     * <p>
-     * The <em>generalized triple</em> supports any {@link RDFTerm} as its
-     * {@link TripleLike#getSubject()} {@link TripleLike#getPredicate()} or
-     * {@link TripleLike#getObject()}.
-     *
-     * @see #createTriple(BlankNodeOrIRI, IRI, RDFTerm)
-     * @see #createGeneralizedQuad(RDFTerm, RDFTerm, RDFTerm, RDFTerm)
-     * 
-     * @param subject
-     *            The subject of the statement
-     * @param predicate
-     *            The predicate of the statement
-     * @param object
-     *            The object of the statement
-     * @return Generalized {@link TripleLike}. Note that the generalized triple
-     *         does <strong>not</strong> implement {@link Triple#equals(Object)}
-     *         or {@link Triple#hashCode()}.
-     */
-    public JenaGeneralizedTripleLike createGeneralizedTriple(final RDFTerm subject, final RDFTerm predicate, final RDFTerm object) {
-        return internalJenaFactory.createGeneralizedTriple(subject, predicate, object);
-    }
-
-    /**
-     * Create a generalized Jena quad.
-     * <p>
-     * The <em>generalized quad</em> supports any {@link RDFTerm} as its
-     * {@link QuadLike#getSubject()} {@link QuadLike#getPredicate()},
-     * {@link QuadLike#getObject()} or {@link QuadLike#getObject()}.
-     * <p>
-     * In addition to supporting a <code>graphName</code> of <code>null</code>
-     * for representing a triple in the <em>default graph</em>, this method also
-     * recognize a {@link JenaIRI} which {@link JenaRDFTerm#asJenaNode()}
-     * represent the default graph according to
-     * {@link org.apache.jena.sparql.core.Quad#isDefaultGraph(Node)}, in which
-     * case the returned JenaQuad will have a {@link Quad#getGraphName()} of
-     * {@link Optional#empty()} rather than the provided IRI.
-     * 
-     * @see #createQuad(BlankNodeOrIRI, BlankNodeOrIRI, IRI, RDFTerm)
-     * @see #createGeneralizedTriple(RDFTerm, RDFTerm, RDFTerm)
-     * 
-     * @param subject
-     *            The subject of the statement
-     * @param predicate
-     *            The predicate of the statement
-     * @param object
-     *            The object of the statement
-     * @param graphName
-     *            The graph name of the statement
-     * @return Generalized {@link QuadLike}. Note that the generalized quad does
-     *         <strong>not</strong> implement {@link Quad#equals(Object)} or
-     *         {@link Quad#hashCode()}.
-     */
-    public JenaGeneralizedQuadLike createGeneralizedQuad(final RDFTerm subject, final RDFTerm predicate, final RDFTerm object,
-            final RDFTerm graphName) {
-        return internalJenaFactory.createGeneralizedQuad(subject, predicate, object, graphName);
-    }
-
-    /**
-     * Adapt an existing Jena Node to CommonsRDF {@link RDFTerm}.
-     * <p>
-     * If {@link Node#isLiteral()}, then the returned value is a
-     * {@link Literal}. If {@link Node#isURI()}, the returned value is a IRI. If
-     * {$@link Node#isBlank()}, the returned value is a {@link BlankNode}, which
-     * will use a {@link UUID} salt from this {@link JenaRDF} instance in
-     * combination with {@link Node#getBlankNodeId()} for the purpose of its
-     * {@link BlankNode#uniqueReference()}.
-     * 
-     * @see #asRDFTerm(RDF, Node)
-     * 
-     * @param node
-     *            The Jena Node to adapt. It's {@link Node#isConcrete()} must be
-     *            <code>true</code>.
-     * @return Adapted {@link JenaRDFTerm}
-     * @throws ConversionException
-     *             If the {@link Node} can't be represented as an
-     *             {@link RDFTerm}, e.g. if the node is not concrete or
-     *             represents a variable in Jena.
-     */
-    public JenaRDFTerm asRDFTerm(final Node node) throws ConversionException {
-        return internalJenaFactory.createRDFTerm(node, salt());
-    }
-
-    /**
-     * Convert from Jena {@link Node} to any Commons RDF implementation.
-     * <p>
-     * Note that if the {@link Node#isBlank()}, then the factory's
-     * {@link RDF#createBlankNode(String)} will be used, meaning that care
-     * should be taken if reusing an {@link RDF} instance for multiple
-     * conversion sessions.
-     * 
-     * @see #asRDFTerm(Node)
-     * 
-     * @param factory
-     *            {@link RDF} to use for creating {@link RDFTerm}.
-     * @param node
-     *            The Jena Node to adapt. It's {@link Node#isConcrete()} must be
-     *            <code>true</code>.
-     * @return Adapted {@link RDFTerm}
-     * @throws ConversionException
-     *             If the {@link Node} can't be represented as an
-     *             {@link RDFTerm}, e.g. if the node is not concrete or
-     *             represents a variable in Jena.
-     */
-    public static RDFTerm asRDFTerm(final RDF factory, final Node node) {
-        if (node == null) {
-            return null;
-        }
-        if (factory instanceof JenaRDF) {
-            // No need to convert, just wrap
-            return ((JenaRDF) factory).asRDFTerm(node);
-        }
-        if (node.isURI()) {
-            return factory.createIRI(node.getURI());
-        }
-        if (node.isLiteral()) {
-            final String lang = node.getLiteralLanguage();
-            if (lang != null && !lang.isEmpty()) {
-                return factory.createLiteral(node.getLiteralLexicalForm(), lang);
-            }
-            if (node.getLiteralDatatype().equals(XSDDatatype.XSDstring)) {
-                return factory.createLiteral(node.getLiteralLexicalForm());
-            }
-            final IRI dt = factory.createIRI(node.getLiteralDatatype().getURI());
-            return factory.createLiteral(node.getLiteralLexicalForm(), dt);
-        }
-        if (node.isBlank()) {
-            // The factory
-            return factory.createBlankNode(node.getBlankNodeLabel());
-        }
-        throw new ConversionException("Node is not a concrete RDF Term: " + node);
-    }
-
-    /**
-     * Adapt an existing Jena Triple to CommonsRDF {@link Triple}.
-     * <p>
-     * If the triple contains any {@link Node#isBlank()}, then any corresponding
-     * {@link BlankNode} will use a {@link UUID} salt from this {@link JenaRDF}
-     * instance in combination with {@link Node#getBlankNodeId()} for the
-     * purpose of its {@link BlankNode#uniqueReference()}.
-     *
-     * @see #asTriple(RDF, org.apache.jena.graph.Triple)
-     * 
-     * @param triple
-     *            Jena {@link org.apache.jena.graph.Triple} to adapt
-     * @return Adapted {@link JenaTriple}
-     * @throws ConversionException
-     *             if any of the triple's nodes are not concrete or the triple
-     *             is a generalized triple
-     */
-    public JenaTriple asTriple(final org.apache.jena.graph.Triple triple) throws ConversionException {
-        return internalJenaFactory.createTriple(triple, salt());
-    }
-
-    /**
-     * Adapt a generalized Jena {@link org.apache.jena.graph.Triple} to a
-     * CommonsRDF {@link TripleLike}.
-     * <p>
-     * The generalized triple supports any {@link RDFTerm} as its
-     * {@link TripleLike#getSubject()} {@link TripleLike#getPredicate()} or
-     * {@link TripleLike#getObject()}.
-     * <p>
-     * If the Jena triple contains any {@link Node#isBlank()}, then any
-     * corresponding {@link BlankNode} will use a {@link UUID} salt from this
-     * {@link JenaRDF} instance in combination with
-     * {@link Node#getBlankNodeId()} for the purpose of its
-     * {@link BlankNode#uniqueReference()}.
-     *
-     * @see #asTriple(RDF, org.apache.jena.graph.Triple)
-     * 
-     * @param triple
-     *            Jena triple
-     * @return Adapted {@link TripleLike}. Note that the generalized triple does
-     *         <strong>not</strong> implement {@link Triple#equals(Object)} or
-     *         {@link Triple#hashCode()}.
-     * @throws ConversionException
-     *             if any of the triple's nodes are not concrete
-     */
-    public JenaTripleLike asGeneralizedTriple(final org.apache.jena.graph.Triple triple) throws ConversionException {
-        return internalJenaFactory.createGeneralizedTriple(triple, salt());
-    }
-
-    /**
-     * Adapt a generalized Jena {@link org.apache.jena.sparql.core.Quad} to a
-     * CommonsRDF {@link QuadLike}.
-     * <p>
-     * The generalized quad supports any {@link RDFTerm} as its
-     * {@link QuadLike#getGraphName()}, {@link QuadLike#getSubject()}
-     * {@link QuadLike#getPredicate()} or {@link QuadLike#getObject()}.
-     * <p>
-     * If the Jena quad contains any {@link Node#isBlank()}, then any
-     * corresponding {@link BlankNode} will use a {@link UUID} salt from this
-     * {@link JenaRDF} instance in combination with
-     * {@link Node#getBlankNodeId()} for the purpose of its
-     * {@link BlankNode#uniqueReference()}.
-     * <p>
-     * If the provided quad {@link org.apache.jena.sparql.core.Quad#isDefaultGraph()},
-     * the returned {@link JenaQuadLike} has a {@link JenaQuadLike#getGraphName()} 
-     * of {@link Optional#empty()}.
-     *
-     * @see #asQuad(org.apache.jena.sparql.core.Quad)
-     * @see #asGeneralizedTriple(org.apache.jena.graph.Triple)
-     * 
-     * @param quad
-     *            Jena quad
-     * @return Adapted {@link QuadLike}. Note that the generalized quad does
-     *         <strong>not</strong> implement {@link Quad#equals(Object)} or
-     *         {@link Quad#hashCode()}.
-     * @throws ConversionException
-     *             if any of the quad nodes are not concrete
-     */
-    public JenaQuadLike<RDFTerm> asGeneralizedQuad(final org.apache.jena.sparql.core.Quad quad) throws ConversionException {
-        return internalJenaFactory.createGeneralizedQuad(quad, salt());
-    }
-
-    /**
-     * Convert from Jena {@link org.apache.jena.graph.Triple} to a Commons RDF
-     * {@link Triple}.
-     * <p>
-     * Note that if any of the triple's nodes {@link Node#isBlank()}, then the
-     * factory's {@link RDF#createBlankNode(String)} will be used, meaning that
-     * care should be taken if reusing an {@link RDF} instance for multiple
-     * conversion sessions.
-     * 
-     * @see #asTriple(org.apache.jena.graph.Triple)
-     *
-     * @param factory
-     *            {@link RDF} to use for creating the {@link Triple} and its
-     *            {@link RDFTerm}s.
-     * @param triple
-     *            Jena triple
-     * @return Converted triple
-     * @throws ConversionException
-     *             if any of the triple's nodes are not concrete or the triple
-     *             is a generalized triple
-     */
-    public static Triple asTriple(final RDF factory, final org.apache.jena.graph.Triple triple) throws ConversionException {
-        if (factory instanceof JenaRDF) {
-            // No need to convert, just wrap
-            return ((JenaRDF) factory).asTriple(triple);
-        }
-        final BlankNodeOrIRI subject;
-        final IRI predicate;
-        try {
-            subject = (BlankNodeOrIRI) asRDFTerm(factory, triple.getSubject());
-            predicate = (IRI) asRDFTerm(factory, triple.getPredicate());
-        } catch (final ClassCastException ex) {
-            throw new ConversionException("Can't convert generalized triple: " + triple, ex);
-        }
-        final RDFTerm object = asRDFTerm(factory, triple.getObject());
-        return factory.createTriple(subject, predicate, object);
-    }
-
-    /**
-     * Adapt an existing Jena {@link org.apache.jena.sparql.core.Quad} to
-     * CommonsRDF {@link Quad}.
-     * <p>
-     * If the quad contains any {@link Node#isBlank()}, then any corresponding
-     * {@link BlankNode} will use a {@link UUID} salt from this {@link JenaRDF}
-     * instance in combination with {@link Node#getBlankNodeId()} for the
-     * purpose of its {@link BlankNode#uniqueReference()}.
-     * <p>
-     * If the provided quad {@link org.apache.jena.sparql.core.Quad#isDefaultGraph()},
-     * the returned {@link JenaQuad} has a {@link Quad#getGraphName()} 
-     * of {@link Optional#empty()}.
-     * 
-     * @param quad
-     *            Jena quad
-     * @return Adapted quad
-     */
-    public JenaQuad asQuad(final org.apache.jena.sparql.core.Quad quad) {
-        return internalJenaFactory.createQuad(quad, salt());
-    }
-
-    /**
-     * Adapt an existing Jena {@link org.apache.jena.graph.Graph} to CommonsRDF
-     * {@link Graph}.
-     * <p>
-     * This does not take a copy, changes to the CommonsRDF Graph are reflected
-     * in the jena graph, which is accessible from
-     * {@link JenaGraph#asJenaGraph()}.
-     * <p>
-     * If the graph contains any {@link Node#isBlank()}, then any corresponding
-     * {@link BlankNode} will use a {@link UUID} salt from this {@link JenaRDF}
-     * instance in combination with {@link Node#getBlankNodeId()} for the
-     * purpose of its {@link BlankNode#uniqueReference()}.
-     * 
-     * @param graph
-     *            Jena {@link org.apache.jena.graph.Graph} to adapt
-     * @return Adapted {@link JenaGraph}
-     */
-    public JenaGraph asGraph(final org.apache.jena.graph.Graph graph) {
-        return internalJenaFactory.createGraph(graph, salt());
-    }
-
-    /**
-     * Adapt an existing Jena {@link org.apache.jena.rdf.model.Model} to
-     * CommonsRDF {@link Graph}.
-     * <p>
-     * This does not ake a copy, changes to the CommonsRDF Graph are reflected
-     * in the jena graph, which is accessible from
-     * {@link JenaGraph#asJenaGraph()}.
-     * <p>
-     * If the graph contains any {@link Node#isBlank()}, then any corresponding
-     * {@link BlankNode} will use a {@link UUID} salt from this {@link JenaRDF}
-     * instance in combination with {@link Node#getBlankNodeId()} for the
-     * purpose of its {@link BlankNode#uniqueReference()}.
-     * 
-     * @param model
-     *            Jena {@link org.apache.jena.rdf.model.Model} to adapt
-     * @return Adapted {@link JenaGraph}
-     */
-    public JenaGraph asGraph(final org.apache.jena.rdf.model.Model model) {
-        return internalJenaFactory.createGraph(model, salt());
-    }
-
-    /**
-     * Adapt an existing Jena {@link DatasetGraph} to CommonsRDF
-     * {@link Dataset}.
-     * <p>
-     * This does not take a copy, changes to the CommonsRDF Dataset are
-     * reflected in the jena dataset graph, which is accessible from
-     * {@link JenaDataset#asJenaDatasetGraph()}.
-     * <p>
-     * If the dataset contains any {@link Node#isBlank()}, then any
-     * corresponding {@link BlankNode} will use a {@link UUID} salt from this
-     * {@link JenaRDF} instance in combination with
-     * {@link Node#getBlankNodeId()} for the purpose of its
-     * {@link BlankNode#uniqueReference()}.
-     * 
-     * @param datasetGraph
-     *            Jena {@link DatasetGraph} to adapt
-     * @return Adapted {@link JenaDataset}
-     */
-    public JenaDataset asDataset(final DatasetGraph datasetGraph) {
-        return internalJenaFactory.createDataset(datasetGraph, salt());
-    }
-
-    /**
-     * Adapt an existing Jena {@link org.apache.jena.query.Dataset} to
-     * CommonsRDF {@link Dataset}.
-     * <p>
-     * This does not take a copy, changes to the CommonsRDF Dataset are
-     * reflected in the jena dataset graph, which is accessible from
-     * {@link JenaDataset#asJenaDatasetGraph()}.
-     * <p>
-     * If the dataset contains any {@link Node#isBlank()}, then any
-     * corresponding {@link BlankNode} will use a {@link UUID} salt from this
-     * {@link JenaRDF} instance in combination with
-     * {@link Node#getBlankNodeId()} for the purpose of its
-     * {@link BlankNode#uniqueReference()}.
-     * 
-     * @param datasetGraph
-     *            Jena {@link org.apache.jena.query.Dataset} to adapt
-     * @return Adapted {@link JenaDataset}
-     */
-    public JenaDataset asDataset(final org.apache.jena.query.Dataset datasetGraph) {
-        return internalJenaFactory.createDataset(datasetGraph.asDatasetGraph(), salt());
-    }
-
-    /**
-     * Convert from Jena {@link org.apache.jena.sparql.core.Quad} to a Commons
-     * RDF {@link Quad}.
-     * <p>
-     * Note that if any of the quad's nodes {@link Node#isBlank()}, then the
-     * factory's {@link RDF#createBlankNode(String)} will be used, meaning that
-     * care should be taken if reusing an {@link RDF} instance for multiple
-     * conversion sessions.
-     * <p>
-     * If the provided quad {@link org.apache.jena.sparql.core.Quad#isDefaultGraph()},
-     * the returned {@link JenaQuadLike} has a {@link JenaQuadLike#getGraphName()} 
-     * of {@link Optional#empty()}.
-     * 
-     * @see #asQuad(org.apache.jena.sparql.core.Quad)
-     * @see #asGeneralizedQuad(org.apache.jena.sparql.core.Quad)
-     *
-     * @param factory
-     *            {@link RDF} to use for creating the {@link Triple} and its
-     *            {@link RDFTerm}s.
-     * @param quad
-     *            Jena {@link org.apache.jena.sparql.core.Quad} to adapt
-     * @return Converted {@link Quad}
-     * @throws ConversionException
-     *             if any of the quad's nodes are not concrete or the quad is a
-     *             generalized quad
-     */
-    public static Quad asQuad(final RDF factory, final org.apache.jena.sparql.core.Quad quad) {
-        if (factory instanceof JenaRDF) {
-            // No need to convert, just wrap
-            return ((JenaRDF) factory).asQuad(quad);
-        }
-        final BlankNodeOrIRI graphName = (BlankNodeOrIRI) (asRDFTerm(factory, quad.getGraph()));
-        final BlankNodeOrIRI subject = (BlankNodeOrIRI) (asRDFTerm(factory, quad.getSubject()));
-        final IRI predicate = (IRI) (asRDFTerm(factory, quad.getPredicate()));
-        final RDFTerm object = asRDFTerm(factory, quad.getObject());
-        return factory.createQuad(graphName, subject, predicate, object);
-    }
-
-    /**
-     * Return {@link RDFSyntax} corresponding to a Jena {@link Lang}.
-     * 
-     * @param lang
-     *            {@link Lang} to convert
-     * @return Matched {@link RDFSyntax}, otherwise {@link Optional#empty()}
-     */
-    public Optional<RDFSyntax> asRDFSyntax(final Lang lang) {
-        return RDFSyntax.byMediaType(lang.getContentType().getContentType());
-    }
-
-    /**
-     * Return Jena {@link Lang} corresponding to a {@link RDFSyntax}.
-     * 
-     * @param rdfSyntax
-     *            {@link RDFSyntax} to convert
-     * @return Matched {@link Lang}, otherwise {@link Optional#empty()}
-     */
-    public Optional<Lang> asJenaLang(final RDFSyntax rdfSyntax) {
-        return Optional.ofNullable(RDFLanguages.contentTypeToLang(rdfSyntax.mediaType()));
-    }
-
-    /**
-     * Create a {@link StreamRDF} instance that inserts the converted
-     * {@link Quad}s. into a the provided {@link Consumer}.
-     * <p>
-     * The returned {@link StreamRDF} can be used for instance with Jena's
-     * {@link RDFDataMgr#parse(StreamRDF, String)}.
-     * 
-     * @param factory
-     *            {@link RDF} to use for creating {@link RDFTerm}s and
-     *            {@link Quad}s.
-     * @param consumer
-     *            A {@link Consumer} of {@link Quad}s
-     * @return A {@link StreamRDF} that will stream converted quads to the
-     *         consumer
-     */
-    public static StreamRDF streamJenaToQuad(final RDF factory, final Consumer<Quad> consumer) {
-        return new StreamRDFBase() {
-            @Override
-            public void quad(final org.apache.jena.sparql.core.Quad quad) {
-                consumer.accept(asQuad(factory, quad));
-            }
-        };
-    }
-
-    /**
-     * Create a {@link StreamRDF} instance that inserts generalized
-     * {@link TripleLike}s. into a the provided {@link Consumer}.
-     * <p>
-     * A generalized triple allows any {@link RDFTerm} for
-     * {@link TripleLike#getSubject()}, {@link TripleLike#getPredicate()} and
-     * {@link TripleLike#getObject()}.
-     * <p>
-     * The returned {@link StreamRDF} can be used for instance with Jena's
-     * {@link RDFDataMgr#parse(StreamRDF, String)}.
-     * 
-     * @param generalizedConsumer
-     *            A {@link Consumer} of generalized {@link TripleLike}s
-     * @return A {@link StreamRDF} that will stream generalized triples to the
-     *         consumer
-     */
-    public StreamRDF streamJenaToGeneralizedTriple(final Consumer<TripleLike> generalizedConsumer) {
-        return new StreamRDFBase() {
-            @Override
-            public void triple(final org.apache.jena.graph.Triple triple) {
-                generalizedConsumer.accept(asGeneralizedTriple(triple));
-            }
-        };
-    }
-
-    /**
-     * Create a {@link StreamRDF} instance that inserts generalized
-     * {@link QuadLike}s. into a the provided {@link Consumer}.
-     * <p>
-     * A generalized quad allows any {@link RDFTerm} for
-     * {@link QuadLike#getSubject()}, {@link TripleLike#getPredicate()},
-     * {@link QuadLike#getObject()} and {@link QuadLike#getGraphName()} .
-     * <p>
-     * The returned {@link StreamRDF} can be used for instance with Jena's
-     * {@link RDFDataMgr#parse(StreamRDF, String)}.
-     * 
-     * @param generalizedConsumer
-     *            A {@link Consumer} of generalized {@link QuadLike}s
-     * @return A {@link StreamRDF} that will stream generalized quads to the
-     *         consumer
-     */
-    public StreamRDF streamJenaToGeneralizedQuad(final Consumer<QuadLike<RDFTerm>> generalizedConsumer) {
-        return new StreamRDFBase() {
-            @Override
-            public void quad(final org.apache.jena.sparql.core.Quad quad) {
-                generalizedConsumer.accept(asGeneralizedQuad(quad));
-            }
-        };
-    }
-
-    /**
-     * Convert a CommonsRDF Graph to a Jena Graph. If the Graph was from Jena
-     * originally, return that original object else create a copy using Jena
-     * objects.
-     * 
-     * @param graph
-     *            Commons RDF {@link Graph} to convert
-     * @return Converted Jena {@link org.apache.jena.graph.Graph}
-     */
-    public org.apache.jena.graph.Graph asJenaGraph(final Graph graph) {
-        if (graph instanceof JenaGraph) {
-            return ((JenaGraph) graph).asJenaGraph();
-        }
-        final org.apache.jena.graph.Graph g = GraphFactory.createGraphMem();
-        graph.stream().forEach(t -> g.add(asJenaTriple(t)));
-        return g;
-    }
-
-    /**
-     * Convert a CommonsRDF RDFTerm to a Jena Node. If the RDFTerm was from Jena
-     * originally, return that original object, else create a copy using Jena
-     * objects.
-     * 
-     * @param term
-     *            Commons RDF {@link RDFTerm} to convert
-     * @return Converted Jena {@link Node}
-     */
-    public Node asJenaNode(final RDFTerm term) {
-        if (term == null) {
-            return null;
-        }
-        if (term instanceof JenaRDFTerm) {
-            // TODO: What if it's a JenaBlankNodeImpl with
-            // a different salt? Do we need to rewrite the
-            // jena blanknode identifier?
-            return ((JenaRDFTerm) term).asJenaNode();
-        }
-
-        if (term instanceof IRI) {
-            return NodeFactory.createURI(((IRI) term).getIRIString());
-        }
-
-        if (term instanceof Literal) {
-            final Literal lit = (Literal) term;
-            final RDFDatatype dt = NodeFactory.getType(lit.getDatatype().getIRIString());
-            final String lang = lit.getLanguageTag().orElse("");
-            return NodeFactory.createLiteral(lit.getLexicalForm(), lang, dt);
-        }
-
-        if (term instanceof BlankNode) {
-            final String id = ((BlankNode) term).uniqueReference();
-            return NodeFactory.createBlankNode(id);
-        }
-        throw new ConversionException("Not a concrete RDF Term: " + term);
-    }
-
-    /**
-     * Convert a CommonsRDF {@link Triple} to a Jena
-     * {@link org.apache.jena.graph.Triple}.
-     * <p>
-     * If the triple was from Jena originally, return that original object, else
-     * create a copy using Jena objects.
-     * 
-     * @param triple
-     *            Commons RDF {@link Triple} to convert
-     * @return Converted Jena {@link org.apache.jena.graph.Triple}
-     */
-    public org.apache.jena.graph.Triple asJenaTriple(final Triple triple) {
-        if (triple instanceof JenaTriple) {
-            return ((JenaTriple) triple).asJenaTriple();
-        }
-        return org.apache.jena.graph.Triple.create(asJenaNode(triple.getSubject()), 
-                asJenaNode(triple.getPredicate()),
-                asJenaNode(triple.getObject()));
-    }
-
-    /**
-     * Convert a CommonsRDF {@link Quad} to a Jena
-     * {@link org.apache.jena.sparql.core.Quad}.
-     * <p>
-     * If the quad was from Jena originally, return that original object,
-     * otherwise create a copy using Jena objects.
-     *
-     * @param quad
-     *            Commons RDF {@link Quad} to convert
-     * @return Converted Jena {@link org.apache.jena.sparql.core.Quad}
-     */
-    public org.apache.jena.sparql.core.Quad asJenaQuad(final Quad quad) {
-        if (quad instanceof JenaQuad) {
-            return ((JenaQuad) quad).asJenaQuad();
-        }
-        return org.apache.jena.sparql.core.Quad.create(
-                asJenaNode(quad.getGraphName().orElse(null)),
-                asJenaNode(quad.getSubject()), 
-                asJenaNode(quad.getPredicate()),
-                asJenaNode(quad.getObject()));
-    }
-
-    // Some simple validations - full IRI parsing is not cheap.
-    private void validateIRI(final String iri) {
-        if (iri.contains(" ")) {
-            throw new IllegalArgumentException();
-        }
-        if (iri.contains("<")) {
-            throw new IllegalArgumentException();
-        }
-        if (iri.contains(">")) {
-            throw new IllegalArgumentException();
-        }
-    }
-
-    private static void validateLang(final String languageTag) {
-        if (languageTag.contains(" ")) {
-            throw new IllegalArgumentException("Invalid language tag: " + languageTag);
-        }
-    }
-
-    /**
-     * Return the {@link UUID} salt used by this factory.
-     * <p>
-     * The salt is used for the purposes of {@link BlankNode} identity, see
-     * {@link BlankNode#uniqueReference()} for details.
-     * <p>
-     * This salt can be used with the constructor {@link JenaRDF#JenaRDF(UUID)}
-     * if consistent or reproducible {@link BlankNode}s are desirable.
-     * 
-     * @return The {@link UUID} used as salt
-     */
-    public UUID salt() {
-        return salt;
-    }
-
-}

http://git-wip-us.apache.org/repos/asf/commons-rdf/blob/d59203ce/jena/src/main/java/org/apache/commons/rdf/jena/JenaRDFTerm.java
----------------------------------------------------------------------
diff --git a/jena/src/main/java/org/apache/commons/rdf/jena/JenaRDFTerm.java b/jena/src/main/java/org/apache/commons/rdf/jena/JenaRDFTerm.java
deleted file mode 100644
index bd854d1..0000000
--- a/jena/src/main/java/org/apache/commons/rdf/jena/JenaRDFTerm.java
+++ /dev/null
@@ -1,35 +0,0 @@
-/**
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements.  See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership.  The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.apache.commons.rdf.jena;
-
-import org.apache.commons.rdf.api.RDFTerm;
-import org.apache.jena.graph.Node;
-
-/**
- * A Jena-backed {@link RDFTerm}.
- * <p>
- * The underlying Jena {@link Node} can be retrieved with {@link #asJenaNode()}.
- * 
- * @see JenaIRI
- * @see JenaLiteral
- * @see JenaBlankNode
- */
-public interface JenaRDFTerm extends RDFTerm {
-    public Node asJenaNode();
-}

http://git-wip-us.apache.org/repos/asf/commons-rdf/blob/d59203ce/jena/src/main/java/org/apache/commons/rdf/jena/JenaTriple.java
----------------------------------------------------------------------
diff --git a/jena/src/main/java/org/apache/commons/rdf/jena/JenaTriple.java b/jena/src/main/java/org/apache/commons/rdf/jena/JenaTriple.java
deleted file mode 100644
index c73e018..0000000
--- a/jena/src/main/java/org/apache/commons/rdf/jena/JenaTriple.java
+++ /dev/null
@@ -1,27 +0,0 @@
-/**
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements.  See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership.  The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-package org.apache.commons.rdf.jena;
-
-/**
- * A Jena-backed {@link org.apache.commons.rdf.api.Triple}.
- * <p>
- * The underlying Jena {@link org.apache.jena.graph.Triple} can be accessed with
- * {@link #asJenaTriple()}.
- */
-public interface JenaTriple extends org.apache.commons.rdf.api.Triple, JenaTripleLike {
-}

http://git-wip-us.apache.org/repos/asf/commons-rdf/blob/d59203ce/jena/src/main/java/org/apache/commons/rdf/jena/JenaTripleLike.java
----------------------------------------------------------------------
diff --git a/jena/src/main/java/org/apache/commons/rdf/jena/JenaTripleLike.java b/jena/src/main/java/org/apache/commons/rdf/jena/JenaTripleLike.java
deleted file mode 100644
index 49a8eb5..0000000
--- a/jena/src/main/java/org/apache/commons/rdf/jena/JenaTripleLike.java
+++ /dev/null
@@ -1,45 +0,0 @@
-/**
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements.  See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership.  The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.apache.commons.rdf.jena;
-
-import org.apache.commons.rdf.api.TripleLike;
-import org.apache.jena.graph.Triple;
-
-/**
- * A {@link TripleLike} wrapper of a Jena {@link Triple}.
- * <p>
- * This is a marker interface common to its specializations {@link JenaTriple},
- * {@link JenaGeneralizedTripleLike}, {@link JenaQuad} and
- * {@link JenaGeneralizedQuadLike}.
- * 
- * @see JenaTriple
- * @see JenaGeneralizedTripleLike
- * @see JenaQuad
- * @see JenaGeneralizedQuadLike
- * 
- */
-public interface JenaTripleLike extends org.apache.commons.rdf.api.TripleLike {
-
-    /**
-     * Return the adapted Jena triple
-     * 
-     * @return Adapted Jena {@link Triple}.
-     */
-    Triple asJenaTriple();
-}

http://git-wip-us.apache.org/repos/asf/commons-rdf/blob/d59203ce/jena/src/main/java/org/apache/commons/rdf/jena/experimental/JenaRDFParser.java
----------------------------------------------------------------------
diff --git a/jena/src/main/java/org/apache/commons/rdf/jena/experimental/JenaRDFParser.java b/jena/src/main/java/org/apache/commons/rdf/jena/experimental/JenaRDFParser.java
deleted file mode 100644
index 2513e82..0000000
--- a/jena/src/main/java/org/apache/commons/rdf/jena/experimental/JenaRDFParser.java
+++ /dev/null
@@ -1,106 +0,0 @@
-/**
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements.  See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership.  The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.apache.commons.rdf.jena.experimental;
-
-import java.io.IOException;
-import java.io.InputStream;
-import java.nio.file.Files;
-import java.util.function.Consumer;
-
-import org.apache.commons.rdf.api.IRI;
-import org.apache.commons.rdf.api.QuadLike;
-import org.apache.commons.rdf.api.RDF;
-import org.apache.commons.rdf.api.RDFTerm;
-import org.apache.commons.rdf.api.TripleLike;
-import org.apache.commons.rdf.jena.JenaGraph;
-import org.apache.commons.rdf.jena.JenaRDF;
-import org.apache.commons.rdf.simple.experimental.AbstractRDFParser;
-import org.apache.jena.graph.Graph;
-import org.apache.jena.riot.Lang;
-import org.apache.jena.riot.RDFParser;
-import org.apache.jena.riot.system.StreamRDF;
-import org.apache.jena.riot.system.StreamRDFLib;
-
-public class JenaRDFParser extends AbstractRDFParser<JenaRDFParser> {
-
-    private Consumer<TripleLike> generalizedConsumerTriple;
-    private Consumer<QuadLike<RDFTerm>> generalizedConsumerQuad;
-
-    @Override
-    protected RDF createRDFTermFactory() {
-        return new JenaRDF();
-    }
-
-    public JenaRDFParser targetGeneralizedTriple(final Consumer<TripleLike> consumer) {
-        final JenaRDFParser c = this.clone();
-        c.resetTarget();
-        c.generalizedConsumerTriple = consumer;
-        return c;
-    }
-
-    public JenaRDFParser targetGeneralizedQuad(final Consumer<QuadLike<RDFTerm>> consumer) {
-        final JenaRDFParser c = this.clone();
-        c.resetTarget();
-        c.generalizedConsumerQuad = consumer;
-        return c;
-    }
-
-    @Override
-    protected void resetTarget() {
-        super.resetTarget();
-        this.generalizedConsumerTriple = null;
-        this.generalizedConsumerQuad = null;
-    }
-
-    @Override
-    protected void parseSynchronusly() throws IOException {
-        StreamRDF dest;
-        final JenaRDF jenaRDF = getJenaFactory();
-        if (getTargetGraph().isPresent() && getTargetGraph().get() instanceof JenaGraph) {
-            final Graph jenaGraph = ((JenaGraph) getTargetGraph().get()).asJenaGraph();
-            dest = StreamRDFLib.graph(jenaGraph);
-        } else {
-            if (generalizedConsumerQuad != null) {
-                dest = jenaRDF.streamJenaToGeneralizedQuad(generalizedConsumerQuad);
-            } else if (generalizedConsumerTriple != null) {
-                dest = jenaRDF.streamJenaToGeneralizedTriple(generalizedConsumerTriple);
-            } else {
-                dest = JenaRDF.streamJenaToQuad(getRdfTermFactory().get(), getTarget());
-            }
-        }
-
-        final Lang lang = getContentTypeSyntax().flatMap(jenaRDF::asJenaLang).orElse(null);
-        final String baseStr = getBase().map(IRI::getIRIString).orElse(null);
-
-        if (getSourceIri().isPresent()) {
-        	    RDFParser.source(getSourceIri().get().toString()).base(baseStr).lang(lang).parse(dest);
-        } else if (getSourceFile().isPresent()) {
-            try (InputStream s = Files.newInputStream(getSourceFile().get())) {
-            	    RDFParser.source(s).base(baseStr).lang(lang).parse(dest);
-            }
-        } else {
-            RDFParser.source(getSourceInputStream().get()).base(baseStr).lang(lang).parse(dest);
-        }
-    }
-
-    private JenaRDF getJenaFactory() {
-        return (JenaRDF) getRdfTermFactory().filter(JenaRDF.class::isInstance).orElseGet(this::createRDFTermFactory);
-    }
-
-}

http://git-wip-us.apache.org/repos/asf/commons-rdf/blob/d59203ce/jena/src/main/java/org/apache/commons/rdf/jena/experimental/package-info.java
----------------------------------------------------------------------
diff --git a/jena/src/main/java/org/apache/commons/rdf/jena/experimental/package-info.java b/jena/src/main/java/org/apache/commons/rdf/jena/experimental/package-info.java
deleted file mode 100644
index 10a1f11..0000000
--- a/jena/src/main/java/org/apache/commons/rdf/jena/experimental/package-info.java
+++ /dev/null
@@ -1,31 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-/**
- * Experimental Commons RDF Jena implementations.
- * <p>
- * Classes in this package should be considered <strong>at risk</strong>; they
- * might change or be removed in the next minor update of Commons RDF.
- * <p>
- * When a class has stabilized, it will move to the
- * {@link org.apache.commons.rdf.jena} package.
- * <ul>
- * <li>{@link JenaRDFParser} - a Jena-backed implementations of
- * {@link org.apache.commons.rdf.experimental.RDFParser}.</li>
- * </ul>
- */
-package org.apache.commons.rdf.jena.experimental;
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/commons-rdf/blob/d59203ce/jena/src/main/java/org/apache/commons/rdf/jena/impl/AbstractJenaRDFTerm.java
----------------------------------------------------------------------
diff --git a/jena/src/main/java/org/apache/commons/rdf/jena/impl/AbstractJenaRDFTerm.java b/jena/src/main/java/org/apache/commons/rdf/jena/impl/AbstractJenaRDFTerm.java
deleted file mode 100644
index 94b8bc4..0000000
--- a/jena/src/main/java/org/apache/commons/rdf/jena/impl/AbstractJenaRDFTerm.java
+++ /dev/null
@@ -1,47 +0,0 @@
-/**
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements.  See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership.  The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.apache.commons.rdf.jena.impl;
-
-import org.apache.commons.rdf.jena.JenaRDFTerm;
-import org.apache.jena.graph.Node;
-import org.apache.jena.riot.out.NodeFmtLib;
-
-class AbstractJenaRDFTerm implements JenaRDFTerm {
-    private final Node node;
-    // static private PrefixMapping empty = new PrefixMappingImpl();
-
-    protected AbstractJenaRDFTerm(final Node node) {
-        this.node = node;
-    }
-
-    @Override
-    public Node asJenaNode() {
-        return node;
-    }
-
-    @Override
-    public String ntriplesString() {
-        return NodeFmtLib.str(node);
-    }
-
-    @Override
-    public String toString() {
-        return ntriplesString();
-    }
-}