You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@stanbol.apache.org by co...@apache.org on 2011/03/25 15:10:12 UTC

svn commit: r1085384 - in /incubator/stanbol/trunk/kres/owlapi: ./ src/main/java/org/apache/stanbol/owlapi/ src/test/java/org/apache/stanbol/owlapi/

Author: concelvio
Date: Fri Mar 25 14:10:11 2011
New Revision: 1085384

URL: http://svn.apache.org/viewvc?rev=1085384&view=rev
Log:
STANBOL-39:
- changed parent version in pom.xml to ${stanbol-version}
- removed kres-version from pom.xml
- changed name KReSRunSPARQL.java to RunSingleSPARQL.java
- changed name KReSRunSPARQLTest.java to RunSingleSPARQLTest.java

Added:
    incubator/stanbol/trunk/kres/owlapi/src/main/java/org/apache/stanbol/owlapi/RunSingleSPARQL.java
      - copied, changed from r1085259, incubator/stanbol/trunk/kres/owlapi/src/main/java/org/apache/stanbol/owlapi/KReSRunSPARQL.java
    incubator/stanbol/trunk/kres/owlapi/src/test/java/org/apache/stanbol/owlapi/RunSingleSPARQLTest.java
      - copied, changed from r1085259, incubator/stanbol/trunk/kres/owlapi/src/test/java/org/apache/stanbol/owlapi/KReSRunSPARQLTest.java
Removed:
    incubator/stanbol/trunk/kres/owlapi/src/main/java/org/apache/stanbol/owlapi/KReSRunSPARQL.java
    incubator/stanbol/trunk/kres/owlapi/src/test/java/org/apache/stanbol/owlapi/KReSRunSPARQLTest.java
Modified:
    incubator/stanbol/trunk/kres/owlapi/pom.xml

Modified: incubator/stanbol/trunk/kres/owlapi/pom.xml
URL: http://svn.apache.org/viewvc/incubator/stanbol/trunk/kres/owlapi/pom.xml?rev=1085384&r1=1085383&r2=1085384&view=diff
==============================================================================
--- incubator/stanbol/trunk/kres/owlapi/pom.xml (original)
+++ incubator/stanbol/trunk/kres/owlapi/pom.xml Fri Mar 25 14:10:11 2011
@@ -1,3 +1,19 @@
+<?xml version="1.0" encoding="UTF-8"?>
+	<!--
+		Licensed to the Apache Software Foundation (ASF) under one or more
+		contributor license agreements. See the NOTICE file distributed with
+		this work for additional information regarding copyright ownership.
+		The ASF licenses this file to You under the Apache License, Version
+		2.0 (the "License"); you may not use this file except in compliance
+		with the License. You may obtain a copy of the License at
+
+		http://www.apache.org/licenses/LICENSE-2.0 Unless required by
+		applicable law or agreed to in writing, software distributed under the
+		License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR
+		CONDITIONS OF ANY KIND, either express or implied. See the License for
+		the specific language governing permissions and limitations under the
+		License.
+	-->
 <project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
 	xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
 
@@ -6,8 +22,8 @@
 	<parent>
 		<groupId>org.apache.stanbol</groupId>
 		<artifactId>stanbol-parent</artifactId>
-		<version>0.9-SNAPSHOT</version>
-		<relativePath>../../../parent</relativePath>
+		<version>${stanbol-version}</version>
+		<relativePath>../../parent</relativePath>
 	</parent>
         
 	<artifactId>org.apache.stanbol.owlapi</artifactId>
@@ -15,11 +31,6 @@
 	<packaging>bundle</packaging>
 	<name>Apache Stanbol Owlapi Dependecy</name>
 
-	<properties>
-		<kres-version>0.7</kres-version>
-		<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
-	</properties>
-
 	<repositories>
 		<repository>
 			<id>stlab-cnr-repo</id>

