/* (non-Javadoc)
  * @see org.semanticweb.HermiT.model.dataranges.CanonicalDataRange#datatypeAccepts(org.semanticweb.HermiT.model.dataranges.DataConstant)
  */
 public boolean datatypeAccepts(DataConstant constant) {
   return constant.getImplementation() == Impl.IRational
       || constant.getImplementation() == Impl.IDecimal
       || constant.getImplementation() == Impl.IDouble
       || constant.getImplementation() == Impl.IFloat
       || constant.getImplementation() == Impl.IInteger;
 }
 /* (non-Javadoc)
  * @see org.semanticweb.HermiT.model.dataranges.CanonicalDataRange#accepts(org.semanticweb.HermiT.model.dataranges.DataConstant)
  */
 public boolean accepts(DataConstant constant) {
   if (!oneOf.isEmpty()) {
     return oneOf.contains(constant);
   }
   if (!notOneOf.isEmpty() && notOneOf.contains(constant)) {
     return false;
   }
   if (intervals.isEmpty()) return true;
   BigRational value = BigRational.parseRational(constant.getValue());
   for (RationalInterval i : intervals) {
     if (i.contains(value)) {
       return true;
     }
   }
   return false;
 }