jena-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From rve...@apache.org
Subject svn commit: r1463235 - in /jena/Experimental/jena-jdbc: ./ jena-jdbc-core/ jena-jdbc-core/src/main/java/org/apache/jena/jdbc/ jena-jdbc-core/src/main/java/org/apache/jena/jdbc/results/ jena-jdbc-core/src/main/java/org/apache/jena/jdbc/results/metadata/...
Date Mon, 01 Apr 2013 18:16:21 GMT
Author: rvesse
Date: Mon Apr  1 18:16:20 2013
New Revision: 1463235

URL: http://svn.apache.org/r1463235
Log:
Some refactoring of the jena-jdbc work in progress

Fix up POMs to all have correct dependencies, also turn on license plugin so I don't check
in code with YarcData copyrights
Refactor bulk of SelectResults into abstract classes QueryExecutionResults and StreamingResults
Add TripleIteratorResults for handling streamed CONSTRUCT/DESCRIBE results

Modified:
    jena/Experimental/jena-jdbc/jena-jdbc-core/pom.xml
    jena/Experimental/jena-jdbc/jena-jdbc-core/src/main/java/org/apache/jena/jdbc/JenaJdbcConnection.java
    jena/Experimental/jena-jdbc/jena-jdbc-core/src/main/java/org/apache/jena/jdbc/JenaJdbcDriver.java
    jena/Experimental/jena-jdbc/jena-jdbc-core/src/main/java/org/apache/jena/jdbc/JenaJdbcStatement.java
    jena/Experimental/jena-jdbc/jena-jdbc-core/src/main/java/org/apache/jena/jdbc/JenaTransactionalJdbcConnection.java
    jena/Experimental/jena-jdbc/jena-jdbc-core/src/main/java/org/apache/jena/jdbc/results/AskResults.java
    jena/Experimental/jena-jdbc/jena-jdbc-core/src/main/java/org/apache/jena/jdbc/results/JenaJdbcResultSet.java
    jena/Experimental/jena-jdbc/jena-jdbc-core/src/main/java/org/apache/jena/jdbc/results/SelectResults.java
    jena/Experimental/jena-jdbc/jena-jdbc-core/src/main/java/org/apache/jena/jdbc/results/metadata/AskResultsMetadata.java
    jena/Experimental/jena-jdbc/jena-jdbc-core/src/main/java/org/apache/jena/jdbc/results/metadata/JenaJdbcResultsMetadata.java
    jena/Experimental/jena-jdbc/jena-jdbc-core/src/main/java/org/apache/jena/jdbc/results/metadata/SelectResultsMetadata.java
    jena/Experimental/jena-jdbc/jena-jdbc-core/src/main/java/org/apache/jena/jdbc/utils/JenaJdbcNodeUtils.java
    jena/Experimental/jena-jdbc/jena-jdbc-core/src/test/java/org/apache/jena/jdbc/AbstractJenaJdbcConnectionTests.java
    jena/Experimental/jena-jdbc/jena-jdbc-core/src/test/java/org/apache/jena/jdbc/AbstractJenaJdbcDriverTests.java
    jena/Experimental/jena-jdbc/jena-jdbc-driver-mem/pom.xml
    jena/Experimental/jena-jdbc/jena-jdbc-driver-mem/src/main/java/org/apache/jena/jdbc/mem/JenaJdbcDatasetConnection.java
    jena/Experimental/jena-jdbc/jena-jdbc-driver-mem/src/main/java/org/apache/jena/jdbc/mem/JenaJdbcDatasetStatement.java
    jena/Experimental/jena-jdbc/jena-jdbc-driver-mem/src/main/java/org/apache/jena/jdbc/mem/JenaJdbcMemDriver.java
    jena/Experimental/jena-jdbc/jena-jdbc-driver-mem/src/test/java/org/apache/jena/jdbc/mem/TestJenaJdbcDatasetConnection.java
    jena/Experimental/jena-jdbc/jena-jdbc-driver-mem/src/test/java/org/apache/jena/jdbc/mem/TestJenaJdbcMemDriver.java
    jena/Experimental/jena-jdbc/jena-jdbc-driver-remote/pom.xml
    jena/Experimental/jena-jdbc/jena-jdbc-driver-tdb/pom.xml
    jena/Experimental/jena-jdbc/jena-jdbc-driver-tdb/src/main/java/org/apache/jena/jdbc/tdb/TDBDriver.java
    jena/Experimental/jena-jdbc/pom.xml

Modified: jena/Experimental/jena-jdbc/jena-jdbc-core/pom.xml
URL: http://svn.apache.org/viewvc/jena/Experimental/jena-jdbc/jena-jdbc-core/pom.xml?rev=1463235&r1=1463234&r2=1463235&view=diff
==============================================================================
--- jena/Experimental/jena-jdbc/jena-jdbc-core/pom.xml (original)
+++ jena/Experimental/jena-jdbc/jena-jdbc-core/pom.xml Mon Apr  1 18:16:20 2013
@@ -9,25 +9,33 @@
 	<artifactId>jena-jdbc-core</artifactId>
 	<name>Jena JDBC - Core</name>
 	<description>This library provides core functionality for Jena JDBC</description>
+	
+	<properties>
+		<plugin.license.headerPath>${project.parent.basedir}</plugin.license.headerPath>
+	</properties>
+	
 	<dependencies>
 		<dependency>
 			<groupId>org.apache.jena</groupId>
 			<artifactId>jena-arq</artifactId>
 			<version>2.10.1-SNAPSHOT</version>
 		</dependency>
+		
+		<!-- Test Dependencies -->
 		<dependency>
 			<groupId>junit</groupId>
 			<artifactId>junit</artifactId>
 			<version>4.11</version>
-			<scope>tests</scope>
+			<scope>test</scope>
 		</dependency>
 	</dependencies>
