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/02/23 19:51:19 UTC

svn commit: r1292893 [1/2] - in /incubator/stanbol/trunk: commons/owl/src/main/java/org/apache/stanbol/commons/owl/transformation/ commons/owl/src/main/java/org/apache/stanbol/commons/owl/web/ data/ data/bundlelist/src/main/bundles/ data/registries/ da...

Author: alexdma
Date: Thu Feb 23 18:51:17 2012
New Revision: 1292893

URL: http://svn.apache.org/viewvc?rev=1292893&view=rev
Log:
STANBOL-410 :
- Registry Manager now supports the Stanbol DataFileProvider for retrieving registries (TODO? use it also for retrieving referenced ontologies, but this would imply a change in the metamodel).
- Registry Manager now works better offline : by default it is configured so that it will not fail when the registry metamodel cannot be fetched (e.g. in offline mode or when there is no import statement for meta.owl). 
- library <--> ontology references are detected when interpreted either as annotations or as object property values.
- Thanks to the changes above, the Stanbol default ontology network (registry) is now included in a default data bundle.

Added:
    incubator/stanbol/trunk/data/registries/
    incubator/stanbol/trunk/data/registries/default/   (with props)
    incubator/stanbol/trunk/data/registries/default/pom.xml
    incubator/stanbol/trunk/data/registries/default/src/
    incubator/stanbol/trunk/data/registries/default/src/main/
    incubator/stanbol/trunk/data/registries/default/src/main/resources/
    incubator/stanbol/trunk/data/registries/default/src/main/resources/org/
    incubator/stanbol/trunk/data/registries/default/src/main/resources/org/apache/
    incubator/stanbol/trunk/data/registries/default/src/main/resources/org/apache/stanbol/
    incubator/stanbol/trunk/data/registries/default/src/main/resources/org/apache/stanbol/data/
    incubator/stanbol/trunk/data/registries/default/src/main/resources/org/apache/stanbol/data/registries/
    incubator/stanbol/trunk/data/registries/default/src/main/resources/org/apache/stanbol/data/registries/default/
    incubator/stanbol/trunk/data/registries/default/src/main/resources/org/apache/stanbol/data/registries/default/stanbol_network.owl
Removed:
    incubator/stanbol/trunk/commons/owl/src/main/java/org/apache/stanbol/commons/owl/web/KRFormat.java
Modified:
    incubator/stanbol/trunk/commons/owl/src/main/java/org/apache/stanbol/commons/owl/transformation/JenaToOwlConvert.java
    incubator/stanbol/trunk/commons/owl/src/main/java/org/apache/stanbol/commons/owl/web/OWLOntologyWriter.java
    incubator/stanbol/trunk/data/bundlelist/src/main/bundles/list.xml
    incubator/stanbol/trunk/data/pom.xml
    incubator/stanbol/trunk/ontologymanager/ontonet/pom.xml
    incubator/stanbol/trunk/ontologymanager/registry/pom.xml
    incubator/stanbol/trunk/ontologymanager/registry/src/main/java/org/apache/stanbol/ontologymanager/registry/api/RegistryItemFactory.java
    incubator/stanbol/trunk/ontologymanager/registry/src/main/java/org/apache/stanbol/ontologymanager/registry/api/RegistryManager.java
    incubator/stanbol/trunk/ontologymanager/registry/src/main/java/org/apache/stanbol/ontologymanager/registry/impl/RegistryItemFactoryImpl.java
    incubator/stanbol/trunk/ontologymanager/registry/src/main/java/org/apache/stanbol/ontologymanager/registry/impl/RegistryManagerImpl.java
    incubator/stanbol/trunk/ontologymanager/registry/src/main/resources/OSGI-INF/metatype/metatype.properties
    incubator/stanbol/trunk/ontologymanager/store/parent/pom.xml
    incubator/stanbol/trunk/ontologymanager/web/pom.xml
    incubator/stanbol/trunk/ontologymanager/web/src/main/java/org/apache/stanbol/ontologymanager/web/resources/StoredOntologyResource.java
    incubator/stanbol/trunk/ontologymanager/web/src/main/resources/org/apache/stanbol/ontologymanager/web/templates/org/apache/stanbol/ontologymanager/web/resources/OntoNetRootResource/index.ftl
    incubator/stanbol/trunk/ontologymanager/web/src/main/resources/org/apache/stanbol/ontologymanager/web/templates/org/apache/stanbol/ontologymanager/web/resources/OntologyNetworkResource/index.ftl

Modified: incubator/stanbol/trunk/commons/owl/src/main/java/org/apache/stanbol/commons/owl/transformation/JenaToOwlConvert.java
URL: http://svn.apache.org/viewvc/incubator/stanbol/trunk/commons/owl/src/main/java/org/apache/stanbol/commons/owl/transformation/JenaToOwlConvert.java?rev=1292893&r1=1292892&r2=1292893&view=diff
==============================================================================
--- incubator/stanbol/trunk/commons/owl/src/main/java/org/apache/stanbol/commons/owl/transformation/JenaToOwlConvert.java (original)
+++ incubator/stanbol/trunk/commons/owl/src/main/java/org/apache/stanbol/commons/owl/transformation/JenaToOwlConvert.java Thu Feb 23 18:51:17 2012
@@ -1,42 +1,30 @@
 /*
-* 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.
-*/
+ * 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.
+ */
 /*
  * To change this template, choose Tools | Templates
  * and open the template in the editor.
  */
-
 package org.apache.stanbol.commons.owl.transformation;
 
-
-import com.hp.hpl.jena.ontology.AnnotationProperty;
-import com.hp.hpl.jena.ontology.DatatypeProperty;
-import com.hp.hpl.jena.ontology.ObjectProperty;
-import com.hp.hpl.jena.ontology.OntClass;
-import com.hp.hpl.jena.ontology.OntModel;
-import com.hp.hpl.jena.rdf.model.ModelFactory;
-import com.hp.hpl.jena.rdf.model.Model;
-import com.hp.hpl.jena.rdf.model.RDFNode;
-import com.hp.hpl.jena.rdf.model.Resource;
-import com.hp.hpl.jena.rdf.model.Statement;
-import com.hp.hpl.jena.rdf.model.StmtIterator;
 import java.io.ByteArrayInputStream;
 import java.io.ByteArrayOutputStream;
 import java.util.Iterator;
 import java.util.Set;
+
 import org.coode.owlapi.turtle.TurtleOntologyFormat;
 import org.semanticweb.owlapi.apibinding.OWLManager;
 import org.semanticweb.owlapi.io.RDFXMLOntologyFormat;
@@ -66,660 +54,786 @@ import org.semanticweb.owlapi.model.OWLO
 import org.semanticweb.owlapi.model.OWLOntologyStorageException;
 import org.semanticweb.owlapi.util.OWLOntologyMerger;
 
