uk.ac.manchester.cs.owl.owlapi
Class OWLEquivalentClassesAxiomImpl

java.lang.Object
  extended by uk.ac.manchester.cs.owl.owlapi.OWLObjectImpl
      extended by uk.ac.manchester.cs.owl.owlapi.OWLAxiomImpl
          extended by uk.ac.manchester.cs.owl.owlapi.OWLLogicalAxiomImpl
              extended by uk.ac.manchester.cs.owl.owlapi.OWLClassAxiomImpl
                  extended by uk.ac.manchester.cs.owl.owlapi.OWLNaryClassAxiomImpl
                      extended by uk.ac.manchester.cs.owl.owlapi.OWLEquivalentClassesAxiomImpl
All Implemented Interfaces:
java.lang.Comparable<OWLObject>, OWLAxiom, OWLClassAxiom, OWLEquivalentClassesAxiom, OWLLogicalAxiom, OWLNaryAxiom, OWLNaryClassAxiom, OWLObject, OWLSubClassOfAxiomSetShortCut

public class OWLEquivalentClassesAxiomImpl
extends OWLNaryClassAxiomImpl
implements OWLEquivalentClassesAxiom

Author: Matthew Horridge
The University Of Manchester
Bio-Health Informatics Group
Date: 26-Oct-2006


Constructor Summary
OWLEquivalentClassesAxiomImpl(OWLDataFactory dataFactory, java.util.Set<? extends OWLClassExpression> classExpressions, java.util.Collection<? extends OWLAnnotation> annotations)
           
 
Method Summary
 void accept(OWLAxiomVisitor visitor)
           
<O> O
accept(OWLAxiomVisitorEx<O> visitor)
           
 void accept(OWLObjectVisitor visitor)
           
<O> O
accept(OWLObjectVisitorEx<O> visitor)
           
 java.util.Set<OWLSubClassOfAxiom> asOWLSubClassOfAxioms()
           
 java.util.Set<OWLEquivalentClassesAxiom> asPairwiseAxioms()
          Gets this axiom as a set of pairwise axioms.
 boolean containsNamedEquivalentClass()
          Determines if this equivalent classes axiom contains at least one named class (excluding owl:Thing or owl:Nothing).
 boolean containsOWLNothing()
          Determines if this class axiom makes a class expression equivalent to nothing.
 boolean containsOWLThing()
          Determines if this class axiom makes a class expression equivalent to thing.
 boolean equals(java.lang.Object obj)
           
 OWLEquivalentClassesAxiom getAnnotatedAxiom(java.util.Set<OWLAnnotation> annotations)
          Gets a copy of this axiom that is annotated with the specified annotations.
 AxiomType getAxiomType()
          Gets the axiom type for this axiom.
 OWLEquivalentClassesAxiom getAxiomWithoutAnnotations()
          Gets an axiom that is structurally equivalent to this axiom without annotations.
 java.util.Set<OWLClass> getNamedClasses()
          Gets the named classes (excluding owl:Thing and owl:Nothing) that are in this equivalent classes axiom.
 
Methods inherited from class uk.ac.manchester.cs.owl.owlapi.OWLNaryClassAxiomImpl
compareObjectOfSameType, contains, getClassExpressions, getClassExpressionsAsList, getClassExpressionsMinus
 
Methods inherited from class uk.ac.manchester.cs.owl.owlapi.OWLLogicalAxiomImpl
isLogicalAxiom
 
Methods inherited from class uk.ac.manchester.cs.owl.owlapi.OWLAxiomImpl
equalsIgnoreAnnotations, getAnnotations, getAnnotations, getNNF, getReferencedEntities, isAnnotated, isOfType, isOfType, mergeAnnos
 
Methods inherited from class uk.ac.manchester.cs.owl.owlapi.OWLObjectImpl
compareSets, compareTo, getClassesInSignature, getDataPropertiesInSignature, getDatatypesInSignature, getIndividualsInSignature, getNestedClassExpressions, getObjectPropertiesInSignature, getOWLDataFactory, getSignature, hashCode, isBottomEntity, isTopEntity, toString
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface org.semanticweb.owlapi.model.OWLNaryClassAxiom
contains, getClassExpressions, getClassExpressionsAsList, getClassExpressionsMinus
 
Methods inherited from interface org.semanticweb.owlapi.model.OWLAxiom
equalsIgnoreAnnotations, getAnnotations, getAnnotations, getNNF, isAnnotated, isLogicalAxiom, isOfType, isOfType
 
Methods inherited from interface org.semanticweb.owlapi.model.OWLObject
getClassesInSignature, getDataPropertiesInSignature, getDatatypesInSignature, getIndividualsInSignature, getNestedClassExpressions, getObjectPropertiesInSignature, getSignature, isBottomEntity, isTopEntity
 
