You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@stanbol.apache.org by al...@apache.org on 2012/06/20 11:42:27 UTC

svn commit: r1352018 [3/3] - in /incubator/stanbol/trunk: commons/owl/src/main/java/org/apache/stanbol/commons/owl/util/ commons/owl/src/test/java/org/apache/stanbol/commons/owl/util/ commons/owl/src/test/java/org/apache/stanbol/owl/ ontologymanager/on...

Modified: incubator/stanbol/trunk/ontologymanager/ontonet/src/test/java/org/apache/stanbol/ontologymanager/ontonet/ontology/TestClerezzaSpaces.java
URL: http://svn.apache.org/viewvc/incubator/stanbol/trunk/ontologymanager/ontonet/src/test/java/org/apache/stanbol/ontologymanager/ontonet/ontology/TestClerezzaSpaces.java?rev=1352018&r1=1352017&r2=1352018&view=diff
==============================================================================
--- incubator/stanbol/trunk/ontologymanager/ontonet/src/test/java/org/apache/stanbol/ontologymanager/ontonet/ontology/TestClerezzaSpaces.java (original)
+++ incubator/stanbol/trunk/ontologymanager/ontonet/src/test/java/org/apache/stanbol/ontologymanager/ontonet/ontology/TestClerezzaSpaces.java Wed Jun 20 09:42:24 2012
@@ -37,7 +37,6 @@ import org.apache.clerezza.rdf.core.Trip
 import org.apache.clerezza.rdf.core.serializedform.SupportedFormat;
 import org.apache.stanbol.commons.owl.OWLOntologyManagerFactory;
 import org.apache.stanbol.commons.owl.util.OWLUtils;
-import org.apache.stanbol.commons.owl.util.URIUtils;
 import org.apache.stanbol.ontologymanager.ontonet.Constants;
 import org.apache.stanbol.ontologymanager.ontonet.api.OfflineConfiguration;
 import org.apache.stanbol.ontologymanager.ontonet.api.collector.UnmodifiableOntologyCollectorException;
@@ -45,7 +44,6 @@ import org.apache.stanbol.ontologymanage
 import org.apache.stanbol.ontologymanager.ontonet.api.io.GraphSource;
 import org.apache.stanbol.ontologymanager.ontonet.api.io.OntologyInputSource;
 import org.apache.stanbol.ontologymanager.ontonet.api.io.ParentPathInputSource;
-import org.apache.stanbol.ontologymanager.ontonet.api.io.RootOntologyIRISource;
 import org.apache.stanbol.ontologymanager.ontonet.api.scope.CoreOntologySpace;
 import org.apache.stanbol.ontologymanager.ontonet.api.scope.CustomOntologySpace;
 import org.apache.stanbol.ontologymanager.ontonet.api.scope.OntologySpace;
@@ -66,6 +64,7 @@ import org.semanticweb.owlapi.model.OWLA
 import org.semanticweb.owlapi.model.OWLClass;
 import org.semanticweb.owlapi.model.OWLDataFactory;
 import org.semanticweb.owlapi.model.OWLIndividual;
+import org.semanticweb.owlapi.model.OWLOntology;
 import org.semanticweb.owlapi.model.OWLOntologyCreationException;
 import org.semanticweb.owlapi.model.OWLOntologyManager;
 
