You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@commonsrdf.apache.org by st...@apache.org on 2016/09/08 14:29:28 UTC

[01/19] incubator-commonsrdf git commit: ASF license header for *.md

Repository: incubator-commonsrdf
Updated Branches:
  refs/heads/jena c6d654bac -> 4e9b11b1f


ASF license header for *.md


Project: http://git-wip-us.apache.org/repos/asf/incubator-commonsrdf/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-commonsrdf/commit/c9dd9746
Tree: http://git-wip-us.apache.org/repos/asf/incubator-commonsrdf/tree/c9dd9746
Diff: http://git-wip-us.apache.org/repos/asf/incubator-commonsrdf/diff/c9dd9746

Branch: refs/heads/jena
Commit: c9dd974656d1e430f9572a80c86de8a93ddc642c
Parents: 058f781
Author: Stian Soiland-Reyes <st...@apache.org>
Authored: Mon Jun 20 10:05:09 2016 +0100
Committer: Stian Soiland-Reyes <st...@apache.org>
Committed: Mon Jun 20 10:05:09 2016 +0100

----------------------------------------------------------------------
 RELEASE-PROCESS.md | 20 ++++++++++++++++++++
 1 file changed, 20 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-commonsrdf/blob/c9dd9746/RELEASE-PROCESS.md
----------------------------------------------------------------------
diff --git a/RELEASE-PROCESS.md b/RELEASE-PROCESS.md
index 22ce224..2d628d7 100644
--- a/RELEASE-PROCESS.md
+++ b/RELEASE-PROCESS.md
@@ -1,3 +1,23 @@
+<!--
+
+    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.
+
+-->
+
 # Commons RDF (incubating) release process
 
 1. Update documentation (`RELEASE-NOTES.md`, `README.md`, version numbers in `src/site/`)


[19/19] incubator-commonsrdf git commit: Remove UUID-less helper methods

Posted by st...@apache.org.
Remove UUID-less helper methods


Project: http://git-wip-us.apache.org/repos/asf/incubator-commonsrdf/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-commonsrdf/commit/4e9b11b1
Tree: http://git-wip-us.apache.org/repos/asf/incubator-commonsrdf/tree/4e9b11b1
Diff: http://git-wip-us.apache.org/repos/asf/incubator-commonsrdf/diff/4e9b11b1

Branch: refs/heads/jena
Commit: 4e9b11b1f352897f0d7b9fd5334d73f3ace375e0
Parents: 7fb1d88
Author: Stian Soiland-Reyes <st...@apache.org>
Authored: Thu Sep 8 15:28:17 2016 +0100
Committer: Stian Soiland-Reyes <st...@apache.org>
Committed: Thu Sep 8 15:29:15 2016 +0100

----------------------------------------------------------------------
 .../commons/rdf/jena/impl/JenaFactory.java      | 32 ++++++++------------
 .../commons/rdf/jena/TestBlankNodeJena.java     |  6 ++--
 2 files changed, 16 insertions(+), 22 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-commonsrdf/blob/4e9b11b1/jena/src/main/java/org/apache/commons/rdf/jena/impl/JenaFactory.java
----------------------------------------------------------------------
diff --git a/jena/src/main/java/org/apache/commons/rdf/jena/impl/JenaFactory.java b/jena/src/main/java/org/apache/commons/rdf/jena/impl/JenaFactory.java
index bc0ae0f..7a6a7ab 100644
--- a/jena/src/main/java/org/apache/commons/rdf/jena/impl/JenaFactory.java
+++ b/jena/src/main/java/org/apache/commons/rdf/jena/impl/JenaFactory.java
@@ -37,6 +37,7 @@ import org.apache.commons.rdf.jena.JenaLiteral;
 import org.apache.commons.rdf.jena.JenaQuad;
 import org.apache.commons.rdf.jena.JenaQuadLike;
 import org.apache.commons.rdf.jena.JenaRDFTerm;
+import org.apache.commons.rdf.jena.JenaRDFTermFactory;
 import org.apache.commons.rdf.jena.JenaTriple;
 import org.apache.commons.rdf.jena.JenaTripleLike;
 import org.apache.commons.rdf.jena.JenaVariable;
@@ -47,10 +48,18 @@ import org.apache.jena.sparql.core.DatasetGraph;
 import org.apache.jena.sparql.core.DatasetGraphFactory;
 import org.apache.jena.sparql.graph.GraphFactory;
 