Methods inherited from interface java.lang.Comparable
compareTo
 

Constructor Detail

OWLEquivalentClassesAxiomImpl

public OWLEquivalentClassesAxiomImpl(OWLDataFactory dataFactory,
                                     java.util.Set<? extends OWLClassExpression> classExpressions,
                                     java.util.Collection<? extends OWLAnnotation> annotations)
Method Detail

getAxiomWithoutAnnotations

public OWLEquivalentClassesAxiom getAxiomWithoutAnnotations()
Description copied from interface: OWLAxiom
Gets an axiom that is structurally equivalent to this axiom without annotations. This essentially returns a version of this axiom stripped of any annotations

Specified by:
getAxiomWithoutAnnotations in interface OWLAxiom
Specified by:
getAxiomWithoutAnnotations in interface OWLEquivalentClassesAxiom
Returns:
The annotationless version of this axiom

getAnnotatedAxiom

public OWLEquivalentClassesAxiom getAnnotatedAxiom(java.util.Set<OWLAnnotation> annotations)
Description copied from interface: OWLAxiom
Gets a copy of this axiom that is annotated with the specified annotations. If this axiom has any annotations on it they will be merged with the specified set of annotations. Note that this axiom will not be modified (or remove from any ontologies).

Specified by:
getAnnotatedAxiom in interface OWLAxiom
Parameters:
annotations - The annotations that will be added to existing annotations to annotate the copy of this axiom
Returns:
A copy of this axiom that has the specified annotations plus any existing annotations returned by the OWLAxiom#getAnnotations() method.

asPairwiseAxioms

public java.util.Set<OWLEquivalentClassesAxiom> asPairwiseAxioms()
Description copied from interface: OWLNaryAxiom
Gets this axiom as a set of pairwise axioms. Note that annotations on this axiom will not be copied to each axiom returned in the set of pairwise axioms.

Specified by:
asPairwiseAxioms in interface OWLEquivalentClassesAxiom
Specified by:
asPairwiseAxioms in interface OWLNaryAxiom
Returns:
This axiom as a set of pairwise axioms.

containsNamedEquivalentClass

public boolean containsNamedEquivalentClass()
Description copied from interface: OWLEquivalentClassesAxiom
Determines if this equivalent classes axiom contains at least one named class (excluding owl:Thing or owl:Nothing).

Specified by:
containsNamedEquivalentClass in interface OWLEquivalentClassesAxiom
Returns:
true if the axiom contains at least one named class otherwise false. Note that this method will return false if the only named classes are owl:Thing or owl:Nothing.

containsOWLNothing

public boolean containsOWLNothing()
Description copied from interface: OWLEquivalentClassesAxiom
Determines if this class axiom makes a class expression equivalent to nothing.

Specified by:
containsOWLNothing in interface OWLEquivalentClassesAxiom
Returns:
true if this axiom contains owl:Nothing as an equivalent class.

containsOWLThing

public boolean containsOWLThing()
Description copied from interface: OWLEquivalentClassesAxiom
Determines if this class axiom makes a class expression equivalent to thing.

Specified by:
containsOWLThing in interface OWLEquivalentClassesAxiom
Returns:
true if this axioms contains owl:Thing as an equivalent class.

getNamedClasses

public java.util.Set<OWLClass> getNamedClasses()
Description copied from interface: OWLEquivalentClassesAxiom
Gets the named classes (excluding owl:Thing and owl:Nothing) that are in this equivalent classes axiom.

Specified by:
getNamedClasses in interface OWLEquivalentClassesAxiom
Returns:
A set of classes that represents the named classes that are specified to be equivalent to some other class (expression), excluding the built in classes owl:Thing and owl:Nothing

asOWLSubClassOfAxioms

public java.util.Set<OWLSubClassOfAxiom> asOWLSubClassOfAxioms()
Specified by:
asOWLSubClassOfAxioms in interface OWLSubClassOfAxiomSetShortCut

equals

public boolean equals(java.lang.Object obj)
Overrides:
equals in class OWLNaryClassAxiomImpl

accept

public void accept(OWLAxiomVisitor visitor)
Specified by:
accept in interface OWLAxiom

accept

public void accept(OWLObjectVisitor visitor)
Specified by:
accept in interface OWLObject

accept

public <O> O accept(OWLAxiomVisitorEx<O> visitor)
Specified by:
accept in interface OWLAxiom

accept

public <O> O accept(OWLObjectVisitorEx<O> visitor)
Specified by:
accept in interface OWLObject

getAxiomType

public AxiomType getAxiomType()
Description copied from interface: OWLAxiom
Gets the axiom type for this axiom.

Specified by:
getAxiomType in interface OWLAxiom
Returns:
The axiom type that corresponds to the type of this axiom.