Copied: incubator/stanbol/trunk/kres/owlapi/src/main/java/org/apache/stanbol/owlapi/RunSingleSPARQL.java (from r1085259, incubator/stanbol/trunk/kres/owlapi/src/main/java/org/apache/stanbol/owlapi/KReSRunSPARQL.java)
URL: http://svn.apache.org/viewvc/incubator/stanbol/trunk/kres/owlapi/src/main/java/org/apache/stanbol/owlapi/RunSingleSPARQL.java?p2=incubator/stanbol/trunk/kres/owlapi/src/main/java/org/apache/stanbol/owlapi/RunSingleSPARQL.java&p1=incubator/stanbol/trunk/kres/owlapi/src/main/java/org/apache/stanbol/owlapi/KReSRunSPARQL.java&r1=1085259&r2=1085384&rev=1085384&view=diff
==============================================================================
--- incubator/stanbol/trunk/kres/owlapi/src/main/java/org/apache/stanbol/owlapi/KReSRunSPARQL.java (original)
+++ incubator/stanbol/trunk/kres/owlapi/src/main/java/org/apache/stanbol/owlapi/RunSingleSPARQL.java Fri Mar 25 14:10:11 2011
@@ -22,7 +22,7 @@ import org.apache.stanbol.owlapi.trasfor
  *
  * @author elvio
  */
