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

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.OWLHasKeyAxiomImpl
All Implemented Interfaces:
java.lang.Comparable<OWLObject>, OWLAxiom, OWLHasKeyAxiom, OWLLogicalAxiom, OWLObject

public class OWLHasKeyAxiomImpl
extends OWLAxiomImpl
implements OWLHasKeyAxiom

Author: Matthew Horridge
The University of Manchester
Information Management Group
Date: 17-Jan-2009


Constructor Summary
OWLHasKeyAxiomImpl(OWLDataFactory dataFactory, OWLClassExpression expression, java.util.Set<? extends OWLPropertyExpression> propertyExpressions, 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)
           
protected  int compareObjectOfSameType(OWLObject object)
           
 boolean equals(java.lang.Object obj)
           
 OWLHasKeyAxiom 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.
 OWLHasKeyAxiom getAxiomWithoutAnnotations()
          Gets an axiom that is structurally equivalent to this axiom without annotations.
 OWLClassExpression getClassExpression()
          Gets the class expression, instances of which, this axiom acts as the key for
 java.util.Set<OWLDataPropertyExpression> getDataPropertyExpressions()
          Gets the set of data property expressions that make up the key.
 java.util.Set<OWLObjectPropertyExpression> getObjectPropertyExpressions()
          Gets the set of object property expressions that make up the key.
 java.util.Set<OWLPropertyExpression> getPropertyExpressions()
          Gets the set of property expressions that form the key
 boolean isLogicalAxiom()
          Determines if this axiom is a logical axiom.
 
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.OWLAxiom
equalsIgnoreAnnotations, getAnnotations, getAnnotations, getNNF, isAnnotated, 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

OWLHasKeyAxiomImpl

public OWLHasKeyAxiomImpl(OWLDataFactory dataFactory,
                          OWLClassExpression expression,
                          java.util.Set<? extends OWLPropertyExpression> propertyExpressions,
                          java.util.Collection<? extends OWLAnnotation> annotations)
Method Detail

getAxiomWithoutAnnotations

public OWLHasKeyAxiom 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 OWLHasKeyAxiom
Returns:
The annotationless version of this axiom

getAnnotatedAxiom

public OWLHasKeyAxiom 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.

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.

isLogicalAxiom

public boolean isLogicalAxiom()
Description copied from interface: OWLAxiom
Determines if this axiom is a logical axiom. Logical axioms are defined to be axioms other than both declaration axioms (including imports declarations) and annotation axioms.

Specified by:
isLogicalAxiom in interface OWLAxiom
Returns:
true if the axiom is a logical axiom, false if the axiom is not a logical axiom.

getClassExpression

public OWLClassExpression getClassExpression()
Description copied from interface: OWLHasKeyAxiom
Gets the class expression, instances of which, this axiom acts as the key for

Specified by:
getClassExpression in interface OWLHasKeyAxiom
Returns:
The class expression

getPropertyExpressions

public java.util.Set<OWLPropertyExpression> getPropertyExpressions()
Description copied from interface: OWLHasKeyAxiom
Gets the set of property expressions that form the key

Specified by:
getPropertyExpressions in interface OWLHasKeyAxiom
Returns:
The set of property expression that form the key

getDataPropertyExpressions

public java.util.Set<OWLDataPropertyExpression> getDataPropertyExpressions()
Description copied from interface: OWLHasKeyAxiom
Gets the set of data property expressions that make up the key. This is simply a convenience method that filteres out the data property expressions in the key. All of the properties returned by this method are included in the return value of the OWLHasKeyAxiom.getPropertyExpressions() method.

Specified by:
getDataPropertyExpressions in interface OWLHasKeyAxiom
Returns:
The set of object property expressions in the key described by this axiom

getObjectPropertyExpressions

public java.util.Set<OWLObjectPropertyExpression> getObjectPropertyExpressions()
Description copied from interface: OWLHasKeyAxiom
Gets the set of object property expressions that make up the key. This is simply a convenience method that filteres out the object property expressions in the key. All of the properties returned by this method are included in the return value of the OWLHasKeyAxiom.getPropertyExpressions() method.

Specified by:
getObjectPropertyExpressions in interface OWLHasKeyAxiom
Returns:
The set of object property expressions in the key described by this axiom

compareObjectOfSameType

protected int compareObjectOfSameType(OWLObject object)
Specified by:
compareObjectOfSameType in class OWLObjectImpl

accept

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

accept

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

accept

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

accept

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

equals

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