|
Protégé-OWL 3.4 beta | ||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectedu.stanford.smi.protegex.owl.inference.reasoner.AbstractProtegeReasoner
public abstract class AbstractProtegeReasoner
| Field Summary | |
|---|---|
protected boolean |
autoSynchReasoner
|
protected ClassListener |
classListener
|
protected ModelListener |
modelListener
|
protected OWLModel |
owlModel
|
protected edu.stanford.smi.protege.event.ProjectListener |
projectListener
|
protected PropertyListener |
propertyListener
|
protected PropertyValueListener |
propertyValueListener
|
protected ReasonerTaskListener |
reasonerTaskListener
|
protected ResourceListener |
resourceAdapter
|
protected boolean |
synchronizeReasoner
|
| Constructor Summary | |
|---|---|
protected |
AbstractProtegeReasoner()
|
| Method Summary | |
|---|---|
protected void |
addListeners()
|
void |
classifyTaxonomy()
For each named class in the ontology, this method queries the reasoner for the consistency of the class, its inferred super classes and its inferred equivalent classes. |
void |
computeEquivalentConcepts()
This method queries the reasoner the equivalent classes for each class in the ontology, and updates protege-owl with the information. |
void |
computeInconsistentConcepts()
This method queries the reasoner for the consistency of all classes in the ontology, and updates protege-owl with the information. |
void |
computeInferredHierarchy()
For each named class in the ontology, this method queries the reasoner to obtain its inferred superclasses. |
void |
computeInferredIndividualTypes()
This method queries the reasoner for the types of all individuals in the ontology, and updates protege-owl with the information. |
void |
dispose()
|
void |
forceReasonerReSynchronization()
Depending on the implementation of the ProtegeGenericReasoner, some kind of caching may be used. |
Collection<OWLClass> |
getAncestorClasses(OWLClass class1)
Gets the inferred ancestor classes of the specified class. |
Collection<OWLProperty> |
getAncestorProperties(OWLProperty property)
|
protected ClassListener |
getClassListener()
|
Collection<OWLClass> |
getDescendantClasses(OWLClass class1)
Gets the inferred descendant classes of the specified class. |
Collection<OWLProperty> |
getDescendantProperties(OWLProperty property)
|
Collection<OWLClass> |
getEquivalentClasses(OWLClass class1)
Gets the equivalent classes of the specified class. |
Collection<OWLClass> |
getIndividualDirectTypes(OWLIndividual owlIndividual)
Get the direct inferred types for the specified individual. |
Collection<OWLIndividual> |
getIndividualsBelongingToClass(OWLClass class1)
Gets the individuals that are inferred to be members of the specified class. |
Collection<OWLClass> |
getIndividualTypes(OWLIndividual individual)
Get the inferred types (direct and indirect) for the specified individual. |
protected ModelListener |
getModelListener()
|
OWLModel |
getOWLModel()
Returns the OWL model to which this reasoner is attached to. |
protected edu.stanford.smi.protege.event.ProjectListener |
getProjectListener()
|
protected PropertyListener |
getPropertyListener()
|
protected PropertyValueListener |
getPropertyValueListener()
|
ReasonerTaskListener |
getReasonerTaskListener()
|
Collection<OWLIndividual> |
getRelatedIndividuals(OWLIndividual subject,
OWLObjectProperty objectProperty)
Get the individuals that are related to the subject individual
through the object property objectProperty. |
Collection |
getRelatedValues(OWLIndividual subject,
OWLDatatypeProperty datatypeProperty)
Get the values that are related to the subject individual
through the datatype property datatypeProperty. |
protected ResourceListener |
getResourceListener()
|
Collection<OWLClass> |
getSubclasses(OWLClass class1)
Gets the (direct) inferred subclasses of the specified class. |
Collection<OWLProperty> |
getSubProperties(OWLProperty property)
|
int |
getSubsumptionRelationship(OWLClass cls1,
OWLClass cls2)
|
Collection<OWLClass> |
getSuperclasses(OWLClass class1)
Gets the (direct) inferred superclasses of the specified class. |
Collection<OWLClass> |
getSuperclassesOfIntersection(OWLClass[] clses)
|
Collection<OWLProperty> |
getSuperProperties(OWLProperty property)
|
void |
initialize()
This is an optional method that can be called by applications and that gives the reasoner a chance to do some pre-computations. |
boolean |
isAutoSynchronizationEnabled()
|
boolean |
isDisjointTo(OWLClass cls1,
OWLClass cls2)
Determines if the specified classes are disjoint from each other. |
boolean |
isIntersectionSatisfiable(OWLClass[] clses)
Determines if the intersection of the list of specified classes is satisfiable. |
boolean |
isSatisfiable(OWLClass class1)
This method queries the reasoner to determine if the specified concept is satisfiable. |
boolean |
isSubsumedBy(OWLClass cls1,
OWLClass cls2)
Determines if one class (cls1) is subsumed by another class (cls2). |
void |
performTask(ReasonerTask task)
|
void |
performTask(ReasonerTask task,
ReasonerTaskListener taskListener)
|
protected void |
reactToKnowledgeBaseChange()
|
void |
rebind()
Resynchronizes the reasoner with the OWL model. |
protected void |
removeListeners()
|
void |
setAutoSynchronizationEnabled(boolean b)
Depending on the implementation of the ProtegeOWLReasoner, the DIG reasoner may automatically be sunchronized with changes in the Protege-OWL knowledgebase. |
void |
setOWLModel(OWLModel owlModel)
Sets the OWL model that will be attached to this reasoner. |
void |
setReasonerTaskListener(ReasonerTaskListener reasonerTaskListener)
Set the listener which will be informed of the progress of the reasoning task. |
protected void |
synchronizeReasoner(ReasonerTaskListener taskListener)
|
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Methods inherited from interface edu.stanford.smi.protegex.owl.inference.reasoner.ProtegeReasoner |
|---|
reset |
| Field Detail |
|---|
protected OWLModel owlModel
protected ReasonerTaskListener reasonerTaskListener
protected boolean synchronizeReasoner
protected boolean autoSynchReasoner
protected ModelListener modelListener
protected ResourceListener resourceAdapter
protected PropertyListener propertyListener
protected ClassListener classListener
protected PropertyValueListener propertyValueListener
protected edu.stanford.smi.protege.event.ProjectListener projectListener
| Constructor Detail |
|---|
protected AbstractProtegeReasoner()
| Method Detail |
|---|
public void setReasonerTaskListener(ReasonerTaskListener reasonerTaskListener)
ProtegeReasonernull if the progress of the task does not
need to be monitored.
setReasonerTaskListener in interface ProtegeReasonerpublic ReasonerTaskListener getReasonerTaskListener()
getReasonerTaskListener in interface ProtegeReasonerpublic void setOWLModel(OWLModel owlModel)
ProtegeReasoner
setOWLModel in interface ProtegeReasonerpublic void dispose()
dispose in interface edu.stanford.smi.protege.util.Disposablepublic void initialize()
ProtegeReasoner
initialize in interface ProtegeReasonerpublic void rebind()
ProtegeReasoner
rebind in interface ProtegeReasoner
public void classifyTaxonomy()
throws ProtegeReasonerException
ProtegeReasonerRDFSClass such as getInferredSuperClasses
will return meaningful results.
classifyTaxonomy in interface ProtegeReasonerProtegeReasonerException
public void computeInferredHierarchy()
throws ProtegeReasonerException
ProtegeReasonergetInferredSuperClasses on RDFSClass will
return meaningful results.
computeInferredHierarchy in interface ProtegeReasonerProtegeReasonerException
public void computeInconsistentConcepts()
throws ProtegeReasonerException
ProtegeReasoner
computeInconsistentConcepts in interface ProtegeReasonerProtegeReasonerException
public void computeInferredIndividualTypes()
throws ProtegeReasonerException
ProtegeReasoner
computeInferredIndividualTypes in interface ProtegeReasonerProtegeReasonerException
public void computeEquivalentConcepts()
throws ProtegeReasonerException
ProtegeReasoner
computeEquivalentConcepts in interface ProtegeReasonerProtegeReasonerException
public Collection<OWLClass> getEquivalentClasses(OWLClass class1)
throws ProtegeReasonerException
ProtegeReasoner
getEquivalentClasses in interface ProtegeReasonerclass1 - The class whose equivalent classes are to be retrieved.
Collection containing the inferred equivalent classes
of the specified class.
ProtegeReasonerException
public Collection<OWLClass> getAncestorClasses(OWLClass class1)
throws ProtegeReasonerException
ProtegeReasoner
getAncestorClasses in interface ProtegeReasonerclass1 - The class whose inferred ancestor classes are to be retrieved.
Collection containing the inferred ancestor classes
of the specified class.
ProtegeReasonerException
public Collection<OWLClass> getDescendantClasses(OWLClass class1)
throws ProtegeReasonerException
ProtegeReasoner
getDescendantClasses in interface ProtegeReasonerclass1 - The class whose descendent classes are to be retrieved.
Collection containing the inferred descendent classes.
ProtegeReasonerException
public Collection<OWLClass> getIndividualTypes(OWLIndividual individual)
throws ProtegeReasonerException
ProtegeReasoner
getIndividualTypes in interface ProtegeReasonerindividual - The individual whose inferred types are to be retrieved.
Collection of OWLClasses that represent the
inferred types for the specified individual.
ProtegeReasonerException
public Collection<OWLClass> getIndividualDirectTypes(OWLIndividual owlIndividual)
throws ProtegeReasonerException
ProtegeReasoner
getIndividualDirectTypes in interface ProtegeReasonerowlIndividual - The individual whose inferred direct types are to be retrieved.
Collection of OWLClasses that represent the
inferred direct types for the specified individual.
ProtegeReasonerException
public Collection<OWLIndividual> getIndividualsBelongingToClass(OWLClass class1)
throws ProtegeReasonerException
ProtegeReasoner
getIndividualsBelongingToClass in interface ProtegeReasonerclass1 - The class whose members are to be retrieved.
Collection containing the OWLIndividuals
that are members of the specified class.
ProtegeReasonerExceptionpublic OWLModel getOWLModel()
ProtegeReasoner
getOWLModel in interface ProtegeReasoner
public Collection<OWLIndividual> getRelatedIndividuals(OWLIndividual subject,
OWLObjectProperty objectProperty)
throws ProtegeReasonerException
ProtegeReasonersubject individual
through the object property objectProperty.
getRelatedIndividuals in interface ProtegeReasonersubject - - An OWLIndividualobjectProperty - - A OWLObjectProperty
Collection of OWLIndividuals that are related
to the subject individual through objectProperty
ProtegeReasonerException
public Collection getRelatedValues(OWLIndividual subject,
OWLDatatypeProperty datatypeProperty)
throws ProtegeReasonerException
ProtegeReasonersubject individual
through the datatype property datatypeProperty.
getRelatedValues in interface ProtegeReasonersubject - - An OWLIndividual
Collection of values that are related
to the subject individual through datatypeProperty
ProtegeReasonerException
public Collection<OWLClass> getSubclasses(OWLClass class1)
throws ProtegeReasonerException
ProtegeReasoner
getSubclasses in interface ProtegeReasonerclass1 - The class whose inferred subclasses are to be retrieved.
Collection containing the inferred subclasses of the
specified class.
ProtegeReasonerException
public int getSubsumptionRelationship(OWLClass cls1,
OWLClass cls2)
throws ProtegeReasonerException
ProtegeReasonerException
public Collection<OWLClass> getSuperclasses(OWLClass class1)
throws ProtegeReasonerException
ProtegeReasoner
getSuperclasses in interface ProtegeReasonerclass1 - The class whose inferred superclasses are to be retrieved.
Collection containing the classes that are the
inferred superclasses of the specified class.
ProtegeReasonerException
public Collection<OWLClass> getSuperclassesOfIntersection(OWLClass[] clses)
throws ProtegeReasonerException
ProtegeReasonerException
public Collection<OWLProperty> getSubProperties(OWLProperty property)
throws ProtegeReasonerException
getSubProperties in interface ProtegeReasonerProtegeReasonerException
public Collection<OWLProperty> getSuperProperties(OWLProperty property)
throws ProtegeReasonerException
getSuperProperties in interface ProtegeReasonerProtegeReasonerException
public Collection<OWLProperty> getAncestorProperties(OWLProperty property)
throws ProtegeReasonerException
getAncestorProperties in interface ProtegeReasonerProtegeReasonerException
public Collection<OWLProperty> getDescendantProperties(OWLProperty property)
throws ProtegeReasonerException
getDescendantProperties in interface ProtegeReasonerProtegeReasonerException
public boolean isDisjointTo(OWLClass cls1,
OWLClass cls2)
throws ProtegeReasonerException
ProtegeReasoner
isDisjointTo in interface ProtegeReasonercls1 - An OWLClasscls2 - An OWLClass
true if cls1 is disjoint with cls2.
ProtegeReasonerException
public boolean isIntersectionSatisfiable(OWLClass[] clses)
throws ProtegeReasonerException
ProtegeReasoner
isIntersectionSatisfiable in interface ProtegeReasonerclses - An array of OWLClasses, of which the satisfiablity of the
intersection will be determined.
true if the intersection of the list of classes is satisfiable (consistent)
or false if the intersection of the list of classes is not satisfiable (not consistent)
ProtegeReasonerException
public boolean isSatisfiable(OWLClass class1)
throws ProtegeReasonerException
ProtegeReasoner
isSatisfiable in interface ProtegeReasonerclass1 - The OWLClass whose satisfiablity is to be determined.
true if the specified class is satisfiable (consistent)
, or false if the specified class is not satisfiable (not consistent).
ProtegeReasonerException
public boolean isSubsumedBy(OWLClass cls1,
OWLClass cls2)
throws ProtegeReasonerException
ProtegeReasoner
isSubsumedBy in interface ProtegeReasonercls1 - The subsumee (the expected subclass)cls2 - The subsumer (the expected superclass)
true if cls1 is subsumed by cls2, or false if cls1
is not subsumed by cls2.
ProtegeReasonerException
public void performTask(ReasonerTask task)
throws ProtegeReasonerException
ProtegeReasonerException
public void performTask(ReasonerTask task,
ReasonerTaskListener taskListener)
throws ProtegeReasonerException
ProtegeReasonerExceptionprotected void removeListeners()
protected void addListeners()
protected ClassListener getClassListener()
protected PropertyListener getPropertyListener()
protected PropertyValueListener getPropertyValueListener()
protected ResourceListener getResourceListener()
protected ModelListener getModelListener()
protected edu.stanford.smi.protege.event.ProjectListener getProjectListener()
protected void synchronizeReasoner(ReasonerTaskListener taskListener)
throws ProtegeReasonerException
ProtegeReasonerExceptionprotected void reactToKnowledgeBaseChange()
public void forceReasonerReSynchronization()
ProtegeReasoner
forceReasonerReSynchronization in interface ProtegeReasonerpublic void setAutoSynchronizationEnabled(boolean b)
ProtegeReasonerforceReasonerReSynchronization method should
be used.
setAutoSynchronizationEnabled in interface ProtegeReasonerb - true to enable autosync, or false
to disable autosync.public boolean isAutoSynchronizationEnabled()
isAutoSynchronizationEnabled in interface ProtegeReasoner
|
Protégé-OWL 3.4 beta | ||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||