-
+	
 	<build>
 		<plugins>
 			<plugin>
 				<groupId>org.apache.maven.plugins</groupId>
 				<artifactId>maven-jar-plugin</artifactId>
+				<version>2.4</version>
 				<executions>
 					<execution>
 						<goals>

Modified: jena/Experimental/jena-jdbc/jena-jdbc-core/src/main/java/org/apache/jena/jdbc/JenaJdbcConnection.java
URL: http://svn.apache.org/viewvc/jena/Experimental/jena-jdbc/jena-jdbc-core/src/main/java/org/apache/jena/jdbc/JenaJdbcConnection.java?rev=1463235&r1=1463234&r2=1463235&view=diff
==============================================================================
--- jena/Experimental/jena-jdbc/jena-jdbc-core/src/main/java/org/apache/jena/jdbc/JenaJdbcConnection.java
(original)
+++ jena/Experimental/jena-jdbc/jena-jdbc-core/src/main/java/org/apache/jena/jdbc/JenaJdbcConnection.java
Mon Apr  1 18:16:20 2013
@@ -1,4 +1,4 @@
-/*
+/**
  * 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

Modified: jena/Experimental/jena-jdbc/jena-jdbc-core/src/main/java/org/apache/jena/jdbc/JenaJdbcDriver.java
URL: http://svn.apache.org/viewvc/jena/Experimental/jena-jdbc/jena-jdbc-core/src/main/java/org/apache/jena/jdbc/JenaJdbcDriver.java?rev=1463235&r1=1463234&r2=1463235&view=diff
==============================================================================
--- jena/Experimental/jena-jdbc/jena-jdbc-core/src/main/java/org/apache/jena/jdbc/JenaJdbcDriver.java
(original)
+++ jena/Experimental/jena-jdbc/jena-jdbc-core/src/main/java/org/apache/jena/jdbc/JenaJdbcDriver.java
Mon Apr  1 18:16:20 2013
@@ -1,4 +1,4 @@
-/*
+/**
  * 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

Modified: jena/Experimental/jena-jdbc/jena-jdbc-core/src/main/java/org/apache/jena/jdbc/JenaJdbcStatement.java
URL: http://svn.apache.org/viewvc/jena/Experimental/jena-jdbc/jena-jdbc-core/src/main/java/org/apache/jena/jdbc/JenaJdbcStatement.java?rev=1463235&r1=1463234&r2=1463235&view=diff
==============================================================================
--- jena/Experimental/jena-jdbc/jena-jdbc-core/src/main/java/org/apache/jena/jdbc/JenaJdbcStatement.java
(original)
+++ jena/Experimental/jena-jdbc/jena-jdbc-core/src/main/java/org/apache/jena/jdbc/JenaJdbcStatement.java
Mon Apr  1 18:16:20 2013
@@ -1,4 +1,4 @@
-/*
+/**
  * 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

Modified: jena/Experimental/jena-jdbc/jena-jdbc-core/src/main/java/org/apache/jena/jdbc/JenaTransactionalJdbcConnection.java
URL: http://svn.apache.org/viewvc/jena/Experimental/jena-jdbc/jena-jdbc-core/src/main/java/org/apache/jena/jdbc/JenaTransactionalJdbcConnection.java?rev=1463235&r1=1463234&r2=1463235&view=diff
==============================================================================
--- jena/Experimental/jena-jdbc/jena-jdbc-core/src/main/java/org/apache/jena/jdbc/JenaTransactionalJdbcConnection.java
(original)
+++ jena/Experimental/jena-jdbc/jena-jdbc-core/src/main/java/org/apache/jena/jdbc/JenaTransactionalJdbcConnection.java
Mon Apr  1 18:16:20 2013
@@ -1,4 +1,4 @@
-/*
+/**
  * 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

Modified: jena/Experimental/jena-jdbc/jena-jdbc-core/src/main/java/org/apache/jena/jdbc/results/AskResults.java
URL: http://svn.apache.org/viewvc/jena/Experimental/jena-jdbc/jena-jdbc-core/src/main/java/org/apache/jena/jdbc/results/AskResults.java?rev=1463235&r1=1463234&r2=1463235&view=diff
==============================================================================
--- jena/Experimental/jena-jdbc/jena-jdbc-core/src/main/java/org/apache/jena/jdbc/results/AskResults.java
(original)
+++ jena/Experimental/jena-jdbc/jena-jdbc-core/src/main/java/org/apache/jena/jdbc/results/AskResults.java
Mon Apr  1 18:16:20 2013
@@ -1,4 +1,4 @@
-/*
+/**
  * 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

Modified: jena/Experimental/jena-jdbc/jena-jdbc-core/src/main/java/org/apache/jena/jdbc/results/JenaJdbcResultSet.java
URL: http://svn.apache.org/viewvc/jena/Experimental/jena-jdbc/jena-jdbc-core/src/main/java/org/apache/jena/jdbc/results/JenaJdbcResultSet.java?rev=1463235&r1=1463234&r2=1463235&view=diff
==============================================================================
--- jena/Experimental/jena-jdbc/jena-jdbc-core/src/main/java/org/apache/jena/jdbc/results/JenaJdbcResultSet.java
(original)
+++ jena/Experimental/jena-jdbc/jena-jdbc-core/src/main/java/org/apache/jena/jdbc/results/JenaJdbcResultSet.java
Mon Apr  1 18:16:20 2013
@@ -1,4 +1,4 @@
-/*
+/**
  * 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

Modified: jena/Experimental/jena-jdbc/jena-jdbc-core/src/main/java/org/apache/jena/jdbc/results/SelectResults.java
URL: http://svn.apache.org/viewvc/jena/Experimental/jena-jdbc/jena-jdbc-core/src/main/java/org/apache/jena/jdbc/results/SelectResults.java?rev=1463235&r1=1463234&r2=1463235&view=diff
==============================================================================
--- jena/Experimental/jena-jdbc/jena-jdbc-core/src/main/java/org/apache/jena/jdbc/results/SelectResults.java
(original)
+++ jena/Experimental/jena-jdbc/jena-jdbc-core/src/main/java/org/apache/jena/jdbc/results/SelectResults.java
Mon Apr  1 18:16:20 2013
@@ -1,4 +1,4 @@
-/*
+/**
  * 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
@@ -18,14 +18,13 @@
 
 package org.apache.jena.jdbc.results;
 
-import java.sql.ResultSet;
 import java.sql.ResultSetMetaData;
 import java.sql.SQLException;
-import java.sql.SQLFeatureNotSupportedException;
 import java.sql.Statement;
 import java.util.ArrayList;
 import java.util.List;
 
+import org.apache.jena.atlas.lib.Closeable;
 import org.apache.jena.jdbc.results.metadata.SelectResultsMetadata;
 
 import com.hp.hpl.jena.graph.Node;
@@ -35,108 +34,57 @@ import com.hp.hpl.jena.sparql.engine.bin
 
 /**
  * Represents SPARQL SELECT results
- *
+ * 
  */