+import com.hp.hpl.jena.ontology.AnnotationProperty;
+import com.hp.hpl.jena.ontology.DatatypeProperty;
+import com.hp.hpl.jena.ontology.ObjectProperty;
+import com.hp.hpl.jena.ontology.OntClass;
+import com.hp.hpl.jena.ontology.OntModel;
+import com.hp.hpl.jena.rdf.model.Model;
+import com.hp.hpl.jena.rdf.model.ModelFactory;
+import com.hp.hpl.jena.rdf.model.RDFNode;
+import com.hp.hpl.jena.rdf.model.Resource;
+import com.hp.hpl.jena.rdf.model.Statement;
+import com.hp.hpl.jena.rdf.model.StmtIterator;
+
 /**
- *
+ * 
  * @author elvio
  * @author andrea.nuzzolese
  */
 public class JenaToOwlConvert {
 
- private boolean available = true;
- private boolean availablemain = true;
- public JenaToOwlConvert(){}
+    private boolean available = true;
+    private boolean availablemain = true;
 
-////////////////////////////////////////////////////////////////////////////////
-//////////////////////////////FUNCTIONS/////////////////////////////////////////
-////////////////////////////////////////////////////////////////////////////////
+    public JenaToOwlConvert() {}
 
+    // //////////////////////////////////////////////////////////////////////////////
+    // ////////////////////////////FUNCTIONS/////////////////////////////////////////
+    // //////////////////////////////////////////////////////////////////////////////
+
+    /**
+     * This function converts an ontology object from Jena to OWLapi
+     * 
+     * @param jenamodel
+     *            {An OntModel object}
+     * @param format
+     *            {only in "RDF/XML"}
+     * @return {An OWLOntology that is an owl object}
+     */
+    public synchronized OWLOntology ModelJenaToOwlConvert(Model jenamodel, String format) {
+
+        while (availablemain == false) {
+            try {
+                wait();
+            } catch (InterruptedException e) {
+                System.err.println("ModelJenaToOwlConvert::: " + e);
+            }
+        }
 
- /**
- * This function converts an ontology object from Jena to OWLapi
- *
- * @param jenamodel {An OntModel object}
- * @param format {only in "RDF/XML"}
- * @return {An OWLOntology  that is an owl object}
- */
-public synchronized OWLOntology ModelJenaToOwlConvert(Model jenamodel,String format){
-
-    while (availablemain == false) {
-        try {wait();} catch (InterruptedException e) {System.err.println("ModelJenaToOwlConvert::: "+e);}
-    }
+        availablemain = false;
 
-    availablemain=false;
+        try {
 
-  try{
+            ByteArrayOutputStream out = new ByteArrayOutputStream();
 
-    ByteArrayOutputStream out = new ByteArrayOutputStream();
+            if (!format.equals("RDF/XML")) {
+                System.err.println("The only format supported is RDF/XML. Please check the format!");
 
-    if(!format.equals("RDF/XML")){
-        System.err.println("The only format supported is RDF/XML. Please check the format!");
+                availablemain = true;
+                notifyAll();
+                return null;
+            } else {
 
-        availablemain = true;
-        notifyAll();
-        return null;
-    }else{
+                jenamodel.write(out, format);
 
-    jenamodel.write(out,format);
-    
-    OWLOntologyManager owlmanager = OWLManager.createOWLOntologyManager();
+                OWLOntologyManager owlmanager = OWLManager.createOWLOntologyManager();
 
-    OWLOntology owlmodel = owlmanager.loadOntologyFromOntologyDocument(new ByteArrayInputStream(out.toByteArray()));
+                OWLOntology owlmodel = owlmanager.loadOntologyFromOntologyDocument(new ByteArrayInputStream(
+                        out.toByteArray()));
 
-    availablemain = true;
-    notifyAll();
-    return owlmodel;
-    }}catch (OWLOntologyCreationException eoc){
-        System.err.print("ModelJenaToOwlConvert::: ");
-        eoc.printStackTrace();
-        return null;
+                availablemain = true;
+                notifyAll();
+                return owlmodel;
+            }
+        } catch (OWLOntologyCreationException eoc) {
+            System.err.print("ModelJenaToOwlConvert::: ");
+            eoc.printStackTrace();
+            return null;
+        }
     }
-}
 
+    /**
+     * This function converts an ontology object from Jena to OWLapi
+     * 
+     * @param jenamodel
+     *            {An OntModel object}
+     * @param format
+     *            {only in "RDF/XML"}
+     * @return {An OWLOntology that is an owl object}
+     */
+    public synchronized OWLOntology ModelJenaToOwlConvert(IRI ontologyIRI, Model jenamodel, String format) {
+
+        while (availablemain == false) {
+            try {
+                wait();
+            } catch (InterruptedException e) {
+                System.err.println("ModelJenaToOwlConvert::: " + e);
+            }
+        }
 
-/**
- * This function converts an ontology object from Jena to OWLapi
- *
- * @param jenamodel {An OntModel object}
- * @param format {only in "RDF/XML"}
- * @return {An OWLOntology  that is an owl object}
- */
-public synchronized OWLOntology ModelJenaToOwlConvert(IRI ontologyIRI, Model jenamodel,String format){
+        availablemain = false;
 
-    while (availablemain == false) {
-        try {wait();} catch (InterruptedException e) {System.err.println("ModelJenaToOwlConvert::: "+e);}
-    }
+        try {
 
-    availablemain=false;
+            ByteArrayOutputStream out = new ByteArrayOutputStream();
 
-  try{
+            if (!format.equals("RDF/XML")) {
+                System.err.println("The only format supported is RDF/XML. Please check the format!");
 
-    ByteArrayOutputStream out = new ByteArrayOutputStream();
+                availablemain = true;
+                notifyAll();
+                return null;
+            } else {
 
-    if(!format.equals("RDF/XML")){
-        System.err.println("The only format supported is RDF/XML. Please check the format!");
+                jenamodel.write(out, format);
 
-        availablemain = true;
-        notifyAll();
-        return null;
-    }else{
+                OWLOntologyManager owlmanager = OWLManager.createOWLOntologyManager();
 
-    jenamodel.write(out,format);
-    
-    OWLOntologyManager owlmanager = OWLManager.createOWLOntologyManager();
+                owlmanager.loadOntologyFromOntologyDocument(new ByteArrayInputStream(out.toByteArray()));
 
-    owlmanager.loadOntologyFromOntologyDocument(new ByteArrayInputStream(out.toByteArray()));
-    
-    OWLOntologyMerger merger = new OWLOntologyMerger(owlmanager);
+                OWLOntologyMerger merger = new OWLOntologyMerger(owlmanager);
 
-    OWLOntology ontology = merger.createMergedOntology(owlmanager, ontologyIRI);
+                OWLOntology ontology = merger.createMergedOntology(owlmanager, ontologyIRI);
 
-    availablemain = true;
-    notifyAll();
-    return ontology;
-    }}catch (OWLOntologyCreationException eoc){
-        System.err.print("ModelJenaToOwlConvert::: ");
-        eoc.printStackTrace();
-        return null;
+                availablemain = true;
+                notifyAll();
+                return ontology;
+            }
+        } catch (OWLOntologyCreationException eoc) {
+            System.err.print("ModelJenaToOwlConvert::: ");
+            eoc.printStackTrace();
+            return null;
+        }
     }
-}
-
-////////////////////////////////////////////////////////////////////////////////
 
-/**
- * This function converts an ontology object from OWLapi to Jena
- *
- * @param owlmodel {An OWLOntology object}
- * @param format {RDF/XML or TURTLE}
- * @return {An OntModel that is a Jena object}
- */
-public synchronized OntModel ModelOwlToJenaConvert(OWLOntology owlmodel,String format){
+    // //////////////////////////////////////////////////////////////////////////////
 
-    while (availablemain == false) {
-        try {wait();} catch (InterruptedException e) {System.err.println("ModelOwlToJenaConvert::: "+e);}
-    }
+    /**
+     * This function converts an ontology object from OWLapi to Jena
+     * 
+     * @param owlmodel
+     *            {An OWLOntology object}
+     * @param format
+     *            {RDF/XML or TURTLE}
+     * @return {An OntModel that is a Jena object}
+     */
+    public synchronized OntModel ModelOwlToJenaConvert(OWLOntology owlmodel, String format) {
+
+        while (availablemain == false) {
+            try {
+                wait();
+            } catch (InterruptedException e) {
+                System.err.println("ModelOwlToJenaConvert::: " + e);
+            }
+        }
 
-    availablemain=false;
+        availablemain = false;
         OWLOntologyID id;
 
-    try{
-    ByteArrayOutputStream out = new ByteArrayOutputStream();
-
-    OWLOntologyManager owlmanager = owlmodel.getOWLOntologyManager();
-
-    format = format.trim();
+        try {
+            ByteArrayOutputStream out = new ByteArrayOutputStream();
 
-    if(format.equals("TURTLE")||format.equals("RDF/XML")){
+            OWLOntologyManager owlmanager = owlmodel.getOWLOntologyManager();
 
-        if(format.equals("TURTLE"))
-          owlmanager.setOntologyFormat(owlmodel, new TurtleOntologyFormat());
-        if(format.equals("RDF/XML"))
-          owlmanager.setOntologyFormat(owlmodel,new RDFXMLOntologyFormat());
+            format = format.trim();
 
-        OWLOntologyFormat owlformat = owlmanager.getOntologyFormat(owlmodel);
-
-        owlmanager.saveOntology(owlmodel, owlformat, out);
-
-        OntModel jenamodel = ModelFactory.createOntologyModel();
-        id = owlmodel.getOntologyID();
-        jenamodel.read(new ByteArrayInputStream(out.toByteArray()),id.toString().replace("<","").replace(">",""),format);
-
-        availablemain = true;
-        notifyAll();
-        return jenamodel;
-    }else{
-        System.err.println("The only format supported is RDF/XML or TURTLE. Please check the format!");
-
-        availablemain = true;
-        notifyAll();
-        return null;
-    }}catch (OWLOntologyStorageException eos){
-        System.err.print("ModelOwlToJenaConvert::: ");
-        eos.printStackTrace();
-        return null;
-    }
-}
-////////////////////////////////////////////////////////////////////////////////
-
-
-/**
- * This function converts every statments relative to a resource in an a set of OWLAxiom objects
- *
- * @param jenadata {A resource in the form (S,P,O), it could be any kind of resource (a class, a data property, an object property and an instance) except a litteral}
- * @param format {The format of the ontology, i.e. "RDF/XML"}
- * @return {A set of axiom in the form of Set<OWLAxiom>}
- */
-public synchronized Set<OWLAxiom> ResourceJenaToOwlAxiom(Resource jenadata,String format){
+            if (format.equals("TURTLE") || format.equals("RDF/XML")) {
 
-    while (available == false) {
-        try {wait();} catch (InterruptedException e) {System.err.println("ResourceJenaToOwlAxiom::: "+e);}
+                if (format.equals("TURTLE")) owlmanager.setOntologyFormat(owlmodel,
+                    new TurtleOntologyFormat());
+                if (format.equals("RDF/XML")) owlmanager.setOntologyFormat(owlmodel,
+                    new RDFXMLOntologyFormat());
+
+                OWLOntologyFormat owlformat = owlmanager.getOntologyFormat(owlmodel);
+
+                owlmanager.saveOntology(owlmodel, owlformat, out);
+
+                OntModel jenamodel = ModelFactory.createOntologyModel();
+                id = owlmodel.getOntologyID();
+                jenamodel.read(new ByteArrayInputStream(out.toByteArray()), id.toString().replace("<", "")
+                        .replace(">", ""), format);
+
+                availablemain = true;
+                notifyAll();
+                return jenamodel;
+            } else {
+                System.err
+                        .println("The only format supported is RDF/XML or TURTLE. Please check the format!");
+
+                availablemain = true;
+                notifyAll();
+                return null;
+            }
+        } catch (OWLOntologyStorageException eos) {
+            System.err.print("ModelOwlToJenaConvert::: ");
+            eos.printStackTrace();
+            return null;
+        }
     }
 
-    available=false;
-
-    try{
-    OntModel model = ModelFactory.createOntologyModel();
+    // //////////////////////////////////////////////////////////////////////////////
 
-    StmtIterator prop = jenadata.listProperties();
-
-    while(prop.hasNext()){
-        Statement stat = prop.nextStatement();
-        model.add(stat);
-        RDFNode obj = stat.getObject();
-        if(obj.isResource()){
-           if(!obj.isURIResource()){
-               StmtIterator aux = ((Resource) obj).listProperties();
-               while(aux.hasNext()){
-                   Statement stataux = aux.nextStatement();
-                   model.add(stataux);
-               }
-           }
+    /**
+     * This function converts every statments relative to a resource in an a set of OWLAxiom objects
+     * 
+     * @param jenadata
+     *            {A resource in the form (S,P,O), it could be any kind of resource (a class, a data property,
+     *            an object property and an instance) except a litteral}
+     * @param format
+     *            {The format of the ontology, i.e. "RDF/XML"}
+     * @return {A set of axiom in the form of Set<OWLAxiom>}
+     */
+    public synchronized Set<OWLAxiom> ResourceJenaToOwlAxiom(Resource jenadata, String format) {
+
+        while (available == false) {
+            try {
+                wait();
+            } catch (InterruptedException e) {
+                System.err.println("ResourceJenaToOwlAxiom::: " + e);
+            }
         }
-    }
 
-    OWLOntology owlmodel = ModelJenaToOwlConvert(model,format);
+        available = false;
 
-    available = true;
-    notifyAll();
-    return owlmodel.getAxioms();
-    }catch (Exception e){
-        System.err.print("ResourceJenaToOwlAxiom::: ");
-        e.printStackTrace();
-        return null;
-    }
-}
-////////////////////////////////////////////////////////////////////////////////
+        try {
+            OntModel model = ModelFactory.createOntologyModel();
 
-/**
- * This function converts a set of OWLAxiom in an iterator over jena statements
- *
- * @param axioms  {A set of aximos}
- * @param format {RDF/XML or TURTLE}
- * @return {An iterator over statments}
- */
-public synchronized StmtIterator AxiomOwlToJenaResource(Set<OWLAxiom> axioms,String format){
+            StmtIterator prop = jenadata.listProperties();
 
-    while (available == false) {
-        try {wait();} catch (InterruptedException e) {System.err.println("AxiomOwlToJenaResource::: "+e);}
+            while (prop.hasNext()) {
+                Statement stat = prop.nextStatement();
+                model.add(stat);
+                RDFNode obj = stat.getObject();
+                if (obj.isResource()) {
+                    if (!obj.isURIResource()) {
+                        StmtIterator aux = ((Resource) obj).listProperties();
+                        while (aux.hasNext()) {
+                            Statement stataux = aux.nextStatement();
+                            model.add(stataux);
+                        }
+                    }
+                }
+            }
+
+            OWLOntology owlmodel = ModelJenaToOwlConvert(model, format);
+
+            available = true;
+            notifyAll();
+            return owlmodel.getAxioms();
+        } catch (Exception e) {
+            System.err.print("ResourceJenaToOwlAxiom::: ");
+            e.printStackTrace();
+            return null;
+        }
     }
 
-    available=false;
-
-    try{
-    OWLOntologyManager manager = OWLManager.createOWLOntologyManager();
-    OWLOntology ontology = manager.createOntology(IRI.create("http://www.semanticweb.org/owlapi/ontologies/ontology"));
-
-    Iterator<OWLAxiom> axiom = axioms.iterator();
-
-        while(axiom.hasNext())
-            manager.addAxiom(ontology,axiom.next());
-
-    OntModel jenamodel = ModelOwlToJenaConvert(ontology, format);
+    // //////////////////////////////////////////////////////////////////////////////
 
-    available = true;
-    notifyAll();
-    return jenamodel.listStatements();
-    }catch (OWLOntologyCreationException eoc){
-        System.err.print("AxiomOwlToJenaResource::: ");
-        eoc.printStackTrace();
-        return null;
-    }
+    /**
+     * This function converts a set of OWLAxiom in an iterator over jena statements
+     * 
+     * @param axioms
+     *            {A set of aximos}
+     * @param format
+     *            {RDF/XML or TURTLE}
+     * @return {An iterator over statments}
+     */
+    public synchronized StmtIterator AxiomOwlToJenaResource(Set<OWLAxiom> axioms, String format) {
+
+        while (available == false) {
+            try {
+                wait();
+            } catch (InterruptedException e) {
+                System.err.println("AxiomOwlToJenaResource::: " + e);
+            }
+        }
 
- }
-////////////////////////////////////////////////////////////////////////////////
+        available = false;
 
-/**
- * This function converts any thingths relatives to an OWL entity in an iterator over Jena statement
- *
- * @param entity {It could be a class, an object property or a data property}
- * @param owlmodel {OWLOntology model where to retrieve information about the entity}
- * @param format {RDF/XML or TURTLE}
- * @return {An iterator over jena statement}
- */
-public synchronized StmtIterator EntityOwlToJenaResource(OWLEntity entity,OWLOntology owlmodel,String format){
+        try {
+            OWLOntologyManager manager = OWLManager.createOWLOntologyManager();
+            OWLOntology ontology = manager.createOntology(IRI
+                    .create("http://www.semanticweb.org/owlapi/ontologies/ontology"));
+
+            Iterator<OWLAxiom> axiom = axioms.iterator();
+
+            while (axiom.hasNext())
+                manager.addAxiom(ontology, axiom.next());
+
+            OntModel jenamodel = ModelOwlToJenaConvert(ontology, format);
+
+            available = true;
+            notifyAll();
+            return jenamodel.listStatements();
+        } catch (OWLOntologyCreationException eoc) {
+            System.err.print("AxiomOwlToJenaResource::: ");
+            eoc.printStackTrace();
+            return null;
+        }
 
-    while (available == false) {
-        try {wait();} catch (InterruptedException e) {System.err.println("EntityOwlToJenaResource::: "+e);}
     }
 
-    available=false;
+    // //////////////////////////////////////////////////////////////////////////////
 
-    try{
-    OWLOntologyManager manager = OWLManager.createOWLOntologyManager();
-    OWLOntology ontology = manager.createOntology(IRI.create("http://www.semanticweb.org/owlapi/ontologies/ontology"));
+    /**
+     * This function converts any thingths relatives to an OWL entity in an iterator over Jena statement
+     * 
+     * @param entity
+     *            {It could be a class, an object property or a data property}
+     * @param owlmodel
+     *            {OWLOntology model where to retrieve information about the entity}
+     * @param format
+     *            {RDF/XML or TURTLE}
+     * @return {An iterator over jena statement}
+     */
+    public synchronized StmtIterator EntityOwlToJenaResource(OWLEntity entity,
+                                                             OWLOntology owlmodel,
+                                                             String format) {
+
+        while (available == false) {
+            try {
+                wait();
+            } catch (InterruptedException e) {
+                System.err.println("EntityOwlToJenaResource::: " + e);
+            }
+        }
 
-    //If the entity is a class
-    if(entity.isOWLClass()){
-        OWLClass owldata = entity.asOWLClass();
+        available = false;
 
-        Iterator<OWLClassAxiom> entityaxiom = owlmodel.getAxioms(owldata).iterator();
+        try {
+            OWLOntologyManager manager = OWLManager.createOWLOntologyManager();
+            OWLOntology ontology = manager.createOntology(IRI
+                    .create("http://www.semanticweb.org/owlapi/ontologies/ontology"));
 
-        while(entityaxiom.hasNext())
-            manager.addAxiom(ontology,entityaxiom.next());
+            // If the entity is a class
+            if (entity.isOWLClass()) {
+                OWLClass owldata = entity.asOWLClass();
 
-        Iterator<OWLAnnotationAssertionAxiom> annotations = entity.getAnnotationAssertionAxioms(owlmodel).iterator();
+                Iterator<OWLClassAxiom> entityaxiom = owlmodel.getAxioms(owldata).iterator();
 
-        while(annotations.hasNext())
-            manager.addAxiom(ontology,annotations.next());
-    }
+                while (entityaxiom.hasNext())
+                    manager.addAxiom(ontology, entityaxiom.next());
 
-    //If the entity is a data property
-    if(entity.isOWLDataProperty()){
-        OWLDataProperty owldata = entity.asOWLDataProperty();
+                Iterator<OWLAnnotationAssertionAxiom> annotations = entity.getAnnotationAssertionAxioms(
+                    owlmodel).iterator();
 
-        Iterator<OWLDataPropertyAxiom> entityaxiom = owlmodel.getAxioms(owldata).iterator();
+                while (annotations.hasNext())
+                    manager.addAxiom(ontology, annotations.next());
+            }
 
-        while(entityaxiom.hasNext())
-            manager.addAxiom(ontology,entityaxiom.next());
+            // If the entity is a data property
+            if (entity.isOWLDataProperty()) {
+                OWLDataProperty owldata = entity.asOWLDataProperty();
 
-        Iterator<OWLAnnotationAssertionAxiom> annotations = entity.getAnnotationAssertionAxioms(owlmodel).iterator();
+                Iterator<OWLDataPropertyAxiom> entityaxiom = owlmodel.getAxioms(owldata).iterator();
 
-        while(annotations.hasNext())
-            manager.addAxiom(ontology,annotations.next());
-    }
+                while (entityaxiom.hasNext())
+                    manager.addAxiom(ontology, entityaxiom.next());
 
-    //If the entity is an object property
-    if(entity.isOWLObjectProperty()){
-        OWLObjectProperty owldata = entity.asOWLObjectProperty();
+                Iterator<OWLAnnotationAssertionAxiom> annotations = entity.getAnnotationAssertionAxioms(
+                    owlmodel).iterator();
 
-        Iterator<OWLObjectPropertyAxiom> entityaxiom = owlmodel.getAxioms(owldata).iterator();
+                while (annotations.hasNext())
+                    manager.addAxiom(ontology, annotations.next());
+            }
 
-        while(entityaxiom.hasNext())
-            manager.addAxiom(ontology,entityaxiom.next());
+            // If the entity is an object property
+            if (entity.isOWLObjectProperty()) {
+                OWLObjectProperty owldata = entity.asOWLObjectProperty();
 
-        Iterator<OWLAnnotationAssertionAxiom> annotations = entity.getAnnotationAssertionAxioms(owlmodel).iterator();
+                Iterator<OWLObjectPropertyAxiom> entityaxiom = owlmodel.getAxioms(owldata).iterator();
 
-        while(annotations.hasNext())
-            manager.addAxiom(ontology,annotations.next());
-    }
+                while (entityaxiom.hasNext())
+                    manager.addAxiom(ontology, entityaxiom.next());
 
-    //If the entity is a data type
-    if(entity.isOWLDatatype()){
-        OWLDatatype owldata = entity.asOWLDatatype();
+                Iterator<OWLAnnotationAssertionAxiom> annotations = entity.getAnnotationAssertionAxioms(
+                    owlmodel).iterator();
 
-        Iterator<OWLDatatypeDefinitionAxiom> entityaxiom = owlmodel.getAxioms(owldata).iterator();
+                while (annotations.hasNext())
+                    manager.addAxiom(ontology, annotations.next());
+            }
 
-        while(entityaxiom.hasNext())
-            manager.addAxiom(ontology,entityaxiom.next());
+            // If the entity is a data type
+            if (entity.isOWLDatatype()) {
+                OWLDatatype owldata = entity.asOWLDatatype();
 
-        Iterator<OWLAnnotationAssertionAxiom> annotations = entity.getAnnotationAssertionAxioms(owlmodel).iterator();
+                Iterator<OWLDatatypeDefinitionAxiom> entityaxiom = owlmodel.getAxioms(owldata).iterator();
 
-        while(annotations.hasNext())
-            manager.addAxiom(ontology,annotations.next());
-    }
+                while (entityaxiom.hasNext())
+                    manager.addAxiom(ontology, entityaxiom.next());
 
-    //If the entity is an individual
-    if(entity.isOWLNamedIndividual()){
-        OWLNamedIndividual owldata = entity.asOWLNamedIndividual();
+                Iterator<OWLAnnotationAssertionAxiom> annotations = entity.getAnnotationAssertionAxioms(
+                    owlmodel).iterator();
 
-        Iterator<OWLIndividualAxiom> entityaxiom = owlmodel.getAxioms(owldata).iterator();
+                while (annotations.hasNext())
+                    manager.addAxiom(ontology, annotations.next());
+            }
 
-        while(entityaxiom.hasNext())
-            manager.addAxiom(ontology,entityaxiom.next());
+            // If the entity is an individual
+            if (entity.isOWLNamedIndividual()) {
+                OWLNamedIndividual owldata = entity.asOWLNamedIndividual();
 
-        Iterator<OWLAnnotationAssertionAxiom> annotations = entity.getAnnotationAssertionAxioms(owlmodel).iterator();
+                Iterator<OWLIndividualAxiom> entityaxiom = owlmodel.getAxioms(owldata).iterator();
 
-        while(annotations.hasNext())
-            manager.addAxiom(ontology,annotations.next());
-    }
+                while (entityaxiom.hasNext())
+                    manager.addAxiom(ontology, entityaxiom.next());
 
-    //If the entity is an annotations property
-    if(entity.isOWLAnnotationProperty()){
-        OWLAnnotationProperty owldata = entity.asOWLAnnotationProperty();
+                Iterator<OWLAnnotationAssertionAxiom> annotations = entity.getAnnotationAssertionAxioms(
+                    owlmodel).iterator();
 
-        Iterator<OWLAnnotationAxiom> entityaxiom = owlmodel.getAxioms(owldata).iterator();
+                while (annotations.hasNext())
+                    manager.addAxiom(ontology, annotations.next());
+            }
 
-        while(entityaxiom.hasNext())
-            manager.addAxiom(ontology,entityaxiom.next());
+            // If the entity is an annotations property
+            if (entity.isOWLAnnotationProperty()) {
+                OWLAnnotationProperty owldata = entity.asOWLAnnotationProperty();
 
-        Iterator<OWLAnnotationAssertionAxiom> annotations = entity.getAnnotationAssertionAxioms(owlmodel).iterator();
+                Iterator<OWLAnnotationAxiom> entityaxiom = owlmodel.getAxioms(owldata).iterator();
 
-        while(annotations.hasNext())
-            manager.addAxiom(ontology,annotations.next());
-    }
+                while (entityaxiom.hasNext())
+                    manager.addAxiom(ontology, entityaxiom.next());
 
-   OntModel ontmodel = ModelOwlToJenaConvert(ontology, format);
-   StmtIterator statement = ontmodel.listStatements();
+                Iterator<OWLAnnotationAssertionAxiom> annotations = entity.getAnnotationAssertionAxioms(
+                    owlmodel).iterator();
 
-   available = true;
-   notifyAll();
-   return statement;
-   }catch (OWLOntologyCreationException eoc){
-       System.err.print("EntityOwlToJenaResource::: ");
-       eoc.printStackTrace();
-       return null;
-   }
-}
-////////////////////////////////////////////////////////////////////////////////
+                while (annotations.hasNext())
+                    manager.addAxiom(ontology, annotations.next());
+            }
 
-/**
- * This function converts a single OntClass of Jena to an OWLClass of OWLAPI
- *
- * @param jenadata {Jena class object}
- * @param format {RDF/XML}
- * @return {An OWLclass}
- */
-public synchronized OWLClass ClassJenaToOwl(OntClass jenadata,String format){
+            OntModel ontmodel = ModelOwlToJenaConvert(ontology, format);
+            StmtIterator statement = ontmodel.listStatements();
 
-    while (available == false) {
-        try {wait();} catch (InterruptedException e) {System.err.println("ClassJenaToOwl::: "+e);}
+            available = true;
+            notifyAll();
+            return statement;
+        } catch (OWLOntologyCreationException eoc) {
+            System.err.print("EntityOwlToJenaResource::: ");
+            eoc.printStackTrace();
+            return null;
+        }
     }
 
-    available=false;
+    // //////////////////////////////////////////////////////////////////////////////
 
-    try{
-    OntModel model = ModelFactory.createOntologyModel();
+    /**
+     * This function converts a single OntClass of Jena to an OWLClass of OWLAPI
+     * 
+     * @param jenadata
+     *            {Jena class object}
+     * @param format
+     *            {RDF/XML}
+     * @return {An OWLclass}
+     */
+    public synchronized OWLClass ClassJenaToOwl(OntClass jenadata, String format) {
+
+        while (available == false) {
+            try {
+                wait();
+            } catch (InterruptedException e) {
+                System.err.println("ClassJenaToOwl::: " + e);
+            }
+        }
 
-    model.createClass(jenadata.getURI());
+        available = false;
 
-    OWLOntology owlmodel = ModelJenaToOwlConvert(model,format);
+        try {
+            OntModel model = ModelFactory.createOntologyModel();
 
-    available = true;
-    notifyAll();
-    return owlmodel.getClassesInSignature().iterator().next();
-    }catch (Exception e){
-        System.err.print("ClassJenaToOwl::: ");
-        e.printStackTrace();
-        return null;
-    }
-}
-////////////////////////////////////////////////////////////////////////////////
+            model.createClass(jenadata.getURI());
 
-/**
- * This function converts a single OWLClass of OWLAPI to an OntClass of Jena
- *
- * @param data {An OWLClass}
- * @param format {RDF/XML or TURTLE}
- * @return {An OntClass}
- */
-public synchronized OntClass ClassOwlToJena(OWLClass data,String format){
+            OWLOntology owlmodel = ModelJenaToOwlConvert(model, format);
 
-    while (available == false) {
-        try {wait();} catch (InterruptedException e) {System.err.println("ClassOwlToJena::: "+e);}
+            available = true;
+            notifyAll();
+            return owlmodel.getClassesInSignature().iterator().next();
+        } catch (Exception e) {
+            System.err.print("ClassJenaToOwl::: ");
+            e.printStackTrace();
+            return null;
+        }
     }
 
-    available=false;
+    // //////////////////////////////////////////////////////////////////////////////
 
-    try{
-    OWLOntologyManager manager = OWLManager.createOWLOntologyManager();
-    OWLOntology ontology = manager.createOntology(IRI.create("http://www.semanticweb.org/owlapi/ontologies/ontology"));
-
-    OWLDataFactory factory = manager.getOWLDataFactory();
-    OWLDeclarationAxiom declarationAxiom = factory.getOWLDeclarationAxiom(data);
-    manager.addAxiom(ontology, declarationAxiom);
-
-    OntModel jenamodel = ModelOwlToJenaConvert(ontology, format);
-
-    available = true;
-    notifyAll();
-    return jenamodel.getOntClass(data.getIRI().toString());
-    }catch (OWLOntologyCreationException eoc){
-        System.err.print("ClassOwlToJena::: ");
-        eoc.printStackTrace();
-        return null;
-    }
+    /**
+     * This function converts a single OWLClass of OWLAPI to an OntClass of Jena
+     * 
+     * @param data
+     *            {An OWLClass}
+     * @param format
+     *            {RDF/XML or TURTLE}
+     * @return {An OntClass}
+     */
+    public synchronized OntClass ClassOwlToJena(OWLClass data, String format) {
+
+        while (available == false) {
+            try {
+                wait();
+            } catch (InterruptedException e) {
+                System.err.println("ClassOwlToJena::: " + e);
+            }
+        }
 
-}
-////////////////////////////////////////////////////////////////////////////////
+        available = false;
 
-/**
- * This function converts a single ObjectProperty of Jena to an OWLObjectProperty of OWLAPI
- *
- * @param jenadata {Jena ObjectProperty object}
- * @param format {RDF/XML}
- * @return {An OWLObjectProperty}
- */
-public synchronized OWLObjectProperty ObjPropJenaToOwl(ObjectProperty jenadata,String format){
+        try {
+            OWLOntologyManager manager = OWLManager.createOWLOntologyManager();
+            OWLOntology ontology = manager.createOntology(IRI
+                    .create("http://www.semanticweb.org/owlapi/ontologies/ontology"));
+
+            OWLDataFactory factory = manager.getOWLDataFactory();
+            OWLDeclarationAxiom declarationAxiom = factory.getOWLDeclarationAxiom(data);
+            manager.addAxiom(ontology, declarationAxiom);
+
+            OntModel jenamodel = ModelOwlToJenaConvert(ontology, format);
+
+            available = true;
+            notifyAll();
+            return jenamodel.getOntClass(data.getIRI().toString());
+        } catch (OWLOntologyCreationException eoc) {
+            System.err.print("ClassOwlToJena::: ");
+            eoc.printStackTrace();
+            return null;
+        }
 
-    while (available == false) {
-        try {wait();} catch (InterruptedException e) {System.err.println("ClassOwlToJena::: "+e);}
     }
 
-    available=false;
+    // //////////////////////////////////////////////////////////////////////////////
 
-    try{
-    OntModel model = ModelFactory.createOntologyModel();
-
-    model.createObjectProperty(jenadata.getURI());
-
-    OWLOntology owlmodel = ModelJenaToOwlConvert(model,format);
-
-    available = true;
-    notifyAll();
-    return owlmodel.getObjectPropertiesInSignature().iterator().next();
-    }catch (Exception e){
-        System.err.print("ClassOwlToJena::: ");
-        e.printStackTrace();
-        return null;
-    }
-
-}
-////////////////////////////////////////////////////////////////////////////////
+    /**
+     * This function converts a single ObjectProperty of Jena to an OWLObjectProperty of OWLAPI
+     * 
+     * @param jenadata
+     *            {Jena ObjectProperty object}
+     * @param format
+     *            {RDF/XML}
+     * @return {An OWLObjectProperty}
+     */
+    public synchronized OWLObjectProperty ObjPropJenaToOwl(ObjectProperty jenadata, String format) {
+
+        while (available == false) {
+            try {
+                wait();
+            } catch (InterruptedException e) {
+                System.err.println("ClassOwlToJena::: " + e);
+            }
+        }
 
-/**
- * This function converts a single OWLObjectProperty of owl to an ObjectProperty of Jena
- *
- * @param data {An OWLObjectProperty object}
- * @param format {RDF/XML or TURTLE}
- * @return {An ObjectProperty}
- */
+        available = false;
 
-public synchronized ObjectProperty ObjPropOwlToJena(OWLObjectProperty  data,String format){
+        try {
+            OntModel model = ModelFactory.createOntologyModel();
 
-    while (available == false) {
-        try {wait();} catch (InterruptedException e) {System.err.println("ObjPropOwlToJena::: "+e);}
-    }
+            model.createObjectProperty(jenadata.getURI());
 
-    available=false;
-try{
-    OWLOntologyManager manager = OWLManager.createOWLOntologyManager();
-    OWLOntology ontology = manager.createOntology(IRI.create("http://www.semanticweb.org/owlapi/ontologies/ontology"));
-
-    OWLDataFactory factory = manager.getOWLDataFactory();
-    OWLDeclarationAxiom declarationAxiom = factory.getOWLDeclarationAxiom(data);
-    manager.addAxiom(ontology, declarationAxiom);
-
-    OntModel jenamodel = ModelOwlToJenaConvert(ontology, format);
-
-    available = true;
-    notifyAll();
-    return jenamodel.getObjectProperty(data.getIRI().toString());
-    }catch (OWLOntologyCreationException eoc){
-        System.err.print("ObjPropOwlToJena::: ");
-        eoc.printStackTrace();
-        return null;
-   }
-}
-////////////////////////////////////////////////////////////////////////////////
+            OWLOntology owlmodel = ModelJenaToOwlConvert(model, format);
 
-/**
- * This function converts a DatatypeProperty of Jena to and OWLDataProperty of owl
- *
- * @param jenadata {Jena DatatypeProperty object}
- * @param format {RDF/XML}
- * @return {An OWLDataProperty}
- */
-public synchronized OWLDataProperty DataPropJenaToOwl(DatatypeProperty jenadata,String format){
+            available = true;
+            notifyAll();
+            return owlmodel.getObjectPropertiesInSignature().iterator().next();
+        } catch (Exception e) {
+            System.err.print("ClassOwlToJena::: ");
+            e.printStackTrace();
+            return null;
+        }
 
-    while (available == false) {
-        try {wait();} catch (InterruptedException e) {System.err.println("DataPropJenaToOwl::: "+e);}
     }
 
-    available=false;
-    try{
-    OntModel model = ModelFactory.createOntologyModel();
-
-    model.createDatatypeProperty(jenadata.getURI());
-
-    OWLOntology owlmodel = ModelJenaToOwlConvert(model,format);
-
-    available = true;
-    notifyAll();
-    return owlmodel.getDataPropertiesInSignature().iterator().next();
-   }catch (Exception e){
-       System.err.print("DataPropJenaToOwl::: ");
-       e.printStackTrace();
-       return null;
-   }
-
-}
-////////////////////////////////////////////////////////////////////////////////
+    // //////////////////////////////////////////////////////////////////////////////
 
-/**
- * This function converts a single OWLDataProperty of OWL to DatatypeProperty of Jena
- *
- * @param data {An OWLDataProperty object}
- * @param format {RDF/XML or TURTLE}
- * @return {A DatatypeProperty object}
- */
-public synchronized DatatypeProperty DataPropOwlToJena(OWLDataProperty data,String format){
+    /**
+     * This function converts a single OWLObjectProperty of owl to an ObjectProperty of Jena
+     * 
+     * @param data
+     *            {An OWLObjectProperty object}
+     * @param format
+     *            {RDF/XML or TURTLE}
+     * @return {An ObjectProperty}
+     */
+
+    public synchronized ObjectProperty ObjPropOwlToJena(OWLObjectProperty data, String format) {
+
+        while (available == false) {
+            try {
+                wait();
+            } catch (InterruptedException e) {
+                System.err.println("ObjPropOwlToJena::: " + e);
+            }
+        }
 
-    while (available == false) {
-        try {wait();} catch (InterruptedException e) {System.err.println("DataPropOwlToJena::: "+e);}
+        available = false;
+        try {
+            OWLOntologyManager manager = OWLManager.createOWLOntologyManager();
+            OWLOntology ontology = manager.createOntology(IRI
+                    .create("http://www.semanticweb.org/owlapi/ontologies/ontology"));
+
+            OWLDataFactory factory = manager.getOWLDataFactory();
+            OWLDeclarationAxiom declarationAxiom = factory.getOWLDeclarationAxiom(data);
+            manager.addAxiom(ontology, declarationAxiom);
+
+            OntModel jenamodel = ModelOwlToJenaConvert(ontology, format);
+
+            available = true;
+            notifyAll();
+            return jenamodel.getObjectProperty(data.getIRI().toString());
+        } catch (OWLOntologyCreationException eoc) {
+            System.err.print("ObjPropOwlToJena::: ");
+            eoc.printStackTrace();
+            return null;
+        }
     }
 
-    available=false;
-
-    try{
-    OWLOntologyManager manager = OWLManager.createOWLOntologyManager();
-    OWLOntology ontology = manager.createOntology(IRI.create("http://www.semanticweb.org/owlapi/ontologies/ontology"));
+    // //////////////////////////////////////////////////////////////////////////////
 
-    OWLDataFactory factory = manager.getOWLDataFactory();
-    OWLDeclarationAxiom declarationAxiom = factory.getOWLDeclarationAxiom(data);
-    manager.addAxiom(ontology, declarationAxiom);
+    /**
+     * This function converts a DatatypeProperty of Jena to and OWLDataProperty of owl
+     * 
+     * @param jenadata
+     *            {Jena DatatypeProperty object}
+     * @param format
+     *            {RDF/XML}
+     * @return {An OWLDataProperty}
+     */
+    public synchronized OWLDataProperty DataPropJenaToOwl(DatatypeProperty jenadata, String format) {
+
+        while (available == false) {
+            try {
+                wait();
+            } catch (InterruptedException e) {
+                System.err.println("DataPropJenaToOwl::: " + e);
+            }
+        }
 
-    OntModel jenamodel = ModelOwlToJenaConvert(ontology, format);
+        available = false;
+        try {
+            OntModel model = ModelFactory.createOntologyModel();
+
+            model.createDatatypeProperty(jenadata.getURI());
+
+            OWLOntology owlmodel = ModelJenaToOwlConvert(model, format);
+
+            available = true;
+            notifyAll();
+            return owlmodel.getDataPropertiesInSignature().iterator().next();
+        } catch (Exception e) {
+            System.err.print("DataPropJenaToOwl::: ");
+            e.printStackTrace();
+            return null;
+        }
 
-    available = true;
-    notifyAll();
-    return jenamodel.getDatatypeProperty(data.getIRI().toString());
-    }catch (OWLOntologyCreationException eoc){
-        System.err.print("DataPropOwlToJena::: ");
-        eoc.printStackTrace();
-        return null;
     }
 
-}
-////////////////////////////////////////////////////////////////////////////////
-
-/**
- * This function converts a single AnnotationProperty of Jena to an OWLAnnotationProperty of OWL
- *
- * @param jenadata {Jena DatatypeProperty object}
- * @param format {RDF/XML}
- * @return {An OWLAnnotationProperty object}
- */
-
-public synchronized OWLAnnotationProperty AnnotationPropJenaToOwl(AnnotationProperty jenadata,String format){
+    // //////////////////////////////////////////////////////////////////////////////
 
-    while (available == false) {
-        try {wait();} catch (InterruptedException e) {System.err.println("AnnotationPropJenaToOwl::: "+e);}
-    }
-
-    available=false;
-    try{
-    OntModel model = ModelFactory.createOntologyModel();
+    /**
+     * This function converts a single OWLDataProperty of OWL to DatatypeProperty of Jena
+     * 
+     * @param data
+     *            {An OWLDataProperty object}
+     * @param format
+     *            {RDF/XML or TURTLE}
+     * @return {A DatatypeProperty object}
+     */
+    public synchronized DatatypeProperty DataPropOwlToJena(OWLDataProperty data, String format) {
+
+        while (available == false) {
+            try {
+                wait();
+            } catch (InterruptedException e) {
+                System.err.println("DataPropOwlToJena::: " + e);
+            }
+        }
 
-    model.createAnnotationProperty(jenadata.getURI());
+        available = false;
 
-    OWLOntology owlmodel = ModelJenaToOwlConvert(model,format);
+        try {
+            OWLOntologyManager manager = OWLManager.createOWLOntologyManager();
+            OWLOntology ontology = manager.createOntology(IRI
+                    .create("http://www.semanticweb.org/owlapi/ontologies/ontology"));
+
+            OWLDataFactory factory = manager.getOWLDataFactory();
+            OWLDeclarationAxiom declarationAxiom = factory.getOWLDeclarationAxiom(data);
+            manager.addAxiom(ontology, declarationAxiom);
+
+            OntModel jenamodel = ModelOwlToJenaConvert(ontology, format);
+
+            available = true;
+            notifyAll();
+            return jenamodel.getDatatypeProperty(data.getIRI().toString());
+        } catch (OWLOntologyCreationException eoc) {
+            System.err.print("DataPropOwlToJena::: ");
+            eoc.printStackTrace();
+            return null;
+        }
 
-    available = true;
-    notifyAll();
-    return owlmodel.getAnnotationPropertiesInSignature().iterator().next();
-    }catch (Exception e){
-        System.err.print("AnnotationPropJenaToOwl::: ");
-        e.printStackTrace();
-        return null;
     }
-}
-////////////////////////////////////////////////////////////////////////////////
 
-/**
- * This function converts a single OWLAnnotationProperty of OWL to an AnnotationProperty of Jena
- *
- * @param data {An OWLAnnotationProperty object}
- * @param format {RDF/XML or TURTLE}
- * @return {An AnnotationProperty object}
+    // //////////////////////////////////////////////////////////////////////////////
 
- */
-public synchronized AnnotationProperty AnnotationPropOwlToJena(OWLAnnotationProperty data,String format){
+    /**
+     * This function converts a single AnnotationProperty of Jena to an OWLAnnotationProperty of OWL
+     * 
+     * @param jenadata
+     *            {Jena DatatypeProperty object}
+     * @param format
+     *            {RDF/XML}
+     * @return {An OWLAnnotationProperty object}
+     */
+
+    public synchronized OWLAnnotationProperty AnnotationPropJenaToOwl(AnnotationProperty jenadata,
+                                                                      String format) {
+
+        while (available == false) {
+            try {
+                wait();
+            } catch (InterruptedException e) {
+                System.err.println("AnnotationPropJenaToOwl::: " + e);
+            }
+        }
 
-    while (available == false) {
-        try {wait();} catch (InterruptedException e) {System.err.println("AnnotationPropOwlToJena::: "+e);}
+        available = false;
+        try {
+            OntModel model = ModelFactory.createOntologyModel();
+
+            model.createAnnotationProperty(jenadata.getURI());
+
+            OWLOntology owlmodel = ModelJenaToOwlConvert(model, format);
+
+            available = true;
+            notifyAll();
+            return owlmodel.getAnnotationPropertiesInSignature().iterator().next();
+        } catch (Exception e) {
+            System.err.print("AnnotationPropJenaToOwl::: ");
+            e.printStackTrace();
+            return null;
+        }
     }
 
-    available=false;
+    // //////////////////////////////////////////////////////////////////////////////
 
-    try{
-    OWLOntologyManager manager = OWLManager.createOWLOntologyManager();
-    OWLOntology ontology = manager.createOntology(IRI.create("http://www.semanticweb.org/owlapi/ontologies/ontology"));
-
-    OWLDataFactory factory = manager.getOWLDataFactory();
-    OWLDeclarationAxiom declarationAxiom = factory.getOWLDeclarationAxiom(data);
-    manager.addAxiom(ontology, declarationAxiom);
+    /**
+     * This function converts a single OWLAnnotationProperty of OWL to an AnnotationProperty of Jena
+     * 
+     * @param data
+     *            {An OWLAnnotationProperty object}
+     * @param format
+     *            {RDF/XML or TURTLE}
+     * @return {An AnnotationProperty object}
+     */
+    public synchronized AnnotationProperty AnnotationPropOwlToJena(OWLAnnotationProperty data, String format) {
+
+        while (available == false) {
+            try {
+                wait();
+            } catch (InterruptedException e) {
+                System.err.println("AnnotationPropOwlToJena::: " + e);
+            }
+        }
 
-    OntModel jenamodel = ModelOwlToJenaConvert(ontology, format);
+        available = false;
 
-    available = true;
-    notifyAll();
-    return jenamodel.getAnnotationProperty(data.getIRI().toString());
-    }catch (OWLOntologyCreationException eoc){
-        System.err.print("AnnotationPropOwlToJena::: ");
-        eoc.printStackTrace();
-        return null;
+        try {
+            OWLOntologyManager manager = OWLManager.createOWLOntologyManager();
+            OWLOntology ontology = manager.createOntology(IRI
+                    .create("http://www.semanticweb.org/owlapi/ontologies/ontology"));
+
+            OWLDataFactory factory = manager.getOWLDataFactory();
+            OWLDeclarationAxiom declarationAxiom = factory.getOWLDeclarationAxiom(data);
+            manager.addAxiom(ontology, declarationAxiom);
+
+            OntModel jenamodel = ModelOwlToJenaConvert(ontology, format);
+
+            available = true;
+            notifyAll();
+            return jenamodel.getAnnotationProperty(data.getIRI().toString());
+        } catch (OWLOntologyCreationException eoc) {
+            System.err.print("AnnotationPropOwlToJena::: ");
+            eoc.printStackTrace();
+            return null;
+        }
     }
-}
-////////////////////////////////////////////////////////////////////////////////
+    // //////////////////////////////////////////////////////////////////////////////
 
 }
-

Modified: incubator/stanbol/trunk/commons/owl/src/main/java/org/apache/stanbol/commons/owl/web/OWLOntologyWriter.java
URL: http://svn.apache.org/viewvc/incubator/stanbol/trunk/commons/owl/src/main/java/org/apache/stanbol/commons/owl/web/OWLOntologyWriter.java?rev=1292893&r1=1292892&r2=1292893&view=diff
==============================================================================
--- incubator/stanbol/trunk/commons/owl/src/main/java/org/apache/stanbol/commons/owl/web/OWLOntologyWriter.java (original)
+++ incubator/stanbol/trunk/commons/owl/src/main/java/org/apache/stanbol/commons/owl/web/OWLOntologyWriter.java Thu Feb 23 18:51:17 2012
@@ -35,6 +35,7 @@ import org.apache.clerezza.rdf.core.seri
 import org.apache.clerezza.rdf.core.serializedform.SupportedFormat;
 import org.apache.clerezza.rdf.rdfjson.serializer.RdfJsonSerializingProvider;
 import org.apache.stanbol.commons.owl.transformation.OWLAPIToClerezzaConverter;
+import org.apache.stanbol.commons.web.base.format.KRFormat;
 import org.coode.owlapi.manchesterowlsyntax.ManchesterOWLSyntaxOntologyFormat;
 import org.coode.owlapi.turtle.TurtleOntologyFormat;
 import org.semanticweb.owlapi.apibinding.OWLManager;

Modified: incubator/stanbol/trunk/data/bundlelist/src/main/bundles/list.xml
URL: http://svn.apache.org/viewvc/incubator/stanbol/trunk/data/bundlelist/src/main/bundles/list.xml?rev=1292893&r1=1292892&r2=1292893&view=diff
==============================================================================
--- incubator/stanbol/trunk/data/bundlelist/src/main/bundles/list.xml (original)
+++ incubator/stanbol/trunk/data/bundlelist/src/main/bundles/list.xml Thu Feb 23 18:51:17 2012
@@ -29,6 +29,13 @@
       <version>1.0.1-incubating-SNAPSHOT</version>
     </bundle>
   </startLevel>
+    <startLevel level="20">
+    <bundle>
+      <groupId>org.apache.stanbol</groupId>
+      <artifactId>org.apache.stanbol.data.registries.default</artifactId>
+      <version>1.0.1-incubating-SNAPSHOT</version>
+    </bundle>
+  </startLevel>
   <startLevel level="30">
     <bundle>
       <groupId>org.apache.stanbol</groupId>

Modified: incubator/stanbol/trunk/data/pom.xml
URL: http://svn.apache.org/viewvc/incubator/stanbol/trunk/data/pom.xml?rev=1292893&r1=1292892&r2=1292893&view=diff
==============================================================================
--- incubator/stanbol/trunk/data/pom.xml (original)
+++ incubator/stanbol/trunk/data/pom.xml Thu Feb 23 18:51:17 2012
@@ -55,6 +55,7 @@
         <module>sites/dbpedia</module>
         <module>opennlp/lang/en</module>
         <module>opennlp/ner/en</module>
+        <module>registries/default</module>
       </modules>
     </profile>
     <profile>

Propchange: incubator/stanbol/trunk/data/registries/default/
------------------------------------------------------------------------------
--- svn:ignore (added)
+++ svn:ignore Thu Feb 23 18:51:17 2012
@@ -0,0 +1,4 @@
+.classpath
+.project
+.settings
+target

Added: incubator/stanbol/trunk/data/registries/default/pom.xml
URL: http://svn.apache.org/viewvc/incubator/stanbol/trunk/data/registries/default/pom.xml?rev=1292893&view=auto
==============================================================================
--- incubator/stanbol/trunk/data/registries/default/pom.xml (added)
+++ incubator/stanbol/trunk/data/registries/default/pom.xml Thu Feb 23 18:51:17 2012
@@ -0,0 +1,83 @@
+<?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">
+
+  <modelVersion>4.0.0</modelVersion>
+
+  <parent>
+    <groupId>org.apache.stanbol</groupId>
+    <artifactId>org.apache.stanbol.data.parent</artifactId>
+    <version>0.9.0-incubating-SNAPSHOT</version>
+    <relativePath>../../parent</relativePath>
+  </parent>
+
+  <groupId>org.apache.stanbol</groupId>
+  <artifactId>org.apache.stanbol.data.registries.default</artifactId>
+  <version>1.0.1-incubating-SNAPSHOT</version>
+  <packaging>bundle</packaging>
+
+  <name>Apache Stanbol Data: Default ontology registries</name>
+  <description>
+    This bundle installs RDF registries that reference the most common ontologies.
+  </description>
+
+  <inceptionYear>2012</inceptionYear>
+
+  <scm>
+    <connection>
+      scm:svn:http://svn.apache.org/repos/asf/incubator/stanbol/trunk/data/registries/default
+    </connection>
+    <developerConnection>
+      scm:svn:https://svn.apache.org/repos/asf/incubator/stanbol/trunk/data/registries/default
+    </developerConnection>
+    <url>http://incubator.apache.org/stanbol/</url>
+  </scm>
+  <properties>
+    <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
+  </properties>
+
+  <build>
+    <plugins>
+      <plugin>
+        <groupId>org.apache.felix</groupId>
+        <artifactId>maven-bundle-plugin</artifactId>
+        <version>2.0.1</version>
+        <inherited>true</inherited>
+        <extensions>true</extensions>
+        <configuration>
+          <instructions>
+            <!-- Header used to load the provided configurations -->
+			<Data-Files>org/apache/stanbol/data/registries/default</Data-Files>
+			<Data-Files-Priority>-100</Data-Files-Priority>
+          </instructions>
+        </configuration>
+      </plugin>
+      <plugin>
+        <groupId>org.apache.rat</groupId>
+        <artifactId>apache-rat-plugin</artifactId>
+        <configuration>
+          <excludes>
+            <!-- License provided in src/main/resources/README -->
+          </excludes>
+        </configuration>
+      </plugin>
+     </plugins>
+  </build>
+
+</project>

Added: incubator/stanbol/trunk/data/registries/default/src/main/resources/org/apache/stanbol/data/registries/default/stanbol_network.owl
URL: http://svn.apache.org/viewvc/incubator/stanbol/trunk/data/registries/default/src/main/resources/org/apache/stanbol/data/registries/default/stanbol_network.owl?rev=1292893&view=auto
==============================================================================
--- incubator/stanbol/trunk/data/registries/default/src/main/resources/org/apache/stanbol/data/registries/default/stanbol_network.owl (added)
+++ incubator/stanbol/trunk/data/registries/default/src/main/resources/org/apache/stanbol/data/registries/default/stanbol_network.owl Thu Feb 23 18:51:17 2012
@@ -0,0 +1,90 @@
+<?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.
+-->
+<rdf:RDF
+    xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
+    xmlns:xsd="http://www.w3.org/2001/XMLSchema#"
+    xmlns:rdfs="http://www.w3.org/2000/01/rdf-schema#"
+    xmlns:owl="http://www.w3.org/2002/07/owl#"
+    xmlns:meta="http://www.ontologydesignpatterns.org/schemas/meta.owl#"
+    xmlns="http://stanbol.apache.org/ontologies/registries/stanbol_network.owl#"
+  xml:base="http://stanbol.apache.org/ontologies/registries/stanbol_network.owl">
+  <owl:Ontology rdf:about="http://www.ontologydesignpatterns.org/registry/stanbol_network.owl">
+    <owl:versionInfo rdf:datatype="http://www.w3.org/2001/XMLSchema#string"
+    >0.3.0</owl:versionInfo>
+    <owl:versionInfo xml:lang="en">Created by Alessandro Adamou</owl:versionInfo>
+    <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:imports rdf:resource="http://www.ontologydesignpatterns.org/schemas/meta.owl"/>
+  	-->
+  </owl:Ontology>
+  
+  <rdf:Description rdf:ID="SocialNetworks">
+    <rdfs:label rdf:datatype="http://www.w3.org/2001/XMLSchema#string">Social Network Models</rdfs:label>
+    <rdf:type rdf:resource="http://www.ontologydesignpatterns.org/cpont/codo/coddata.owl#OntologyLibrary"/>
+    <owl:versionInfo rdf:datatype="http://www.w3.org/2001/XMLSchema#string">0.1</owl:versionInfo>
+  </rdf:Description>
+  
+  <rdf:Description rdf:ID="W3C">
+    <rdfs:label rdf:datatype="http://www.w3.org/2001/XMLSchema#string">W3C Ontology Recommendations</rdfs:label>
+    <rdf:type rdf:resource="http://www.ontologydesignpatterns.org/cpont/codo/coddata.owl#OntologyLibrary"/>
+    <owl:versionInfo rdf:datatype="http://www.w3.org/2001/XMLSchema#string">0.1</owl:versionInfo>
+    <meta:hasOntology rdf:resource="http://w3.org/ns/org"/>
+  </rdf:Description>
+  
+  <rdf:Description rdf:ID="GeneralPurposeOntologies">
+    <rdfs:label rdf:datatype="http://www.w3.org/2001/XMLSchema#string">General Purpose Ontologies</rdfs:label>
+    <rdf:type rdf:resource="http://www.ontologydesignpatterns.org/cpont/codo/coddata.owl#OntologyLibrary"/>
+    <owl:versionInfo rdf:datatype="http://www.w3.org/2001/XMLSchema#string">0.1</owl:versionInfo>
+    <meta:hasOntology rdf:resource="http://schema.org/docs/schemaorg.owl"/>
+  </rdf:Description>
+  
+  <rdf:Description rdf:ID="Alignments">
+    <rdfs:label rdf:datatype="http://www.w3.org/2001/XMLSchema#string">Cross-vocabulary alignments</rdfs:label>
+    <rdf:type rdf:resource="http://www.ontologydesignpatterns.org/cpont/codo/coddata.owl#OntologyLibrary"/>
+    <owl:versionInfo rdf:datatype="http://www.w3.org/2001/XMLSchema#string">0.1</owl:versionInfo>
+  </rdf:Description>
+
+  <rdf:Description rdf:about="http://www.ontologydesignpatterns.org/ont/alignments/schemaorg.owl">
+    <rdfs:label rdf:datatype="http://www.w3.org/2001/XMLSchema#string">Alignments to schema.org</rdfs:label>
+    <meta:isOntologyOf rdf:resource="#Alignments"/>
+    <rdf:type rdf:resource="http://www.ontologydesignpatterns.org/cpont/codo/codkernel.owl#Ontology"/>
+  </rdf:Description>
+
+  <rdf:Description rdf:about="http://xmlns.com/foaf/spec/index.rdf">
+    <rdfs:label rdf:datatype="http://www.w3.org/2001/XMLSchema#string">Friend-Of-A-Friend</rdfs:label>
+    <meta:isOntologyOf rdf:resource="#SocialNetworks"/>
+    <rdf:type rdf:resource="http://www.ontologydesignpatterns.org/cpont/codo/codkernel.owl#Ontology"/>
+  </rdf:Description>
+
+  <rdf:Description rdf:about="http://w3.org/ns/org">
+    <rdfs:label rdf:datatype="http://www.w3.org/2001/XMLSchema#string">Organisation Ontology</rdfs:label>
+    <rdf:type rdf:resource="http://www.ontologydesignpatterns.org/cpont/codo/codkernel.owl#Ontology"/>
+  </rdf:Description>
+  
+  <rdf:Description rdf:about="http://schema.org/docs/schemaorg.owl">
+    <rdfs:label rdf:datatype="http://www.w3.org/2001/XMLSchema#string">Schema.org</rdfs:label>
+    <rdf:type rdf:resource="http://www.ontologydesignpatterns.org/cpont/codo/codkernel.owl#Ontology"/>
+  </rdf:Description>
+  
+  
+</rdf:RDF>
\ No newline at end of file

Modified: incubator/stanbol/trunk/ontologymanager/ontonet/pom.xml
URL: http://svn.apache.org/viewvc/incubator/stanbol/trunk/ontologymanager/ontonet/pom.xml?rev=1292893&r1=1292892&r2=1292893&view=diff
==============================================================================
--- incubator/stanbol/trunk/ontologymanager/ontonet/pom.xml (original)
+++ incubator/stanbol/trunk/ontologymanager/ontonet/pom.xml Thu Feb 23 18:51:17 2012
@@ -129,11 +129,11 @@
 			<groupId>junit</groupId>
 			<artifactId>junit</artifactId>
 		</dependency>
-    	<dependency>
-    		<groupId>org.slf4j</groupId>
-    		<artifactId>slf4j-simple</artifactId>
-    		<scope>test</scope>
-    	</dependency>
+		<dependency>
+			<groupId>org.apache.stanbol</groupId>
+			<artifactId>org.apache.stanbol.commons.testing.stanbol</artifactId>
+			<scope>test</scope>
+		</dependency>
 		<dependency>
 			<groupId>org.apache.clerezza</groupId>
 			<artifactId>rdf.jena.parser</artifactId>

Modified: incubator/stanbol/trunk/ontologymanager/registry/pom.xml
URL: http://svn.apache.org/viewvc/incubator/stanbol/trunk/ontologymanager/registry/pom.xml?rev=1292893&r1=1292892&r2=1292893&view=diff
==============================================================================
--- incubator/stanbol/trunk/ontologymanager/registry/pom.xml (original)
+++ incubator/stanbol/trunk/ontologymanager/registry/pom.xml Thu Feb 23 18:51:17 2012
@@ -52,11 +52,11 @@
 						</Bundle-ClassPath>
 						<Export-Package>
 							org.apache.stanbol.ontologymanager.registry.*
-	          			</Export-Package>
+						</Export-Package>
 						<Import-Package>
 							org.slf4j.*,
 							*
-            			</Import-Package>
+						</Import-Package>
 						<Private-Package>
 							org.apache.stanbol.ontologymanager.registry.xd.*
 						</Private-Package>
@@ -85,7 +85,7 @@
 			<groupId>org.apache.felix</groupId>
 			<artifactId>org.apache.felix.scr.annotations</artifactId>
 		</dependency>
-		
+
 		<!-- OWL deps -->
 		<dependency>
 			<groupId>com.hp.hpl.jena</groupId>
@@ -95,6 +95,10 @@
 		<!-- Stanbol deps -->
 		<dependency>
 			<groupId>org.apache.stanbol</groupId>
+			<artifactId>org.apache.stanbol.commons.stanboltools.datafileprovider</artifactId>
+		</dependency>
+		<dependency>
+			<groupId>org.apache.stanbol</groupId>
 			<artifactId>org.apache.stanbol.commons.stanboltools.offline</artifactId>
 		</dependency>
 		<dependency>
@@ -105,7 +109,7 @@
 			<groupId>org.apache.stanbol</groupId>
 			<artifactId>org.apache.stanbol.commons.owl</artifactId>
 		</dependency>
-		
+
 		<!-- Persistence deps -->
 		<dependency>
 			<groupId>org.apache.clerezza</groupId>
@@ -123,11 +127,11 @@
 			<groupId>junit</groupId>
 			<artifactId>junit</artifactId>
 		</dependency>
-    	<dependency>
-    		<groupId>org.slf4j</groupId>
-    		<artifactId>slf4j-simple</artifactId>
-    		<scope>test</scope>
-    	</dependency>
+		<dependency>
+			<groupId>org.apache.stanbol</groupId>
+			<artifactId>org.apache.stanbol.commons.testing.stanbol</artifactId>
+			<scope>test</scope>
+		</dependency>
 		<dependency>
 			<groupId>org.apache.clerezza</groupId>
 			<artifactId>rdf.jena.parser</artifactId>

Modified: incubator/stanbol/trunk/ontologymanager/registry/src/main/java/org/apache/stanbol/ontologymanager/registry/api/RegistryItemFactory.java
URL: http://svn.apache.org/viewvc/incubator/stanbol/trunk/ontologymanager/registry/src/main/java/org/apache/stanbol/ontologymanager/registry/api/RegistryItemFactory.java?rev=1292893&r1=1292892&r2=1292893&view=diff
==============================================================================
--- incubator/stanbol/trunk/ontologymanager/registry/src/main/java/org/apache/stanbol/ontologymanager/registry/api/RegistryItemFactory.java (original)
+++ incubator/stanbol/trunk/ontologymanager/registry/src/main/java/org/apache/stanbol/ontologymanager/registry/api/RegistryItemFactory.java Thu Feb 23 18:51:17 2012
@@ -21,7 +21,7 @@ import java.util.Set;
 import org.apache.stanbol.ontologymanager.registry.api.model.Library;
 import org.apache.stanbol.ontologymanager.registry.api.model.Registry;
 import org.apache.stanbol.ontologymanager.registry.api.model.RegistryOntology;
-import org.semanticweb.owlapi.model.OWLNamedIndividual;
+import org.semanticweb.owlapi.model.OWLNamedObject;
 import org.semanticweb.owlapi.model.OWLOntology;
 
 /**
@@ -44,7 +44,7 @@ public interface RegistryItemFactory {
      *            the named individual to extract the library model from.
      * @return the library model.
      */
-    Library createLibrary(OWLNamedIndividual ind);
+    Library createLibrary(OWLNamedObject ind);
 
     /**
      * Creates a new {@link Registry} object named after the ID of the supplied ontology.
@@ -63,6 +63,6 @@ public interface RegistryItemFactory {
      *            the named individual to extract the ontology model from.
      * @return the ontology model.
      */
-    RegistryOntology createRegistryOntology(OWLNamedIndividual ind);
+    RegistryOntology createRegistryOntology(OWLNamedObject ind);
 
 }

Modified: incubator/stanbol/trunk/ontologymanager/registry/src/main/java/org/apache/stanbol/ontologymanager/registry/api/RegistryManager.java
URL: http://svn.apache.org/viewvc/incubator/stanbol/trunk/ontologymanager/registry/src/main/java/org/apache/stanbol/ontologymanager/registry/api/RegistryManager.java?rev=1292893&r1=1292892&r2=1292893&view=diff
==============================================================================
--- incubator/stanbol/trunk/ontologymanager/registry/src/main/java/org/apache/stanbol/ontologymanager/registry/api/RegistryManager.java (original)
+++ incubator/stanbol/trunk/ontologymanager/registry/src/main/java/org/apache/stanbol/ontologymanager/registry/api/RegistryManager.java Thu Feb 23 18:51:17 2012
@@ -44,6 +44,11 @@ public interface RegistryManager extends
     public String LAZY_LOADING = "org.apache.stanbol.ontologymanager.registry.laziness";
 
     /**
+     * The key used to configure the retention policy for incomplete registries.
+     */
+    public String RETAIN_INCOMPLETE = "org.apache.stanbol.ontologymanager.registry.retainIncomplete";
+
+    /**
      * The key used to configure the locations of the registries to be scanned by the registry manager.
      */
     public String REGISTRY_LOCATIONS = "org.apache.stanbol.ontologymanager.registry.locations";

Modified: incubator/stanbol/trunk/ontologymanager/registry/src/main/java/org/apache/stanbol/ontologymanager/registry/impl/RegistryItemFactoryImpl.java
URL: http://svn.apache.org/viewvc/incubator/stanbol/trunk/ontologymanager/registry/src/main/java/org/apache/stanbol/ontologymanager/registry/impl/RegistryItemFactoryImpl.java?rev=1292893&r1=1292892&r2=1292893&view=diff
==============================================================================
--- incubator/stanbol/trunk/ontologymanager/registry/src/main/java/org/apache/stanbol/ontologymanager/registry/impl/RegistryItemFactoryImpl.java (original)
+++ incubator/stanbol/trunk/ontologymanager/registry/src/main/java/org/apache/stanbol/ontologymanager/registry/impl/RegistryItemFactoryImpl.java Thu Feb 23 18:51:17 2012
@@ -24,7 +24,7 @@ import org.apache.stanbol.ontologymanage
 import org.apache.stanbol.ontologymanager.registry.impl.model.LibraryImpl;
 import org.apache.stanbol.ontologymanager.registry.impl.model.RegistryImpl;
 import org.apache.stanbol.ontologymanager.registry.impl.model.RegistryOntologyImpl;
-import org.semanticweb.owlapi.model.OWLNamedIndividual;
+import org.semanticweb.owlapi.model.OWLNamedObject;
 import org.semanticweb.owlapi.model.OWLOntology;
 
 /**
@@ -44,7 +44,7 @@ public class RegistryItemFactoryImpl imp
     }
 
     @Override
-    public Library createLibrary(OWLNamedIndividual ind) {
+    public Library createLibrary(OWLNamedObject ind) {
         return new LibraryImpl(ind.getIRI(), ind.getIRI().getFragment(), cache);
     }
 
@@ -55,7 +55,7 @@ public class RegistryItemFactoryImpl imp
     }
 
     @Override
-    public RegistryOntology createRegistryOntology(OWLNamedIndividual ind) {
+    public RegistryOntology createRegistryOntology(OWLNamedObject ind) {
         return new RegistryOntologyImpl(ind.getIRI(), ind.getIRI().getFragment());
     }