@@ -78,7 +77,9 @@ public class TestClerezzaSpaces {
 
     private static OntologySpaceFactory factory;
 
-    private static OntologyInputSource<?,?> inMemorySrc, minorSrc, dropSrc, nonexSrc;
+    private static OntologyInputSource<TripleCollection,?> minorSrc, dropSrc, nonexSrc;
+
+    private static OntologyInputSource<OWLOntology,?> inMemorySrc;
 
     private static OfflineConfiguration offline;
 
@@ -106,8 +107,8 @@ public class TestClerezzaSpaces {
         minorSrc = new GraphSource(ont2.getGraph());
         dropSrc = getLocalSource("/ontologies/droppedcharacters.owl");
         nonexSrc = getLocalSource("/ontologies/nonexistentcharacters.owl");
-        inMemorySrc = new RootOntologyIRISource(IRI.create(TestClerezzaSpaces.class
-                .getResource("/ontologies/maincharacters.owl")));
+        inMemorySrc = new ParentPathInputSource(new File(TestClerezzaSpaces.class.getResource(
+            "/ontologies/maincharacters.owl").toURI()));
 
         OWLDataFactory df = OWLManager.getOWLDataFactory();
         OWLClass cHuman = df.getOWLClass(IRI.create(baseIri + "/" + Constants.humanBeing));
@@ -129,16 +130,17 @@ public class TestClerezzaSpaces {
     @Test
     public void testAddOntology() throws Exception {
         CustomOntologySpace space = null;
-        IRI logicalId = IRI.create(OWLUtils.guessOntologyIdentifier(nonexSrc.getRootOntology())
-                .getUnicodeString());
+
+        IRI logicalId = OWLUtils.guessOntologyIdentifier(nonexSrc.getRootOntology()).getOntologyIRI();
+        assertNotNull(logicalId);
 
         space = factory.createCustomOntologySpace(scopeId, dropSrc, minorSrc);
         space.addOntology(minorSrc);
         space.addOntology(nonexSrc);
-
         assertTrue(space.hasOntology(logicalId));
-        logicalId = IRI
-                .create(OWLUtils.guessOntologyIdentifier(dropSrc.getRootOntology()).getUnicodeString());
+
+        logicalId = OWLUtils.guessOntologyIdentifier(dropSrc.getRootOntology()).getOntologyIRI();
+        assertNotNull(logicalId);
         assertTrue(space.hasOntology(logicalId));
     }
 
@@ -157,8 +159,13 @@ public class TestClerezzaSpaces {
     @Test
     public void testCreateSpace() throws Exception {
         CustomOntologySpace space = factory.createCustomOntologySpace(scopeId, dropSrc);
-        IRI logicalId = IRI.create(OWLUtils.guessOntologyIdentifier(dropSrc.getRootOntology())
-                .getUnicodeString());
+        IRI logicalId = null;
+        Object o = dropSrc.getRootOntology();
+        if (o instanceof TripleCollection) logicalId = OWLUtils.guessOntologyIdentifier((TripleCollection) o)
+                .getOntologyIRI();
+        else if (o instanceof OWLOntology) logicalId = OWLUtils.guessOntologyIdentifier((OWLOntology) o)
+                .getOntologyIRI();
+        assertNotNull(logicalId);
         assertTrue(space.hasOntology(logicalId));
     }
 
@@ -253,8 +260,8 @@ public class TestClerezzaSpaces {
     public void testRemoveCustomOntology() throws Exception {
         CustomOntologySpace space = null;
         space = factory.createCustomOntologySpace(scopeId, dropSrc);
-        IRI dropId = URIUtils.createIRI(OWLUtils.guessOntologyIdentifier(dropSrc.getRootOntology()));
-        IRI nonexId = URIUtils.createIRI(OWLUtils.guessOntologyIdentifier(nonexSrc.getRootOntology()));
+        IRI dropId = OWLUtils.guessOntologyIdentifier(dropSrc.getRootOntology()).getOntologyIRI();
+        IRI nonexId = OWLUtils.guessOntologyIdentifier(nonexSrc.getRootOntology()).getOntologyIRI();
 
         space.addOntology(inMemorySrc);
         space.addOntology(nonexSrc);

Modified: incubator/stanbol/trunk/ontologymanager/ontonet/src/test/java/org/apache/stanbol/ontologymanager/ontonet/ontology/TestOntologySpaces.java
URL: http://svn.apache.org/viewvc/incubator/stanbol/trunk/ontologymanager/ontonet/src/test/java/org/apache/stanbol/ontologymanager/ontonet/ontology/TestOntologySpaces.java?rev=1352018&r1=1352017&r2=1352018&view=diff
==============================================================================
--- incubator/stanbol/trunk/ontologymanager/ontonet/src/test/java/org/apache/stanbol/ontologymanager/ontonet/ontology/TestOntologySpaces.java (original)
+++ incubator/stanbol/trunk/ontologymanager/ontonet/src/test/java/org/apache/stanbol/ontologymanager/ontonet/ontology/TestOntologySpaces.java Wed Jun 20 09:42:24 2012
@@ -101,8 +101,6 @@ public class TestOntologySpaces {
 
     }
 
-    String scopeId = "Comics";
-
     @After
     public void cleanup() {
         reset();
@@ -113,7 +111,7 @@ public class TestOntologySpaces {
         CustomOntologySpace space = null;
         IRI logicalId = nonexSrc.getRootOntology().getOntologyID().getOntologyIRI();
 
-        space = factory.createCustomOntologySpace(scopeId, dropSrc);
+        space = factory.createCustomOntologySpace("testAddOntology", dropSrc);
         space.addOntology(minorSrc);
         space.addOntology(nonexSrc);
 
@@ -124,7 +122,7 @@ public class TestOntologySpaces {
 
     @Test
     public void testCoreLock() throws Exception {
-        CoreOntologySpace space = factory.createCoreOntologySpace(scopeId, inMemorySrc);
+        CoreOntologySpace space = factory.createCoreOntologySpace("testCoreLock", inMemorySrc);
         space.setUp();
         try {
             space.addOntology(minorSrc);
@@ -136,14 +134,14 @@ public class TestOntologySpaces {
 
     @Test
     public void testCreateSpace() throws Exception {
-        CustomOntologySpace space = factory.createCustomOntologySpace(scopeId, dropSrc);
+        CustomOntologySpace space = factory.createCustomOntologySpace("testCreateSpace", dropSrc);
         IRI logicalId = dropSrc.getRootOntology().getOntologyID().getOntologyIRI();
         assertTrue(space.hasOntology(logicalId));
     }
 
     @Test
     public void testCustomLock() throws Exception {
-        CustomOntologySpace space = factory.createCustomOntologySpace(scopeId, inMemorySrc);
+        CustomOntologySpace space = factory.createCustomOntologySpace("testCustomLock", inMemorySrc);
         space.setUp();
         try {
             space.addOntology(minorSrc);
@@ -231,7 +229,8 @@ public class TestOntologySpaces {
     @Test
     public void testRemoveCustomOntology() throws Exception {
         CustomOntologySpace space = null;
-        space = factory.createCustomOntologySpace(scopeId, dropSrc);
+        space = factory.createCustomOntologySpace("testRemoveCustomOntology", dropSrc);
+
         IRI dropId = dropSrc.getRootOntology().getOntologyID().getOntologyIRI();
         IRI nonexId = nonexSrc.getRootOntology().getOntologyID().getOntologyIRI();
 
@@ -240,6 +239,10 @@ public class TestOntologySpaces {
         // The other remote ontologies may change base IRI...
         assertTrue(space.hasOntology(ont.getOntologyID().getOntologyIRI()) && space.hasOntology(dropId)
                    && space.hasOntology(nonexId));
+
+        IRI bogus = IRI.create("http://www.example.org/ontology/bogus");
+        space.removeOntology(bogus);
+
         space.removeOntology(dropId);
         assertFalse(space.hasOntology(dropId));
         space.removeOntology(nonexId);

Added: incubator/stanbol/trunk/ontologymanager/ontonet/src/test/resources/log4j.properties
URL: http://svn.apache.org/viewvc/incubator/stanbol/trunk/ontologymanager/ontonet/src/test/resources/log4j.properties?rev=1352018&view=auto
==============================================================================
--- incubator/stanbol/trunk/ontologymanager/ontonet/src/test/resources/log4j.properties (added)
+++ incubator/stanbol/trunk/ontologymanager/ontonet/src/test/resources/log4j.properties Wed Jun 20 09:42:24 2012
@@ -0,0 +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.
+
+
+log4j.rootLogger=WARN, CONSOLE
+log4j.appender.CONSOLE=org.apache.log4j.ConsoleAppender
+log4j.appender.CONSOLE.layout=org.apache.log4j.PatternLayout
+#log4j.appender.CONSOLE.layout.ConversionPattern=%d{HH:mm:ss,SSS} %-5p [%C{1}] %m%n
+log4j.appender.CONSOLE.layout.ConversionPattern=[%-5p] [%C{1}] %m%n
+
+log4j.category.org.apache.stanbol.ontologymanager.ontonet=INFO
\ No newline at end of file

Modified: incubator/stanbol/trunk/ontologymanager/ontonet/src/test/resources/ontologies/maincharacters.owl
URL: http://svn.apache.org/viewvc/incubator/stanbol/trunk/ontologymanager/ontonet/src/test/resources/ontologies/maincharacters.owl?rev=1352018&r1=1352017&r2=1352018&view=diff
==============================================================================
--- incubator/stanbol/trunk/ontologymanager/ontonet/src/test/resources/ontologies/maincharacters.owl (original)
+++ incubator/stanbol/trunk/ontologymanager/ontonet/src/test/resources/ontologies/maincharacters.owl Wed Jun 20 09:42:24 2012
@@ -40,6 +40,7 @@
 
 Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an &quot;AS IS&quot; 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.
         </owl:versionInfo>
+        <owl:imports rdf:resource="http://xmlns.com/foaf/0.1/"/>
     </owl:Ontology>
     
 

Modified: incubator/stanbol/trunk/ontologymanager/ontonet/src/test/resources/ontologies/minorcharacters.owl
URL: http://svn.apache.org/viewvc/incubator/stanbol/trunk/ontologymanager/ontonet/src/test/resources/ontologies/minorcharacters.owl?rev=1352018&r1=1352017&r2=1352018&view=diff
==============================================================================
--- incubator/stanbol/trunk/ontologymanager/ontonet/src/test/resources/ontologies/minorcharacters.owl (original)
+++ incubator/stanbol/trunk/ontologymanager/ontonet/src/test/resources/ontologies/minorcharacters.owl Wed Jun 20 09:42:24 2012
@@ -40,6 +40,7 @@
 
 Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an &quot;AS IS&quot; 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.
         </owl:versionInfo>
+        <owl:imports rdf:resource="http://xmlns.com/foaf/0.1/"/>
     </owl:Ontology>
     
 

Modified: incubator/stanbol/trunk/ontologymanager/ontonet/src/test/resources/ontologies/mockfoaf.rdf
URL: http://svn.apache.org/viewvc/incubator/stanbol/trunk/ontologymanager/ontonet/src/test/resources/ontologies/mockfoaf.rdf?rev=1352018&r1=1352017&r2=1352018&view=diff
==============================================================================
--- incubator/stanbol/trunk/ontologymanager/ontonet/src/test/resources/ontologies/mockfoaf.rdf (original)
+++ incubator/stanbol/trunk/ontologymanager/ontonet/src/test/resources/ontologies/mockfoaf.rdf Wed Jun 20 09:42:24 2012
@@ -16,7 +16,8 @@
   limitations under the License.
 -->
 
-<rdf:RDF 
+<rdf:RDF
+	xml:base="http://xmlns.com/foaf/0.1/"
 	xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" 
 	xmlns:rdfs="http://www.w3.org/2000/01/rdf-schema#" 
 	xmlns:owl="http://www.w3.org/2002/07/owl#" 

Modified: incubator/stanbol/trunk/ontologymanager/ontonet/src/test/resources/ontologies/test1.owl
URL: http://svn.apache.org/viewvc/incubator/stanbol/trunk/ontologymanager/ontonet/src/test/resources/ontologies/test1.owl?rev=1352018&r1=1352017&r2=1352018&view=diff
==============================================================================
--- incubator/stanbol/trunk/ontologymanager/ontonet/src/test/resources/ontologies/test1.owl (original)
+++ incubator/stanbol/trunk/ontologymanager/ontonet/src/test/resources/ontologies/test1.owl Wed Jun 20 09:42:24 2012
@@ -30,16 +30,8 @@
      xmlns:owl="http://www.w3.org/2002/07/owl#"
      xmlns:xsd="http://www.w3.org/2001/XMLSchema#"
      xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#">
-    <owl:Ontology rdf:about="http://stanbol.apache.org/ontologies/test1.owl">
-		<owl:versionInfo xml:lang="en">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 &quot;License&quot;); 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 &quot;AS IS&quot; 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.
-		</owl:versionInfo>
-		<rdfs:comment>A dummy model whose only purpose if to test the presence of its members.</rdfs:comment>
-    </owl:Ontology>
-    
 
 
     <!-- 
@@ -73,7 +65,7 @@ Unless required by applicable law or agr
     ///////////////////////////////////////////////////////////////////////////////////////
      -->
 
-    
+ 
 
 
     <!-- http://stanbol.apache.org/ontologies/test1.owl#aboutFiction -->
@@ -348,6 +340,17 @@ Unless required by applicable law or agr
             <rdf:Description rdf:about="http://stanbol.apache.org/ontologies/test1.owl#Fish"/>
         </owl:unionOf>
     </owl:Class>
+    
+    <owl:Ontology rdf:about="http://stanbol.apache.org/ontologies/test1.owl">
+		<owl:versionInfo xml:lang="en">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 &quot;License&quot;); 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 &quot;AS IS&quot; 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.
+		</owl:versionInfo>
+		<rdfs:comment>A dummy model whose only purpose if to test the presence of its members.</rdfs:comment>
+    </owl:Ontology>
+    
 </rdf:RDF>
 
 

Added: incubator/stanbol/trunk/ontologymanager/ontonet/src/test/resources/ontologies/versiontest_v1.owl
URL: http://svn.apache.org/viewvc/incubator/stanbol/trunk/ontologymanager/ontonet/src/test/resources/ontologies/versiontest_v1.owl?rev=1352018&view=auto
==============================================================================
--- incubator/stanbol/trunk/ontologymanager/ontonet/src/test/resources/ontologies/versiontest_v1.owl (added)
+++ incubator/stanbol/trunk/ontologymanager/ontonet/src/test/resources/ontologies/versiontest_v1.owl Wed Jun 20 09:42:24 2012
@@ -0,0 +1,110 @@
+<?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 rdf:RDF [
+    <!ENTITY owl "http://www.w3.org/2002/07/owl#" >
+    <!ENTITY xsd "http://www.w3.org/2001/XMLSchema#" >
+    <!ENTITY rdfs "http://www.w3.org/2000/01/rdf-schema#" >
+    <!ENTITY rdf "http://www.w3.org/1999/02/22-rdf-syntax-ns#" >
+]>
+
+
+<rdf:RDF xmlns="http://stanbol.apache.org/ontologies/versiontest#"
+     xml:base="http://stanbol.apache.org/ontologies/versiontest"
+     xmlns:rdfs="http://www.w3.org/2000/01/rdf-schema#"
+     xmlns:owl="http://www.w3.org/2002/07/owl#"
+     xmlns:xsd="http://www.w3.org/2001/XMLSchema#"
+     xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#">
+    <owl:Ontology rdf:about="http://stanbol.apache.org/ontologies/versiontest">
+        <owl:versionInfo xml:lang="en">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 &quot;License&quot;); 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 &quot;AS IS&quot; 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.
+		</owl:versionInfo>
+        <owl:versionIRI rdf:resource="http://stanbol.apache.org/ontologies/version/1"/>
+    </owl:Ontology>
+    
+
+
+    <!-- 
+    ///////////////////////////////////////////////////////////////////////////////////////
+    //
+    // Annotation properties
+    //
+    ///////////////////////////////////////////////////////////////////////////////////////
+     -->
+
+    
+
+
+    <!-- 
+    ///////////////////////////////////////////////////////////////////////////////////////
+    //
+    // Datatypes
+    //
+    ///////////////////////////////////////////////////////////////////////////////////////
+     -->
+
+    
+
+
+    <!-- 
+    ///////////////////////////////////////////////////////////////////////////////////////
+    //
+    // Classes
+    //
+    ///////////////////////////////////////////////////////////////////////////////////////
+     -->
+
+    
+
+
+    <!-- http://stanbol.apache.org/ontologies/versiontest#Clazz1 -->
+
+    <owl:Class rdf:about="http://stanbol.apache.org/ontologies/versiontest#Clazz1">
+        <rdfs:label xml:lang="en">Clazz 1</rdfs:label>
+        <rdfs:comment xml:lang="en">Dummy type used for checking its absence in another ontology with the same ontology IRI but a different version IRI.</rdfs:comment>
+    </owl:Class>
+    
+
+
+    <!-- 
+    ///////////////////////////////////////////////////////////////////////////////////////
+    //
+    // Individuals
+    //
+    ///////////////////////////////////////////////////////////////////////////////////////
+     -->
+
+    
+
+
+    <!-- http://stanbol.apache.org/ontologies/versiontest#SharedIndividual1 -->
+
+    <owl:NamedIndividual rdf:about="http://stanbol.apache.org/ontologies/versiontest#SharedIndividual1">
+        <rdf:type rdf:resource="http://stanbol.apache.org/ontologies/versiontest#Clazz1"/>
+        <rdfs:label xml:lang="en">shared individual 1</rdfs:label>
+        <rdfs:comment xml:lang="en">An individual for whom axioms are featured on two ontologies with different versions</rdfs:comment>
+    </owl:NamedIndividual>
+</rdf:RDF>
+
+
+
+<!-- Generated by the OWL API (version 3.2.3.1824) http://owlapi.sourceforge.net -->
+

Added: incubator/stanbol/trunk/ontologymanager/ontonet/src/test/resources/ontologies/versiontest_v2.owl
URL: http://svn.apache.org/viewvc/incubator/stanbol/trunk/ontologymanager/ontonet/src/test/resources/ontologies/versiontest_v2.owl?rev=1352018&view=auto
==============================================================================
--- incubator/stanbol/trunk/ontologymanager/ontonet/src/test/resources/ontologies/versiontest_v2.owl (added)
+++ incubator/stanbol/trunk/ontologymanager/ontonet/src/test/resources/ontologies/versiontest_v2.owl Wed Jun 20 09:42:24 2012
@@ -0,0 +1,114 @@
+<?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 rdf:RDF [
+    <!ENTITY owl "http://www.w3.org/2002/07/owl#" >
+    <!ENTITY xsd "http://www.w3.org/2001/XMLSchema#" >
+    <!ENTITY rdfs "http://www.w3.org/2000/01/rdf-schema#" >
+    <!ENTITY rdf "http://www.w3.org/1999/02/22-rdf-syntax-ns#" >
+    <!ENTITY versiontest "http://stanbol.apache.org/ontologies/versiontest#" >
+]>
+
+
+<rdf:RDF xmlns="http://stanbol.apache.org/ontologies/versiontest#"
+     xml:base="http://stanbol.apache.org/ontologies/versiontest"
+     xmlns:rdfs="http://www.w3.org/2000/01/rdf-schema#"
+     xmlns:owl="http://www.w3.org/2002/07/owl#"
+     xmlns:xsd="http://www.w3.org/2001/XMLSchema#"
+     xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
+     xmlns:versiontest="http://stanbol.apache.org/ontologies/versiontest#">
+    <owl:Ontology rdf:about="http://stanbol.apache.org/ontologies/versiontest">
+		<owl:versionInfo xml:lang="en">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 &quot;License&quot;); 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 &quot;AS IS&quot; 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.
+		</owl:versionInfo>
+        <owl:versionIRI rdf:resource="version/2"/>
+    </owl:Ontology>
+    
+
+
+    <!-- 
+    ///////////////////////////////////////////////////////////////////////////////////////
+    //
+    // Annotation properties
+    //
+    ///////////////////////////////////////////////////////////////////////////////////////
+     -->
+
+    
+
+
+    <!-- 
+    ///////////////////////////////////////////////////////////////////////////////////////
+    //
+    // Datatypes
+    //
+    ///////////////////////////////////////////////////////////////////////////////////////
+     -->
+
+    
+
+
+    <!-- 
+    ///////////////////////////////////////////////////////////////////////////////////////
+    //
+    // Classes
+    //
+    ///////////////////////////////////////////////////////////////////////////////////////
+     -->
+
+    
+
+
+    <!-- http://stanbol.apache.org/ontologies/versiontest#Clazz1 -->
+
+    <owl:Class rdf:about="&versiontest;Clazz2">
+        <rdfs:label xml:lang="en">Clazz 2</rdfs:label>
+        <rdfs:comment xml:lang="en">Dummy type used for checking its absence in another ontology with the same ontology IRI but a different version IRI.</rdfs:comment>
+    </owl:Class>
+    
+
+
+    <!-- 
+    ///////////////////////////////////////////////////////////////////////////////////////
+    //
+    // Individuals
+    //
+    ///////////////////////////////////////////////////////////////////////////////////////
+     -->
+
+    
+
+
+    <!-- http://stanbol.apache.org/ontologies/versiontest#SharedIndividual1 -->
+
+    <!-- http://stanbol.apache.org/ontologies/versiontest#SharedIndividual1 -->
+
+    <owl:NamedIndividual rdf:about="http://stanbol.apache.org/ontologies/versiontest#SharedIndividual1">
+        <rdf:type rdf:resource="http://stanbol.apache.org/ontologies/versiontest#Clazz2"/>
+        <rdfs:label xml:lang="en">shared individual 1</rdfs:label>
+        <rdfs:comment xml:lang="en">An individual for whom axioms are featured on two ontologies with different versions</rdfs:comment>
+    </owl:NamedIndividual>
+</rdf:RDF>
+
+
+
+<!-- Generated by the OWL API (version 3.2.3.1824) http://owlapi.sourceforge.net -->
+

Modified: incubator/stanbol/trunk/ontologymanager/registry/pom.xml
URL: http://svn.apache.org/viewvc/incubator/stanbol/trunk/ontologymanager/registry/pom.xml?rev=1352018&r1=1352017&r2=1352018&view=diff
==============================================================================
--- incubator/stanbol/trunk/ontologymanager/registry/pom.xml (original)
+++ incubator/stanbol/trunk/ontologymanager/registry/pom.xml Wed Jun 20 09:42:24 2012
@@ -87,7 +87,7 @@
     <dependency>
       <groupId>org.apache.stanbol</groupId>
       <artifactId>org.apache.stanbol.ontologymanager.ontonet</artifactId>
-      <version>0.9.0-incubating</version>
+      <version>0.10.0-incubating-SNAPSHOT</version>
     </dependency>
     <dependency>
       <groupId>org.apache.stanbol</groupId>

Modified: incubator/stanbol/trunk/ontologymanager/registry/src/main/java/org/apache/stanbol/ontologymanager/registry/impl/model/LibraryImpl.java
URL: http://svn.apache.org/viewvc/incubator/stanbol/trunk/ontologymanager/registry/src/main/java/org/apache/stanbol/ontologymanager/registry/impl/model/LibraryImpl.java?rev=1352018&r1=1352017&r2=1352018&view=diff
==============================================================================
--- incubator/stanbol/trunk/ontologymanager/registry/src/main/java/org/apache/stanbol/ontologymanager/registry/impl/model/LibraryImpl.java (original)
+++ incubator/stanbol/trunk/ontologymanager/registry/src/main/java/org/apache/stanbol/ontologymanager/registry/impl/model/LibraryImpl.java Wed Jun 20 09:42:24 2012
@@ -161,7 +161,7 @@ public class LibraryImpl extends Abstrac
                 IRI id = o.getIRI();
                 try {
                     // No preferred key, we don't have a prefix here.
-                    String key = loader.loadInStore(id, null, null, false);
+                    String key = loader.loadInStore(id, null, false);
                     if (key == null || key.isEmpty()) log.error(
                         "Empty storage key. Ontology {} was apparently not stored.", id);
                 } catch (IOException ex) {

Modified: incubator/stanbol/trunk/ontologymanager/registry/src/main/java/org/apache/stanbol/ontologymanager/registry/io/LibrarySource.java
URL: http://svn.apache.org/viewvc/incubator/stanbol/trunk/ontologymanager/registry/src/main/java/org/apache/stanbol/ontologymanager/registry/io/LibrarySource.java?rev=1352018&r1=1352017&r2=1352018&view=diff
==============================================================================
--- incubator/stanbol/trunk/ontologymanager/registry/src/main/java/org/apache/stanbol/ontologymanager/registry/io/LibrarySource.java (original)
+++ incubator/stanbol/trunk/ontologymanager/registry/src/main/java/org/apache/stanbol/ontologymanager/registry/io/LibrarySource.java Wed Jun 20 09:42:24 2012
@@ -22,8 +22,8 @@ import org.apache.stanbol.commons.owl.OW
 import org.apache.stanbol.ontologymanager.ontonet.api.OfflineConfiguration;
 import org.apache.stanbol.ontologymanager.ontonet.api.io.AbstractOWLOntologyInputSource;
 import org.apache.stanbol.ontologymanager.ontonet.api.io.OntologyInputSource;
-import org.apache.stanbol.ontologymanager.ontonet.api.io.OntologySetInputSource;
 import org.apache.stanbol.ontologymanager.ontonet.api.io.RootOntologySource;
+import org.apache.stanbol.ontologymanager.ontonet.api.io.SetInputSource;
 import org.apache.stanbol.ontologymanager.ontonet.impl.util.OntologyUtils;
 import org.apache.stanbol.ontologymanager.registry.api.RegistryContentException;
 import org.apache.stanbol.ontologymanager.registry.api.RegistryManager;
@@ -42,7 +42,7 @@ import org.slf4j.LoggerFactory;
  * ontology, either new or supplied by the developer. This input source can either accept an already built
  * {@link LibraryImpl} object, or parse a library OWL file from its logical URI.
  */
-public class LibrarySource extends AbstractOWLOntologyInputSource implements OntologySetInputSource {
+public class LibrarySource extends AbstractOWLOntologyInputSource implements SetInputSource {
 
     /**
      * Creates a new ontology manager that shares the same offline configuration as the registry manager.

Modified: incubator/stanbol/trunk/ontologymanager/web/pom.xml
URL: http://svn.apache.org/viewvc/incubator/stanbol/trunk/ontologymanager/web/pom.xml?rev=1352018&r1=1352017&r2=1352018&view=diff
==============================================================================
--- incubator/stanbol/trunk/ontologymanager/web/pom.xml (original)
+++ incubator/stanbol/trunk/ontologymanager/web/pom.xml Wed Jun 20 09:42:24 2012
@@ -106,7 +106,7 @@
     <dependency>
       <groupId>org.apache.stanbol</groupId>
       <artifactId>org.apache.stanbol.ontologymanager.registry</artifactId>
-      <version>0.9.0-incubating</version>
+      <version>0.10.0-incubating-SNAPSHOT</version>
     </dependency>
     <dependency>
       <groupId>org.apache.stanbol</groupId>

Modified: incubator/stanbol/trunk/ontologymanager/web/src/main/java/org/apache/stanbol/ontologymanager/web/resources/OntoNetRootResource.java
URL: http://svn.apache.org/viewvc/incubator/stanbol/trunk/ontologymanager/web/src/main/java/org/apache/stanbol/ontologymanager/web/resources/OntoNetRootResource.java?rev=1352018&r1=1352017&r2=1352018&view=diff
==============================================================================
--- incubator/stanbol/trunk/ontologymanager/web/src/main/java/org/apache/stanbol/ontologymanager/web/resources/OntoNetRootResource.java (original)
+++ incubator/stanbol/trunk/ontologymanager/web/src/main/java/org/apache/stanbol/ontologymanager/web/resources/OntoNetRootResource.java Wed Jun 20 09:42:24 2012
@@ -397,7 +397,7 @@ public class OntoNetRootResource extends
         if (file != null && file.canRead() && file.exists()) {
             try {
                 InputStream content = new FileInputStream(file);
-                key = ontologyProvider.loadInStore(content, format, null, true);
+                key = ontologyProvider.loadInStore(content, format, true);
             } catch (UnsupportedFormatException e) {
                 log.warn(
                     "POST method failed for media type {}. This should not happen (should fail earlier)",
@@ -408,7 +408,7 @@ public class OntoNetRootResource extends
             }
         } else if (location != null) {
             try {
-                key = ontologyProvider.loadInStore(location, null, null, true);
+                key = ontologyProvider.loadInStore(location, null, true);
             } catch (Exception e) {
                 log.error("Failed to load ontology from " + location, e);
                 throw new WebApplicationException(e, BAD_REQUEST);
@@ -474,7 +474,7 @@ public class OntoNetRootResource extends
             || N3_TYPE.equals(mt) || N_TRIPLE_TYPE.equals(mt) || RDF_JSON_TYPE.equals(mt)) {
             String key = null;
             try {
-                key = ontologyProvider.loadInStore(content, headers.getMediaType().toString(), null, true);
+                key = ontologyProvider.loadInStore(content, headers.getMediaType().toString(), true);
                 rb = Response.ok();
             } catch (UnsupportedFormatException e) {
                 log.warn(
@@ -491,7 +491,7 @@ public class OntoNetRootResource extends
             try {
                 OntologyInputSource<OWLOntology,OWLOntologyManager> src = new OntologyContentInputSource(
                         content);
-                ontologyProvider.loadInStore(src.getRootOntology(), null, true);
+                ontologyProvider.loadInStore(src.getRootOntology(), true);
                 rb = Response.ok();
             } catch (OWLOntologyCreationException e) {
                 throw new WebApplicationException(e, INTERNAL_SERVER_ERROR);

Modified: incubator/stanbol/trunk/ontologymanager/web/src/main/java/org/apache/stanbol/ontologymanager/web/resources/ScopeResource.java
URL: http://svn.apache.org/viewvc/incubator/stanbol/trunk/ontologymanager/web/src/main/java/org/apache/stanbol/ontologymanager/web/resources/ScopeResource.java?rev=1352018&r1=1352017&r2=1352018&view=diff
==============================================================================
--- incubator/stanbol/trunk/ontologymanager/web/src/main/java/org/apache/stanbol/ontologymanager/web/resources/ScopeResource.java (original)
+++ incubator/stanbol/trunk/ontologymanager/web/src/main/java/org/apache/stanbol/ontologymanager/web/resources/ScopeResource.java Wed Jun 20 09:42:24 2012
@@ -71,6 +71,7 @@ import javax.ws.rs.core.Response.Status;
 import javax.ws.rs.core.UriInfo;
 
 import org.apache.clerezza.rdf.core.Graph;
+import org.apache.clerezza.rdf.core.TripleCollection;
 import org.apache.clerezza.rdf.core.serializedform.UnsupportedFormatException;
 import org.apache.stanbol.commons.web.base.ContextHelper;
 import org.apache.stanbol.commons.web.base.resource.BaseStanbolResource;
@@ -79,10 +80,11 @@ import org.apache.stanbol.ontologymanage
 import org.apache.stanbol.ontologymanager.ontonet.api.collector.OntologyCollectorModificationException;
 import org.apache.stanbol.ontologymanager.ontonet.api.collector.UnmodifiableOntologyCollectorException;
 import org.apache.stanbol.ontologymanager.ontonet.api.io.GraphContentInputSource;
+import org.apache.stanbol.ontologymanager.ontonet.api.io.GraphSource;
 import org.apache.stanbol.ontologymanager.ontonet.api.io.OntologyInputSource;
-import org.apache.stanbol.ontologymanager.ontonet.api.io.OntologySetInputSource;
 import org.apache.stanbol.ontologymanager.ontonet.api.io.RootOntologyIRISource;
 import org.apache.stanbol.ontologymanager.ontonet.api.io.RootOntologySource;
+import org.apache.stanbol.ontologymanager.ontonet.api.io.SetInputSource;
 import org.apache.stanbol.ontologymanager.ontonet.api.scope.OntologyScope;
 import org.apache.stanbol.ontologymanager.ontonet.api.scope.OntologySpace;
 import org.apache.stanbol.ontologymanager.registry.api.RegistryManager;
@@ -650,17 +652,24 @@ public class ScopeResource extends BaseS
             // Expand core sources
             List<OntologyInputSource<?,?>> expanded = new ArrayList<OntologyInputSource<?,?>>();
             if (coreSrc != null) {
-                if (coreSrc instanceof OntologySetInputSource) {
-                    for (OWLOntology o : ((OntologySetInputSource) coreSrc).getOntologies()) {
-                        expanded.add(new RootOntologySource(o));
+                if (coreSrc instanceof SetInputSource) {
+                    for (Object o : ((SetInputSource<?>) coreSrc).getOntologies()) {
+                        OntologyInputSource<?,?> src = null;
+                        if (o instanceof OWLOntology) src = new RootOntologySource((OWLOntology) o);
+                        else if (o instanceof TripleCollection) src = new GraphSource((TripleCollection) o);
+                        if (src != null) expanded.add(src);
                     }
-                } else expanded.add(coreSrc);
+                } else expanded.add(coreSrc); // Must be denoting a single ontology
             }
             if (custSrc != null) {
-                if (custSrc instanceof OntologySetInputSource) for (OWLOntology o : ((OntologySetInputSource) custSrc)
-                        .getOntologies())
-                    expanded.add(new RootOntologySource(o));
-                else expanded.add(custSrc);
+                if (custSrc instanceof SetInputSource) {
+                    for (Object o : ((SetInputSource<?>) custSrc).getOntologies()) {
+                        OntologyInputSource<?,?> src = null;
+                        if (o instanceof OWLOntology) src = new RootOntologySource((OWLOntology) o);
+                        else if (o instanceof TripleCollection) src = new GraphSource((TripleCollection) o);
+                        if (src != null) expanded.add(src);
+                    }
+                } else expanded.add(custSrc); // Must be denoting a single ontology
             }
             // Invoke the appropriate factory method depending on the
             // availability of a custom source.

Modified: incubator/stanbol/trunk/reengineer/base/pom.xml
URL: http://svn.apache.org/viewvc/incubator/stanbol/trunk/reengineer/base/pom.xml?rev=1352018&r1=1352017&r2=1352018&view=diff
==============================================================================
--- incubator/stanbol/trunk/reengineer/base/pom.xml (original)
+++ incubator/stanbol/trunk/reengineer/base/pom.xml Wed Jun 20 09:42:24 2012
@@ -23,7 +23,7 @@
   <parent>
     <groupId>org.apache.stanbol</groupId>
     <artifactId>stanbol-parent</artifactId>
-    <version>0.10.0-incubating-SNAPSHOT</version>
+    <version>2-incubating-SNAPSHOT</version>
     <relativePath>../../parent</relativePath>
   </parent>
 
@@ -83,12 +83,12 @@
     <dependency>
       <groupId>org.apache.stanbol</groupId>
       <artifactId>org.apache.stanbol.ontologymanager.ontonet</artifactId>
-      <version>0.9.0-incubating</version>
+      <version>0.10.0-incubating-SNAPSHOT</version>
     </dependency>
     <dependency>
       <groupId>org.apache.stanbol</groupId>
       <artifactId>org.apache.stanbol.commons.owl</artifactId>
-      <version>0.9.0-incubating</version>
+      <version>0.10.0-incubating-SNAPSHOT</version>
     </dependency>
 
     <!-- OSGi deps --> 

Modified: incubator/stanbol/trunk/reengineer/db/pom.xml
URL: http://svn.apache.org/viewvc/incubator/stanbol/trunk/reengineer/db/pom.xml?rev=1352018&r1=1352017&r2=1352018&view=diff
==============================================================================
--- incubator/stanbol/trunk/reengineer/db/pom.xml (original)
+++ incubator/stanbol/trunk/reengineer/db/pom.xml Wed Jun 20 09:42:24 2012
@@ -23,7 +23,7 @@
   <parent>
     <groupId>org.apache.stanbol</groupId>
     <artifactId>stanbol-parent</artifactId>
-    <version>0.10.0-incubating-SNAPSHOT</version>
+    <version>2-incubating-SNAPSHOT</version>
     <relativePath>../../parent</relativePath>
   </parent>
 
@@ -88,7 +88,7 @@
     <dependency>
       <groupId>org.apache.stanbol</groupId>
       <artifactId>org.apache.stanbol.ontologymanager.ontonet</artifactId>
-      <version>0.9.0-incubating</version>
+      <version>0.10.0-incubating-SNAPSHOT</version>
     </dependency>
     <dependency>
       <groupId>org.apache.stanbol</groupId>
@@ -98,7 +98,7 @@
     <dependency>
       <groupId>org.apache.stanbol</groupId>
       <artifactId>org.apache.stanbol.reengineer.base</artifactId>
-      <version>0.9.0-incubating</version>
+      <version>0.10.0-incubating-SNAPSHOT</version>
       <scope>provided</scope>
     </dependency>
 

Modified: incubator/stanbol/trunk/reengineer/db/src/test/java/org/apache/stanbol/reengineer/db/DBExtractorTest.java
URL: http://svn.apache.org/viewvc/incubator/stanbol/trunk/reengineer/db/src/test/java/org/apache/stanbol/reengineer/db/DBExtractorTest.java?rev=1352018&r1=1352017&r2=1352018&view=diff
==============================================================================
--- incubator/stanbol/trunk/reengineer/db/src/test/java/org/apache/stanbol/reengineer/db/DBExtractorTest.java (original)
+++ incubator/stanbol/trunk/reengineer/db/src/test/java/org/apache/stanbol/reengineer/db/DBExtractorTest.java Wed Jun 20 09:42:24 2012
@@ -48,7 +48,7 @@ public class DBExtractorTest {
 
         OfflineConfiguration offline = new OfflineConfigurationImpl(emptyConf);
         OntologyProvider<TcProvider> ontologyProvider = new ClerezzaOntologyProvider(tcm, offline,
-                Parser.getInstance());
+                new Parser());
 
         // Two different ontology storages, the same sparql engine and tcprovider
         OntologySpaceFactory sf = new OntologySpaceFactoryImpl(ontologyProvider, emptyConf);

Modified: incubator/stanbol/trunk/reengineer/web/pom.xml
URL: http://svn.apache.org/viewvc/incubator/stanbol/trunk/reengineer/web/pom.xml?rev=1352018&r1=1352017&r2=1352018&view=diff
==============================================================================
--- incubator/stanbol/trunk/reengineer/web/pom.xml (original)
+++ incubator/stanbol/trunk/reengineer/web/pom.xml Wed Jun 20 09:42:24 2012
@@ -22,7 +22,7 @@
   <parent>
     <groupId>org.apache.stanbol</groupId>
     <artifactId>stanbol-parent</artifactId>
-    <version>0.10.0-incubating-SNAPSHOT</version>
+    <version>2-incubating-SNAPSHOT</version>
     <relativePath>../../parent</relativePath>
   </parent>
 
@@ -73,7 +73,7 @@
     <dependency>
       <groupId>org.apache.stanbol</groupId>
       <artifactId>org.apache.stanbol.reengineer.base</artifactId>
-      <version>0.9.0-incubating</version>
+      <version>0.10.0-incubating-SNAPSHOT</version>
       <scope>provided</scope>
     </dependency>
     <dependency>
@@ -84,7 +84,7 @@
     <dependency>
       <groupId>org.apache.stanbol</groupId>
       <artifactId>org.apache.stanbol.ontologymanager.ontonet</artifactId>
-      <version>0.9.0-incubating</version>
+      <version>0.10.0-incubating-SNAPSHOT</version>
     </dependency>
 
     <!-- Clerezza dependencies -->

Modified: incubator/stanbol/trunk/reengineer/web/src/main/java/org/apache/stanbol/reengineer/web/resources/ReengineerResource.java
URL: http://svn.apache.org/viewvc/incubator/stanbol/trunk/reengineer/web/src/main/java/org/apache/stanbol/reengineer/web/resources/ReengineerResource.java?rev=1352018&r1=1352017&r2=1352018&view=diff
==============================================================================
--- incubator/stanbol/trunk/reengineer/web/src/main/java/org/apache/stanbol/reengineer/web/resources/ReengineerResource.java (original)
+++ incubator/stanbol/trunk/reengineer/web/src/main/java/org/apache/stanbol/reengineer/web/resources/ReengineerResource.java Wed Jun 20 09:42:24 2012
@@ -98,8 +98,7 @@ public class ReengineerResource extends 
     public Response countReengineers(@Context HttpHeaders headers) {
 
         return Response.ok(reengineeringManager.countReengineers()).build();
-        
-        
+
     }
 
     @GET
@@ -124,7 +123,7 @@ public class ReengineerResource extends 
             mGraph.add(new TripleImpl(semionRef, hasReengineer, reenginnerLiteral));
         }
 
-        //return Response.ok(mGraph).build();
+        // return Response.ok(mGraph).build();
         ResponseBuilder rb = Response.ok(mGraph);
         rb.header(HttpHeaders.CONTENT_TYPE, TEXT_HTML + "; charset=utf-8");
         addCORSOrigin(servletContext, rb, headers);
@@ -144,7 +143,7 @@ public class ReengineerResource extends 
         try {
             reengineerType = ReengineerType.getType(inputType);
         } catch (UnsupportedReengineerException e) {
-            //Response.status(404).build();
+            // Response.status(404).build();
             ResponseBuilder rb = Response.status(Status.NOT_FOUND);
             addCORSOrigin(servletContext, rb, headers);
             return rb.build();
@@ -163,37 +162,37 @@ public class ReengineerResource extends 
                               + httpServletRequest.getLocalPort();
                 if (outputGraph == null || outputGraph.equals("")) {
                     ontology = reengineeringManager.performReengineering(servletPath, null, dataSource);
-                    //return Response.ok().build();
+                    // return Response.ok().build();
                     ResponseBuilder rb = Response.ok();
                     addCORSOrigin(servletContext, rb, headers);
                     return rb.build();
-                    
+
                 } else {
                     ontology = reengineeringManager.performReengineering(servletPath,
                         IRI.create(outputGraph), dataSource);
 
                     store(ontology);
-                    //return Response.ok(ontology).build();
+                    // return Response.ok(ontology).build();
                     ResponseBuilder rb = Response.ok(ontology);
                     addCORSOrigin(servletContext, rb, headers);
                     return rb.build();
                 }
             } catch (ReengineeringException e) {
                 e.printStackTrace();
-                //return Response.status(500).build();
+                // return Response.status(500).build();
                 ResponseBuilder rb = Response.status(Status.BAD_REQUEST);
                 addCORSOrigin(servletContext, rb, headers);
                 return rb.build();
             }
 
         } catch (NoSuchDataSourceExpection e) {
-            //return Response.status(415).build();
+            // return Response.status(415).build();
             ResponseBuilder rb = Response.status(415);
             addCORSOrigin(servletContext, rb, headers);
             return rb.build();
-            
+
         } catch (InvalidDataSourceForTypeSelectedException e) {
-            //return Response.status(204).build();
+            // return Response.status(204).build();
             ResponseBuilder rb = Response.status(204);
             addCORSOrigin(servletContext, rb, headers);
             return rb.build();
@@ -231,14 +230,14 @@ public class ReengineerResource extends 
             try {
                 ontology = reengineeringManager.performReengineering(servletPath, IRI.create(outputGraph),
                     dataSource);
-                //return Response.ok(ontology).build();
+                // return Response.ok(ontology).build();
                 ResponseBuilder rb = Response.ok(ontology);
                 addCORSOrigin(servletContext, rb, headers);
                 return rb.build();
-                
+
             } catch (ReengineeringException e) {
-                //return Response.status(500).build();
-                
+                // return Response.status(500).build();
+
                 ResponseBuilder rb = Response.status(Status.BAD_REQUEST);
                 addCORSOrigin(servletContext, rb, headers);
                 return rb.build();
@@ -247,12 +246,12 @@ public class ReengineerResource extends 
         } else {
             try {
                 reengineeringManager.performReengineering(servletPath, null, dataSource);
-                //return Response.ok().build();
+                // return Response.ok().build();
                 ResponseBuilder rb = Response.ok();
                 addCORSOrigin(servletContext, rb, headers);
                 return rb.build();
             } catch (ReengineeringException e) {
-                //return Response.status(500).build();
+                // return Response.status(500).build();
                 ResponseBuilder rb = Response.status(Status.BAD_REQUEST);
                 addCORSOrigin(servletContext, rb, headers);
                 return rb.build();
@@ -294,12 +293,12 @@ public class ReengineerResource extends 
                  * MediaType mediaType = headers.getMediaType(); String res =
                  * OntologyRenderUtils.renderOntology(ontology, mediaType.getType());
                  */
-                //return Response.ok(ontology).build();
+                // return Response.ok(ontology).build();
                 ResponseBuilder rb = Response.ok(ontology);
                 addCORSOrigin(servletContext, rb, headers);
                 return rb.build();
             } catch (ReengineeringException e) {
-                //return Response.status(500).build();
+                // return Response.status(500).build();
                 ResponseBuilder rb = Response.status(Status.BAD_REQUEST);
                 addCORSOrigin(servletContext, rb, headers);
                 return rb.build();
@@ -307,12 +306,12 @@ public class ReengineerResource extends 
         } else {
             try {
                 reengineeringManager.performSchemaReengineering(servletPath, null, dataSource);
-                //return Response.ok().build();
+                // return Response.ok().build();
                 ResponseBuilder rb = Response.ok();
                 addCORSOrigin(servletContext, rb, headers);
                 return rb.build();
             } catch (ReengineeringException e) {
-                //return Response.status(500).build();
+                // return Response.status(500).build();
                 ResponseBuilder rb = Response.status(Status.BAD_REQUEST);
                 addCORSOrigin(servletContext, rb, headers);
                 return rb.build();
@@ -361,7 +360,7 @@ public class ReengineerResource extends 
                     return rb.build();
                 }
             } catch (ReengineeringException e) {
-                //return Response.status(500).build();
+                // return Response.status(500).build();
                 ResponseBuilder rb = Response.status(Status.BAD_REQUEST);
                 addCORSOrigin(servletContext, rb, headers);
                 return rb.build();
@@ -391,7 +390,7 @@ public class ReengineerResource extends 
         // MGraph mg = JenaToClerezzaConverter.jenaModelToClerezzaMGraph(om);
         TripleCollection mg = OWLAPIToClerezzaConverter.owlOntologyToClerezzaMGraph(o);
         MGraph mg2 = null;
-        IRI iri = OWLUtils.guessOntologyIdentifier(o);
+        IRI iri = OWLUtils.guessOntologyIdentifier(o).getOntologyIRI();
         UriRef ref = new UriRef(iri.toString());
         try {
             mg2 = tcManager.createMGraph(ref);
@@ -402,7 +401,7 @@ public class ReengineerResource extends 
 
         mg2.addAll(mg);
     }
-    
+
     @OPTIONS
     public Response handleCorsPreflight(@Context HttpHeaders headers) {
         ResponseBuilder rb = Response.ok();

Modified: incubator/stanbol/trunk/reengineer/xml/pom.xml
URL: http://svn.apache.org/viewvc/incubator/stanbol/trunk/reengineer/xml/pom.xml?rev=1352018&r1=1352017&r2=1352018&view=diff
==============================================================================
--- incubator/stanbol/trunk/reengineer/xml/pom.xml (original)
+++ incubator/stanbol/trunk/reengineer/xml/pom.xml Wed Jun 20 09:42:24 2012
@@ -23,7 +23,7 @@
   <parent>
     <groupId>org.apache.stanbol</groupId>
     <artifactId>stanbol-parent</artifactId>
-    <version>0.10.0-incubating-SNAPSHOT</version>
+    <version>2-incubating-SNAPSHOT</version>
     <relativePath>../../parent</relativePath>
   </parent>
 
@@ -92,7 +92,7 @@
     <dependency>
       <groupId>org.apache.stanbol</groupId>
       <artifactId>org.apache.stanbol.ontologymanager.ontonet</artifactId>
-      <version>0.9.0-incubating</version>
+      <version>0.10.0-incubating-SNAPSHOT</version>
     </dependency>
     <dependency>
       <groupId>org.apache.stanbol</groupId>
@@ -102,7 +102,7 @@
     <dependency>
       <groupId>org.apache.stanbol</groupId>
       <artifactId>org.apache.stanbol.reengineer.base</artifactId>
-      <version>0.9.0-incubating</version>
+      <version>0.10.0-incubating-SNAPSHOT</version>
       <scope>provided</scope>
     </dependency>
 

Modified: incubator/stanbol/trunk/reengineer/xml/src/test/java/org/apache/stanbol/reengineer/xml/XMLReengineerTest.java
URL: http://svn.apache.org/viewvc/incubator/stanbol/trunk/reengineer/xml/src/test/java/org/apache/stanbol/reengineer/xml/XMLReengineerTest.java?rev=1352018&r1=1352017&r2=1352018&view=diff
==============================================================================
--- incubator/stanbol/trunk/reengineer/xml/src/test/java/org/apache/stanbol/reengineer/xml/XMLReengineerTest.java (original)
+++ incubator/stanbol/trunk/reengineer/xml/src/test/java/org/apache/stanbol/reengineer/xml/XMLReengineerTest.java Wed Jun 20 09:42:24 2012
@@ -23,17 +23,19 @@ import java.util.Dictionary;
 import java.util.Hashtable;
 
 import org.apache.clerezza.rdf.core.access.TcManager;
+import org.apache.clerezza.rdf.core.access.TcProvider;
 import org.apache.clerezza.rdf.core.access.WeightedTcProvider;
 import org.apache.clerezza.rdf.core.serializedform.Parser;
-import org.apache.clerezza.rdf.core.serializedform.Serializer;
 import org.apache.clerezza.rdf.core.sparql.QueryEngine;
 import org.apache.clerezza.rdf.jena.sparql.JenaSparqlEngine;
 import org.apache.clerezza.rdf.simple.storage.SimpleTcProvider;
 import org.apache.stanbol.ontologymanager.ontonet.api.ONManager;
 import org.apache.stanbol.ontologymanager.ontonet.api.OfflineConfiguration;
+import org.apache.stanbol.ontologymanager.ontonet.api.ontology.OntologyProvider;
 import org.apache.stanbol.ontologymanager.ontonet.impl.ONManagerImpl;
 import org.apache.stanbol.ontologymanager.ontonet.impl.OfflineConfigurationImpl;
 import org.apache.stanbol.ontologymanager.ontonet.impl.clerezza.ClerezzaOntologyProvider;
+import org.apache.stanbol.ontologymanager.ontonet.impl.clerezza.OntologySpaceFactoryImpl;
 import org.apache.stanbol.reengineer.base.api.DataSource;
 import org.apache.stanbol.reengineer.base.api.Reengineer;
 import org.apache.stanbol.reengineer.base.api.util.ReengineerType;
@@ -123,8 +125,10 @@ public class XMLReengineerTest {
         TcManager tcm = new SpecialTcManager(qe, wtcp);
 
         // Two different ontology storages, the same sparql engine and tcprovider
-        ONManager onManager = new ONManagerImpl(new ClerezzaOntologyProvider(tcm, offline, new Parser()),
-                offline, emptyConf);
+
+        OntologyProvider<TcProvider> provider = new ClerezzaOntologyProvider(tcm, offline, new Parser());
+        ONManager onManager = new ONManagerImpl(provider, offline, new OntologySpaceFactoryImpl(provider,
+                emptyConf), emptyConf);
         xmlExtractor = new XMLExtractor(new ReengineerManagerImpl(emptyConf), onManager, emptyConf);
     }