-public class KReSRunSPARQL {
+public class RunSingleSPARQL {
 
     private OWLOntology owlmodel;
     private OntModel jenamodel;
@@ -33,7 +33,7 @@ public class KReSRunSPARQL {
      *
      * @param owl {The OWLOntology to be querying.}
      */
-    public KReSRunSPARQL(OWLOntology owl){
+    public RunSingleSPARQL(OWLOntology owl){
         this.owlmodel = owl;
 
         try{
@@ -67,7 +67,7 @@ public class KReSRunSPARQL {
      * @param owl {The OWLOntology to be querying}
      * @param prefix {The map where the keys are the prefix label and the value the IRI of the prefix on the form: http://www.w3.org/2000/01/rdf-schema#.}
      */
-    public KReSRunSPARQL(OWLOntology owl, HashMap<String,String> prefix){
+    public RunSingleSPARQL(OWLOntology owl, HashMap<String,String> prefix){
         this.owlmodel = owl;
         JenaToOwlConvert j2o = new JenaToOwlConvert();
         this.jenamodel = j2o.ModelOwlToJenaConvert(owlmodel,"RDF/XML");

Copied: incubator/stanbol/trunk/kres/owlapi/src/test/java/org/apache/stanbol/owlapi/RunSingleSPARQLTest.java (from r1085259, incubator/stanbol/trunk/kres/owlapi/src/test/java/org/apache/stanbol/owlapi/KReSRunSPARQLTest.java)
URL: http://svn.apache.org/viewvc/incubator/stanbol/trunk/kres/owlapi/src/test/java/org/apache/stanbol/owlapi/RunSingleSPARQLTest.java?p2=incubator/stanbol/trunk/kres/owlapi/src/test/java/org/apache/stanbol/owlapi/RunSingleSPARQLTest.java&p1=incubator/stanbol/trunk/kres/owlapi/src/test/java/org/apache/stanbol/owlapi/KReSRunSPARQLTest.java&r1=1085259&r2=1085384&rev=1085384&view=diff
==============================================================================
--- incubator/stanbol/trunk/kres/owlapi/src/test/java/org/apache/stanbol/owlapi/KReSRunSPARQLTest.java (original)
+++ incubator/stanbol/trunk/kres/owlapi/src/test/java/org/apache/stanbol/owlapi/RunSingleSPARQLTest.java Fri Mar 25 14:10:11 2011
@@ -10,7 +10,7 @@ import static org.junit.Assert.*;
 import java.io.File;
 import java.util.HashMap;
 
-import org.apache.stanbol.owlapi.KReSRunSPARQL;
+import org.apache.stanbol.owlapi.RunSingleSPARQL;
 import org.junit.After;
 import org.junit.AfterClass;
 import org.junit.Before;
@@ -27,13 +27,13 @@ import com.hp.hpl.jena.query.ResultSet;
  *
  * @author elvio
  */
-public class KReSRunSPARQLTest {
+public class RunSingleSPARQLTest {
 
     public OWLOntologyManager owlmanager;
     public OWLOntology owl;
     public HashMap<String,String> sparqlprefix;
 
-    public KReSRunSPARQLTest() throws OWLOntologyCreationException {
+    public RunSingleSPARQLTest() throws OWLOntologyCreationException {
         this.owlmanager = OWLManager.createOWLOntologyManager();
         this.owl = owlmanager.loadOntologyFromOntologyDocument(new File("./src/main/resources/TestFile/ProvaParent.owl"));
     }
@@ -55,7 +55,7 @@ public class KReSRunSPARQLTest {
     }
 
     /**
-     * Test of getSPARQLprefix method, of class KReSRunSPARQL.
+     * Test of getSPARQLprefix method, of class RunSingleSPARQL.
      */
     @Test
     public void testGetSPARQLprefix() {
@@ -67,7 +67,7 @@ public class KReSRunSPARQLTest {
         map.put("rdf","<http://www.w3.org/1999/02/22-rdf-syntax-ns#>");
         map.put("ex","<http://www.w3.org/1999/02/22-rdf-syntax-ns#>");
 
-        KReSRunSPARQL instance = new KReSRunSPARQL(owl,map);
+        RunSingleSPARQL instance = new RunSingleSPARQL(owl,map);
         HashMap expResult = map;
         HashMap result = instance.getSPARQLprefix();
         if(!result.isEmpty()){
@@ -79,7 +79,7 @@ public class KReSRunSPARQLTest {
     }
 
     /**
-     * Test of addSPARQLprefix method, of class KReSRunSPARQL.
+     * Test of addSPARQLprefix method, of class RunSingleSPARQL.
      */
     @Test
     public void testAddSPARQLprefix() {
@@ -93,7 +93,7 @@ public class KReSRunSPARQLTest {
         map.put("rdf","<http://www.w3.org/1999/02/22-rdf-syntax-ns#>");
         map.put("ex","<http://www.w3.org/1999/02/22-rdf-syntax-ns#>");
 
-        KReSRunSPARQL instance = new KReSRunSPARQL(owl,map);
+        RunSingleSPARQL instance = new RunSingleSPARQL(owl,map);
         boolean result = instance.addSPARQLprefix(label, prefix);
         if(result){
             HashMap<String, String> mymap = instance.getSPARQLprefix();
@@ -106,7 +106,7 @@ public class KReSRunSPARQLTest {
     }
 
     /**
-     * Test of removeSPARQLprefix method, of class KReSRunSPARQL.
+     * Test of removeSPARQLprefix method, of class RunSingleSPARQL.
      */
     @Test
     public void testRemoveSPARQLprefix() {
@@ -118,7 +118,7 @@ public class KReSRunSPARQLTest {
         map.put("rdf","<http://www.w3.org/1999/02/22-rdf-syntax-ns#>");
         map.put("ex","<http://www.w3.org/1999/02/22-rdf-syntax-ns#>");
 
-        KReSRunSPARQL instance = new KReSRunSPARQL(owl,map);
+        RunSingleSPARQL instance = new RunSingleSPARQL(owl,map);
         boolean result = instance.removeSPARQLprefix("ex");
 
         if(result){
@@ -131,7 +131,7 @@ public class KReSRunSPARQLTest {
     }
 
     /**
-     * Test of runSPARQL method, of class KReSRunSPARQL.
+     * Test of runSPARQL method, of class RunSingleSPARQL.
      */
     @Test
     public void testRunSPARQL() {
@@ -142,7 +142,7 @@ public class KReSRunSPARQLTest {
         map.put("rdf","<http://www.w3.org/1999/02/22-rdf-syntax-ns#>");
         map.put("ex","<http://www.semanticweb.org/ontologies/2010/6/ProvaParent.owl#>");
         String query = "SELECT * WHERE {?p rdf:type ex:Person .}";
-        KReSRunSPARQL instance = new KReSRunSPARQL(owl,map);
+        RunSingleSPARQL instance = new RunSingleSPARQL(owl,map);
         ResultSet result = instance.runSPARQL(query);
 
         if(result!=null){