uk.ac.manchester.cs.owl
Class OWLConstantAnnotationImpl

java.lang.Object
  extended by uk.ac.manchester.cs.owl.OWLObjectImpl
      extended by uk.ac.manchester.cs.owl.OWLAnnotationImpl<OWLConstant>
          extended by uk.ac.manchester.cs.owl.OWLConstantAnnotationImpl
All Implemented Interfaces:
java.lang.Comparable<OWLObject>, OWLAnnotation<OWLConstant>, OWLConstantAnnotation, OWLObject
Direct Known Subclasses:
OWLCommentAnnotationImpl, OWLLabelAnnotationImpl

public class OWLConstantAnnotationImpl
extends OWLAnnotationImpl<OWLConstant>
implements OWLConstantAnnotation

Author: Matthew Horridge
The University Of Manchester
Bio-Health Informatics Group
Date: 19-Dec-2006


Constructor Summary
OWLConstantAnnotationImpl(OWLDataFactory dataFactory, java.net.URI uri, OWLConstant object)
           
 
Method Summary
 void accept(OWLAnnotationVisitor visitor)
           
<O> O
accept(OWLAnnotationVisitorEx<O> visitor)
           
 void accept(OWLObjectVisitor visitor)
           
<O> O
accept(OWLObjectVisitorEx<O> visitor)
           
 boolean equals(java.lang.Object obj)
           
 OWLConstant getAnnotationValueAsConstant()
          If this is a constant annotation (rather than an entity annotation) then this convenience method obtains the annoation value as a constant.
 boolean isAnnotationByConstant()
          Determines if the annotation value is a constant.
 
Methods inherited from class uk.ac.manchester.cs.owl.OWLAnnotationImpl
getAnnotationURI, getAnnotationValue, isComment, isLabel
 
Methods inherited from class uk.ac.manchester.cs.owl.OWLObjectImpl
compareTo, getOWLDataFactory, getSignature, hashCode, toString
 
Methods inherited from class java.lang.Object
getClass, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface org.semanticweb.owl.model.OWLConstantAnnotation
isComment, isLabel
 
Methods inherited from interface org.semanticweb.owl.model.OWLAnnotation
getAnnotationURI, getAnnotationValue
 
Methods inherited from interface org.semanticweb.owl.model.OWLObject
getSignature
 
Methods inherited from interface java.lang.Comparable
compareTo
 

Constructor Detail

OWLConstantAnnotationImpl

public OWLConstantAnnotationImpl(OWLDataFactory dataFactory,
                                 java.net.URI uri,
                                 OWLConstant object)
Method Detail

getAnnotationValueAsConstant

public OWLConstant getAnnotationValueAsConstant()
Description copied from interface: OWLAnnotation
If this is a constant annotation (rather than an entity annotation) then this convenience method obtains the annoation value as a constant. Calling this method if the isAnnotationByConstant method returns false will throws an OWLRuntimeException

Specified by:
getAnnotationValueAsConstant in interface OWLAnnotation<OWLConstant>

isAnnotationByConstant

public boolean isAnnotationByConstant()
Description copied from interface: OWLAnnotation
Determines if the annotation value is a constant.

Specified by:
isAnnotationByConstant in interface OWLAnnotation<OWLConstant>
Returns:
true if the annotation value is a constant, or false if the annotation value is an entity (class, property, individual or datatype)

accept

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

equals

public boolean equals(java.lang.Object obj)
Overrides:
equals in class OWLAnnotationImpl<OWLConstant>

accept

public void accept(OWLAnnotationVisitor visitor)
Specified by:
accept in interface OWLAnnotation<OWLConstant>

accept

public <O> O accept(OWLAnnotationVisitorEx<O> visitor)
Specified by:
accept in interface OWLAnnotation<OWLConstant>

accept

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