-public class SelectResults extends JenaJdbcResultSet {
-    
-    private QueryExecution qe;
+public class SelectResults extends StreamedResults<Binding> {
+
     private com.hp.hpl.jena.query.ResultSet innerResults;
-    private Binding binding;
-    private boolean started = false;
-    private boolean finished = false;
-    private int currRow = 0;
     private List<String> columns;
-    
+
     /**
      * Creates new select results
-     * @param statement Statement that created the result set
-     * @param qe Query Execution
-     * @param results SPARQL Results
-     * @throws SQLException Thrown if the arguments are invalid
+     * 
+     * @param statement
+     *            Statement that created the result set
+     * @param qe
+     *            Query Execution
+     * @param results
+     *            SPARQL Results
+     * @throws SQLException
+     *             Thrown if the arguments are invalid
      */
     public SelectResults(Statement statement, QueryExecution qe, com.hp.hpl.jena.query.ResultSet
results) throws SQLException {
-        super(statement);
-        if (qe == null) throw new SQLException("Query Execution cannot be null");
-        this.qe = qe;
-        if (results == null) throw new SQLException("SPARQL Results cannot be null");
+        super(statement, qe);
+        if (results == null)
+            throw new SQLException("SPARQL Results cannot be null");
         this.innerResults = results;
         this.columns = new ArrayList<String>(this.innerResults.getResultVars());
     }
 
-    public boolean absolute(int row) throws SQLException {
-        if (this.isClosed()) {
-            throw new SQLException("Cannot move to a row after the result set has been closed");
-        } else if (row == 1) {
-            // Try and move to the first row
-            return this.first();
-        } else if (row == -1) {
-            // Try and move to the last row
-            return this.last();
-        } else if (row <= 0) {
-            //Can't move to an arbitrary relative row from the end of the results
-            throw new SQLException("Jena JDBC result sets are forward only, cannot move to
a row which is relative to the end of the result set");
-        } else if (row == this.currRow) {
-            // Already at the desired row
-            return true;
-        } else if (row < this.currRow) {
-            throw new SQLException("Jena JDBC result sets are forward only");
-        } else {
-            // Before the desired row
-            while (this.innerResults.hasNext() && this.currRow < row) {
-                this.binding = this.innerResults.nextBinding();
-                this.currRow++;
-            }
-            // If we didn't reach it we hit the end of the result set
-            if (this.currRow < row) {
-                this.finished = true;
-                this.binding = null;
-            }
-            return (row == this.currRow);
-        }
-    }
-
-    public void afterLast() throws SQLException {
-        if (this.isClosed()) throw new SQLException("Result Set is closed");
-        if (finished) return;
-        
-        // Move to end of results
-        while (this.innerResults.hasNext()) {
-            this.binding = this.innerResults.nextBinding();
-            this.currRow++;
-        }
-        this.binding = null;
-        this.finished = true;
-    }
-
-    public void beforeFirst() throws SQLException {
-        if (this.isClosed()) throw new SQLException("Result Set is closed");
-        //If we've started throw an error as we can't move backwards
-        if (started) throw new SQLException("Jena JDBC result sets are forward only");
-        //Otherwise OK
-        this.binding = null;
-    }
-
-    public void close() throws SQLException {
+    @Override
+    public void closeStreamInternal() throws SQLException {
         if (this.innerResults != null) {
-            this.qe.close();
-            this.qe = null;
+            if (this.innerResults instanceof Closeable) {
+                ((Closeable) this.innerResults).close();
+            }
             this.innerResults = null;
         }
-        this.binding = null;
-        this.finished = true;
     }
 
     public int findColumn(String columnLabel) throws SQLException {
-        if (this.isClosed()) throw new SQLException("Result Set is closed");
+        if (this.isClosed())
+            throw new SQLException("Result Set is closed");
         for (int i = 0; i < this.columns.size(); i++) {
-            if (this.columns.get(i).equals(columnLabel)) return i + 1;
+            if (this.columns.get(i).equals(columnLabel))
+                return i + 1;
         }
         throw new SQLException("The given column does not exist in this result set");
     }
-    
+
     @Override
     protected String findColumnLabel(int columnIndex) throws SQLException {
-        if (this.isClosed()) throw new SQLException("Result Set is closed");
+        if (this.isClosed())
+            throw new SQLException("Result Set is closed");
         if (columnIndex >= 1 && columnIndex <= this.columns.size()) {
             return this.columns.get(columnIndex - 1);
         } else {
@@ -144,125 +92,39 @@ public class SelectResults extends JenaJ
         }
     }
 
-    public boolean first() throws SQLException {
-        if (this.isClosed()) throw new SQLException("Result Set is closed");
-        if (this.started && this.currRow == 1) return true;
-        throw new SQLException("Jena JDBC result sets are forward only");
-    }
-
-    public int getFetchDirection() throws SQLException {
-        return ResultSet.FETCH_FORWARD;
-    }
-
-    public int getFetchSize() throws SQLException {
-        // TODO Need a buffering wrapper around ResultSet to make this configurable
-        return 0;
-    }
-    
     @Override
     protected Node getNode(String columnLabel) throws SQLException {
-        if (this.isClosed()) throw new SQLException("Result Set is closed");
-        if (this.binding == null) throw new SQLException("Not currently at a row");
-        if (!this.columns.contains(columnLabel)) throw new SQLException("The given column
does not exist in the result set");
-        return this.binding.get(Var.alloc(columnLabel));
+        if (this.isClosed())
+            throw new SQLException("Result Set is closed");
+        if (this.getCurrentRow() == null)
+            throw new SQLException("Not currently at a row");
+        if (!this.columns.contains(columnLabel))
+            throw new SQLException("The given column does not exist in the result set");
+        return this.getCurrentRow().get(Var.alloc(columnLabel));
     }
-    
+
     @Override
     public ResultSetMetaData getMetaData() throws SQLException {
         return new SelectResultsMetadata(this.innerResults, this.columns);
     }
 
-    public int getRow() throws SQLException {
-        return this.currRow;
-    }
-
-    public final int getType() throws SQLException {
-        return ResultSet.TYPE_FORWARD_ONLY;
-    }
-
-    public boolean isAfterLast() throws SQLException {
-        if (this.isClosed()) throw new SQLException("Result Set is closed");
-        return this.finished;
-    }
-
-    public boolean isBeforeFirst() throws SQLException {
-        if (this.isClosed()) throw new SQLException("Result Set is closed");
-        return !this.started;
-    }
-
-    public boolean isClosed() throws SQLException {
-        return this.innerResults == null;
-    }
-
-    public boolean isFirst() throws SQLException {
-        if (this.isClosed()) throw new SQLException("Result Set is closed");
-        return this.currRow == 1;
-    }
-
-    public boolean isLast() throws SQLException {
-        if (this.isClosed()) throw new SQLException("Result Set is closed");
-        return !this.innerResults.hasNext();
-    }
-
-    public boolean last() throws SQLException {
-        if (this.isClosed() || this.finished) {
-            throw new SQLException("Jena JDBC Result Sets are forward-only");
-        } else {
-            while (this.innerResults.hasNext()) {
-                this.binding = this.innerResults.nextBinding();
-                this.currRow++;
-            }
-            return true;
-        }
-    }
-
-    public boolean next() throws SQLException {
-        if (this.isClosed()) {
-            throw new SQLException("Cannot move to the next row in a closed result set");
-        } else {
-            if (this.innerResults.hasNext()) {
-                this.binding = this.innerResults.nextBinding();
-                this.currRow++;
-                return true;
-            } else {
-                if (!this.finished) this.currRow++;
-                this.finished = true;
-                return false;
-            }
-        }
-    }
-
-    public boolean relative(int rows) throws SQLException {
-        if (this.isClosed()) {
-            throw new SQLException("Cannot move to a row after the result set has been closed");
-        } else if (rows == 0) {
-            // Already at the desired row
-            return true;
-        } else if (rows < 0) {
-            throw new SQLException("Jena JDBC result sets are forward only");
-        } else {
-            // Before the desired row
-            int moved = 0;
-            while (this.innerResults.hasNext() && moved < rows) {
-                this.binding = this.innerResults.nextBinding();
-                this.currRow++;
-                moved++;
-            }
-            // If we didn't reach it we hit the end of the result set
-            if (moved < rows) {
-                this.finished = true;
-                this.binding = null;
-            }
-            return (rows == moved);
-        }
-    }
-
-    public void setFetchDirection(int direction) throws SQLException {
-        if (direction != ResultSet.FETCH_FORWARD) throw new SQLFeatureNotSupportedException("Jena
JDBC Result Sets only support forward fetch");
+    /**
+     * Gets whether there are further rows in the underlying SELECT results
+     */
+    @Override
+    protected boolean hasNext() throws SQLException {
+        // No null check here because superclass will not call us after we are
+        // closed and set to null
+        return this.innerResults.hasNext();
     }
 
-    public void setFetchSize(int rows) throws SQLException {
-        // TODO Need to provide some buffering wrapper over a ResultSet to make this possible
-        throw new SQLFeatureNotSupportedException();
+    /**
+     * Gets the next row from the underlying SELECT results
+     */
+    @Override
+    protected Binding moveNext() throws SQLException {
+        // No null check here because superclass will not call us after we are
+        // closed and set to null
+        return this.innerResults.nextBinding();
     }
 }

Modified: jena/Experimental/jena-jdbc/jena-jdbc-core/src/main/java/org/apache/jena/jdbc/results/metadata/AskResultsMetadata.java
URL: http://svn.apache.org/viewvc/jena/Experimental/jena-jdbc/jena-jdbc-core/src/main/java/org/apache/jena/jdbc/results/metadata/AskResultsMetadata.java?rev=1463235&r1=1463234&r2=1463235&view=diff
==============================================================================
--- jena/Experimental/jena-jdbc/jena-jdbc-core/src/main/java/org/apache/jena/jdbc/results/metadata/AskResultsMetadata.java
(original)
+++ jena/Experimental/jena-jdbc/jena-jdbc-core/src/main/java/org/apache/jena/jdbc/results/metadata/AskResultsMetadata.java
Mon Apr  1 18:16:20 2013
@@ -1,4 +1,4 @@
-/*
+/**
  * 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

Modified: jena/Experimental/jena-jdbc/jena-jdbc-core/src/main/java/org/apache/jena/jdbc/results/metadata/JenaJdbcResultsMetadata.java
URL: http://svn.apache.org/viewvc/jena/Experimental/jena-jdbc/jena-jdbc-core/src/main/java/org/apache/jena/jdbc/results/metadata/JenaJdbcResultsMetadata.java?rev=1463235&r1=1463234&r2=1463235&view=diff
==============================================================================
--- jena/Experimental/jena-jdbc/jena-jdbc-core/src/main/java/org/apache/jena/jdbc/results/metadata/JenaJdbcResultsMetadata.java
(original)
+++ jena/Experimental/jena-jdbc/jena-jdbc-core/src/main/java/org/apache/jena/jdbc/results/metadata/JenaJdbcResultsMetadata.java
Mon Apr  1 18:16:20 2013
@@ -1,4 +1,4 @@
-/*
+/**
  * 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

Modified: jena/Experimental/jena-jdbc/jena-jdbc-core/src/main/java/org/apache/jena/jdbc/results/metadata/SelectResultsMetadata.java
URL: http://svn.apache.org/viewvc/jena/Experimental/jena-jdbc/jena-jdbc-core/src/main/java/org/apache/jena/jdbc/results/metadata/SelectResultsMetadata.java?rev=1463235&r1=1463234&r2=1463235&view=diff
==============================================================================
--- jena/Experimental/jena-jdbc/jena-jdbc-core/src/main/java/org/apache/jena/jdbc/results/metadata/SelectResultsMetadata.java
(original)
+++ jena/Experimental/jena-jdbc/jena-jdbc-core/src/main/java/org/apache/jena/jdbc/results/metadata/SelectResultsMetadata.java
Mon Apr  1 18:16:20 2013
@@ -1,4 +1,4 @@
-/*
+/**
  * 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

Modified: jena/Experimental/jena-jdbc/jena-jdbc-core/src/main/java/org/apache/jena/jdbc/utils/JenaJdbcNodeUtils.java
URL: http://svn.apache.org/viewvc/jena/Experimental/jena-jdbc/jena-jdbc-core/src/main/java/org/apache/jena/jdbc/utils/JenaJdbcNodeUtils.java?rev=1463235&r1=1463234&r2=1463235&view=diff
==============================================================================
--- jena/Experimental/jena-jdbc/jena-jdbc-core/src/main/java/org/apache/jena/jdbc/utils/JenaJdbcNodeUtils.java
(original)
+++ jena/Experimental/jena-jdbc/jena-jdbc-core/src/main/java/org/apache/jena/jdbc/utils/JenaJdbcNodeUtils.java
Mon Apr  1 18:16:20 2013
@@ -1,4 +1,4 @@
-/*
+/**
  * 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

Modified: jena/Experimental/jena-jdbc/jena-jdbc-core/src/test/java/org/apache/jena/jdbc/AbstractJenaJdbcConnectionTests.java
URL: http://svn.apache.org/viewvc/jena/Experimental/jena-jdbc/jena-jdbc-core/src/test/java/org/apache/jena/jdbc/AbstractJenaJdbcConnectionTests.java?rev=1463235&r1=1463234&r2=1463235&view=diff
==============================================================================
--- jena/Experimental/jena-jdbc/jena-jdbc-core/src/test/java/org/apache/jena/jdbc/AbstractJenaJdbcConnectionTests.java
(original)
+++ jena/Experimental/jena-jdbc/jena-jdbc-core/src/test/java/org/apache/jena/jdbc/AbstractJenaJdbcConnectionTests.java
Mon Apr  1 18:16:20 2013
@@ -1,4 +1,4 @@
-/*
+/**
  * 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

Modified: jena/Experimental/jena-jdbc/jena-jdbc-core/src/test/java/org/apache/jena/jdbc/AbstractJenaJdbcDriverTests.java
URL: http://svn.apache.org/viewvc/jena/Experimental/jena-jdbc/jena-jdbc-core/src/test/java/org/apache/jena/jdbc/AbstractJenaJdbcDriverTests.java?rev=1463235&r1=1463234&r2=1463235&view=diff
==============================================================================
--- jena/Experimental/jena-jdbc/jena-jdbc-core/src/test/java/org/apache/jena/jdbc/AbstractJenaJdbcDriverTests.java
(original)
+++ jena/Experimental/jena-jdbc/jena-jdbc-core/src/test/java/org/apache/jena/jdbc/AbstractJenaJdbcDriverTests.java
Mon Apr  1 18:16:20 2013
@@ -1,4 +1,4 @@
-/*
+/**
  * 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

Modified: jena/Experimental/jena-jdbc/jena-jdbc-driver-mem/pom.xml
URL: http://svn.apache.org/viewvc/jena/Experimental/jena-jdbc/jena-jdbc-driver-mem/pom.xml?rev=1463235&r1=1463234&r2=1463235&view=diff
==============================================================================
--- jena/Experimental/jena-jdbc/jena-jdbc-driver-mem/pom.xml (original)
+++ jena/Experimental/jena-jdbc/jena-jdbc-driver-mem/pom.xml Mon Apr  1 18:16:20 2013
@@ -1,25 +1,39 @@
-<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
-  <modelVersion>4.0.0</modelVersion>
-  <parent>
-    <groupId>org.apache.jena</groupId>
-    <artifactId>jena-jdbc</artifactId>
-    <version>0.0.1-SNAPSHOT</version>
-  </parent>
-  <artifactId>jena-jdbc-driver-mem</artifactId>
-  <name>Jena JDBC - In-Memory Driver</name>
-  <description>A Jena JDBC driver that uses an ARQ in-memory endpoint, intended primarily
for testing purposes.</description>
-  <dependencies>
-  	<dependency>
-  		<groupId>org.apache.jena</groupId>
-  		<artifactId>jena-jdbc-core</artifactId>
-  		<version>0.0.1-SNAPSHOT</version>
-  	</dependency>
-  	<dependency>
-  		<groupId>org.apache.jena</groupId>
-  		<artifactId>jena-jdbc-core</artifactId>
-  		<version>0.0.1-SNAPSHOT</version>
-  		<classifier>tests</classifier>
-  		<scope>tests</scope>
-  	</dependency>
-  </dependencies>
+<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+	xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
+	<modelVersion>4.0.0</modelVersion>
+	<parent>
+		<groupId>org.apache.jena</groupId>
+		<artifactId>jena-jdbc</artifactId>
+		<version>0.0.1-SNAPSHOT</version>
+	</parent>
+	<artifactId>jena-jdbc-driver-mem</artifactId>
+	<name>Jena JDBC - In-Memory Driver</name>
+	<description>A Jena JDBC driver that uses an ARQ in-memory endpoint, intended primarily
for testing purposes.</description>
+
+	<properties>
+		<plugin.license.headerPath>${project.parent.basedir}</plugin.license.headerPath>
+	</properties>
+	
+	<dependencies>
+		<dependency>
+			<groupId>org.apache.jena</groupId>
+			<artifactId>jena-jdbc-core</artifactId>
+			<version>0.0.1-SNAPSHOT</version>
+		</dependency>
+		
+		<!-- Test Dependencies -->
+		<dependency>
+			<groupId>org.apache.jena</groupId>
+			<artifactId>jena-jdbc-core</artifactId>
+			<version>0.0.1-SNAPSHOT</version>
+			<classifier>tests</classifier>
+			<scope>test</scope>
+		</dependency>
+		<dependency>
+			<groupId>junit</groupId>
+			<artifactId>junit</artifactId>
+			<version>4.11</version>
+			<scope>test</scope>
+		</dependency>
+	</dependencies>
 </project>
\ No newline at end of file

Modified: jena/Experimental/jena-jdbc/jena-jdbc-driver-mem/src/main/java/org/apache/jena/jdbc/mem/JenaJdbcDatasetConnection.java
URL: http://svn.apache.org/viewvc/jena/Experimental/jena-jdbc/jena-jdbc-driver-mem/src/main/java/org/apache/jena/jdbc/mem/JenaJdbcDatasetConnection.java?rev=1463235&r1=1463234&r2=1463235&view=diff
==============================================================================
--- jena/Experimental/jena-jdbc/jena-jdbc-driver-mem/src/main/java/org/apache/jena/jdbc/mem/JenaJdbcDatasetConnection.java
(original)
+++ jena/Experimental/jena-jdbc/jena-jdbc-driver-mem/src/main/java/org/apache/jena/jdbc/mem/JenaJdbcDatasetConnection.java
Mon Apr  1 18:16:20 2013
@@ -1,4 +1,4 @@
-/*
+/**
  * 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

Modified: jena/Experimental/jena-jdbc/jena-jdbc-driver-mem/src/main/java/org/apache/jena/jdbc/mem/JenaJdbcDatasetStatement.java
URL: http://svn.apache.org/viewvc/jena/Experimental/jena-jdbc/jena-jdbc-driver-mem/src/main/java/org/apache/jena/jdbc/mem/JenaJdbcDatasetStatement.java?rev=1463235&r1=1463234&r2=1463235&view=diff
==============================================================================
--- jena/Experimental/jena-jdbc/jena-jdbc-driver-mem/src/main/java/org/apache/jena/jdbc/mem/JenaJdbcDatasetStatement.java
(original)
+++ jena/Experimental/jena-jdbc/jena-jdbc-driver-mem/src/main/java/org/apache/jena/jdbc/mem/JenaJdbcDatasetStatement.java
Mon Apr  1 18:16:20 2013
@@ -1,4 +1,4 @@
-/*
+/**
  * 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
@@ -33,7 +33,6 @@ import com.hp.hpl.jena.update.UpdateRequ
 
 /**
  * A Jena JDBC statement over a {@link Dataset}
- * @author rvesse
  *
  */
 public class JenaJdbcDatasetStatement extends JenaJdbcStatement {

Modified: jena/Experimental/jena-jdbc/jena-jdbc-driver-mem/src/main/java/org/apache/jena/jdbc/mem/JenaJdbcMemDriver.java
URL: http://svn.apache.org/viewvc/jena/Experimental/jena-jdbc/jena-jdbc-driver-mem/src/main/java/org/apache/jena/jdbc/mem/JenaJdbcMemDriver.java?rev=1463235&r1=1463234&r2=1463235&view=diff
==============================================================================
--- jena/Experimental/jena-jdbc/jena-jdbc-driver-mem/src/main/java/org/apache/jena/jdbc/mem/JenaJdbcMemDriver.java
(original)
+++ jena/Experimental/jena-jdbc/jena-jdbc-driver-mem/src/main/java/org/apache/jena/jdbc/mem/JenaJdbcMemDriver.java
Mon Apr  1 18:16:20 2013
@@ -1,4 +1,4 @@
-/*
+/**
  * 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

Modified: jena/Experimental/jena-jdbc/jena-jdbc-driver-mem/src/test/java/org/apache/jena/jdbc/mem/TestJenaJdbcDatasetConnection.java
URL: http://svn.apache.org/viewvc/jena/Experimental/jena-jdbc/jena-jdbc-driver-mem/src/test/java/org/apache/jena/jdbc/mem/TestJenaJdbcDatasetConnection.java?rev=1463235&r1=1463234&r2=1463235&view=diff
==============================================================================
--- jena/Experimental/jena-jdbc/jena-jdbc-driver-mem/src/test/java/org/apache/jena/jdbc/mem/TestJenaJdbcDatasetConnection.java
(original)
+++ jena/Experimental/jena-jdbc/jena-jdbc-driver-mem/src/test/java/org/apache/jena/jdbc/mem/TestJenaJdbcDatasetConnection.java
Mon Apr  1 18:16:20 2013
@@ -1,4 +1,4 @@
-/*
+/**
  * 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

Modified: jena/Experimental/jena-jdbc/jena-jdbc-driver-mem/src/test/java/org/apache/jena/jdbc/mem/TestJenaJdbcMemDriver.java
URL: http://svn.apache.org/viewvc/jena/Experimental/jena-jdbc/jena-jdbc-driver-mem/src/test/java/org/apache/jena/jdbc/mem/TestJenaJdbcMemDriver.java?rev=1463235&r1=1463234&r2=1463235&view=diff
==============================================================================
--- jena/Experimental/jena-jdbc/jena-jdbc-driver-mem/src/test/java/org/apache/jena/jdbc/mem/TestJenaJdbcMemDriver.java
(original)
+++ jena/Experimental/jena-jdbc/jena-jdbc-driver-mem/src/test/java/org/apache/jena/jdbc/mem/TestJenaJdbcMemDriver.java
Mon Apr  1 18:16:20 2013
@@ -1,4 +1,4 @@
-/*
+/**
  * 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

Modified: jena/Experimental/jena-jdbc/jena-jdbc-driver-remote/pom.xml
URL: http://svn.apache.org/viewvc/jena/Experimental/jena-jdbc/jena-jdbc-driver-remote/pom.xml?rev=1463235&r1=1463234&r2=1463235&view=diff
==============================================================================
--- jena/Experimental/jena-jdbc/jena-jdbc-driver-remote/pom.xml (original)
+++ jena/Experimental/jena-jdbc/jena-jdbc-driver-remote/pom.xml Mon Apr  1 18:16:20 2013
@@ -1,11 +1,33 @@
-<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
-  <modelVersion>4.0.0</modelVersion>
-  <parent>
-    <groupId>org.apache.jena</groupId>
-    <artifactId>jena-jdbc</artifactId>
-    <version>0.0.1-SNAPSHOT</version>
-  </parent>
-  <artifactId>jena-jdbc-driver-remote</artifactId>
-  <name>Jena JDBC - Remote Endpoint Driver</name>
-  <description>A Jena JDBC driver for use with remote SPARQL endpoints.</description>
+<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+	xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
+	<modelVersion>4.0.0</modelVersion>
+	<parent>
+		<groupId>org.apache.jena</groupId>
+		<artifactId>jena-jdbc</artifactId>
+		<version>0.0.1-SNAPSHOT</version>
+	</parent>
+	<artifactId>jena-jdbc-driver-remote</artifactId>
+	<name>Jena JDBC - Remote Endpoint Driver</name>
+	<description>A Jena JDBC driver for use with remote SPARQL endpoints.</description>
+
+	<properties>
+		<plugin.license.headerPath>${project.parent.basedir}</plugin.license.headerPath>
+	</properties>
+
+	<dependencies>
+		<!-- Test Dependencies -->
+		<dependency>
+			<groupId>org.apache.jena</groupId>
+			<artifactId>jena-jdbc-core</artifactId>
+			<version>0.0.1-SNAPSHOT</version>
+			<classifier>tests</classifier>
+			<scope>test</scope>
+		</dependency>
+		<dependency>
+			<groupId>junit</groupId>
+			<artifactId>junit</artifactId>
+			<version>4.11</version>
+			<scope>test</scope>
+		</dependency>
+	</dependencies>
 </project>
\ No newline at end of file

Modified: jena/Experimental/jena-jdbc/jena-jdbc-driver-tdb/pom.xml
URL: http://svn.apache.org/viewvc/jena/Experimental/jena-jdbc/jena-jdbc-driver-tdb/pom.xml?rev=1463235&r1=1463234&r2=1463235&view=diff
==============================================================================
--- jena/Experimental/jena-jdbc/jena-jdbc-driver-tdb/pom.xml (original)
+++ jena/Experimental/jena-jdbc/jena-jdbc-driver-tdb/pom.xml Mon Apr  1 18:16:20 2013
@@ -1,35 +1,49 @@
-<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
-  <modelVersion>4.0.0</modelVersion>
-  <parent>
-    <groupId>org.apache.jena</groupId>
-    <artifactId>jena-jdbc</artifactId>
-    <version>0.0.1-SNAPSHOT</version>
-  </parent>
-  <artifactId>jena-jdbc-driver-tdb</artifactId>
-  <name>Jena JDBC - TDB Driver</name>
-  <description>A Jena JDBC driver for use with the Jena TDB backend</description>
-  <dependencies>
-  	<dependency>
-  		<groupId>org.apache.jena</groupId>
-  		<artifactId>jena-jdbc-core</artifactId>
-  		<version>0.0.1-SNAPSHOT</version>
-  	</dependency>
-  	  	<dependency>
-  		<groupId>org.apache.jena</groupId>
-  		<artifactId>jena-jdbc-core</artifactId>
-  		<version>0.0.1-SNAPSHOT</version>
-  		<classifier>tests</classifier>
-  		<scope>tests</scope>
-  	</dependency>
-  	<dependency>
-  		<groupId>org.apache.jena</groupId>
-  		<artifactId>jena-jdbc-driver-mem</artifactId>
-  		<version>0.0.1-SNAPSHOT</version>
-  	</dependency>
-  	<dependency>
-  		<groupId>org.apache.jena</groupId>
-  		<artifactId>jena-tdb</artifactId>
-  		<version>0.9.0-incubating</version>
-  	</dependency>
-  </dependencies>
+<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+	xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
+	<modelVersion>4.0.0</modelVersion>
+	<parent>
+		<groupId>org.apache.jena</groupId>
+		<artifactId>jena-jdbc</artifactId>
+		<version>0.0.1-SNAPSHOT</version>
+	</parent>
+	<artifactId>jena-jdbc-driver-tdb</artifactId>
+	<name>Jena JDBC - TDB Driver</name>
+	<description>A Jena JDBC driver for use with the Jena TDB backend</description>
+
+	<properties>
+		<plugin.license.headerPath>${project.parent.basedir}</plugin.license.headerPath>
+	</properties>
+
+	<dependencies>
+		<dependency>
+			<groupId>org.apache.jena</groupId>
+			<artifactId>jena-jdbc-core</artifactId>
+			<version>0.0.1-SNAPSHOT</version>
+		</dependency>
+		<dependency>
+			<groupId>org.apache.jena</groupId>
+			<artifactId>jena-jdbc-driver-mem</artifactId>
+			<version>0.0.1-SNAPSHOT</version>
+		</dependency>
+		<dependency>
+			<groupId>org.apache.jena</groupId>
+			<artifactId>jena-tdb</artifactId>
+			<version>0.10.1-SNAPSHOT</version>
+		</dependency>
+
+		<!-- Test Dependencies -->
+		<dependency>
+			<groupId>junit</groupId>
+			<artifactId>junit</artifactId>
+			<version>4.11</version>
+			<scope>test</scope>
+		</dependency>
+		<dependency>
+			<groupId>org.apache.jena</groupId>
+			<artifactId>jena-jdbc-core</artifactId>
+			<version>0.0.1-SNAPSHOT</version>
+			<classifier>tests</classifier>
+			<scope>test</scope>
+		</dependency>
+	</dependencies>
 </project>
\ No newline at end of file

Modified: jena/Experimental/jena-jdbc/jena-jdbc-driver-tdb/src/main/java/org/apache/jena/jdbc/tdb/TDBDriver.java
URL: http://svn.apache.org/viewvc/jena/Experimental/jena-jdbc/jena-jdbc-driver-tdb/src/main/java/org/apache/jena/jdbc/tdb/TDBDriver.java?rev=1463235&r1=1463234&r2=1463235&view=diff
==============================================================================
--- jena/Experimental/jena-jdbc/jena-jdbc-driver-tdb/src/main/java/org/apache/jena/jdbc/tdb/TDBDriver.java
(original)
+++ jena/Experimental/jena-jdbc/jena-jdbc-driver-tdb/src/main/java/org/apache/jena/jdbc/tdb/TDBDriver.java
Mon Apr  1 18:16:20 2013
@@ -1,4 +1,4 @@
-/*
+/**
  * 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

Modified: jena/Experimental/jena-jdbc/pom.xml
URL: http://svn.apache.org/viewvc/jena/Experimental/jena-jdbc/pom.xml?rev=1463235&r1=1463234&r2=1463235&view=diff
==============================================================================
--- jena/Experimental/jena-jdbc/pom.xml (original)
+++ jena/Experimental/jena-jdbc/pom.xml Mon Apr  1 18:16:20 2013
@@ -1,15 +1,49 @@
-<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
-  <modelVersion>4.0.0</modelVersion>
-  <groupId>org.apache.jena</groupId>
-  <artifactId>jena-jdbc</artifactId>
-  <version>0.0.1-SNAPSHOT</version>
-  <packaging>pom</packaging>
-  <name>Jena JDBC</name>
-  <description>This is the parent module for the Jena JDBC modules.  These modules
provide JDBC Type 4 drivers for in-memory and TDB datasets as well as remote SPARQL endpoints.</description>
-  <modules>
-  	<module>jena-jdbc-core</module>
-  	<module>jena-jdbc-driver-remote</module>
-  	<module>jena-jdbc-driver-tdb</module>
-  	<module>jena-jdbc-driver-mem</module>
-  </modules>
+<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+	xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
+	<modelVersion>4.0.0</modelVersion>
+	<groupId>org.apache.jena</groupId>
+	<artifactId>jena-jdbc</artifactId>
+	<version>0.0.1-SNAPSHOT</version>
+	<packaging>pom</packaging>
+	<name>Jena JDBC</name>
+	<description>This is the parent module for the Jena JDBC modules.  These modules provide
JDBC Type 4 drivers for in-memory and TDB datasets as well as remote SPARQL endpoints.</description>
+	<modules>
+		<module>jena-jdbc-core</module>
+		<module>jena-jdbc-driver-remote</module>
+		<module>jena-jdbc-driver-tdb</module>
+		<module>jena-jdbc-driver-mem</module>
+	</modules>
+
+	<properties>
+		<plugin.license.version>1.9.0</plugin.license.version>
+		<plugin.license.headerPath>${project.basedir}</plugin.license.headerPath>
+	</properties>
+
+	<build>
+		<plugins>
+			<!-- License Plugin -->
+			<plugin>
+				<groupId>com.mycila.maven-license-plugin</groupId>
+				<artifactId>maven-license-plugin</artifactId>
+				<version>${plugin.license.version}</version>
+				<executions>
+					<execution>
+						<phase>package</phase>
+						<goals>
+							<goal>check</goal>
+						</goals>
+					</execution>
+				</executions>
+				<configuration>
+					<header>${plugin.license.headerPath}/license-header.txt</header>
+					<failIfMissing>true</failIfMissing>
+					<aggregate>true</aggregate>
+					<excludes>
+					</excludes>
+					<useDefaultMapping>true</useDefaultMapping>
+					<strictCheck>true</strictCheck>
+				</configuration>
+			</plugin>
+		</plugins>
+	</build>
 </project>
\ No newline at end of file



Mime
View raw message