示例#1
0
 public Object visit(OWLDataOneOf node) {
   if (node.getValues().size() != 1) {
     profileViolations.add(
         new UseOfDataOneOfWithMultipleLiterals(getCurrentOntology(), getCurrentAxiom(), node));
   }
   return null;
 }
 @Override
 public void visit(OWLDataOneOf node) {
   for (Iterator<OWLLiteral> it = node.getValues().iterator(); it.hasNext(); ) {
     writeOpenBrace();
     it.next().accept(this);
     writeCloseBrace();
     if (it.hasNext()) {
       writeSpace();
       write(OR);
       writeSpace();
     }
   }
 }
  public void visit(OWLDataOneOf node) {
    try {
      lastDataTypeExpressionPointer = owlDataRange2DataTypeExpressionPointerMap.get(node);
      if (lastDataTypeExpressionPointer == null) {

        List<DataValuePointer> pointers = new ArrayList<DataValuePointer>();
        for (OWLConstant con : node.getValues()) {
          con.accept(this);
          pointers.add(getLastDataValuePointer());
        }
        faCTPlusPlus.initArgList();
        for (DataValuePointer pointer : pointers) {
          faCTPlusPlus.addArg(pointer);
        }
        faCTPlusPlus.closeArgList();
        lastDataTypeExpressionPointer = faCTPlusPlus.getDataEnumeration();
        owlDataRange2DataTypeExpressionPointerMap.put(node, lastDataTypeExpressionPointer);
        dataTypeExpressionPointerMap.put(lastDataTypeExpressionPointer, node);
      }
    } catch (Exception e) {
      throw new FaCTPlusPlusRuntimeException(e);
    }
  }
 @Override
 public void visit(OWLDataOneOf node) {
   Set<OWLLiteral> vals = duplicateSet(node.getValues());
   obj = dataFactory.getOWLDataOneOf(vals);
 }
 public void visit(OWLDataOneOf node) {
   for (OWLLiteral val : node.getValues()) {
     val.accept(this);
   }
 }