|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface OWLOntology
Author: Matthew Horridge
The University Of Manchester
Bio-Health Informatics Group Date: 24-Oct-2006
OWLOntology
contains a set of axioms. Ontologies do not specifically contain entities such as
classes, properties or individuals - these entities are merely referenced by the axioms that the ontology contains.
They form the signature of the ontology. Unlike some APIs it is therefore not possible to directly add or
remove entities to or from an ontology.
An ontology cannot be modified directly. Changes must be applied using an OWLOntologyManager
.
Method Summary | ||
---|---|---|
boolean |
containsAxiom(OWLAxiom axiom)
Determines if this ontology contains the specified axiom. |
|
boolean |
containsClassReference(java.net.URI owlClassURI)
Determines if the ontology contains a reference to a class that has a specific URI. |
|
boolean |
containsDataPropertyReference(java.net.URI propURI)
Determines if the ontology contains a reference to a data property that has a specific URI. |
|
boolean |
containsDataTypeReference(java.net.URI datatypeURI)
|
|
boolean |
containsEntityDeclaration(OWLEntity owlEntity)
Determines if this ontology contains a declaration axiom for the specified entity. |
|
boolean |
containsEntityReference(OWLEntity owlEntity)
Determines if the ontology contains a reference to the specified entity. |
|
boolean |
containsIndividualReference(java.net.URI individualURI)
Determines if the ontology contains a reference to an individual that has a specific URI. |
|
boolean |
containsObjectPropertyReference(java.net.URI propURI)
Determines if the ontology contains a reference to an object property that has a specific URI. |
|
java.util.Set<OWLAnnotationAxiom> |
getAnnotationAxioms()
Gets all of the annotation axioms in this ontology. |
|
java.util.Set<OWLAxiomAnnotationAxiom> |
getAnnotations(OWLAxiom axiom)
Gets the annotation axioms that annotate the specified axiom in this ontology. |
|
java.util.Set<OWLOntologyAnnotationAxiom> |
getAnnotations(OWLOntology subject)
Gets the ontology annotations whose subject is the specified ontology. |
|
java.util.Set<java.net.URI> |
getAnnotationURIs()
Gets the set of URIs that are used in annotations (e.g. |
|
OWLAntiSymmetricObjectPropertyAxiom |
getAntiSymmetricObjectPropertyAxiom(OWLObjectPropertyExpression property)
Deprecated. use getAsymmetricObjectPropertyAxiom instead. |
|
OWLAntiSymmetricObjectPropertyAxiom |
getAsymmetricObjectPropertyAxiom(OWLObjectPropertyExpression property)
Gets the axiom that states that this property is asymmetric. |
|
int |
getAxiomCount()
Gets the number of axioms in this ontology. |
|
|
getAxiomCount(AxiomType<T> axiomType)
Gets the axiom count of a specific type of axiom |
|
java.util.Set<OWLAxiom> |
getAxioms()
Retrieves all of the axioms in this ontology. |
|
|
getAxioms(AxiomType<T> axiomType)
Gets the axioms which are of the specified type. |
|
java.util.Set<OWLClassAxiom> |
getAxioms(OWLClass cls)
Gets the axioms that form the definition/description of a class. |
|
java.util.Set<OWLDataPropertyAxiom> |
getAxioms(OWLDataProperty prop)
Gets the axioms that form the definition/description of a data property. |
|
java.util.Set<OWLIndividualAxiom> |
getAxioms(OWLIndividual individual)
Gets the axioms that form the definition/description of an individual |
|
java.util.Set<OWLObjectPropertyAxiom> |
getAxioms(OWLObjectPropertyExpression prop)
Gets the axioms that form the definition/description of an object property. |
|
java.util.Set<OWLClassAssertionAxiom> |
getClassAssertionAxioms(OWLClass type)
|
|
java.util.Set<OWLClassAssertionAxiom> |
getClassAssertionAxioms(OWLIndividual individual)
|
|
java.util.Set<OWLClassAxiom> |
getClassAxioms()
Gets all of the class axioms in this ontology. |
|
java.util.Set<OWLDataPropertyAssertionAxiom> |
getDataPropertyAssertionAxioms(OWLIndividual individual)
|
|
java.util.Set<OWLPropertyAxiom> |
getDataPropertyAxioms()
Gets all of the data property axioms in this ontology. |
|
java.util.Set<OWLDataPropertyDomainAxiom> |
getDataPropertyDomainAxioms(OWLDataProperty property)
|
|
java.util.Set<OWLDataPropertyRangeAxiom> |
getDataPropertyRangeAxiom(OWLDataProperty property)
|
|
java.util.Set<OWLDataSubPropertyAxiom> |
getDataSubPropertyAxiomsForLHS(OWLDataProperty lhsProperty)
|
|
java.util.Set<OWLDataSubPropertyAxiom> |
getDataSubPropertyAxiomsForRHS(OWLDataPropertyExpression property)
|
|
java.util.Set<OWLDeclarationAxiom> |
getDeclarationAxioms()
Gets all of the annotation axioms in this ontology. |
|
java.util.Set<OWLDeclarationAxiom> |
getDeclarationAxioms(OWLEntity subject)
Gets the declaration axioms for specified entity. |
|
java.util.Set<OWLDifferentIndividualsAxiom> |
getDifferentIndividualAxioms(OWLIndividual individual)
|
|
java.util.Set<OWLDisjointClassesAxiom> |
getDisjointClassesAxioms(OWLClass cls)
Gets the set of disjoint class axioms that contain the specified class as an operand. |
|
java.util.Set<OWLDisjointDataPropertiesAxiom> |
getDisjointDataPropertiesAxiom(OWLDataProperty property)
|
|
java.util.Set<OWLDisjointObjectPropertiesAxiom> |
getDisjointObjectPropertiesAxiom(OWLObjectPropertyExpression property)
|
|
java.util.Set<OWLDisjointUnionAxiom> |
getDisjointUnionAxioms(OWLClass owlClass)
Gets the set of disjoint union axioms that have the specified class as the named class that is equivalent to the disjoint union of operands. |
|
java.util.Set<OWLEntityAnnotationAxiom> |
getEntityAnnotationAxioms(OWLEntity entity)
Gets the axioms that annotate the specified entity. |
|
java.util.Set<OWLEquivalentClassesAxiom> |
getEquivalentClassesAxioms(OWLClass cls)
Gets all of the equivalent axioms in this ontology that contain the specified class as an operand. |
|
java.util.Set<OWLEquivalentDataPropertiesAxiom> |
getEquivalentDataPropertiesAxiom(OWLDataProperty property)
|
|
java.util.Set<OWLEquivalentObjectPropertiesAxiom> |
getEquivalentObjectPropertiesAxioms(OWLObjectPropertyExpression property)
|
|
OWLFunctionalDataPropertyAxiom |
getFunctionalDataPropertyAxiom(OWLDataPropertyExpression property)
|
|
OWLFunctionalObjectPropertyAxiom |
getFunctionalObjectPropertyAxiom(OWLObjectPropertyExpression property)
|
|
java.util.Set<OWLClassAxiom> |
getGeneralClassAxioms()
Gets the set of general axioms in this ontology. |
|
java.util.Set<OWLOntology> |
getImports(OWLOntologyManager ontologyManager)
Gets the OWLOntology instances that this ontology imports. |
|
java.util.Set<OWLImportsDeclaration> |
getImportsDeclarations()
Gets the set of imports annotations for this ontology. |
|
java.util.Set<OWLIndividualAxiom> |
getIndividualAxioms()
Gets all of the individual axioms in this ontology. |
|
OWLInverseFunctionalObjectPropertyAxiom |
getInverseFunctionalObjectPropertyAxiom(OWLObjectPropertyExpression property)
|
|
java.util.Set<OWLInverseObjectPropertiesAxiom> |
getInverseObjectPropertyAxioms(OWLObjectPropertyExpression property)
|
|
OWLIrreflexiveObjectPropertyAxiom |
getIrreflexiveObjectPropertyAxiom(OWLObjectPropertyExpression property)
|
|
int |
getLogicalAxiomCount()
Gets the number of logical axioms in this ontology. |
|
java.util.Set<OWLLogicalAxiom> |
getLogicalAxioms()
Gets all of the axioms in the ontology that affect the logical meaning of the ontology. |
|
java.util.Set<OWLNegativeDataPropertyAssertionAxiom> |
getNegativeDataPropertyAssertionAxioms(OWLIndividual individual)
|
|
java.util.Set<OWLNegativeObjectPropertyAssertionAxiom> |
getNegativeObjectPropertyAssertionAxioms(OWLIndividual individual)
|
|
java.util.Set<OWLObjectPropertyAssertionAxiom> |
getObjectPropertyAssertionAxioms(OWLIndividual individual)
|
|
java.util.Set<OWLPropertyAxiom> |
getObjectPropertyAxioms()
Gets all of the object property axioms in this ontology. |
|
java.util.Set<OWLObjectPropertyDomainAxiom> |
getObjectPropertyDomainAxioms(OWLObjectPropertyExpression property)
|
|
java.util.Set<OWLObjectPropertyRangeAxiom> |
getObjectPropertyRangeAxioms(OWLObjectPropertyExpression property)
|
|
java.util.Set<OWLObjectSubPropertyAxiom> |
getObjectSubPropertyAxiomsForLHS(OWLObjectPropertyExpression property)
Gets the object property sub property axioms where the specified property is on the left hand side of the axiom. |
|
java.util.Set<OWLObjectSubPropertyAxiom> |
getObjectSubPropertyAxiomsForRHS(OWLObjectPropertyExpression property)
|
|
java.util.Set<OWLOntologyAnnotationAxiom> |
getOntologyAnnotationAxioms()
Gets all of the ontology annotation axioms which have been asserted in this ontology. |
|
java.util.Set<OWLObjectPropertyChainSubPropertyAxiom> |
getPropertyChainSubPropertyAxioms()
Gets the property chain sub property axioms in the ontology. |
|
java.util.Set<OWLClass> |
getReferencedClasses()
Gets the classes that are referenced by axioms (including annotation axioms) in this ontology. |
|
java.util.Set<OWLDataProperty> |
getReferencedDataProperties()
Gets the data properties that are referenced by axioms (including annotation axioms) in this ontology. |
|
java.util.Set<OWLEntity> |
getReferencedEntities()
Gets the entities that are referenced by axioms in this ontology. |
|
java.util.Set<OWLIndividual> |
getReferencedIndividuals()
Gets the individuals that are referenced by axioms (including annotation axioms) in this ontology. |
|
java.util.Set<OWLObjectProperty> |
getReferencedObjectProperties()
Gets the object properties that are referenced by axioms (including annotation axioms) in this ontology. |
|
java.util.Set<OWLAxiom> |
getReferencingAxioms(OWLEntity owlEntity)
Gets the axioms where the specified entity appears anywhere in the axiom. |
|
OWLReflexiveObjectPropertyAxiom |
getReflexiveObjectPropertyAxiom(OWLObjectPropertyExpression property)
|
|
java.util.Set<SWRLRule> |
getRules()
Gets the rules in this ontology. |
|
java.util.Set<OWLSameIndividualsAxiom> |
getSameIndividualAxioms(OWLIndividual individual)
|
|
java.util.Set<OWLSubClassAxiom> |
getSubClassAxiomsForLHS(OWLClass cls)
Gets all of the subclass axioms where the left hand side (the subclass) is equal to the specified class. |
|
java.util.Set<OWLSubClassAxiom> |
getSubClassAxiomsForRHS(OWLClass cls)
Gets all of the subclass axioms where the right hand side (the superclass) is equal to the specified class. |
|
OWLSymmetricObjectPropertyAxiom |
getSymmetricObjectPropertyAxiom(OWLObjectPropertyExpression property)
|
|
OWLTransitiveObjectPropertyAxiom |
getTransitiveObjectPropertyAxiom(OWLObjectPropertyExpression property)
|
|
boolean |
isEmpty()
Determines if this ontology is empty - an ontology is empty if it does not contain any axioms. |
|
boolean |
isPunned(java.net.URI uri)
Determines if the specified URI refers to more than one type of entity (i.e. |
Methods inherited from interface org.semanticweb.owl.model.OWLNamedObject |
---|
accept, getURI |
Methods inherited from interface org.semanticweb.owl.model.OWLObject |
---|
accept, accept, getSignature |
Methods inherited from interface java.lang.Comparable |
---|
compareTo |
Method Detail |
---|
boolean isEmpty()
true
if the ontology is empty, otherwise false
.java.util.Set<OWLAxiom> getAxioms()
containsAxiom
method is used to determine whether or not this ontology
contains a particular axiom rather than using getAxioms().contains().int getAxiomCount()
java.util.Set<OWLLogicalAxiom> getLogicalAxioms()
OWLLogicalAxiom
The set that is returned is a copy of
the axioms in the ontology - it will not be updated if the ontology changes.int getLogicalAxiomCount()
java.util.Set<SWRLRule> getRules()
<T extends OWLAxiom> java.util.Set<T> getAxioms(AxiomType<T> axiomType)
axiomType
- The type of axioms to be retrived.
<T extends OWLAxiom> int getAxiomCount(AxiomType<T> axiomType)
axiomType
- The type of axiom to count
java.util.Set<OWLClassAxiom> getClassAxioms()
java.util.Set<OWLPropertyAxiom> getObjectPropertyAxioms()
java.util.Set<OWLPropertyAxiom> getDataPropertyAxioms()
java.util.Set<OWLIndividualAxiom> getIndividualAxioms()
java.util.Set<OWLClassAxiom> getGeneralClassAxioms()
OWLClass
es)OWLClass
es)
java.util.Set<OWLObjectPropertyChainSubPropertyAxiom> getPropertyChainSubPropertyAxioms()
java.util.Set<OWLEntity> getReferencedEntities()
OWLEntity
objects. The set that is returned is a copy - it will not be updated if
the ontology changes. It is therefore safe to apply changes to this ontology while iterating over this
set.java.util.Set<OWLClass> getReferencedClasses()
java.util.Set<OWLObjectProperty> getReferencedObjectProperties()
java.util.Set<OWLDataProperty> getReferencedDataProperties()
java.util.Set<OWLIndividual> getReferencedIndividuals()
java.util.Set<java.net.URI> getAnnotationURIs()
java.util.Set<OWLAxiom> getReferencingAxioms(OWLEntity owlEntity)
owlEntity
- The entity that should be directly referred to by an axiom that appears in the results set.
boolean containsEntityReference(OWLEntity owlEntity)
owlEntity
- The entity
true
if the ontology contains a reference to the specified entity, otherwise
false
The set that is returned is a copy - it will not be updated if the ontology changes.
It is therefore safe to apply changes to this ontology while iterating over this set.boolean containsEntityDeclaration(OWLEntity owlEntity)
owlEntity
- The entity
true
if the ontology contains a declaration for the specified entity, otherwise
false
The set that is returned is a copy - it will not be updated if the ontology changes.
It is therefore safe to apply changes to this ontology while iterating over this set.boolean containsClassReference(java.net.URI owlClassURI)
owlClassURI
- The URI to test for.
true
if the ontology refers to a class with the specified URI, otherwise false
boolean containsObjectPropertyReference(java.net.URI propURI)
propURI
- The URI of the property
true
if the ontology references (ontology signature contains) a property that has the
specified URI.boolean containsDataPropertyReference(java.net.URI propURI)
propURI
- The URI of the property
true
if the ontology references (ontology signature contains) a property that has the
specified URI.boolean containsIndividualReference(java.net.URI individualURI)
individualURI
- The URI of the individual
true
if the ontology references (ontology signature contains) an individual that has the
specified URI.boolean containsDataTypeReference(java.net.URI datatypeURI)
boolean isPunned(java.net.URI uri)
uri
- The URI to test.
true
if the URI refers to more than one entity, for example because the ontology references
a class with the URI and also an individual with the same URI.java.util.Set<OWLClassAxiom> getAxioms(OWLClass cls)
cls
- The class whose describing axioms are to be retrieved.
java.util.Set<OWLObjectPropertyAxiom> getAxioms(OWLObjectPropertyExpression prop)
prop
- The property whose defining axioms are to be retrieved.
java.util.Set<OWLDataPropertyAxiom> getAxioms(OWLDataProperty prop)
prop
- The property whose defining axioms are to be retrieved.
java.util.Set<OWLIndividualAxiom> getAxioms(OWLIndividual individual)
individual
- The individual whose defining axioms are to be retrieved.
java.util.Set<OWLAnnotationAxiom> getAnnotationAxioms()
java.util.Set<OWLDeclarationAxiom> getDeclarationAxioms()
java.util.Set<OWLImportsDeclaration> getImportsDeclarations()
java.util.Set<OWLOntology> getImports(OWLOntologyManager ontologyManager) throws UnknownOWLOntologyException
OWLOntology
instances that this ontology imports.
ontologyManager
- The OWLOntologyManager
that will map the imports annotations to actual
OWLOntology
instances.
UnknownOWLOntologyException
- if this ontology isn't managed by the specified manager.boolean containsAxiom(OWLAxiom axiom)
axiom
- The axiom to test for.
true
if the ontology contains the specified axioms, or false
if the ontology
doesn't contain the specified axiom.java.util.Set<OWLDeclarationAxiom> getDeclarationAxioms(OWLEntity subject)
subject
- The entity that is the subject of the set of returned axioms.
java.util.Set<OWLAxiomAnnotationAxiom> getAnnotations(OWLAxiom axiom)
axiom
- The axiom that the returned set of axiom annotation axioms annotate.
java.util.Set<OWLEntityAnnotationAxiom> getEntityAnnotationAxioms(OWLEntity entity)
entity
- The entity whose annotations are to be retrieved.
java.util.Set<OWLOntologyAnnotationAxiom> getAnnotations(OWLOntology subject)
subject
- The ontology that is the subject of the annotations.
java.util.Set<OWLOntologyAnnotationAxiom> getOntologyAnnotationAxioms()
java.util.Set<OWLSubClassAxiom> getSubClassAxiomsForLHS(OWLClass cls)
cls
- The class that is equal to the left hand side of the axiom (subclass).
java.util.Set<OWLSubClassAxiom> getSubClassAxiomsForRHS(OWLClass cls)
cls
- The class
java.util.Set<OWLEquivalentClassesAxiom> getEquivalentClassesAxioms(OWLClass cls)
cls
- The class
java.util.Set<OWLDisjointClassesAxiom> getDisjointClassesAxioms(OWLClass cls)
cls
- The class that should be contained in the set of disjoint class axioms that will be returned.
java.util.Set<OWLDisjointUnionAxiom> getDisjointUnionAxioms(OWLClass owlClass)
owlClass
- The class that indexes the axioms to be retrieved.
java.util.Set<OWLObjectSubPropertyAxiom> getObjectSubPropertyAxiomsForLHS(OWLObjectPropertyExpression property)
property
- The property which is on the left hand side of the axiom.
java.util.Set<OWLObjectSubPropertyAxiom> getObjectSubPropertyAxiomsForRHS(OWLObjectPropertyExpression property)
java.util.Set<OWLObjectPropertyDomainAxiom> getObjectPropertyDomainAxioms(OWLObjectPropertyExpression property)
java.util.Set<OWLObjectPropertyRangeAxiom> getObjectPropertyRangeAxioms(OWLObjectPropertyExpression property)
java.util.Set<OWLInverseObjectPropertiesAxiom> getInverseObjectPropertyAxioms(OWLObjectPropertyExpression property)
java.util.Set<OWLEquivalentObjectPropertiesAxiom> getEquivalentObjectPropertiesAxioms(OWLObjectPropertyExpression property)
java.util.Set<OWLDisjointObjectPropertiesAxiom> getDisjointObjectPropertiesAxiom(OWLObjectPropertyExpression property)
OWLFunctionalObjectPropertyAxiom getFunctionalObjectPropertyAxiom(OWLObjectPropertyExpression property)
OWLInverseFunctionalObjectPropertyAxiom getInverseFunctionalObjectPropertyAxiom(OWLObjectPropertyExpression property)
OWLSymmetricObjectPropertyAxiom getSymmetricObjectPropertyAxiom(OWLObjectPropertyExpression property)
OWLAntiSymmetricObjectPropertyAxiom getAntiSymmetricObjectPropertyAxiom(OWLObjectPropertyExpression property)
OWLAntiSymmetricObjectPropertyAxiom getAsymmetricObjectPropertyAxiom(OWLObjectPropertyExpression property)
property
- The property
null
if there is
no axiom that states this.OWLReflexiveObjectPropertyAxiom getReflexiveObjectPropertyAxiom(OWLObjectPropertyExpression property)
OWLIrreflexiveObjectPropertyAxiom getIrreflexiveObjectPropertyAxiom(OWLObjectPropertyExpression property)
OWLTransitiveObjectPropertyAxiom getTransitiveObjectPropertyAxiom(OWLObjectPropertyExpression property)
java.util.Set<OWLDataSubPropertyAxiom> getDataSubPropertyAxiomsForLHS(OWLDataProperty lhsProperty)
java.util.Set<OWLDataSubPropertyAxiom> getDataSubPropertyAxiomsForRHS(OWLDataPropertyExpression property)
java.util.Set<OWLDataPropertyDomainAxiom> getDataPropertyDomainAxioms(OWLDataProperty property)
java.util.Set<OWLDataPropertyRangeAxiom> getDataPropertyRangeAxiom(OWLDataProperty property)
java.util.Set<OWLEquivalentDataPropertiesAxiom> getEquivalentDataPropertiesAxiom(OWLDataProperty property)
java.util.Set<OWLDisjointDataPropertiesAxiom> getDisjointDataPropertiesAxiom(OWLDataProperty property)
OWLFunctionalDataPropertyAxiom getFunctionalDataPropertyAxiom(OWLDataPropertyExpression property)
java.util.Set<OWLClassAssertionAxiom> getClassAssertionAxioms(OWLIndividual individual)
java.util.Set<OWLClassAssertionAxiom> getClassAssertionAxioms(OWLClass type)
java.util.Set<OWLDataPropertyAssertionAxiom> getDataPropertyAssertionAxioms(OWLIndividual individual)
java.util.Set<OWLObjectPropertyAssertionAxiom> getObjectPropertyAssertionAxioms(OWLIndividual individual)
java.util.Set<OWLNegativeObjectPropertyAssertionAxiom> getNegativeObjectPropertyAssertionAxioms(OWLIndividual individual)
java.util.Set<OWLNegativeDataPropertyAssertionAxiom> getNegativeDataPropertyAssertionAxioms(OWLIndividual individual)
java.util.Set<OWLSameIndividualsAxiom> getSameIndividualAxioms(OWLIndividual individual)
java.util.Set<OWLDifferentIndividualsAxiom> getDifferentIndividualAxioms(OWLIndividual individual)
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |