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

java.lang.Object
  extended by uk.ac.manchester.cs.owl.owlapi.OWLObjectImpl
      extended by uk.ac.manchester.cs.owl.owlapi.OWLDataOneOfImpl
All Implemented Interfaces:
java.lang.Comparable<OWLObject>, OWLDataOneOf, OWLDataRange, OWLObject, OWLPropertyRange, SWRLPredicate

public class OWLDataOneOfImpl
extends OWLObjectImpl
implements OWLDataOneOf

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


Constructor Summary
OWLDataOneOfImpl(OWLDataFactory dataFactory, java.util.Set<? extends OWLLiteral> values)
           
 
Method Summary
 void accept(OWLDataRangeVisitor visitor)
           
<O> O
accept(OWLDataRangeVisitorEx<O> visitor)
           
 void accept(OWLDataVisitor visitor)
           
<O> O
accept(OWLDataVisitorEx<O> visitor)
           
 void accept(OWLObjectVisitor visitor)
           
<O> O
accept(OWLObjectVisitorEx<O> visitor)
           
 OWLDatatype asOWLDatatype()
          If this data range is a datatype then this method may be used to obtain it as a datatype (rather than using an explicit cast).
protected  int compareObjectOfSameType(OWLObject object)
           
 boolean equals(java.lang.Object obj)
           
 DataRangeType getDataRangeType()
          Gets the type of this data range
 java.util.Set<OWLLiteral> getValues()
          Gets the values (OWLLiterals) that this data range consists of.
 boolean isDatatype()
          Determines if this data range is a datatype (int, float, ...)
 boolean isTopDatatype()
          Determines if this data range is the top data type.
 
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
 

Constructor Detail

OWLDataOneOfImpl

public OWLDataOneOfImpl(OWLDataFactory dataFactory,
                        java.util.Set<? extends OWLLiteral> values)
Method Detail

getDataRangeType

public DataRangeType getDataRangeType()
Description copied from interface: OWLDataRange
Gets the type of this data range

Specified by:
getDataRangeType in interface OWLDataRange
Returns:
The data range type

getValues

public java.util.Set<OWLLiteral> getValues()
Description copied from interface: OWLDataOneOf
Gets the values (OWLLiterals) that this data range consists of. These values may be a mixture of org.semanticweb.owlapi.model.OWLTypedLiterals and org.semanticweb.owlapi.model.OWLStringLiterals.

Specified by:
getValues in interface OWLDataOneOf
Returns:
The values that this data range consists of.

isDatatype

public boolean isDatatype()
Description copied from interface: OWLDataRange
Determines if this data range is a datatype (int, float, ...)

Specified by:
isDatatype in interface OWLDataRange
Returns:
true if this datarange is a datatype, or false if it is not a datatype and is some other data range such as a data range restriction, data oneOf or data complementOf.

isTopDatatype

public boolean isTopDatatype()
Description copied from interface: OWLDataRange
Determines if this data range is the top data type.

Specified by:
isTopDatatype in interface OWLDataRange
Returns:
true if this data range is the top datatype otherwise false

asOWLDatatype

public OWLDatatype asOWLDatatype()
Description copied from interface: OWLDataRange
If this data range is a datatype then this method may be used to obtain it as a datatype (rather than using an explicit cast).

Specified by:
asOWLDatatype in interface OWLDataRange
Returns:
This data range as an OWLDatatype

equals

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

accept

public void accept(OWLDataVisitor visitor)
Specified by:
accept in interface OWLDataRange

accept

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

accept

public <O> O accept(OWLDataVisitorEx<O> visitor)
Specified by:
accept in interface OWLDataRange

accept

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

accept

public void accept(OWLDataRangeVisitor visitor)
Specified by:
accept in interface OWLDataRange

accept

public <O> O accept(OWLDataRangeVisitorEx<O> visitor)
Specified by:
accept in interface OWLDataRange

compareObjectOfSameType

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