+/**
+ * Construct Jena implementations of Commons RDF.
+ * <p>
+ * This class is primarily an internal helper class, users should instead use
+ * {@link JenaRDFTermFactory}.
+ * <p>
+ * For the purpose of blank node identity, some of 
+ * these methods require a {@link UUID} to use as a salt.
+ * See {@link BlankNode#uniqueReference()} for details.
+ * 
+ */
 public class JenaFactory {
-	public static BlankNode createBlankNode() {
-		return new BlankNodeImpl(NodeFactory.createBlankNode(), UUID.randomUUID());
-	}
 
 	public static JenaBlankNode createBlankNode(String id, UUID salt) {
 		return new BlankNodeImpl(NodeFactory.createBlankNode(id), salt);
@@ -59,21 +68,12 @@ public class JenaFactory {
 	public static JenaBlankNode createBlankNode(UUID salt) {
 		return new BlankNodeImpl(NodeFactory.createBlankNode(), salt);
 	}
-
-	public static Dataset createDataset() {
-		return createDataset(UUID.randomUUID());
-	}
-	
 	public static Dataset createDataset(UUID salt) {
 		DatasetGraph dg = DatasetGraphFactory.createGeneral();
 		// Or which createMethod() -- a bit confusing with lots of choice..
 		return new DatasetImpl(dg, salt);
 	}
 
-	public static JenaGraph createGraph() {
-		return createGraph(UUID.randomUUID());
-	}
-
 	public static JenaGraph createGraph(UUID salt) {
 		return new GraphImpl(GraphFactory.createDefaultGraph(), salt);
 	}
@@ -144,10 +144,6 @@ public class JenaFactory {
 		throw new IllegalArgumentException("Unrecognized node type: " + node);
 	}
 
-	public static JenaGraph fromJena(org.apache.jena.graph.Graph graph) {
-		return new GraphImpl(graph, UUID.randomUUID());
-	}
-
 	public static JenaGraph fromJena(org.apache.jena.graph.Graph graph, UUID salt) {
 		return new GraphImpl(graph, salt);
 	}
@@ -156,10 +152,6 @@ public class JenaFactory {
 		return new GraphImpl(model, salt);
 	}
 
-	public static JenaDataset fromJena(DatasetGraph datasetGraph) {
-		return new DatasetImpl(datasetGraph, UUID.randomUUID());
-	}
-
 	public static JenaDataset fromJena(DatasetGraph datasetGraph, UUID salt) {
 		return new DatasetImpl(datasetGraph, salt);
 	}

http://git-wip-us.apache.org/repos/asf/incubator-commonsrdf/blob/4e9b11b1/jena/src/test/java/org/apache/commons/rdf/jena/TestBlankNodeJena.java
----------------------------------------------------------------------
diff --git a/jena/src/test/java/org/apache/commons/rdf/jena/TestBlankNodeJena.java b/jena/src/test/java/org/apache/commons/rdf/jena/TestBlankNodeJena.java
index 10edd09..f37922f 100644
--- a/jena/src/test/java/org/apache/commons/rdf/jena/TestBlankNodeJena.java
+++ b/jena/src/test/java/org/apache/commons/rdf/jena/TestBlankNodeJena.java
@@ -26,12 +26,14 @@ import org.apache.commons.rdf.jena.impl.JenaFactory;
 
 public class TestBlankNodeJena extends AbstractBlankNodeTest {
 
-	
+	/** 
+	 * Fixed salt for the purpose of this test.
+	 */
     private static final UUID SALT = UUID.fromString("ccfde817-55b8-4a5f-bc2d-6bfd8eaa41ce");
 
 	@Override
     protected BlankNode getBlankNode() {
-        return JenaFactory.createBlankNode() ;
+        return JenaFactory.createBlankNode(SALT) ;
     }
     
     @Override


[14/19] incubator-commonsrdf git commit: about implementation branches

Posted by st...@apache.org.
about implementation branches


Project: http://git-wip-us.apache.org/repos/asf/incubator-commonsrdf/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-commonsrdf/commit/9782a586
Tree: http://git-wip-us.apache.org/repos/asf/incubator-commonsrdf/tree/9782a586
Diff: http://git-wip-us.apache.org/repos/asf/incubator-commonsrdf/diff/9782a586

Branch: refs/heads/jena
Commit: 9782a5860db860c6870620f8c16adf0afa511ec3
Parents: 2566399
Author: Stian Soiland-Reyes <st...@apache.org>
Authored: Wed Sep 7 03:23:36 2016 +0100
Committer: Stian Soiland-Reyes <st...@apache.org>
Committed: Wed Sep 7 03:23:36 2016 +0100

----------------------------------------------------------------------
 src/site/markdown/implementations.md | 63 +++++++++++++++++++++++--------
 1 file changed, 47 insertions(+), 16 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-commonsrdf/blob/9782a586/src/site/markdown/implementations.md
----------------------------------------------------------------------
diff --git a/src/site/markdown/implementations.md b/src/site/markdown/implementations.md
index 8ceba74..bf1b460 100644
--- a/src/site/markdown/implementations.md
+++ b/src/site/markdown/implementations.md
@@ -44,7 +44,7 @@ usage (e.g. prototyping).
 <dependency>
     <groupId>org.apache.commons</groupId>
     <artifactId>commons-rdf-simple</artifactId>
-    <version>0.1.0-incubating-SNAPSHOT</version>
+    <version>0.2.0-incubating-SNAPSHOT</version>
 </dependency>
 ```
 
@@ -57,10 +57,22 @@ RDFTermFactory rdfTermFactory = new SimpleRDFTermFactory();
 Graph graph = rdfTermFactory.createGraph();
 ```
 
+### OWL API
+
+[OWL API](http://owlapi.sourceforge.net/) 5 extends Commons RDF
+directly for its family of
+[RDFNode](https://github.com/owlcs/owlapi/blob/version5/api/src/main/java/org/semanticweb/owlapi/io/RDFNode.java#L25)
+implementations.
+
+For details, see [pull request #446](https://github.com/owlcs/owlapi/pull/446),
+and [pull request #452](https://github.com/owlcs/owlapi/pull/452)).
+
+
+
 ## Planned implementations
 
 The information in this section should not be considered updated or
-authoritative as it relies on external project planning.
+authoritative as it describes ongoing development.
 
 Feel free to [suggest changes](http://commonsrdf.incubator.apache.org/contributing.html) to the
 [source code for this page](https://github.com/apache/incubator-commonsrdf/blob/master/src/site/markdown/implementations.md).
@@ -69,15 +81,42 @@ Feel free to [suggest changes](http://commonsrdf.incubator.apache.org/contributi
 
 ### Apache Jena
 
-[Apache Jena](http://jena.apache.org/) is considering a compatibility interface
-that provides and consumes Commons RDF objects
-([JENA-1015](https://issues.apache.org/jira/browse/JENA-1015)).
+An implementation that maps [Apache Jena](http://jena.apache.org/) types
+to Commons RDF is being developed on
+the [`jena`](https://github.com/apache/incubator-commonsrdf/tree/jena)
+branch of Commons RDF.
+
+For details, see [COMMONSRDF-33](https://issues.apache.org/jira/browse/COMMONSRDF-33),
+[JENA-1015](https://issues.apache.org/jira/browse/JENA-1015) or contact
+[dev@commonsrdf](mail-lists.html).
+
+
+### Eclipse RDF4j (formerly Sesame)
 
+An implementation that maps [RDF4J 2.0](http://rdf4j.org/)
+to Commons RDF is being developed on
+the [`rdf4j`](https://github.com/apache/incubator-commonsrdf/tree/rdf4j)
+branch of Commons RDF.
 
-### RDF4j Sesame
 
-[Sesame](http://rdf4j.org/) is planning to support Commons RDF
-([SES-2091](https://openrdf.atlassian.net/browse/SES-2091)).
+For details, see [COMMONSRDF-35](https://issues.apache.org/jira/browse/COMMONSRDF-35),
+[SES-2091](https://openrdf.atlassian.net/browse/SES-2091) or contact
+[dev@commonsrdf](mail-lists.html).
+
+
+### Eclipse RDF4j (formerly Sesame)
+
+An implementation that maps [JSON-LD-Java](https://github.com/jsonld-java/jsonld-java)
+to Commons RDF is being developed on
+the [`jsonld-java`](https://github.com/apache/incubator-commonsrdf/tree/jsonld-java/jsonld-java)
+branch of Commons RDF.
+
+This aims to support [JSON-LD](http://json-ld.org/) parsing and writing by adding
+new interfaces like
+[RDFParserBuilder](https://github.com/apache/incubator-commonsrdf/pull/21).
+
+For details, see [COMMONSRDF-36](https://issues.apache.org/jira/browse/COMMONSRDF-36) or contact
+[dev@commonsrdf](mail-lists.html).
 
 
 ### Apache Clerezza
@@ -85,11 +124,3 @@ that provides and consumes Commons RDF objects
 [Apache Clerezza](https://clerezza.apache.org/) is
 aligning its [RDF core](https://github.com/apache/clerezza-rdf-core) module
 with Commons RDF.
-
-
-### OWL API
-
-[OWL API](http://owlapi.sourceforge.net/) is considering the integration with
-Commons RDF in OWLAPI 5
-(<strike>[pull request #446](https://github.com/owlcs/owlapi/pull/446)</strike>,
-[pull request #452](https://github.com/owlcs/owlapi/pull/452)).


[06/19] incubator-commonsrdf git commit: avoid maven-jar-plugin error

Posted by st...@apache.org.
avoid maven-jar-plugin error

... by running <goal>jar</goal> again


Project: http://git-wip-us.apache.org/repos/asf/incubator-commonsrdf/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-commonsrdf/commit/7fd7faeb
Tree: http://git-wip-us.apache.org/repos/asf/incubator-commonsrdf/tree/7fd7faeb
Diff: http://git-wip-us.apache.org/repos/asf/incubator-commonsrdf/diff/7fd7faeb

Branch: refs/heads/jena
Commit: 7fd7faeb0556f1544de18201bec8886fdf40dbc5
Parents: fc70462
Author: Stian Soiland-Reyes <st...@apache.org>
Authored: Mon Sep 5 17:45:58 2016 +0100
Committer: Stian Soiland-Reyes <st...@apache.org>
Committed: Mon Sep 5 17:47:00 2016 +0100

----------------------------------------------------------------------
 api/pom.xml | 5 ++---
 1 file changed, 2 insertions(+), 3 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-commonsrdf/blob/7fd7faeb/api/pom.xml
----------------------------------------------------------------------
diff --git a/api/pom.xml b/api/pom.xml
index 4b13406..14278d6 100644
--- a/api/pom.xml
+++ b/api/pom.xml
@@ -47,10 +47,9 @@
                 <artifactId>maven-jar-plugin</artifactId>
                 <executions>
                   <execution>
-                      <id>jar-and-test-jar</id>
-                      <!-- Expose abstract test classes -->
+                      <id>test-jar</id>
+                      <!-- Also expose abstract test classes -->
                       <goals>
-                          <goal>jar</goal>
                           <goal>test-jar</goal>
                         </goals>
                     </execution>


[13/19] incubator-commonsrdf git commit: COMMONSRDF-37 Describe Quad/Dataset

Posted by st...@apache.org.
COMMONSRDF-37 Describe Quad/Dataset

updated UML diagram


Project: http://git-wip-us.apache.org/repos/asf/incubator-commonsrdf/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-commonsrdf/commit/25663998
Tree: http://git-wip-us.apache.org/repos/asf/incubator-commonsrdf/tree/25663998
Diff: http://git-wip-us.apache.org/repos/asf/incubator-commonsrdf/diff/25663998

Branch: refs/heads/jena
Commit: 25663998f086c802c76114b3bed8edb6dfdf0307
Parents: d7e4cbe
Author: Stian Soiland-Reyes <st...@apache.org>
Authored: Wed Sep 7 03:22:54 2016 +0100
Committer: Stian Soiland-Reyes <st...@apache.org>
Committed: Wed Sep 7 03:22:54 2016 +0100

----------------------------------------------------------------------
 src/site/markdown/index.md                      |  58 ++++++++++++++-----
 src/site/resources/images/class-diagram.nomnoml |  49 +++++++++++++---
 src/site/resources/images/class-diagram.png     | Bin 57632 -> 56161 bytes
 3 files changed, 85 insertions(+), 22 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-commonsrdf/blob/25663998/src/site/markdown/index.md
----------------------------------------------------------------------
diff --git a/src/site/markdown/index.md b/src/site/markdown/index.md
index 4e01ed6..71b0b68 100644
--- a/src/site/markdown/index.md
+++ b/src/site/markdown/index.md
@@ -61,25 +61,58 @@ which may be included in Commons RDF, specifically:
 * [Graph](apidocs/index.html?org/apache/commons/rdf/api/Graph.html): a graph,
   a set of RDF triples.
 * [Triple](apidocs/index.html?org/apache/commons/rdf/api/Triple.html): a
-  `(subject, predicate, object)` RDF triple.
-* [RDFTerm](apidocs/index.html?org/apache/commons/rdf/api/RDFTerm.html): a RDF 1.1
-  Term, where IRIs, literals and blank nodes are collectively known as RDF terms.
+  RDF triple with `getSubject()`, `getPredicate()`, `getObject()`.
+* [Dataset](apidocs/index.html?org/apache/commons/rdf/api/Dataset.html): a dataset,
+  of RDF quads (or if you like, a set of named graphs).
+* [Quad](apidocs/index.html?org/apache/commons/rdf/api/Quad.html): a
+  RDF quad with with `getGraphName()`, `getSubject()`, `getPredicate()`, `getObject()`.
+* [RDFTerm](apidocs/index.html?org/apache/commons/rdf/api/RDFTerm.html): any RDF 1.1
+  Term which can be part of a Triple or Quad.
+  IRIs, literals and blank nodes are collectively known as RDF terms.
 * [IRI](apidocs/index.html?org/apache/commons/rdf/api/IRI.html): an
-  Internationalized Resource Identifier.
+  Internationalized Resource Identifier (e.g. representing  `<http://example.com/>`)
 * [BlankNode](apidocs/index.html?org/apache/commons/rdf/api/BlankNode.html): a
-   RDF-1.1 Blank Node, where they are disjoint from IRIs and literals.
+   RDF-1.1 Blank Node, e.g. representing `_:b1`. Disjoint from IRIs and literals.
 * [BlankNodeOrIRI](apidocs/index.html?org/apache/commons/rdf/api/BlankNodeOrIRI.html):
   this interface represents the RDF Terms that may be used in the subject position
   of an RDF 1.1 `Triple`, including `BlankNode` and `IRI`.
-* [Literal](apidocs/index.html?org/apache/commons/rdf/api/Literal.html): a RDF-1.1 literal.
-* [RDFTermFactory](apidocs/index.html?org/apache/commons/rdf/api/RDFTermFactory.html):
-  factory for creating `RDFTerm` and `Graph` instances.
+* [Literal](apidocs/index.html?org/apache/commons/rdf/api/Literal.html): a RDF-1.1 literal, e.g.
+  representing `"Hello there"@en`.
 
 The design of the [API](apidocs/index.html?org/apache/commons/rdf/api/package-summary.html)
 follows the terminology as defined by [RDF 1.1 Concepts and Abstract Syntax](http://www.w3.org/TR/rdf11-concepts/),
 a W3C Recommendation published on 25 February 2014. The idea is that Commons RDF
-will provide a common library for RDF 1.1 that could be implemented by systems
-on the Java Virtual Machine, allowing the portability across different implementations.
+provide a common library for RDF 1.1 with multiple implementions for
+the Java Virtual Machine, allowing the portability across different
+Commons RDF implementations.
+
+
+Commons RDF is designed for compatibility between different
+[implementations](implementations.html), e.g. by defining
+strong equality and hash code semantics (e.g. for
+[triple](apidocs/org/apache/commons/rdf/api/Triple.html#equals-java.lang.Object-)
+and [literals](fapidocs/org/apache/commons/rdf/api/Literal.html#equals-java.lang.Object-) );
+this allows users of Commons RDF to "mix and match", for instance querying a `FooGraphImpl`
+and directly adding its `FooTripleImpl`s to a `BarGraphImpl` without any
+explicit convertion.
+
+To create such instances without hard-coding an implementation, one can use:
+
+* [RDFTermFactory](apidocs/index.html?org/apache/commons/rdf/api/RDFTermFactory.html):
+  factory interface for creating instances of the above types
+  (e.g. `LiteralImpl` and `GraphImpl`).
+
+
+The API also includes a couple of "upper" interfaces  which do not have
+the above equality semantics and bridge the graph/quad duality:
+
+* [TripleLike](apidocs/index.html?org/apache/commons/rdf/api/TripleLike.html):
+  common super-interface of `Triple` and `Quad` (also a generalised triple).
+* [QuadLike](apidocs/index.html?org/apache/commons/rdf/api/QuadLike.html):
+  a `TripleLike` that also has `getGraphName()` (a generalized quad)
+* [GraphLike](apidocs/index.html?org/apache/commons/rdf/api/GraphLike.html):
+  common super-interface of `Graph` and `Dataset`.
+
 
 See the the [user guide](userguide.html) for examples of how to interact with these interfaces.
 
@@ -98,9 +131,8 @@ where version `x.y.z` of `Simple` implements version `x.y` of
 the `API`; i.e., the version `z` are backwards-compatible patches of the
 implementation.
 
-External [implementations of the Commons RDF API](implementations.html) are
-being developed as part of their retrospective projects.
-[Contributions welcome!](contributing.html)
+[Implementations of the Commons RDF API](implementations.html) are
+being developed as additional modules. [Contributions welcome!](contributing.html)
 
 
 ## Contributing

http://git-wip-us.apache.org/repos/asf/incubator-commonsrdf/blob/25663998/src/site/resources/images/class-diagram.nomnoml
----------------------------------------------------------------------
diff --git a/src/site/resources/images/class-diagram.nomnoml b/src/site/resources/images/class-diagram.nomnoml
index b309423..67278bf 100644
--- a/src/site/resources/images/class-diagram.nomnoml
+++ b/src/site/resources/images/class-diagram.nomnoml
@@ -17,12 +17,43 @@
 // To render, see http://www.nomnoml.com
 
 #fill: #bbccdd; #aabbcc
-[<abstract>RDFTermFactory]--[<abstract>Graph]
-[RDFTermFactory]--[<abstract>Triple]
-[RDFTermFactory]--[<abstract>RDFTerm]
-[Graph]->[Triple]
-[Triple]->[RDFTerm]
-[RDFTerm]<:-[<abstract>Literal] 
-[RDFTerm]<:-[<abstract>BlankNodeOrIRI] 
-[BlankNodeOrIRI]<:-[<abstract>BlankNode]
-[BlankNodeOrIRI]<:-[<abstract>IRI]
+#title: class-diagram
+
+#.like: fill=#fff italics
+
+
+[<like>GraphLike]
+[<like>TripleLike]
+[<like>QuadLike]
+
+[<like>RDFTerm]
+[<like>BlankNodeOrIRI]
+
+[<abstract>Graph]
+[<abstract>Dataset]
+[<abstract>Triple]
+[<abstract>Quad]
+[<abstract>Graph]
+
+
+[<abstract>Literal]
+[<abstract>IRI]
+[<abstract>BlankNode]
+
+[GraphLike] -> 0..* [TripleLike]
+[GraphLike]<:-[Graph]
+[GraphLike]<:-[Dataset]
+[Graph] -> 0..* [Triple]
+[Dataset] -> 0..* [Quad]
+[Triple] -> 3 [RDFTerm]
+[Quad]->4 [RDFTerm]
+[<abstract>TripleLike]<:-[Triple]
+[<abstract>QuadLike]<:-[Quad]
+[TripleLike]<:-[QuadLike]
+[RDFTerm]<:-[Literal]
+[RDFTerm]<:-[BlankNodeOrIRI]
+[BlankNodeOrIRI]<:-[BlankNode]
+[BlankNodeOrIRI]<:-[IRI]
+
+#.factory: fill=#ccbbdd italics
+[<factory>RDFTermFactory||createGraph()|createDataset()|createTriple(..)|createQuad(..)|..]

http://git-wip-us.apache.org/repos/asf/incubator-commonsrdf/blob/25663998/src/site/resources/images/class-diagram.png
----------------------------------------------------------------------
diff --git a/src/site/resources/images/class-diagram.png b/src/site/resources/images/class-diagram.png
index 16b9c3b..b725b65 100644
Binary files a/src/site/resources/images/class-diagram.png and b/src/site/resources/images/class-diagram.png differ


[17/19] incubator-commonsrdf git commit: Add asJenaModel() and fromJena(Model)

Posted by st...@apache.org.
Add asJenaModel() and fromJena(Model)


Project: http://git-wip-us.apache.org/repos/asf/incubator-commonsrdf/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-commonsrdf/commit/361aaba1
Tree: http://git-wip-us.apache.org/repos/asf/incubator-commonsrdf/tree/361aaba1
Diff: http://git-wip-us.apache.org/repos/asf/incubator-commonsrdf/diff/361aaba1

Branch: refs/heads/jena
Commit: 361aaba1c2ec3791d9dd88f18ccb4142b562fb09
Parents: c752d8c
Author: Stian Soiland-Reyes <st...@apache.org>
Authored: Thu Sep 8 15:18:07 2016 +0100
Committer: Stian Soiland-Reyes <st...@apache.org>
Committed: Thu Sep 8 15:18:07 2016 +0100

----------------------------------------------------------------------
 jena/pom.xml                                    |  3 ++-
 .../org/apache/commons/rdf/jena/JenaGraph.java  | 19 +++++++++++++++
 .../commons/rdf/jena/JenaRDFTermFactory.java    | 18 +++++++++++++-
 .../apache/commons/rdf/jena/impl/GraphImpl.java | 25 +++++++++++++++++++-
 .../commons/rdf/jena/impl/JenaFactory.java      |  7 +++++-
 5 files changed, 68 insertions(+), 4 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-commonsrdf/blob/361aaba1/jena/pom.xml
----------------------------------------------------------------------
diff --git a/jena/pom.xml b/jena/pom.xml
index 6bf0aeb..c06c5bf 100644
--- a/jena/pom.xml
+++ b/jena/pom.xml
@@ -48,6 +48,8 @@
 		<!-- 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>
@@ -55,7 +57,6 @@
 			<type>pom</type>
 			<scope>optional</scope>
 		</dependency>
-		--> 
 
 		<!-- As commons-rdf-jena is an OSGi bundle, we'll use the Jena OSGi bundle -->
 		<dependency>

http://git-wip-us.apache.org/repos/asf/incubator-commonsrdf/blob/361aaba1/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
index 7596021..fa8954e 100644
--- a/jena/src/main/java/org/apache/commons/rdf/jena/JenaGraph.java
+++ b/jena/src/main/java/org/apache/commons/rdf/jena/JenaGraph.java
@@ -19,8 +19,27 @@
 package org.apache.commons.rdf.jena;
 
 import org.apache.jena.graph.Graph;
+import org.apache.jena.rdf.model.Model;
 
 /** Access the Jena graph backing this object */
 public interface JenaGraph extends org.apache.commons.rdf.api.Graph {
+	
+	/**
+	 * Return the underlying Jena {@link Graph}.
+	 * <p>
+	 * Changes to the Jena graph are reflected in the Commons RDF graph and vice versa.
+	 * 
+	 * @return A Jena {@link Graph}
+	 */
 	public Graph asJenaGraph();
+
+	/**
+	 * Return the underlying Jena {@link Model}.
+	 * <p>
+	 * Changes to the Jena model are reflected in the Commons RDF graph and vice
+	 * versa.
+	 * 
+	 * @return A Jena {@link Model}
+	 */	
+	public Model asJenaModel();
 }

http://git-wip-us.apache.org/repos/asf/incubator-commonsrdf/blob/361aaba1/jena/src/main/java/org/apache/commons/rdf/jena/JenaRDFTermFactory.java
----------------------------------------------------------------------
diff --git a/jena/src/main/java/org/apache/commons/rdf/jena/JenaRDFTermFactory.java b/jena/src/main/java/org/apache/commons/rdf/jena/JenaRDFTermFactory.java
index 52fde28..a75b61e 100644
--- a/jena/src/main/java/org/apache/commons/rdf/jena/JenaRDFTermFactory.java
+++ b/jena/src/main/java/org/apache/commons/rdf/jena/JenaRDFTermFactory.java
@@ -78,7 +78,7 @@ public final class JenaRDFTermFactory implements RDFTermFactory {
 	}
 	
 	@Override
-	public Dataset createDataset() throws UnsupportedOperationException {
+	public Dataset createDataset() {
 		return JenaFactory.createDataset(salt);
 	}
 
@@ -467,6 +467,22 @@ public final class JenaRDFTermFactory implements RDFTermFactory {
 		return JenaFactory.fromJena(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 JenaRDFTermFactory} instance
+	 * in combination with {@link Node#getBlankNodeId()} 
+	 * for the purpose of its {@link BlankNode#uniqueReference()}.
+
+	 */
+	public JenaGraph fromJena(org.apache.jena.rdf.model.Model model) {
+		return JenaFactory.fromJena(model, salt);
+	}	
 
 	/**
 	 * Adapt an existing Jena {@link org.apache.jena.graph.Graph} to CommonsRDF {@link Graph}. 

http://git-wip-us.apache.org/repos/asf/incubator-commonsrdf/blob/361aaba1/jena/src/main/java/org/apache/commons/rdf/jena/impl/GraphImpl.java
----------------------------------------------------------------------
diff --git a/jena/src/main/java/org/apache/commons/rdf/jena/impl/GraphImpl.java b/jena/src/main/java/org/apache/commons/rdf/jena/impl/GraphImpl.java
index 02c4a25..3b74ee0 100644
--- a/jena/src/main/java/org/apache/commons/rdf/jena/impl/GraphImpl.java
+++ b/jena/src/main/java/org/apache/commons/rdf/jena/impl/GraphImpl.java
@@ -30,6 +30,8 @@ import org.apache.commons.rdf.jena.JenaGraph;
 import org.apache.commons.rdf.jena.JenaRDFTermFactory;
 import org.apache.jena.atlas.iterator.Iter;
 import org.apache.jena.graph.Node;
+import org.apache.jena.rdf.model.Model;
+import org.apache.jena.rdf.model.ModelFactory;
 import org.apache.jena.riot.Lang;
 import org.apache.jena.riot.RDFDataMgr;
 
@@ -37,12 +39,19 @@ public class GraphImpl implements JenaGraph {
 
 	private org.apache.jena.graph.Graph graph;
 	private UUID salt;
+	private Model model;
 
-	/* package */ GraphImpl(org.apache.jena.graph.Graph graph, UUID salt) {
+	GraphImpl(org.apache.jena.graph.Graph graph, UUID salt) {
 		this.graph = graph;
 		this.salt = salt;
 	}
 
+	GraphImpl(Model model, UUID salt) {
+		this.model = model;
+		this.graph = model.getGraph();
+		this.salt = salt;
+	}
+
 	@Override
 	public void add(BlankNodeOrIRI subject, IRI predicate, RDFTerm object) {
 		graph.add(org.apache.jena.graph.Triple.create(
@@ -128,4 +137,18 @@ public class GraphImpl implements JenaGraph {
 		return sw.toString();
 	}
 
+	@Override
+	public Model asJenaModel() {
+		if (model == null) {
+			synchronized(this) {
+				// As Model can be used for locks, we should make sure we don't make
+				// more than one model
+				if (model == null) {
+					model = ModelFactory.createModelForGraph(graph);
+				}
+			}
+		}
+		return model;
+	}
+
 }

http://git-wip-us.apache.org/repos/asf/incubator-commonsrdf/blob/361aaba1/jena/src/main/java/org/apache/commons/rdf/jena/impl/JenaFactory.java
----------------------------------------------------------------------
diff --git a/jena/src/main/java/org/apache/commons/rdf/jena/impl/JenaFactory.java b/jena/src/main/java/org/apache/commons/rdf/jena/impl/JenaFactory.java
index 1832232..bc0ae0f 100644
--- a/jena/src/main/java/org/apache/commons/rdf/jena/impl/JenaFactory.java
+++ b/jena/src/main/java/org/apache/commons/rdf/jena/impl/JenaFactory.java
@@ -42,6 +42,7 @@ import org.apache.commons.rdf.jena.JenaTripleLike;
 import org.apache.commons.rdf.jena.JenaVariable;
 import org.apache.jena.graph.Node;
 import org.apache.jena.graph.NodeFactory;
+import org.apache.jena.rdf.model.Model;
 import org.apache.jena.sparql.core.DatasetGraph;
 import org.apache.jena.sparql.core.DatasetGraphFactory;
 import org.apache.jena.sparql.graph.GraphFactory;
@@ -142,7 +143,7 @@ public class JenaFactory {
 		}
 		throw new IllegalArgumentException("Unrecognized node type: " + node);
 	}
-	
+
 	public static JenaGraph fromJena(org.apache.jena.graph.Graph graph) {
 		return new GraphImpl(graph, UUID.randomUUID());
 	}
@@ -151,6 +152,10 @@ public class JenaFactory {
 		return new GraphImpl(graph, salt);
 	}
 
+	public static JenaGraph fromJena(Model model, UUID salt) {
+		return new GraphImpl(model, salt);
+	}
+
 	public static JenaDataset fromJena(DatasetGraph datasetGraph) {
 		return new DatasetImpl(datasetGraph, UUID.randomUUID());
 	}


[09/19] incubator-commonsrdf git commit: link to github

Posted by st...@apache.org.
link to github


Project: http://git-wip-us.apache.org/repos/asf/incubator-commonsrdf/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-commonsrdf/commit/1a3e291b
Tree: http://git-wip-us.apache.org/repos/asf/incubator-commonsrdf/tree/1a3e291b
Diff: http://git-wip-us.apache.org/repos/asf/incubator-commonsrdf/diff/1a3e291b

Branch: refs/heads/jena
Commit: 1a3e291ba9214ed71c69ae968400ac427ffaa18f
Parents: 4e7f261
Author: Stian Soiland-Reyes <st...@apache.org>
Authored: Wed Sep 7 02:12:05 2016 +0100
Committer: Stian Soiland-Reyes <st...@apache.org>
Committed: Wed Sep 7 02:12:05 2016 +0100

----------------------------------------------------------------------
 src/site/site.xml | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-commonsrdf/blob/1a3e291b/src/site/site.xml
----------------------------------------------------------------------
diff --git a/src/site/site.xml b/src/site/site.xml
index f6586d8..ee7edca 100644
--- a/src/site/site.xml
+++ b/src/site/site.xml
@@ -56,7 +56,7 @@
       <item name="Home"                 href="/index.html" />
       <item name="API"                  href="/apidocs/index.html?org/apache/commons/rdf/api/package-summary.html" />
       <item name="Implementations"      href="/implementations.html" />
-      <item name="User Guide"           href="/userguide.html" />       
+      <item name="User Guide"           href="/userguide.html" />
       <item name="Download"             href="/download.html" />
       <item name="Contributing"         href="/contributing.html" />
       <item name="Team"                 href="/team-list.html" />
@@ -64,6 +64,7 @@
     <menu name="Tools">
       <item name="Mailing Lists"        href="/mail-lists.html" />
       <item name="Source (Git)"         href="https://git-wip-us.apache.org/repos/asf/incubator-commonsrdf.git" />
+      <item name="Source (GitHub mirror)" href="https://github.com/apache/incubator-commonsrdf/" />
       <item name="Issues (Jira)"        href="https://issues.apache.org/jira/browse/COMMONSRDF" />
     </menu>
   </body>


[02/19] incubator-commonsrdf git commit: quad: fixed typo in error message

Posted by st...@apache.org.
quad: fixed typo in error message


Project: http://git-wip-us.apache.org/repos/asf/incubator-commonsrdf/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-commonsrdf/commit/53ef2282
Tree: http://git-wip-us.apache.org/repos/asf/incubator-commonsrdf/tree/53ef2282
Diff: http://git-wip-us.apache.org/repos/asf/incubator-commonsrdf/diff/53ef2282

Branch: refs/heads/jena
Commit: 53ef22820e750200b888d0ae93de438bfb4037d6
Parents: 580484c
Author: Stian Soiland-Reyes <st...@apache.org>
Authored: Mon Jun 20 18:18:46 2016 +0100
Committer: Stian Soiland-Reyes <st...@apache.org>
Committed: Mon Jun 20 18:18:46 2016 +0100

----------------------------------------------------------------------
 api/src/main/java/org/apache/commons/rdf/api/RDFTermFactory.java | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-commonsrdf/blob/53ef2282/api/src/main/java/org/apache/commons/rdf/api/RDFTermFactory.java
----------------------------------------------------------------------
diff --git a/api/src/main/java/org/apache/commons/rdf/api/RDFTermFactory.java b/api/src/main/java/org/apache/commons/rdf/api/RDFTermFactory.java
index f2a6f95..48605e7 100644
--- a/api/src/main/java/org/apache/commons/rdf/api/RDFTermFactory.java
+++ b/api/src/main/java/org/apache/commons/rdf/api/RDFTermFactory.java
@@ -271,7 +271,7 @@ public interface RDFTermFactory {
                                 RDFTerm object) throws IllegalArgumentException,
             UnsupportedOperationException {
         throw new UnsupportedOperationException(
-                "createTriple(BlankNodeOrIRI,IRI,RDFTerm) not supported");
+                "createQuad(BlankNodeOrIRI,BlankNodeOrIRI,IRI,RDFTerm) not supported");
     }
 
 }


[05/19] incubator-commonsrdf git commit: COMMONSRDF-37 Add Quad, Dataset, TripleLike

Posted by st...@apache.org.
COMMONSRDF-37 Add Quad, Dataset, TripleLike

Also adds QuadLike, GraphLike

simple adds DatasetGraphView, DatsetImple, QuadImpl

TODO: Dataset tests

This closes #19


Project: http://git-wip-us.apache.org/repos/asf/incubator-commonsrdf/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-commonsrdf/commit/fc70462e
Tree: http://git-wip-us.apache.org/repos/asf/incubator-commonsrdf/tree/fc70462e
Diff: http://git-wip-us.apache.org/repos/asf/incubator-commonsrdf/diff/fc70462e

Branch: refs/heads/jena
Commit: fc70462ebf3462233a42f10a80c13040c6bb5a43
Parents: 6c673b7 a1d6554
Author: Stian Soiland-Reyes <st...@apache.org>
Authored: Mon Sep 5 16:39:35 2016 +0100
Committer: Stian Soiland-Reyes <st...@apache.org>
Committed: Mon Sep 5 16:39:56 2016 +0100

----------------------------------------------------------------------
 .../org/apache/commons/rdf/api/Dataset.java     | 338 +++++++++++++++++++
 .../java/org/apache/commons/rdf/api/Graph.java  |  40 ++-
 .../org/apache/commons/rdf/api/GraphLike.java   | 113 +++++++
 .../java/org/apache/commons/rdf/api/Quad.java   | 211 ++++++++++++
 .../org/apache/commons/rdf/api/QuadLike.java    |  67 ++++
 .../apache/commons/rdf/api/RDFTermFactory.java  |  40 +++
 .../java/org/apache/commons/rdf/api/Triple.java |   2 +-
 .../org/apache/commons/rdf/api/TripleLike.java  |  69 ++++
 .../commons/rdf/api/AbstractGraphTest.java      |  24 +-
 .../commons/rdf/simple/DatasetGraphView.java    | 138 ++++++++
 .../apache/commons/rdf/simple/DatasetImpl.java  | 221 ++++++++++++
 .../apache/commons/rdf/simple/GraphImpl.java    |  12 +-
 .../org/apache/commons/rdf/simple/QuadImpl.java | 109 ++++++
 .../rdf/simple/SimpleRDFTermFactory.java        |  13 +
 .../commons/rdf/simple/TestWritingGraph.java    |   8 +-
 15 files changed, 1374 insertions(+), 31 deletions(-)
----------------------------------------------------------------------



[16/19] incubator-commonsrdf git commit: Reformatted comments in pom

Posted by st...@apache.org.
Reformatted comments in pom


Project: http://git-wip-us.apache.org/repos/asf/incubator-commonsrdf/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-commonsrdf/commit/c752d8c4
Tree: http://git-wip-us.apache.org/repos/asf/incubator-commonsrdf/tree/c752d8c4
Diff: http://git-wip-us.apache.org/repos/asf/incubator-commonsrdf/diff/c752d8c4

Branch: refs/heads/jena
Commit: c752d8c448b4d91ef426a302ac11f2d9656797ab
Parents: bd644d3
Author: Stian Soiland-Reyes <st...@apache.org>
Authored: Thu Sep 8 15:03:18 2016 +0100
Committer: Stian Soiland-Reyes <st...@apache.org>
Committed: Thu Sep 8 15:03:18 2016 +0100

----------------------------------------------------------------------
 jena/pom.xml | 14 +++++++++++---
 1 file changed, 11 insertions(+), 3 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-commonsrdf/blob/c752d8c4/jena/pom.xml
----------------------------------------------------------------------
diff --git a/jena/pom.xml b/jena/pom.xml
index 11b3e0e..6bf0aeb 100644
--- a/jena/pom.xml
+++ b/jena/pom.xml
@@ -45,9 +45,17 @@
 			<artifactId>commons-rdf-simple</artifactId>
 			<version>${project.version}</version>
 		</dependency>
-		<!-- Uncomment below to use instead of jena-osgi to access Jena source 
-			code <dependency> <groupId>org.apache.jena</groupId> <artifactId>apache-jena-libs</artifactId> 
-			<version>${ver.jena}</version> <type>pom</type> <scope>optional</scope> </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>${ver.jena}</version>
+			<type>pom</type>
+			<scope>optional</scope>
+		</dependency>
+		--> 
 
 		<!-- As commons-rdf-jena is an OSGi bundle, we'll use the Jena OSGi bundle -->
 		<dependency>


[12/19] incubator-commonsrdf git commit: enable all report plugins

Posted by st...@apache.org.
enable all report plugins

(sadly this also mean enabling lots of "Project Information"
<reportSet> enabled in commons-parent )


Project: http://git-wip-us.apache.org/repos/asf/incubator-commonsrdf/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-commonsrdf/commit/d7e4cbe4
Tree: http://git-wip-us.apache.org/repos/asf/incubator-commonsrdf/tree/d7e4cbe4
Diff: http://git-wip-us.apache.org/repos/asf/incubator-commonsrdf/diff/d7e4cbe4

Branch: refs/heads/jena
Commit: d7e4cbe49aa56e515a5ae83f8e531a91e1c5c44c
Parents: 091f1d1
Author: Stian Soiland-Reyes <st...@apache.org>
Authored: Wed Sep 7 02:13:28 2016 +0100
Committer: Stian Soiland-Reyes <st...@apache.org>
Committed: Wed Sep 7 02:14:06 2016 +0100

----------------------------------------------------------------------
 pom.xml | 305 +++++++++++++++++++++++++++++++++++++----------------------
 1 file changed, 194 insertions(+), 111 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-commonsrdf/blob/d7e4cbe4/pom.xml
----------------------------------------------------------------------
diff --git a/pom.xml b/pom.xml
index 6ac78f3..f9b85fc 100644
--- a/pom.xml
+++ b/pom.xml
@@ -35,18 +35,10 @@
     <name>Commons RDF</name>
     <description>Commons Java API for RDF 1.1</description>
 
-    <url>http://commonsrdf.incubator.apache.org</url>
+    <url>http://commonsrdf.incubator.apache.org/</url>
 
     <inceptionYear>2015</inceptionYear>
 
-    <licenses>
-        <license>
-            <name>The Apache Software License, Version 2.0</name>
-            <url>http://www.apache.org/licenses/LICENSE-2.0.txt</url>
-            <distribution>repo</distribution>
-        </license>
-    </licenses>
-
     <properties>
         <maven.compiler.source>1.8</maven.compiler.source>
         <maven.compiler.target>1.8</maven.compiler.target>
@@ -59,7 +51,9 @@
         <commons.site.path>rdf</commons.site.path>
         <commons.scmPubUrl>https://svn.apache.org/repos/infra/websites/production/commonsrdf/content/</commons.scmPubUrl>
         <commons.scmPubCheckoutDirectory>${project.build.directory}/site-content</commons.scmPubCheckoutDirectory>
-        <commons.javadoc.java.link>http://docs.oracle.com/javase/8/docs/api/</commons.javadoc.java.link>
+        <commons.javadoc.java.link>https://docs.oracle.com/javase/8/docs/api/</commons.javadoc.java.link>
+        <!-- upgrade from 0.8.0 -->
+         <commons.japicmp.version>0.9.0</commons.japicmp.version>
     </properties>
 
     <scm>
@@ -73,6 +67,10 @@
         <system>Jira</system>
         <url>https://issues.apache.org/jira/browse/COMMONSRDF</url>
     </issueManagement>
+    <ciManagement>
+      <system>jenkins</system>
+      <url>https://builds.apache.org/</url>
+    </ciManagement>
 
     <mailingLists>
         <mailingList>
@@ -180,7 +178,7 @@
         <contributor>
             <name>Peter Ansell</name>
             <email>ansell[at]apache[dot]org</email>
-            <url>http://github.com/ansell</url>
+            <url>https://github.com/ansell</url>
             <roles>
                 <role>Emeritus Committer</role>
                 <role>Emeritus PPMC Member</role>
@@ -280,26 +278,30 @@
                         <goals>
                             <goal>jar</goal>
                         </goals>
-                        <configuration>                        	
-                            <additionalparam>-Xdoclint:none</additionalparam>
-                        </configuration>
                     </execution>
                 </executions>
+                <configuration>
+                    <additionalparam>-Xdoclint:none</additionalparam>
+                </configuration>
             </plugin>
+            <!--
             <plugin>
                 <groupId>org.apache.maven.plugins</groupId>
-                <artifactId>maven-compiler-plugin</artifactId>                
+                <artifactId>maven-compiler-plugin</artifactId>
                 <configuration>
                     <source>${maven.compiler.source}</source>
                     <target>${maven.compiler.target}</target>
                     <encoding>${project.build.encoding}</encoding>
                 </configuration>
             </plugin>
+-->
             <plugin>
                 <groupId>org.apache.maven.plugins</groupId>
                 <artifactId>maven-release-plugin</artifactId>
                 <configuration>
-                    <useReleaseProfile>false</useReleaseProfile>
+                    <useReleaseProfile>true</useReleaseProfile>
+                    <!-- TODO: Use apache-parent's apache-release rather than common-parent's release? -->
+                    <releaseProfiles>release</releaseProfiles>
                     <goals>deploy</goals>
                     <autoVersionSubmodules>true</autoVersionSubmodules>
                     <localCheckout>true</localCheckout>
@@ -309,25 +311,41 @@
                     <connectionUrl>scm:git:file://`pwd`/.git</connectionUrl>
                 </configuration>
             </plugin>
-            <!-- Create code coverage reports and submit them to coveralls.io. -->
+            <!-- Create code coverage reports and submit them to coveralls.io.
+            https://coveralls.io/github/apache/incubator-commonsrdf
+            -->
             <plugin>
                 <groupId>org.eluder.coveralls</groupId>
                 <artifactId>coveralls-maven-plugin</artifactId>
-                <version>3.1.0</version>
-            </plugin>
-            <plugin>
-                <groupId>org.jacoco</groupId>
-                <artifactId>jacoco-maven-plugin</artifactId>
-                <version>0.7.2.201409121644</version>
-                <executions>
-                    <execution>
-                        <id>prepare-agent</id>
-                        <goals>
-                            <goal>prepare-agent</goal>
-                        </goals>
-                    </execution>
-                </executions>
+                <version>4.2.0</version>
             </plugin>
+      <plugin>
+        <groupId>org.codehaus.mojo</groupId>
+        <artifactId>jdepend-maven-plugin</artifactId>
+        <version>${commons.jdepend.version}</version>
+        <dependencies>
+            <!-- Forked jdepend https://github.com/nidi3/jdepend supports Java 8 -->
+            <dependency>
+              <groupId>guru.nidi</groupId>
+              <artifactId>jdepend</artifactId>
+              <version>2.9.5</version>
+            </dependency>
+        </dependencies>
+      </plugin>
+
+      <plugin>
+        <!-- Check if we broke compatibibility against previous release -->
+        <groupId>com.github.siom79.japicmp</groupId>
+        <artifactId>japicmp-maven-plugin</artifactId>
+        <version>${commons.japicmp.version}</version>
+        <configuration>
+          <parameter>
+            <!-- Tell japicmp about the -incubator suffix  -->
+            <oldVersionPattern>\d+\.\d+\.\d+\-incubating</oldVersionPattern>
+          </parameter>
+        </configuration>
+      </plugin>
+
             <plugin>
                 <groupId>org.apache.maven.plugins</groupId>
                 <artifactId>maven-site-plugin</artifactId>
@@ -338,41 +356,20 @@
                         <version>1.6</version>
                     </dependency>
                 </dependencies>
+                <!--
                 <configuration>
-                    <siteDirectory>${basedir}/src/site</siteDirectory>
+                    <siteDirectory>${project.basedir}/src/site</siteDirectory>
                     <outputDirectory>${project.build.directory}/site</outputDirectory>
-                    <inputEncoding>${project.build.encoding}</inputEncoding>
-                    <outputEncoding>${project.build.encoding}</outputEncoding>
                     <showAvatarImages>false</showAvatarImages>
-                    <reportPlugins>
-                        <plugin>
-                            <groupId>org.apache.maven.plugins</groupId>
-                            <artifactId>maven-javadoc-plugin</artifactId>
-                            <configuration>
-                                <additionalparam>-Xdoclint:none</additionalparam>
-                            </configuration>
-                        </plugin>
-                        <plugin>
-                            <groupId>org.apache.maven.plugins</groupId>
-                            <artifactId>maven-project-info-reports-plugin</artifactId>
-                            <version>2.7</version> 
-                            <configuration>
-                                <dependencyLocationsEnabled>false</dependencyLocationsEnabled>
-                            </configuration>
-                            <reports> 
-                                <report>project-team</report>
-                                <report>mailing-list</report>
-                                <report>scm</report>
-                            </reports>
-                        </plugin>
-                    </reportPlugins>
                 </configuration>
+              -->
             </plugin>
         </plugins>
         <pluginManagement>
             <plugins>
-                <!--This plugin's configuration is used to store Eclipse m2e settings 
+                <!--This plugin's configuration is used to store Eclipse m2e settings
                     only. It has no influence on the Maven build itself. -->
+
                 <plugin>
                     <groupId>org.eclipse.m2e</groupId>
                     <artifactId>lifecycle-mapping</artifactId>
@@ -380,11 +377,12 @@
                     <configuration>
                         <lifecycleMappingMetadata>
                             <pluginExecutions>
+                              <!-- No longer needed?
                                 <pluginExecution>
                                     <pluginExecutionFilter>
                                         <groupId>org.jacoco</groupId>
                                         <artifactId>jacoco-maven-plugin</artifactId>
-                                        <versionRange>[0.7.2.201409121644,)</versionRange>
+                                        <versionRange>[${commons.jacoco.version},)</versionRange>
                                         <goals>
                                             <goal>prepare-agent</goal>
                                         </goals>
@@ -393,6 +391,7 @@
                                         <ignore />
                                     </action>
                                 </pluginExecution>
+                              -->
                                 <pluginExecution>
                                     <pluginExecutionFilter>
                                         <groupId>org.apache.maven.plugins</groupId>
@@ -410,6 +409,8 @@
                         </lifecycleMappingMetadata>
                     </configuration>
                 </plugin>
+
+                <!--
                 <plugin>
                     <groupId>org.codehaus.mojo</groupId>
                     <artifactId>animal-sniffer-maven-plugin</artifactId>
@@ -417,7 +418,7 @@
                     <configuration>
                         <skip>true</skip>
                     </configuration>
-                </plugin>
+                </plugin>-->
                 <plugin>
                     <groupId>org.apache.rat</groupId>
                     <artifactId>apache-rat-plugin</artifactId>
@@ -440,6 +441,93 @@
             </plugins>
         </pluginManagement>
     </build>
+    <reporting>
+
+      <plugins>
+        <plugin>
+             <groupId>org.apache.maven.plugins</groupId>
+             <artifactId>maven-javadoc-plugin</artifactId>
+             <configuration>
+                 <additionalparam>-Xdoclint:none</additionalparam>
+             </configuration>
+             <reportSets>
+               <reportSet><!-- by default, id = "default" -->
+                 <reports><!-- select non-aggregate reports -->
+                   <report>javadoc</report>
+                   <report>test-javadoc</report>
+                 </reports>
+               </reportSet>
+               <reportSet><!-- aggregate reportSet, to define in poms having modules -->
+                 <id>aggregate</id>
+                 <inherited>false</inherited><!-- don't run aggregate in child modules -->
+                 <reports>
+                   <report>aggregate</report>
+                 </reports>
+               </reportSet>
+             </reportSets>
+         </plugin>
+  <plugin>
+    <groupId>org.apache.maven.plugins</groupId>
+    <artifactId>maven-checkstyle-plugin</artifactId>
+    <version>${checkstyle.plugin.version}</version>
+        <configuration>
+          <configLocation>${project.basedir}/src/conf/checkstyle.xml</configLocation>
+          <!-- Needed to define config_loc -->
+          <propertyExpansion>config_loc=${project.basedir}</propertyExpansion>
+          <enableRulesSummary>false</enableRulesSummary>
+        </configuration>
+        <reportSets>
+          <reportSet>
+            <reports>
+              <report>checkstyle-aggregate</report>
+            </reports>
+          </reportSet>
+        </reportSets>
+  </plugin>
+
+<plugin>
+  <artifactId>maven-pmd-plugin</artifactId>
+          <version>3.6</version>
+          <configuration>
+            <targetJdk>${maven.compiler.target}</targetJdk>
+            <linkXref>true</linkXref>
+          </configuration>
+          <reportSets>
+            <reportSet>
+              <id>pmd-report</id>
+              <reports>
+                <report>pmd</report>
+              </reports>
+            </reportSet>
+            <reportSet>
+              <id>pmd-aggregate</id>
+              <inherited>false</inherited>
+              <reports>
+                <report>pmd</report>
+              </reports>
+              <configuration>
+                <aggregate>true</aggregate>
+              </configuration>
+            </reportSet>
+          </reportSets>
+        </plugin>
+
+      <plugin>
+        <groupId>org.codehaus.mojo</groupId>
+        <artifactId>findbugs-maven-plugin</artifactId>
+        <version>${commons.findbugs.version}</version>
+        <configuration>
+          <threshold>Normal</threshold>
+          <effort>Default</effort>
+          <excludeFilterFile>src/conf/findbugs-exclude-filter.xml</excludeFilterFile>
+          <fork>true</fork>
+          <jvmArgs>-Duser.language=en</jvmArgs>
+        </configuration>
+      </plugin>
+
+</plugins>
+
+    </reporting>
 
     <profiles>
         <profile>
@@ -447,65 +535,60 @@
             <!-- extends the release profile from commons -->
             <build>
                 <plugins>
+                  <!-- Generate convenience *.md5 *.sha1 files for dist puropses -->
+                  <plugin>
+                      <groupId>org.apache.maven.plugins</groupId>
+                      <artifactId>maven-antrun-plugin</artifactId>
+                      <executions>
+                          <execution>
+                              <id>default-cli</id>
+                              <goals>
+                                  <goal>run</goal>
+                              </goals>
+                              <phase>package</phase>
+                              <configuration>
+                                  <tasks>
+                                      <checksum algorithm="MD5" fileext=".md5">
+                                          <fileset dir="${project.build.directory}">
+                                              <include name="*.zip" />
+                                              <include name="*.tar.gz" />
+                                          </fileset>
+                                      </checksum>
+                                      <checksum algorithm="SHA1" fileext=".sha1">
+                                          <fileset dir="${project.build.directory}">
+                                              <include name="*.zip" />
+                                              <include name="*.tar.gz" />
+                                          </fileset>
+                                      </checksum>
+                                  </tasks>
+                              </configuration>
+                          </execution>
+                      </executions>
+                      <dependencies>
+                          <dependency>
+                              <groupId>org.apache.ant</groupId>
+                              <artifactId>ant-nodeps</artifactId>
+                              <version>1.8.1</version>
+                          </dependency>
+                      </dependencies>
+                  </plugin>
+
                     <plugin>
                         <groupId>org.apache.maven.plugins</groupId>
                         <artifactId>maven-gpg-plugin</artifactId>
-                        <executions>
-                            <execution>
-                                <id>sign-artifacts</id>
-                                <phase>verify</phase>
-                                <goals>
-                                    <goal>sign</goal>
-                                </goals>
-                                <configuration>
-                                    <excludes>
-                                        <exclude>**/*.asc</exclude>
-                                        <exclude>**/*.md5</exclude>
-                                        <exclude>**/*.sha1</exclude>
-                                    </excludes>
-                                </configuration>
-                            </execution>
-                        </executions>
-                    </plugin>
-                    <plugin>
-                        <groupId>org.apache.maven.plugins</groupId>
-                        <artifactId>maven-antrun-plugin</artifactId>
-                        <executions>
-                            <execution>
-                                <id>default-cli</id>
-                                <goals>
-                                    <goal>run</goal>
-                                </goals>
-                                <phase>package</phase>
-                                <configuration>
-                                    <tasks>
-                                        <checksum algorithm="MD5" fileext=".md5">
-                                            <fileset dir="${project.build.directory}">
-                                                <include name="*.zip" />
-                                                <include name="*.tar.gz" />
-                                            </fileset>
-                                        </checksum>
-                                        <checksum algorithm="SHA1" fileext=".sha1">
-                                            <fileset dir="${project.build.directory}">
-                                                <include name="*.zip" />
-                                                <include name="*.tar.gz" />
-                                            </fileset>
-                                        </checksum>
-                                    </tasks>
-                                </configuration>
-                            </execution>
-                        </executions>
-                        <dependencies>
-                            <dependency>
-                                <groupId>org.apache.ant</groupId>
-                                <artifactId>ant-nodeps</artifactId>
-                                <version>1.8.1</version>
-                            </dependency>
-                        </dependencies>
+                        <configuration>
+                            <excludes>
+                                <exclude>**/*.asc</exclude>
+                                <exclude>**/*.md5</exclude>
+                                <exclude>**/*.sha1</exclude>
+                            </excludes>
+                        </configuration>
                     </plugin>
                 </plugins>
             </build>
         </profile>
     </profiles>
 
+
+
 </project>


[04/19] incubator-commonsrdf git commit: updated to commons-parent 41

Posted by st...@apache.org.
updated to commons-parent 41


Project: http://git-wip-us.apache.org/repos/asf/incubator-commonsrdf/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-commonsrdf/commit/6c673b71
Tree: http://git-wip-us.apache.org/repos/asf/incubator-commonsrdf/tree/6c673b71
Diff: http://git-wip-us.apache.org/repos/asf/incubator-commonsrdf/diff/6c673b71

Branch: refs/heads/jena
Commit: 6c673b7190f22ca80b6555ca3028c167cef06a7a
Parents: c9dd974
Author: Sergio Fern�ndez <wi...@apache.org>
Authored: Thu Aug 11 16:58:49 2016 +0200
Committer: Sergio Fern�ndez <wi...@apache.org>
Committed: Thu Aug 11 16:58:49 2016 +0200

----------------------------------------------------------------------
 pom.xml | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-commonsrdf/blob/6c673b71/pom.xml
----------------------------------------------------------------------
diff --git a/pom.xml b/pom.xml
index 5353db3..6ac78f3 100644
--- a/pom.xml
+++ b/pom.xml
@@ -24,7 +24,7 @@
     <parent>
         <groupId>org.apache.commons</groupId>
         <artifactId>commons-parent</artifactId>
-        <version>40</version>
+        <version>41</version>
     </parent>
 
     <groupId>org.apache.commons</groupId>


[10/19] incubator-commonsrdf git commit: Enable jacoco and japicmp

Posted by st...@apache.org.
Enable jacoco and japicmp

both for api and simple


Project: http://git-wip-us.apache.org/repos/asf/incubator-commonsrdf/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-commonsrdf/commit/dd6e7fa4
Tree: http://git-wip-us.apache.org/repos/asf/incubator-commonsrdf/tree/dd6e7fa4
Diff: http://git-wip-us.apache.org/repos/asf/incubator-commonsrdf/diff/dd6e7fa4

Branch: refs/heads/jena
Commit: dd6e7fa4e9894d859b7ddd7336c92d6a2e8dc1af
Parents: 1a3e291
Author: Stian Soiland-Reyes <st...@apache.org>
Authored: Wed Sep 7 02:12:28 2016 +0100
Committer: Stian Soiland-Reyes <st...@apache.org>
Committed: Wed Sep 7 02:12:28 2016 +0100

----------------------------------------------------------------------
 api/src/site/resources/profile.jacoco     | 0
 api/src/site/resources/profile.japicmp    | 0
 simple/src/site/resources/profile.jacoco  | 0
 simple/src/site/resources/profile.japicmp | 0
 4 files changed, 0 insertions(+), 0 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-commonsrdf/blob/dd6e7fa4/api/src/site/resources/profile.jacoco
----------------------------------------------------------------------
diff --git a/api/src/site/resources/profile.jacoco b/api/src/site/resources/profile.jacoco
new file mode 100644
index 0000000..e69de29

http://git-wip-us.apache.org/repos/asf/incubator-commonsrdf/blob/dd6e7fa4/api/src/site/resources/profile.japicmp
----------------------------------------------------------------------
diff --git a/api/src/site/resources/profile.japicmp b/api/src/site/resources/profile.japicmp
new file mode 100644
index 0000000..e69de29

http://git-wip-us.apache.org/repos/asf/incubator-commonsrdf/blob/dd6e7fa4/simple/src/site/resources/profile.jacoco
----------------------------------------------------------------------
diff --git a/simple/src/site/resources/profile.jacoco b/simple/src/site/resources/profile.jacoco
new file mode 100644
index 0000000..e69de29

http://git-wip-us.apache.org/repos/asf/incubator-commonsrdf/blob/dd6e7fa4/simple/src/site/resources/profile.japicmp
----------------------------------------------------------------------
diff --git a/simple/src/site/resources/profile.japicmp b/simple/src/site/resources/profile.japicmp
new file mode 100644
index 0000000..e69de29


[11/19] incubator-commonsrdf git commit: Move report plugins to src/conf

Posted by st...@apache.org.
Move report plugins to src/conf


Project: http://git-wip-us.apache.org/repos/asf/incubator-commonsrdf/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-commonsrdf/commit/091f1d10
Tree: http://git-wip-us.apache.org/repos/asf/incubator-commonsrdf/tree/091f1d10
Diff: http://git-wip-us.apache.org/repos/asf/incubator-commonsrdf/diff/091f1d10

Branch: refs/heads/jena
Commit: 091f1d10e972d5a350a50502bfebb0326c258dcc
Parents: dd6e7fa
Author: Stian Soiland-Reyes <st...@apache.org>
Authored: Wed Sep 7 02:13:17 2016 +0100
Committer: Stian Soiland-Reyes <st...@apache.org>
Committed: Wed Sep 7 02:13:17 2016 +0100

----------------------------------------------------------------------
 checkstyle-suppressions.xml          |  27 ----
 checkstyle.xml                       |  73 -----------
 pmd.xml                              |  26 ----
 src/conf/checkstyle-suppressions.xml |  32 +++++
 src/conf/checkstyle.xml              | 197 ++++++++++++++++++++++++++++++
 src/conf/findbugs-exclude-filter.xml |  27 ++++
 src/conf/pmd.xml                     |  25 ++++
 7 files changed, 281 insertions(+), 126 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-commonsrdf/blob/091f1d10/checkstyle-suppressions.xml
----------------------------------------------------------------------
diff --git a/checkstyle-suppressions.xml b/checkstyle-suppressions.xml
deleted file mode 100644
index 4796ea0..0000000
--- a/checkstyle-suppressions.xml
+++ /dev/null
@@ -1,27 +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.
--->
-
-<!DOCTYPE suppressions PUBLIC
-    "-//Puppy Crawl//DTD Suppressions 1.0//EN"
-    "http://www.puppycrawl.com/dtds/suppressions_1_0.dtd">
-
-<suppressions>
-    <suppress checks="Header" files="LICENSE.txt"/>
-    <suppress checks="Header" files="NOTICE.txt"/>
-</suppressions>

http://git-wip-us.apache.org/repos/asf/incubator-commonsrdf/blob/091f1d10/checkstyle.xml
----------------------------------------------------------------------
diff --git a/checkstyle.xml b/checkstyle.xml
deleted file mode 100644
index efc00c8..0000000
--- a/checkstyle.xml
+++ /dev/null
@@ -1,73 +0,0 @@
-<?xml version="1.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.
--->
-
-<!DOCTYPE module PUBLIC
-    "-//Puppy Crawl//DTD Check Configuration 1.1//EN"
-    "http://www.puppycrawl.com/dtds/configuration_1_1.dtd">
-
-<!-- commons codec customization of default Checkstyle behavior -->
-<module name="Checker">
-  <property name="localeLanguage" value="en" />
-
-  <module name="SuppressionFilter">
-    <property name="file" value="checkstyle-suppressions.xml"/>
-  </module>
-
-  <!-- Checks whether files end with a new line. -->
-  <!-- See http://checkstyle.sf.net/config_misc.html#NewlineAtEndOfFile -->
-  <module name="NewlineAtEndOfFile" />
-
-  <!-- Verify that EVERY source file has the appropriate license -->
-  <module name="Header">
-    <property name="headerFile" value="${checkstyle.header.file}" />
-  </module>
-
-  <!-- Checks for Tab characters -->
-  <!-- See http://checkstyle.sourceforge.net/config_whitespace.html#FileTabCharacter -->
-  <module name="FileTabCharacter">
-    <property name="fileExtensions" value="java" />
-  </module>
-
-  <!-- Checks for white space at the end of the line -->
-  <!-- See http://checkstyle.sourceforge.net/config_regexp.html -->
-  <module name="RegexpSingleline">
-    <property name="format" value="\s+$" />
-    <property name="message" value="Line has trailing spaces." />
-    <property name="fileExtensions" value="java" />
-  </module>
-
-  <!-- @author tags are deprecated -->
-  <module name="RegexpSingleline">
-    <property name="format" value="^\s+\*\s+@author\s" />
-    <property name="message" value="Deprecated @author tag" />
-    <property name="fileExtensions" value="java" />
-    <property name="severity" value="warning" />
-  </module>
-
-  <module name="TreeWalker">
-    <property name="cacheFile" value="target/cachefile" />
-    <module name="OperatorWrap">
-      <property name="option" value="eol" />
-    </module>
-    <module name="LineLength">
-      <property name="max" value="120"/>
-    </module>
-  </module>
-
-</module>
-

http://git-wip-us.apache.org/repos/asf/incubator-commonsrdf/blob/091f1d10/pmd.xml
----------------------------------------------------------------------
diff --git a/pmd.xml b/pmd.xml
deleted file mode 100644
index d88cdbd..0000000
--- a/pmd.xml
+++ /dev/null
@@ -1,26 +0,0 @@
-<?xml version="1.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.
--->
-<ruleset name="mybraces"
-    xmlns="http://pmd.sourceforge.net/ruleset/2.0.0"
-    xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
-    xsi:schemaLocation="http://pmd.sourceforge.net/ruleset/2.0.0 http://pmd.sourceforge.net/ruleset_2_0_0.xsd">
-  <description>Excludes from default PMD rules.</description>
-  <rule ref="rulesets/java/unnecessary.xml">
-    <exclude name="UselessParentheses"/>
-  </rule>
-</ruleset>
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/incubator-commonsrdf/blob/091f1d10/src/conf/checkstyle-suppressions.xml
----------------------------------------------------------------------
diff --git a/src/conf/checkstyle-suppressions.xml b/src/conf/checkstyle-suppressions.xml
new file mode 100644
index 0000000..2494608
--- /dev/null
+++ b/src/conf/checkstyle-suppressions.xml
@@ -0,0 +1,32 @@
+<?xml version="1.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.
+-->
+
+<!DOCTYPE suppressions PUBLIC
+    "-//Puppy Crawl//DTD Suppressions 1.1//EN"
+    "http://www.puppycrawl.com/dtds/suppressions_1_1.dtd">
+<!-- SEE: http://checkstyle.sourceforge.net/config.html#Examples -->
+<suppressions>
+    <suppress checks="LineLength"  files="InstructionFinder.java"/> <!-- TODO later -->
+
+    <suppress checks="MagicNumber" files="VerifierAppFrame.java"/> <!-- Swing files use lots of numbers -->
+    <suppress checks="MagicNumber" files="VerifyDialog.java"/> <!-- Swing files use lots of numbers -->
+    <suppress checks="MagicNumber" files="src[/\\]test[/\\]"/> <!-- test files need numbers -->
+
+     <!-- Maven generated code -->
+    <suppress checks=".*"          files="[/\\]target[/\\]"/>
+</suppressions>

http://git-wip-us.apache.org/repos/asf/incubator-commonsrdf/blob/091f1d10/src/conf/checkstyle.xml
----------------------------------------------------------------------
diff --git a/src/conf/checkstyle.xml b/src/conf/checkstyle.xml
new file mode 100644
index 0000000..f2ab194
--- /dev/null
+++ b/src/conf/checkstyle.xml
@@ -0,0 +1,197 @@
+<?xml version="1.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.
+-->
+
+<!DOCTYPE module PUBLIC
+    "-//Puppy Crawl//DTD Check Configuration 1.1//EN"
+    "http://www.puppycrawl.com/dtds/configuration_1_1.dtd">
+
+<!-- commons codec customization of default Checkstyle behavior -->
+<module name="Checker">
+  <property name="localeLanguage" value="en" />
+
+  <!-- Checks whether files end with a new line. -->
+  <!-- See http://checkstyle.sf.net/config_misc.html#NewlineAtEndOfFile -->
+  <module name="NewlineAtEndOfFile" />
+
+  <!-- Checks for Tab characters -->
+  <!-- See http://checkstyle.sourceforge.net/config_whitespace.html#FileTabCharacter -->
+  <module name="FileTabCharacter">
+    <property name="fileExtensions" value="java" />
+  </module>
+
+  <!-- Checks for white space at the end of the line -->
+  <!-- See http://checkstyle.sourceforge.net/config_regexp.html -->
+  <!-- 706
+  <module name="RegexpSingleline">
+    <property name="format" value="\s+$" />
+    <property name="message" value="Line has trailing spaces." />
+    <property name="fileExtensions" value="java" />
+  </module>
+  -->
+
+  <!-- @author tags are deprecated -->
+  <module name="RegexpSingleline">
+    <property name="format" value="^\s+\*\s+@author\s" />
+    <property name="message" value="Deprecated @author tag" />
+    <property name="fileExtensions" value="java" />
+    <property name="severity" value="warning" />
+  </module>
+
+  <module name="TreeWalker">
+    <property name="cacheFile" value="target/cachefile" />
+    <!-- 
+     -->
+    <module name="LineLength">
+      <property name="max" value="160"/>
+    </module>
+ 
+    <!-- Checks for Naming Conventions.                  -->
+    <!-- See http://checkstyle.sf.net/config_naming.html -->
+    <!-- allow CONSTANT_Long etc -->
+    <!-- 
+    <module name="ConstantName">
+      <property name="format" value="^[A-Z][A-Z0-9]*(_[A-Za-z0-9]+)*$"/>
+    </module>
+    <module name="LocalFinalVariableName"/>
+    <module name="LocalVariableName"/>
+    <module name="MemberName">
+      <property name="format" value="^[a-z][a-zA-Z0-9_]*(_[a-zA-Z0-9]+)*$"/>
+    </module>
+    <module name="MethodName"/>
+    <module name="PackageName"/>
+    <module name="ParameterName"/>
+    <module name="StaticVariableName"/>
+     -->
+    <module name="TypeName">
+        <!-- Allow underscore in class names -->
+        <property name="format" value="^[A-Z][A-Za-z0-9]*(_[A-Za-z0-9]+)*$"/>
+    </module>
+
+    <!-- Checks for imports                              -->
+    <!-- See http://checkstyle.sf.net/config_imports.html -->
+    <module name="AvoidStarImport">
+        <property name="excludes" value="org.junit.Assert"/>
+    </module>
+    <module name="IllegalImport"/> <!-- defaults to sun.* packages -->
+    <module name="RedundantImport"/>
+    <module name="UnusedImports"/>
+    
+    <!-- Checks for whitespace                               -->
+    <!-- See http://checkstyle.sf.net/config_whitespace.html -->
+    <module name="EmptyForIteratorPad"/>
+    <!-- Too many to fix at present
+    <module name="NoWhitespaceAfter"/>
+    <module name="NoWhitespaceBefore"/>
+    <module name="OperatorWrap">
+      <property name="option" value="nl" />
+    </module>
+    -->
+    <!-- Too many to fix at present
+    <module name="ParenPad"/>
+    <module name="WhitespaceAfter"/>
+    <module name="WhitespaceAround"/>
+    -->
+    
+    <!-- Modifier Checks                                    -->
+    <!-- See http://checkstyle.sf.net/config_modifiers.html -->
+    <module name="ModifierOrder"/>
+    
+    <!--module name="RedundantModifier"/-->
+    
+    <!-- Checks for blocks. You know, those {}'s         -->
+    <!-- See http://checkstyle.sf.net/config_blocks.html -->
+    <!--module name="AvoidNestedBlocks"/-->
+    <module name="EmptyBlock">
+      <property name="option" value="text"/>
+    </module>
+    <!--
+    <module name="LeftCurly">
+        <property name="option" value="nl"/>
+    </module>
+    -->
+    <module name="NeedBraces"/>
+    <!--
+    <module name="RightCurly">
+        <property name="option" value="alone"/>
+    </module>
+    -->
+    
+    <!-- Checks for common coding problems               -->
+    <!-- See http://checkstyle.sf.net/config_coding.html -->
+    <module name="CovariantEquals"/>
+    <module name="EqualsHashCode"/>
+    <module name="IllegalInstantiation"/>
+    <!--module name="InnerAssignment"/--><!-- Inner assignments are OK -->
+    <!-- module name="MagicNumber">
+        <property name="ignoreNumbers" value="-1,0,1,2,3"/>
+    </module-->
+    <module name="SimplifyBooleanExpression"/>
+    <module name="SimplifyBooleanReturn"/>
+    <module name="StringLiteralEquality"/>
+    <!--module name="SuperClone"/-->
+    <module name="SuperFinalize"/>
+    <!--module name="DeclarationOrder"/-->
+    <!--module name="ExplicitInitialization"/-->
+    <module name="DefaultComesLast"/>
+    <module name="FallThrough">
+        <property name="reliefPattern" value="\$FALL-THROUGH\$"/><!-- to agree with Eclipse -->
+    </module>
+    <module name="MultipleVariableDeclarations"/>
+    <module name="UnnecessaryParentheses"/>
+
+    <!-- Checks for class design                         -->
+    <!-- See http://checkstyle.sf.net/config_design.html -->
+    <!--module name="FinalClass"/-->
+    <!--module name="HideUtilityClassConstructor"/-->
+    <!--module name="InterfaceIsType"/-->
+
+    <module name="VisibilityModifier">
+        <property name="ignoreAnnotationCanonicalNames" value="java.lang.Deprecated"/>
+        <property name="protectedAllowed" value="false"/>
+        <property name="packageAllowed" value="true"/>
+    </module>
+    
+    <!-- Miscellaneous other checks.                   -->
+    <!-- See http://checkstyle.sf.net/config_misc.html -->
+    <module name="ArrayTypeStyle"/>
+    <!--module name="TodoComment"/-->
+    <module name="UpperEll"/>
+    
+    <!-- Required for SuppressionCommentFilter below -->
+    <module name="FileContentsHolder"/>
+
+  </module>
+
+  <module name="SuppressionCommentFilter"/>
+
+  <module name="SuppressionFilter">
+    <!-- config_loc is used by Eclipse plugin -->
+    <property name="file" value="${config_loc}/src/conf/checkstyle-suppressions.xml"/>
+  </module>
+
+  <!-- 
+      Allow comment to suppress checkstyle for a single line
+      e.g. // CHECKSTYLE IGNORE MagicNumber
+   -->
+  <module name="SuppressWithNearbyCommentFilter">
+    <property name="commentFormat" value="CHECKSTYLE IGNORE (\w+)"/>
+    <property name="checkFormat" value="$1"/>
+  </module>
+
+</module>
+

http://git-wip-us.apache.org/repos/asf/incubator-commonsrdf/blob/091f1d10/src/conf/findbugs-exclude-filter.xml
----------------------------------------------------------------------
diff --git a/src/conf/findbugs-exclude-filter.xml b/src/conf/findbugs-exclude-filter.xml
new file mode 100644
index 0000000..e681a70
--- /dev/null
+++ b/src/conf/findbugs-exclude-filter.xml
@@ -0,0 +1,27 @@
+<?xml version="1.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.
+-->
+
+<!--
+  Edit this file to add any false positive bugs detected by findbugs. Their
+  false positive nature should be analyzed individually and then added
+  here so findbugs will ignore them.
+-->
+<FindBugsFilter>
+
+
+</FindBugsFilter>

http://git-wip-us.apache.org/repos/asf/incubator-commonsrdf/blob/091f1d10/src/conf/pmd.xml
----------------------------------------------------------------------
diff --git a/src/conf/pmd.xml b/src/conf/pmd.xml
new file mode 100644
index 0000000..d988308
--- /dev/null
+++ b/src/conf/pmd.xml
@@ -0,0 +1,25 @@
+<?xml version="1.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.
+-->
+<ruleset name="mybraces"
+    xmlns="http://pmd.sourceforge.net/ruleset/2.0.0"
+    xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+    xsi:schemaLocation="http://pmd.sourceforge.net/ruleset/2.0.0 http://pmd.sourceforge.net/ruleset_2_0_0.xsd">
+  <description>Excludes from default PMD rules.</description>
+  <rule ref="rulesets/java/unusedcode.xml">
+  </rule>
+</ruleset>
\ No newline at end of file


[15/19] incubator-commonsrdf git commit: Merge branch 'master' into jena

Posted by st...@apache.org.
Merge branch 'master' into jena


Project: http://git-wip-us.apache.org/repos/asf/incubator-commonsrdf/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-commonsrdf/commit/bd644d3a
Tree: http://git-wip-us.apache.org/repos/asf/incubator-commonsrdf/tree/bd644d3a
Diff: http://git-wip-us.apache.org/repos/asf/incubator-commonsrdf/diff/bd644d3a

Branch: refs/heads/jena
Commit: bd644d3a6a7cce2705259a66d143b2fed06fa565
Parents: c6d654b 9782a58
Author: Stian Soiland-Reyes <st...@apache.org>
Authored: Thu Sep 8 15:00:18 2016 +0100
Committer: Stian Soiland-Reyes <st...@apache.org>
Committed: Thu Sep 8 15:00:18 2016 +0100

----------------------------------------------------------------------
 LICENSE-header.txt                              |  16 +
 RELEASE-PROCESS.md                              |  20 ++
 api/pom.xml                                     |   5 +-
 .../org/apache/commons/rdf/api/GraphLike.java   |  27 +-
 .../java/org/apache/commons/rdf/api/Quad.java   |  25 +-
 .../org/apache/commons/rdf/api/QuadLike.java    |  24 +-
 .../apache/commons/rdf/api/RDFTermFactory.java  |   3 +-
 .../java/org/apache/commons/rdf/api/Triple.java |   2 +
 .../org/apache/commons/rdf/api/TripleLike.java  |  20 +-
 api/src/site/resources/profile.jacoco           |   0
 api/src/site/resources/profile.japicmp          |   0
 pom.xml                                         | 307 ++++++++++++-------
 .../commons/rdf/simple/DatasetGraphView.java    |   2 +-
 simple/src/site/resources/profile.jacoco        |   0
 simple/src/site/resources/profile.japicmp       |   0
 src/conf/checkstyle-suppressions.xml            |  32 ++
 src/conf/checkstyle.xml                         | 197 ++++++++++++
 src/conf/findbugs-exclude-filter.xml            |  27 ++
 src/conf/pmd.xml                                |  25 ++
 src/site/markdown/implementations.md            |  63 +++-
 src/site/markdown/index.md                      |  58 +++-
 src/site/resources/images/class-diagram.nomnoml |  49 ++-
 src/site/resources/images/class-diagram.png     | Bin 57632 -> 56161 bytes
 src/site/site.xml                               |   3 +-
 24 files changed, 722 insertions(+), 183 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-commonsrdf/blob/bd644d3a/pom.xml
----------------------------------------------------------------------
diff --cc pom.xml
index 6dcdb54,f9b85fc..e7e009e
--- a/pom.xml
+++ b/pom.xml
@@@ -59,10 -51,9 +51,12 @@@
          <commons.site.path>rdf</commons.site.path>
          <commons.scmPubUrl>https://svn.apache.org/repos/infra/websites/production/commonsrdf/content/</commons.scmPubUrl>
          <commons.scmPubCheckoutDirectory>${project.build.directory}/site-content</commons.scmPubCheckoutDirectory>
-         <commons.javadoc.java.link>http://docs.oracle.com/javase/8/docs/api/</commons.javadoc.java.link>
+         <commons.javadoc.java.link>https://docs.oracle.com/javase/8/docs/api/</commons.javadoc.java.link>
+         <!-- upgrade from 0.8.0 -->
+          <commons.japicmp.version>0.9.0</commons.japicmp.version>
 +        <ver.jena>3.1.0</ver.jena>
 +        <dexx.collection.version>0.6</dexx.collection.version>
 +        <servicemix.xerces.version>2.11.0_1</servicemix.xerces.version>
      </properties>
  
      <scm>


[08/19] incubator-commonsrdf git commit: javadoc tweaks

Posted by st...@apache.org.
javadoc tweaks


Project: http://git-wip-us.apache.org/repos/asf/incubator-commonsrdf/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-commonsrdf/commit/4e7f2617
Tree: http://git-wip-us.apache.org/repos/asf/incubator-commonsrdf/tree/4e7f2617
Diff: http://git-wip-us.apache.org/repos/asf/incubator-commonsrdf/diff/4e7f2617

Branch: refs/heads/jena
Commit: 4e7f26179615ece7f0a3c38eb33d00309e430a8a
Parents: 7500084
Author: Stian Soiland-Reyes <st...@apache.org>
Authored: Tue Sep 6 16:07:19 2016 +0100
Committer: Stian Soiland-Reyes <st...@apache.org>
Committed: Tue Sep 6 16:07:19 2016 +0100

----------------------------------------------------------------------
 api/src/main/java/org/apache/commons/rdf/api/GraphLike.java    | 6 +++---
 api/src/main/java/org/apache/commons/rdf/api/Quad.java         | 2 ++
 api/src/main/java/org/apache/commons/rdf/api/QuadLike.java     | 6 ++++--
 .../main/java/org/apache/commons/rdf/api/RDFTermFactory.java   | 1 +
 api/src/main/java/org/apache/commons/rdf/api/Triple.java       | 2 ++
 api/src/main/java/org/apache/commons/rdf/api/TripleLike.java   | 6 ++++--
 6 files changed, 16 insertions(+), 7 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-commonsrdf/blob/4e7f2617/api/src/main/java/org/apache/commons/rdf/api/GraphLike.java
----------------------------------------------------------------------
diff --git a/api/src/main/java/org/apache/commons/rdf/api/GraphLike.java b/api/src/main/java/org/apache/commons/rdf/api/GraphLike.java
index bd37510..f8d052f 100644
--- a/api/src/main/java/org/apache/commons/rdf/api/GraphLike.java
+++ b/api/src/main/java/org/apache/commons/rdf/api/GraphLike.java
@@ -26,9 +26,9 @@ import java.util.stream.Stream;
  * Extended by {@link Graph} (for {@link Triple}) and {@link Dataset} (for
  * {@link Quad}).
  * <p>
- * Unlike {@link Graph} and {@link Dataset}, this interface can support with
- * generalised {@link TripleLike} or {@link QuadLike} statements, and does not
- * include semantics like {@link #size()} or the requirement of mapping
+ * Unlike {@link Graph} and {@link Dataset}, this interface can support
+ * generalised {@link TripleLike} or {@link QuadLike} statements, but does not
+ * imply semantics like {@link #size()} or the requirement of mapping
  * {@link RDFTerm} instances from different implementations.
  * <p>
  * As {@link TripleLike} do not have a specific {@link Object#equals(Object)}

http://git-wip-us.apache.org/repos/asf/incubator-commonsrdf/blob/4e7f2617/api/src/main/java/org/apache/commons/rdf/api/Quad.java
----------------------------------------------------------------------
diff --git a/api/src/main/java/org/apache/commons/rdf/api/Quad.java b/api/src/main/java/org/apache/commons/rdf/api/Quad.java
index 679000b..951f593 100644
--- a/api/src/main/java/org/apache/commons/rdf/api/Quad.java
+++ b/api/src/main/java/org/apache/commons/rdf/api/Quad.java
@@ -29,6 +29,8 @@ import java.util.Optional;
  * February 2014.
  * 
  * @since 0.3.0-incubating
+ * @see Dataset
+ * @see RDFTermFactory#createQuad(BlankNodeOrIRI,BlankNodeOrIRI,IRI,RDFTerm)
  * @see <a href="http://www.w3.org/TR/2014/NOTE-rdf11-datasets-20140225/">RDF
  *      1.1: On Semantics of RDF Datasets</a>
  * @see <a href="http://www.w3.org/TR/rdf11-concepts/#section-dataset"> </a>

http://git-wip-us.apache.org/repos/asf/incubator-commonsrdf/blob/4e7f2617/api/src/main/java/org/apache/commons/rdf/api/QuadLike.java
----------------------------------------------------------------------
diff --git a/api/src/main/java/org/apache/commons/rdf/api/QuadLike.java b/api/src/main/java/org/apache/commons/rdf/api/QuadLike.java
index 3f85862..8de180a 100644
--- a/api/src/main/java/org/apache/commons/rdf/api/QuadLike.java
+++ b/api/src/main/java/org/apache/commons/rdf/api/QuadLike.java
@@ -25,8 +25,10 @@ import java.util.Optional;
  * A QuadLike statement has at least a {@link #getSubject()},
  * {@link #getPredicate()}, {@link #getObject()} and {@link #getGraphName()},
  * but unlike a {@link Quad} does not have a formalised
- * {@link Quad#equals(Object)} semantics, and can allow generalised quads (e.g.
- * a {@link BlankNode} as predicate).
+ * {@link Quad#equals(Object)} 
+ * or {@link Quad#hashCode()} 
+ * semantics. This interface can also be used for <em>generalised quads</em>
+ * (e.g. a {@link BlankNode} as predicate).
  * <p>
  * Implementations should specialise which specific {@link RDFTerm} types they
  * return for {@link #getSubject()}, {@link #getPredicate()},

http://git-wip-us.apache.org/repos/asf/incubator-commonsrdf/blob/4e7f2617/api/src/main/java/org/apache/commons/rdf/api/RDFTermFactory.java
----------------------------------------------------------------------
diff --git a/api/src/main/java/org/apache/commons/rdf/api/RDFTermFactory.java b/api/src/main/java/org/apache/commons/rdf/api/RDFTermFactory.java
index 48605e7..17758b6 100644
--- a/api/src/main/java/org/apache/commons/rdf/api/RDFTermFactory.java
+++ b/api/src/main/java/org/apache/commons/rdf/api/RDFTermFactory.java
@@ -36,6 +36,7 @@ import java.util.Locale;
  *
  * @see RDFTerm
  * @see Graph
+ * @see Quad
  */
 public interface RDFTermFactory {
 

http://git-wip-us.apache.org/repos/asf/incubator-commonsrdf/blob/4e7f2617/api/src/main/java/org/apache/commons/rdf/api/Triple.java
----------------------------------------------------------------------
diff --git a/api/src/main/java/org/apache/commons/rdf/api/Triple.java b/api/src/main/java/org/apache/commons/rdf/api/Triple.java
index dcbb509..9375983 100644
--- a/api/src/main/java/org/apache/commons/rdf/api/Triple.java
+++ b/api/src/main/java/org/apache/commons/rdf/api/Triple.java
@@ -25,6 +25,8 @@ import java.util.Objects;
  * >RDF-1.1 Concepts and Abstract Syntax</a>, a W3C Recommendation published on
  * 25 February 2014.<br>
  *
+ * @see Quad 
+ * @see RDFTermFactory#createTriple(BlankNodeOrIRI,IRI,RDFTerm)
  * @see <a href= "http://www.w3.org/TR/rdf11-concepts/#dfn-rdf-triple" >RDF-1.1
  * Triple</a>
  */

http://git-wip-us.apache.org/repos/asf/incubator-commonsrdf/blob/4e7f2617/api/src/main/java/org/apache/commons/rdf/api/TripleLike.java
----------------------------------------------------------------------
diff --git a/api/src/main/java/org/apache/commons/rdf/api/TripleLike.java b/api/src/main/java/org/apache/commons/rdf/api/TripleLike.java
index 9bead97..55d0380 100644
--- a/api/src/main/java/org/apache/commons/rdf/api/TripleLike.java
+++ b/api/src/main/java/org/apache/commons/rdf/api/TripleLike.java
@@ -23,8 +23,10 @@ package org.apache.commons.rdf.api;
  * <p>
  * A TripleLike statement has at least a {@link #getSubject()},
  * {@link #getPredicate()} and {@link #getObject()}, but unlike a {@link Triple}
- * does not have a formalised {@link Triple#equals(Object)} semantics, and can
- * allow generalised triples (e.g. a {@link BlankNode} as predicate).
+ * does not have a formalised 
+ * {@link Triple#equals(Object)} or 
+ * {@link Triple#hashCode()} semantics. This interfaced can also be 
+ * used for <em>generalised triples</em> (e.g. a {@link BlankNode} as predicate).
  * <p>
  * Implementations should specialise which specific {@link RDFTerm} types they
  * return for {@link #getSubject()}, {@link #getPredicate()} and


[18/19] incubator-commonsrdf git commit: JenaRDFTermFactory javadoc on constructors

Posted by st...@apache.org.
JenaRDFTermFactory javadoc on constructors


Project: http://git-wip-us.apache.org/repos/asf/incubator-commonsrdf/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-commonsrdf/commit/7fb1d889
Tree: http://git-wip-us.apache.org/repos/asf/incubator-commonsrdf/tree/7fb1d889
Diff: http://git-wip-us.apache.org/repos/asf/incubator-commonsrdf/diff/7fb1d889

Branch: refs/heads/jena
Commit: 7fb1d8895c5947b54fec2f23d4e3d900414dade1
Parents: 361aaba
Author: Stian Soiland-Reyes <st...@apache.org>
Authored: Thu Sep 8 15:28:00 2016 +0100
Committer: Stian Soiland-Reyes <st...@apache.org>
Committed: Thu Sep 8 15:28:00 2016 +0100

----------------------------------------------------------------------
 .../commons/rdf/jena/JenaRDFTermFactory.java    | 58 +++++++++++++++-----
 1 file changed, 43 insertions(+), 15 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-commonsrdf/blob/7fb1d889/jena/src/main/java/org/apache/commons/rdf/jena/JenaRDFTermFactory.java
----------------------------------------------------------------------
diff --git a/jena/src/main/java/org/apache/commons/rdf/jena/JenaRDFTermFactory.java b/jena/src/main/java/org/apache/commons/rdf/jena/JenaRDFTermFactory.java
index a75b61e..f393cec 100644
--- a/jena/src/main/java/org/apache/commons/rdf/jena/JenaRDFTermFactory.java
+++ b/jena/src/main/java/org/apache/commons/rdf/jena/JenaRDFTermFactory.java
@@ -52,39 +52,56 @@ import org.apache.jena.sparql.graph.GraphFactory;
  * <p>
  * This factory can also convert existing objects from/to Jena with methods like
  * {@link #fromJena(org.apache.jena.graph.Graph)} and {@link #toJena(Graph)}.
+ * <p>
+ * For the purpose of {@link BlankNode} identity, this factory will use an internal
+ * {@link UUID} as a salt. See {@link BlankNode#uniqueReference()} for details.
  * 
  * @see RDFTermFactory
  */
 public final class JenaRDFTermFactory implements RDFTermFactory {
 
-	private UUID salt;
+	private final UUID salt;
 
+	/**
+	 * Create a JenaRDFTermFactory.
+	 * <p>
+	 * This constructor will use a randomly generated {@link UUID} as a salt 
+	 * for the purposes of {@link BlankNode} identity, see {@link #getSalt()}.
+	 */
 	public JenaRDFTermFactory() {
 		this.salt = UUID.randomUUID();
 	}
 
+	/**
+	 * Create a JenaRDFTermFactory.
+	 * <p>
+	 * This constructor will use the specified {@link UUID} as a salt 
+	 * for the purposes of {@link BlankNode} identity.
+	 * 
+	 * @param salt {@link UUID} to use as salt
+	 */	
 	public JenaRDFTermFactory(UUID salt) {
 		this.salt = salt;
 	}
 
 	@Override
 	public JenaBlankNode createBlankNode() {
-		return JenaFactory.createBlankNode(salt);
+		return JenaFactory.createBlankNode(getSalt());
 	}
 
 	@Override
 	public JenaBlankNode createBlankNode(String name) {
-		return JenaFactory.createBlankNode(name, salt);
+		return JenaFactory.createBlankNode(name, getSalt());
 	}
 	
 	@Override
 	public Dataset createDataset() {
-		return JenaFactory.createDataset(salt);
+		return JenaFactory.createDataset(getSalt());
 	}
 
 	@Override
 	public JenaGraph createGraph() {
-		return JenaFactory.createGraph(salt);
+		return JenaFactory.createGraph(getSalt());
 	}
 
 	@Override
@@ -168,7 +185,7 @@ public final class JenaRDFTermFactory implements RDFTermFactory {
 	 *             if the node is not concrete.
 	 */
 	public JenaRDFTerm fromJena(Node node) throws ConversionException {
-		return JenaFactory.fromJena(node, salt);
+		return JenaFactory.fromJena(node, getSalt());
 	}
 
 	/**
@@ -259,7 +276,7 @@ public final class JenaRDFTermFactory implements RDFTermFactory {
 	 *             is a generalized triple
 	 */
 	public JenaTriple fromJena(org.apache.jena.graph.Triple triple) throws ConversionException {
-		return JenaFactory.fromJena(triple, salt);
+		return JenaFactory.fromJena(triple, getSalt());
 	}
 
 
@@ -318,7 +335,7 @@ public final class JenaRDFTermFactory implements RDFTermFactory {
 	 *             if any of the triple's nodes are not concrete
 	 */
 	public JenaTripleLike<RDFTerm, RDFTerm, RDFTerm> fromJenaGeneralized(org.apache.jena.graph.Triple triple) throws ConversionException {
-		return JenaFactory.fromJenaGeneralized(triple, salt);
+		return JenaFactory.fromJenaGeneralized(triple, getSalt());
 	}
 
 	/**
@@ -350,7 +367,7 @@ public final class JenaRDFTermFactory implements RDFTermFactory {
 	 *             if any of the quad nodes are not concrete
 	 */
 	public JenaQuadLike<RDFTerm, RDFTerm, RDFTerm, RDFTerm> fromJenaGeneralized(org.apache.jena.sparql.core.Quad quad) throws ConversionException {
-		return JenaFactory.fromJenaGeneralized(quad, salt);
+		return JenaFactory.fromJenaGeneralized(quad, getSalt());
 	}
 	
 	
@@ -428,7 +445,7 @@ public final class JenaRDFTermFactory implements RDFTermFactory {
 	 * @return Adapted quad
 	 */	
 	public Quad fromJena(org.apache.jena.sparql.core.Quad quad) {
-		return JenaFactory.fromJena(quad, salt);
+		return JenaFactory.fromJena(quad, getSalt());
 	}
 	
 	/**
@@ -464,7 +481,7 @@ public final class JenaRDFTermFactory implements RDFTermFactory {
 
 	 */
 	public JenaGraph fromJena(org.apache.jena.graph.Graph graph) {
-		return JenaFactory.fromJena(graph, salt);
+		return JenaFactory.fromJena(graph, getSalt());
 	}
 
 	/**
@@ -481,7 +498,7 @@ public final class JenaRDFTermFactory implements RDFTermFactory {
 
 	 */
 	public JenaGraph fromJena(org.apache.jena.rdf.model.Model model) {
-		return JenaFactory.fromJena(model, salt);
+		return JenaFactory.fromJena(model, getSalt());
 	}	
 
 	/**
@@ -521,7 +538,7 @@ public final class JenaRDFTermFactory implements RDFTermFactory {
 	 * @return Adapted dataset 
 	 */
 	public JenaDataset fromJena(DatasetGraph datasetGraph) {
-		return JenaFactory.fromJena(datasetGraph, salt);
+		return JenaFactory.fromJena(datasetGraph, getSalt());
 	}	
 	
 	/**
@@ -541,7 +558,7 @@ public final class JenaRDFTermFactory implements RDFTermFactory {
 	 * @return Adapted dataset 
 	 */
 	public JenaDataset fromJena(org.apache.jena.query.Dataset datasetGraph) {
-		return JenaFactory.fromJena(datasetGraph.asDatasetGraph(), salt);
+		return JenaFactory.fromJena(datasetGraph.asDatasetGraph(), getSalt());
 	}		
 	
 	/**
@@ -582,7 +599,6 @@ public final class JenaRDFTermFactory implements RDFTermFactory {
 		return g;
 	}
 
-
 	public static Quad fromJena(RDFTermFactory factory, org.apache.jena.sparql.core.Quad quad) {
 		if (factory instanceof JenaRDFTermFactory) {
 			// No need to convert, just wrap
@@ -737,4 +753,16 @@ public final class JenaRDFTermFactory implements RDFTermFactory {
 			throw new IllegalArgumentException("Invalid language tag: " + languageTag);
 	}
 
+	/**
+	 * Return the {@link UUID} salt.
+	 * <p>
+	 * The salt is used for the purposes of {@link BlankNode} identity, see
+	 * {@link BlankNode#uniqueReference()} for details.
+	 * 
+	 * @return The {@link UUID} used as salt
+	 */
+	public UUID getSalt() {
+		return salt;
+	}
+
 }


[03/19] incubator-commonsrdf git commit: COMMONSRDF-37: Improve Quad javadoc

Posted by st...@apache.org.
COMMONSRDF-37: Improve Quad javadoc


Project: http://git-wip-us.apache.org/repos/asf/incubator-commonsrdf/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-commonsrdf/commit/a1d65546
Tree: http://git-wip-us.apache.org/repos/asf/incubator-commonsrdf/tree/a1d65546
Diff: http://git-wip-us.apache.org/repos/asf/incubator-commonsrdf/diff/a1d65546

Branch: refs/heads/jena
Commit: a1d65546388f3d9acf56456d08d923aae3beaa41
Parents: 53ef228
Author: Stian Soiland-Reyes <st...@apache.org>
Authored: Thu Jul 7 10:47:06 2016 +0100
Committer: Stian Soiland-Reyes <st...@apache.org>
Committed: Thu Jul 7 10:47:06 2016 +0100

----------------------------------------------------------------------
 .../org/apache/commons/rdf/api/GraphLike.java   | 21 +++++++++++++++---
 .../java/org/apache/commons/rdf/api/Quad.java   | 23 +++++++++++---------
 .../org/apache/commons/rdf/api/QuadLike.java    | 18 +++++++++++----
 .../org/apache/commons/rdf/api/TripleLike.java  | 14 +++++++++---
 .../commons/rdf/simple/DatasetGraphView.java    |  2 +-
 5 files changed, 57 insertions(+), 21 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-commonsrdf/blob/a1d65546/api/src/main/java/org/apache/commons/rdf/api/GraphLike.java
----------------------------------------------------------------------
diff --git a/api/src/main/java/org/apache/commons/rdf/api/GraphLike.java b/api/src/main/java/org/apache/commons/rdf/api/GraphLike.java
index c68278e..bd37510 100644
--- a/api/src/main/java/org/apache/commons/rdf/api/GraphLike.java
+++ b/api/src/main/java/org/apache/commons/rdf/api/GraphLike.java
@@ -30,7 +30,23 @@ import java.util.stream.Stream;
  * generalised {@link TripleLike} or {@link QuadLike} statements, and does not
  * include semantics like {@link #size()} or the requirement of mapping
  * {@link RDFTerm} instances from different implementations.
+ * <p>
+ * As {@link TripleLike} do not have a specific {@link Object#equals(Object)}
+ * semantics, the behaviour of methods like {@link #contains(TripleLike)} and
+ * {@link #remove(TripleLike)} is undefined for arguments that are not object
+ * identical to previously added or returned {@link TripleLike} statements.
  * 
+ * @param <T>
+ *            A {@link TripleLike} type used by the graph methods, typically
+ *            {@link Triple} or {@link Quad}
+ * @param <S>
+ *            The type of subjects in the statements, typically
+ *            {@link BlankNodeOrIRI}
+ * @param <P>
+ *            The type of predicates in the statements, typically {@link IRI}
+ * @param <O>
+ *            The type of objects in the statements, typically {@link RDFTerm}
+ *            
  * @since 0.3.0-incubating
  * @see Graph
  * @see Dataset
@@ -50,7 +66,7 @@ public interface GraphLike<T extends TripleLike<S, P, O>, S extends RDFTerm, P e
 	 * Check if statement is contained.
 	 * 
 	 * @param statement
-	 *            The {@link TripleLike} statement to chec
+	 *            The {@link TripleLike} statement to check
 	 * @return True if the statement is contained
 	 */
 	boolean contains(T statement);
@@ -71,7 +87,7 @@ public interface GraphLike<T extends TripleLike<S, P, O>, S extends RDFTerm, P e
 	/**
 	 * Number of statements.
 	 * 
-	 * @return
+	 * @return Number of statements
 	 */
 	long size();
 
@@ -86,7 +102,6 @@ public interface GraphLike<T extends TripleLike<S, P, O>, S extends RDFTerm, P e
 	 * Iterate over contained statements.
 	 * 
 	 * @return An {@link Iterable} of {@link TripleLike} statements.
-	 * 
 	 * @throws IllegalStateException
 	 *             if the {@link Iterable} has been reused
 	 * @throws ConcurrentModificationException

http://git-wip-us.apache.org/repos/asf/incubator-commonsrdf/blob/a1d65546/api/src/main/java/org/apache/commons/rdf/api/Quad.java
----------------------------------------------------------------------
diff --git a/api/src/main/java/org/apache/commons/rdf/api/Quad.java b/api/src/main/java/org/apache/commons/rdf/api/Quad.java
index 5a67571..679000b 100644
--- a/api/src/main/java/org/apache/commons/rdf/api/Quad.java
+++ b/api/src/main/java/org/apache/commons/rdf/api/Quad.java
@@ -67,31 +67,31 @@ public interface Quad extends QuadLike<BlankNodeOrIRI,IRI,RDFTerm,BlankNodeOrIRI
 	BlankNodeOrIRI getSubject();
 
 	/**
-	 * The predicate {@link IRI} of this triple.
+	 * The predicate {@link IRI} of this quad.
 	 *
-	 * @return The predicate {@link IRI} of this triple.
+	 * @return The predicate {@link IRI} of this quad.
 	 * @see <a href="http://www.w3.org/TR/rdf11-concepts/#dfn-predicate">RDF-1.1
 	 *      Triple predicate</a>
 	 */
 	IRI getPredicate();
 
 	/**
-	 * The object of this triple, which may be either a {@link BlankNode}, an
+	 * The object of this quad, which may be either a {@link BlankNode}, an
 	 * {@link IRI}, or a {@link Literal}, which are represented in Commons RDF
 	 * by the interface {@link RDFTerm}.
 	 *
-	 * @return The object {@link RDFTerm} of this triple.
+	 * @return The object {@link RDFTerm} of this quad.
 	 * @see <a href="http://www.w3.org/TR/rdf11-concepts/#dfn-object">RDF-1.1
 	 *      Triple object</a>
 	 */
 	RDFTerm getObject();
 
 	/**
-	 * Convert this Quad to a Triple.
+	 * Adapt this Quad to a Triple.
 	 * <p>
 	 * The returned {@link Triple} will have equivalent values returned from the
-	 * methods {@link TripleOrQuad#getSubject()},
-	 * {@link TripleOrQuad#getPredicate()} and {@link TripleOrQuad#getObject()}.
+	 * methods {@link TripleLike#getSubject()},
+	 * {@link TripleLike#getPredicate()} and {@link TripleLike#getObject()}.
 	 * <p>
 	 * The returned {@link Triple} MUST NOT be {@link #equals(Object)} to this
 	 * {@link Quad}, even if this quad has a default graph
@@ -113,12 +113,12 @@ public interface Quad extends QuadLike<BlankNodeOrIRI,IRI,RDFTerm,BlankNodeOrIRI
 	 * 
 	 * The <code>default</code> implementation of this method return a proxy
 	 * {@link Triple} instance that keeps a reference to this {@link Quad} to
-	 * calls the underlying {@link TripleOrQuad} methods, but supplies a
+	 * call the underlying {@link TripleLike} methods, but supplies a
 	 * {@link Triple} compatible implementation of {@link Triple#equals(Object)}
 	 * and {@link Triple#hashCode()}. Implementations may override this method,
 	 * e.g. for a more efficient solution.
 	 * 
-	 * @return A {@link Triple} that contains the same {@link TripleOrQuad}
+	 * @return A {@link Triple} that contains the same {@link TripleLike}
 	 *         properties as this Quad.
 	 */
 	default Triple asTriple() {
@@ -140,6 +140,9 @@ public interface Quad extends QuadLike<BlankNodeOrIRI,IRI,RDFTerm,BlankNodeOrIRI
 
 			@Override
 			public boolean equals(Object obj) {
+				if (obj == this)  { 
+					return true;
+				}
 				if (!(obj instanceof Triple)) {
 					return false;
 				}
@@ -159,7 +162,7 @@ public interface Quad extends QuadLike<BlankNodeOrIRI,IRI,RDFTerm,BlankNodeOrIRI
 	/**
 	 * Check it this Quad is equal to another Quad.
 	 * <p>
-	 * Two Triples are equal if and only if their {@link #getGraphName()}, 
+	 * Two Quads are equal if and only if their {@link #getGraphName()}, 
 	 * {@link #getSubject()}, {@link #getPredicate()} and 
 	 * {@link #getObject()} are equal.
 	 * </p>

http://git-wip-us.apache.org/repos/asf/incubator-commonsrdf/blob/a1d65546/api/src/main/java/org/apache/commons/rdf/api/QuadLike.java
----------------------------------------------------------------------
diff --git a/api/src/main/java/org/apache/commons/rdf/api/QuadLike.java b/api/src/main/java/org/apache/commons/rdf/api/QuadLike.java
index 9c42465..3f85862 100644
--- a/api/src/main/java/org/apache/commons/rdf/api/QuadLike.java
+++ b/api/src/main/java/org/apache/commons/rdf/api/QuadLike.java
@@ -28,10 +28,20 @@ import java.util.Optional;
  * {@link Quad#equals(Object)} semantics, and can allow generalised quads (e.g.
  * a {@link BlankNode} as predicate).
  * <p>
- * Implementations should specialise which {@link RDFTerm} subclasses they
- * return for subject {@link S}, predicate {@link P}, object {@link O} and graph
- * name {@link G}.
- * <p>
+ * Implementations should specialise which specific {@link RDFTerm} types they
+ * return for {@link #getSubject()}, {@link #getPredicate()},
+ * {@link #getObject()} and {@link #getGraphName()}.
+ *
+ * @param <S>
+ *            The type of subjects in the statements, typically
+ *            {@link BlankNodeOrIRI}
+ * @param <P>
+ *            The type of predicates in the statements, typically {@link IRI}
+ * @param <O>
+ *            The type of objects in the statements, typically {@link RDFTerm}
+ * @param <G>
+ *            The type of graph names in the statements, typically
+ *            {@link BlankNodeOrIRI}
  * 
  * @since 0.3.0-incubating
  * @see Quad

http://git-wip-us.apache.org/repos/asf/incubator-commonsrdf/blob/a1d65546/api/src/main/java/org/apache/commons/rdf/api/TripleLike.java
----------------------------------------------------------------------
diff --git a/api/src/main/java/org/apache/commons/rdf/api/TripleLike.java b/api/src/main/java/org/apache/commons/rdf/api/TripleLike.java
index 2fbeb11..9bead97 100644
--- a/api/src/main/java/org/apache/commons/rdf/api/TripleLike.java
+++ b/api/src/main/java/org/apache/commons/rdf/api/TripleLike.java
@@ -26,14 +26,22 @@ package org.apache.commons.rdf.api;
  * does not have a formalised {@link Triple#equals(Object)} semantics, and can
  * allow generalised triples (e.g. a {@link BlankNode} as predicate).
  * <p>
- * Implementations should specialise which {@link RDFTerm} subclasses they
- * return for subject {@link S}, predicate {@link P} and object {@link O}.
+ * Implementations should specialise which specific {@link RDFTerm} types they
+ * return for {@link #getSubject()}, {@link #getPredicate()} and
+ * {@link #getObject()}.
+ * 
+ * @param <S>
+ *            The type of subjects in the statements, typically
+ *            {@link BlankNodeOrIRI}
+ * @param <P>
+ *            The type of predicates in the statements, typically {@link IRI}
+ * @param <O>
+ *            The type of objects in the statements, typically {@link RDFTerm}
  * 
  * @since 0.3.0-incubating
  * @see Triple
  * @see Quad
  * @see QuadLike
- * 
  */
 public interface TripleLike<S extends RDFTerm, P extends RDFTerm, O extends RDFTerm> {
 

http://git-wip-us.apache.org/repos/asf/incubator-commonsrdf/blob/a1d65546/simple/src/main/java/org/apache/commons/rdf/simple/DatasetGraphView.java
----------------------------------------------------------------------
diff --git a/simple/src/main/java/org/apache/commons/rdf/simple/DatasetGraphView.java b/simple/src/main/java/org/apache/commons/rdf/simple/DatasetGraphView.java
index a347c3e..d578a40 100644
--- a/simple/src/main/java/org/apache/commons/rdf/simple/DatasetGraphView.java
+++ b/simple/src/main/java/org/apache/commons/rdf/simple/DatasetGraphView.java
@@ -41,7 +41,7 @@ import org.apache.commons.rdf.api.Triple;
  * triples will add them to the <em>default graph</em>, while removing triples
  * will remove from all graphs.</dd>
 * 
- * <dt>{@link #DatasetGraphView(Dataset, IRI)}</dt>
+ * <dt>{@link #DatasetGraphView(Dataset, BlankNodeOrIRI)}</dt>
  * <dd>Expose a particular graph of the Dataset, either named by an {@link IRI}, a
  * {@link BlankNode}, or  <code>null</code> for the <em>default graph</em>.</dd>
  * </dl>


[07/19] incubator-commonsrdf git commit: Trying to enable reports

Posted by st...@apache.org.
Trying to enable reports

as on
https://commons.apache.org/proper/commons-codec/project-reports.html


Project: http://git-wip-us.apache.org/repos/asf/incubator-commonsrdf/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-commonsrdf/commit/7500084f
Tree: http://git-wip-us.apache.org/repos/asf/incubator-commonsrdf/tree/7500084f
Diff: http://git-wip-us.apache.org/repos/asf/incubator-commonsrdf/diff/7500084f

Branch: refs/heads/jena
Commit: 7500084f0cf8934c287bcb65cb61fc1697552a0f
Parents: 7fd7fae
Author: Stian Soiland-Reyes <st...@apache.org>
Authored: Mon Sep 5 17:52:14 2016 +0100
Committer: Stian Soiland-Reyes <st...@apache.org>
Committed: Mon Sep 5 17:52:14 2016 +0100

----------------------------------------------------------------------
 LICENSE-header.txt          | 16 +++++++++
 checkstyle-suppressions.xml | 27 +++++++++++++++
 checkstyle.xml              | 73 ++++++++++++++++++++++++++++++++++++++++
 pmd.xml                     | 26 ++++++++++++++
 4 files changed, 142 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-commonsrdf/blob/7500084f/LICENSE-header.txt
----------------------------------------------------------------------
diff --git a/LICENSE-header.txt b/LICENSE-header.txt
new file mode 100644
index 0000000..ae6f28c
--- /dev/null
+++ b/LICENSE-header.txt
@@ -0,0 +1,16 @@
+/*
+ * 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.
+ */

http://git-wip-us.apache.org/repos/asf/incubator-commonsrdf/blob/7500084f/checkstyle-suppressions.xml
----------------------------------------------------------------------
diff --git a/checkstyle-suppressions.xml b/checkstyle-suppressions.xml
new file mode 100644
index 0000000..4796ea0
--- /dev/null
+++ b/checkstyle-suppressions.xml
@@ -0,0 +1,27 @@
+<?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.
+-->
+
+<!DOCTYPE suppressions PUBLIC
+    "-//Puppy Crawl//DTD Suppressions 1.0//EN"
+    "http://www.puppycrawl.com/dtds/suppressions_1_0.dtd">
+
+<suppressions>
+    <suppress checks="Header" files="LICENSE.txt"/>
+    <suppress checks="Header" files="NOTICE.txt"/>
+</suppressions>

http://git-wip-us.apache.org/repos/asf/incubator-commonsrdf/blob/7500084f/checkstyle.xml
----------------------------------------------------------------------
diff --git a/checkstyle.xml b/checkstyle.xml
new file mode 100644
index 0000000..efc00c8
--- /dev/null
+++ b/checkstyle.xml
@@ -0,0 +1,73 @@
+<?xml version="1.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.
+-->
+
+<!DOCTYPE module PUBLIC
+    "-//Puppy Crawl//DTD Check Configuration 1.1//EN"
+    "http://www.puppycrawl.com/dtds/configuration_1_1.dtd">
+
+<!-- commons codec customization of default Checkstyle behavior -->
+<module name="Checker">
+  <property name="localeLanguage" value="en" />
+
+  <module name="SuppressionFilter">
+    <property name="file" value="checkstyle-suppressions.xml"/>
+  </module>
+
+  <!-- Checks whether files end with a new line. -->
+  <!-- See http://checkstyle.sf.net/config_misc.html#NewlineAtEndOfFile -->
+  <module name="NewlineAtEndOfFile" />
+
+  <!-- Verify that EVERY source file has the appropriate license -->
+  <module name="Header">
+    <property name="headerFile" value="${checkstyle.header.file}" />
+  </module>
+
+  <!-- Checks for Tab characters -->
+  <!-- See http://checkstyle.sourceforge.net/config_whitespace.html#FileTabCharacter -->
+  <module name="FileTabCharacter">
+    <property name="fileExtensions" value="java" />
+  </module>
+
+  <!-- Checks for white space at the end of the line -->
+  <!-- See http://checkstyle.sourceforge.net/config_regexp.html -->
+  <module name="RegexpSingleline">
+    <property name="format" value="\s+$" />
+    <property name="message" value="Line has trailing spaces." />
+    <property name="fileExtensions" value="java" />
+  </module>
+
+  <!-- @author tags are deprecated -->
+  <module name="RegexpSingleline">
+    <property name="format" value="^\s+\*\s+@author\s" />
+    <property name="message" value="Deprecated @author tag" />
+    <property name="fileExtensions" value="java" />
+    <property name="severity" value="warning" />
+  </module>
+
+  <module name="TreeWalker">
+    <property name="cacheFile" value="target/cachefile" />
+    <module name="OperatorWrap">
+      <property name="option" value="eol" />
+    </module>
+    <module name="LineLength">
+      <property name="max" value="120"/>
+    </module>
+  </module>
+
+</module>
+

http://git-wip-us.apache.org/repos/asf/incubator-commonsrdf/blob/7500084f/pmd.xml
----------------------------------------------------------------------
diff --git a/pmd.xml b/pmd.xml
new file mode 100644
index 0000000..d88cdbd
--- /dev/null
+++ b/pmd.xml
@@ -0,0 +1,26 @@
+<?xml version="1.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.
+-->
+<ruleset name="mybraces"
+    xmlns="http://pmd.sourceforge.net/ruleset/2.0.0"
+    xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+    xsi:schemaLocation="http://pmd.sourceforge.net/ruleset/2.0.0 http://pmd.sourceforge.net/ruleset_2_0_0.xsd">
+  <description>Excludes from default PMD rules.</description>
+  <rule ref="rulesets/java/unnecessary.xml">
+    <exclude name="UselessParentheses"/>
+  </rule>
+</ruleset>
\ No newline at end of file