org.deri.wsmo4j.logicalexpression.util
Class OntologyUtil

java.lang.Object
  extended by org.deri.wsmo4j.logicalexpression.util.OntologyUtil

public class OntologyUtil
extends Object

Utility class to extract concepts, instances, relations and attributes from a given ontology.

Author:
Martin Tanler, DERI Innsbruck, Nathalie Steinmetz, DERI Innsbruck

Constructor Summary
OntologyUtil()
           
 
Method Summary
static List getAttributes(org.omwg.ontology.Concept c)
          Collecting all attributes from a given concept.
static List getAttributes(org.omwg.logicalexpression.terms.Term c, org.omwg.ontology.Ontology o)
          Collecting all attributes from a given concept.
static List getConcepts(org.omwg.ontology.Ontology o)
          Collecting all concepts from a given ontology.
static List getInstances(org.omwg.ontology.Ontology o)
          Collecting all instances from a given ontology.
static List getRelations(org.omwg.ontology.Ontology o)
          Collecting all relations from a given ontology.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

OntologyUtil

public OntologyUtil()
Method Detail

getConcepts

public static List getConcepts(org.omwg.ontology.Ontology o)
                        throws org.wsmo.common.exception.SynchronisationException,
                               org.wsmo.common.exception.InvalidModelException
Collecting all concepts from a given ontology.

Parameters:
o - Ontology to be checked for contained concepts
Returns:
List of terms, identifying all concepts from the ontology
Throws:
org.wsmo.common.exception.InvalidModelException
org.wsmo.common.exception.SynchronisationException

getRelations

public static List getRelations(org.omwg.ontology.Ontology o)
                         throws org.wsmo.common.exception.SynchronisationException,
                                org.wsmo.common.exception.InvalidModelException
Collecting all relations from a given ontology.

Parameters:
o - Ontolgoy to be checked for contained relations
Returns:
List of terms, identifying all relations from the ontology
Throws:
org.wsmo.common.exception.InvalidModelException
org.wsmo.common.exception.SynchronisationException

getAttributes

public static List getAttributes(org.omwg.logicalexpression.terms.Term c,
                                 org.omwg.ontology.Ontology o)
                          throws org.wsmo.common.exception.SynchronisationException,
                                 org.wsmo.common.exception.InvalidModelException
Collecting all attributes from a given concept.

Parameters:
c - Identifier of the concept to be checked for belonging attributes.
o - Ontology to be checked for concepts and their attributes.
Returns:
List of terms, identifying all Attributes belonging to a concept
Throws:
org.wsmo.common.exception.InvalidModelException
org.wsmo.common.exception.SynchronisationException

getAttributes

public static List getAttributes(org.omwg.ontology.Concept c)
                          throws org.wsmo.common.exception.SynchronisationException,
                                 org.wsmo.common.exception.InvalidModelException
Collecting all attributes from a given concept. It is preferebly to use the method getAttributes(Term c, Ontology o) for collecting the attributes from a concept, as that method is more complete in regard to implicitly defined concepts.

Parameters:
c - Concept to be checked for belonging attributes.
Returns:
List of terms, identifying all Attributes belonging to a concept
Throws:
org.wsmo.common.exception.InvalidModelException
org.wsmo.common.exception.SynchronisationException
See Also:
getAttributes(Term, Ontology)

getInstances

public static List getInstances(org.omwg.ontology.Ontology o)
                         throws org.wsmo.common.exception.SynchronisationException,
                                org.wsmo.common.exception.InvalidModelException
Collecting all instances from a given ontology.

Parameters:
o - Ontology to be checked for contained instances
Returns:
List of terms, identifying all instances from the ontology
Throws:
org.wsmo.common.exception.InvalidModelException
org.wsmo.common.exception.SynchronisationException


Copyright © 2004-2008 Ontotext Lab.. All Rights Reserved.