コード例 #1
0
    public void visit(OWLDataAllValuesFrom object) {
      // if the filler is the negation of a supported range then we will leave the expression as if
      // it was in the head,
      // because when we overapproximate we are only going to look at the property so there's no
      // point in decomposing it further
      // if the filler is positive, however, we will decompose it a bit
      LiteralDataRange literalRange = m_dataRangeConverter.convertDataRange(object.getFiller());
      if (object.getProperty().isOWLTopDataProperty()) {
        if (literalRange.isAlwaysFalse()) return; // bottom
      }

      Variable y = nextY();
      m_bodyAtoms.add(getRoleAtom(object.getProperty(), X, y));
      if (literalRange.isNegatedInternalDatatype()) {
        InternalDatatype negatedRange = (InternalDatatype) literalRange.getNegation();
        if (!negatedRange.isAlwaysTrue()) m_bodyAtoms.add(Atom.create(negatedRange, y));
      } else {
        if (!literalRange.isAlwaysFalse()) {
          if (object.getFiller() instanceof OWLDataOneOf) {
            for (OWLLiteral lit : ((OWLDataOneOf) object.getFiller()).getValues())
              m_headAtoms.add(
                  Atom.create(Equality.INSTANCE, y, (Constant) lit.accept(m_dataRangeConverter)));
          } else m_headAtoms.add(Atom.create((DLPredicate) literalRange, y));
        }
      }
    }
コード例 #2
0
 @Override
 public void visit(OWLDataAllValuesFrom desc) {
   desc.getProperty().accept(this);
   OWLDataPropertyExpression prop = (OWLDataPropertyExpression) obj;
   desc.getFiller().accept(this);
   OWLDataRange filler = (OWLDataRange) obj;
   obj = dataFactory.getOWLDataAllValuesFrom(prop, filler);
 }
コード例 #3
0
 @Override
 public void visit(OWLDataAllValuesFrom node) {
   write(ALL);
   writeSpace();
   node.getProperty().accept(this);
   writeSpace();
   node.getFiller().accept(this);
 }
コード例 #4
0
 @Override
 public void visit(OWLDataAllValuesFrom desc) {
   handleObject(desc);
   desc.getProperty().accept(this);
 }
コード例 #5
0
 @Override
 public void visit(OWLDataAllValuesFrom ce) {
   ce.getFiller().accept(this);
   ce.getProperty().accept(this);
 }
 public void visit(OWLDataAllValuesFrom desc) {
   desc.getProperty().accept(this);
   desc.getFiller().accept(this);
 }