@Override protected DefaultNodeSet<OWLNamedIndividual> createDefaultNodeSet(Stream<Node<OWLNamedIndividual>> stream) { return new OWLNamedIndividualNodeSet(stream); } }
@Override public NodeSet<OWLNamedIndividual> asNode() { OWLNamedIndividualNodeSet set = new OWLNamedIndividualNodeSet(); for (IndividualSynset synset : this.synsets) { set.addNode(synset.asNode()); } return set; } }
protected NodeSet<OWLNamedIndividual> translateNodeSet(Stream<IndividualExpression> pointers) { OWLNamedIndividualNodeSet ns = new OWLNamedIndividualNodeSet(); // XXX skipping anonymous individuals - counterintuitive but // that's the specs for you pointers.filter(p -> p instanceof IndividualName).forEach(p -> ns.addEntity( individualTranslator.getEntityFromPointer((IndividualName) p))); return ns; }
public NodeSet<OWLNamedIndividual> getDifferentIndividuals(OWLNamedIndividual ind) throws InconsistentOntologyException, FreshEntitiesException, ReasonerInterruptedException, TimeOutException { return new OWLNamedIndividualNodeSet(); }
public NodeSet<OWLNamedIndividual> getObjectPropertyValues(@Nonnull OWLNamedIndividual ind, @Nonnull OWLObjectPropertyExpression pe) throws InconsistentOntologyException, FreshEntitiesException, ReasonerInterruptedException, TimeOutException { ensurePrepared(); OWLNamedIndividualNodeSet result = new OWLNamedIndividualNodeSet(); Node<OWLObjectPropertyExpression> inverses = getInverseObjectProperties(pe); for (OWLOntology ontology : getRootOntology().getImportsClosure()) { if (axiom.getProperty().equals(pe)) { if (getIndividualNodeSetPolicy().equals(IndividualNodeSetPolicy.BY_SAME_AS)) { result.addNode(getSameIndividuals(axiom.getObject().asOWLNamedIndividual())); result.addNode(new OWLNamedIndividualNode(axiom.getObject().asOWLNamedIndividual())); if (!invPe.isAnonymous() && inverses.contains(invPe.asOWLObjectProperty())) { if (getIndividualNodeSetPolicy().equals(IndividualNodeSetPolicy.BY_SAME_AS)) { result.addNode(getSameIndividuals(axiom.getObject().asOWLNamedIndividual())); result.addNode(new OWLNamedIndividualNode(axiom.getObject().asOWLNamedIndividual()));
public NodeSet<OWLNamedIndividual> getDifferentIndividuals(OWLNamedIndividual ind) throws InconsistentOntologyException, FreshEntitiesException, ReasonerInterruptedException, TimeOutException { return new OWLNamedIndividualNodeSet(); }
OWLObjectPropertyExpression pe) { ensurePrepared(); OWLNamedIndividualNodeSet result = new OWLNamedIndividualNodeSet(); Node<OWLObjectPropertyExpression> inverses = getInverseObjectProperties(pe); getRootOntology().importsClosure().flatMap(o -> o.objectPropertyAssertionAxioms(ind)) if (getIndividualNodeSetPolicy().equals(IndividualNodeSetPolicy.BY_SAME_AS)) { result .addNode(getSameIndividuals(axiom.getObject().asOWLNamedIndividual())); } else { result.addNode( new OWLNamedIndividualNode(axiom.getObject().asOWLNamedIndividual())); if (getIndividualNodeSetPolicy() .equals(IndividualNodeSetPolicy.BY_SAME_AS)) { result.addNode( getSameIndividuals(axiom.getObject().asOWLNamedIndividual())); } else { result.addNode(new OWLNamedIndividualNode( axiom.getObject().asOWLNamedIndividual()));
public NodeSet<OWLNamedIndividual> getInstances(OWLClassExpression ce, boolean direct) throws InconsistentOntologyException, ClassExpressionNotInProfileException, ReasonerInterruptedException, TimeOutException { return new OWLNamedIndividualNodeSet(); }
OWLObjectPropertyExpression pe) { ensurePrepared(); OWLNamedIndividualNodeSet result = new OWLNamedIndividualNodeSet(); Node<OWLObjectPropertyExpression> inverses = getInverseObjectProperties(pe); getRootOntology().importsClosure().flatMap(o -> o.objectPropertyAssertionAxioms(ind)) if (getIndividualNodeSetPolicy().equals(IndividualNodeSetPolicy.BY_SAME_AS)) { result .addNode(getSameIndividuals(axiom.getObject().asOWLNamedIndividual())); } else { result.addNode( new OWLNamedIndividualNode(axiom.getObject().asOWLNamedIndividual())); if (getIndividualNodeSetPolicy() .equals(IndividualNodeSetPolicy.BY_SAME_AS)) { result.addNode( getSameIndividuals(axiom.getObject().asOWLNamedIndividual())); } else { result.addNode(new OWLNamedIndividualNode( axiom.getObject().asOWLNamedIndividual()));
public NodeSet<OWLNamedIndividual> getObjectPropertyValues(OWLNamedIndividual ind, OWLObjectPropertyExpression pe) throws InconsistentOntologyException, ReasonerInterruptedException, TimeOutException { return new OWLNamedIndividualNodeSet(); }
OWLObjectPropertyExpression pe) { ensurePrepared(); OWLNamedIndividualNodeSet result = new OWLNamedIndividualNodeSet(); Node<OWLObjectPropertyExpression> inverses = getInverseObjectProperties(pe); getRootOntology().importsClosure().flatMap(o -> o.objectPropertyAssertionAxioms(ind)) if (getIndividualNodeSetPolicy().equals(IndividualNodeSetPolicy.BY_SAME_AS)) { result .addNode(getSameIndividuals(axiom.getObject().asOWLNamedIndividual())); } else { result.addNode( new OWLNamedIndividualNode(axiom.getObject().asOWLNamedIndividual())); if (getIndividualNodeSetPolicy() .equals(IndividualNodeSetPolicy.BY_SAME_AS)) { result.addNode( getSameIndividuals(axiom.getObject().asOWLNamedIndividual())); } else { result.addNode(new OWLNamedIndividualNode( axiom.getObject().asOWLNamedIndividual()));
public NodeSet<OWLNamedIndividual> getDifferentIndividuals(OWLNamedIndividual ind) throws InconsistentOntologyException, FreshEntitiesException, ReasonerInterruptedException, TimeOutException { return new OWLNamedIndividualNodeSet(); }
OWLObjectPropertyExpression pe) { ensurePrepared(); OWLNamedIndividualNodeSet result = new OWLNamedIndividualNodeSet(); Node<OWLObjectPropertyExpression> inverses = getInverseObjectProperties(pe); getRootOntology().importsClosure().flatMap(o -> o.objectPropertyAssertionAxioms(ind)) if (getIndividualNodeSetPolicy().equals(IndividualNodeSetPolicy.BY_SAME_AS)) { result .addNode(getSameIndividuals(axiom.getObject().asOWLNamedIndividual())); } else { result.addNode( new OWLNamedIndividualNode(axiom.getObject().asOWLNamedIndividual())); if (getIndividualNodeSetPolicy() .equals(IndividualNodeSetPolicy.BY_SAME_AS)) { result.addNode( getSameIndividuals(axiom.getObject().asOWLNamedIndividual())); } else { result.addNode(new OWLNamedIndividualNode( axiom.getObject().asOWLNamedIndividual()));
public NodeSet<OWLNamedIndividual> getDifferentIndividuals(OWLNamedIndividual ind) throws InconsistentOntologyException, ReasonerInterruptedException, TimeOutException { return new OWLNamedIndividualNodeSet(); }
public NodeSet<OWLNamedIndividual> getObjectPropertyValues(OWLNamedIndividual ind, OWLObjectPropertyExpression pe) throws InconsistentOntologyException, FreshEntitiesException, ReasonerInterruptedException, TimeOutException { ensurePrepared(); OWLNamedIndividualNodeSet result = new OWLNamedIndividualNodeSet(); Node<OWLObjectPropertyExpression> inverses = getInverseObjectProperties(pe); for (OWLOntology ontology : getRootOntology().getImportsClosure()) { if (axiom.getProperty().getSimplified().equals(pe.getSimplified())) { if (getIndividualNodeSetPolicy().equals(IndividualNodeSetPolicy.BY_SAME_AS)) { result.addNode(getSameIndividuals(axiom.getObject().asOWLNamedIndividual())); } else { result.addNode(new OWLNamedIndividualNode(axiom.getObject().asOWLNamedIndividual())); if (!invPe.isAnonymous() && inverses.contains(invPe.asOWLObjectProperty())) { if (getIndividualNodeSetPolicy().equals(IndividualNodeSetPolicy.BY_SAME_AS)) { result.addNode(getSameIndividuals(axiom.getObject().asOWLNamedIndividual())); } else { result.addNode(new OWLNamedIndividualNode(axiom.getObject().asOWLNamedIndividual()));
public NodeSet<OWLNamedIndividual> getDifferentIndividuals(OWLNamedIndividual ind) throws InconsistentOntologyException, ReasonerInterruptedException, TimeOutException { return new OWLNamedIndividualNodeSet(); }
public NodeSet<OWLNamedIndividual> getObjectPropertyValues(OWLNamedIndividual ind, OWLObjectPropertyExpression pe) throws InconsistentOntologyException, FreshEntitiesException, ReasonerInterruptedException, TimeOutException { OWLNamedIndividualNodeSet result = new OWLNamedIndividualNodeSet(); Node<OWLObjectProperty> inverses = getInverseObjectProperties(pe); for (OWLOntology ontology : getRootOntology().getImportsClosure()) { if (axiom.getProperty().getSimplified().equals(pe.getSimplified())) { if (getIndividualNodeSetPolicy().equals(IndividualNodeSetPolicy.BY_SAME_AS)) { result.addNode(getSameIndividuals(axiom.getObject().asOWLNamedIndividual())); result.addNode(new OWLNamedIndividualNode(axiom.getObject().asOWLNamedIndividual())); if (!invPe.isAnonymous() && inverses.contains(invPe.asOWLObjectProperty())) { if (getIndividualNodeSetPolicy().equals(IndividualNodeSetPolicy.BY_SAME_AS)) { result.addNode(getSameIndividuals(axiom.getObject().asOWLNamedIndividual())); result.addNode(new OWLNamedIndividualNode(axiom.getObject().asOWLNamedIndividual()));
public NodeSet<OWLNamedIndividual> getInstances(OWLClassExpression ce, boolean direct) throws InconsistentOntologyException, ClassExpressionNotInProfileException, ReasonerInterruptedException, TimeOutException { return new OWLNamedIndividualNodeSet(); }
public NodeSet<OWLNamedIndividual> getObjectPropertyValues(OWLNamedIndividual ind, OWLObjectPropertyExpression pe) throws InconsistentOntologyException, FreshEntitiesException, ReasonerInterruptedException, TimeOutException { ensurePrepared(); OWLNamedIndividualNodeSet result = new OWLNamedIndividualNodeSet(); Node<OWLObjectPropertyExpression> inverses = getInverseObjectProperties(pe); for (OWLOntology ontology : getRootOntology().getImportsClosure()) { if (axiom.getProperty().getSimplified().equals(pe.getSimplified())) { if (getIndividualNodeSetPolicy().equals(IndividualNodeSetPolicy.BY_SAME_AS)) { result.addNode(getSameIndividuals(axiom.getObject().asOWLNamedIndividual())); result.addNode(new OWLNamedIndividualNode(axiom.getObject().asOWLNamedIndividual())); if (!invPe.isAnonymous() && inverses.contains(invPe.asOWLObjectProperty())) { if (getIndividualNodeSetPolicy().equals(IndividualNodeSetPolicy.BY_SAME_AS)) { result.addNode(getSameIndividuals(axiom.getObject().asOWLNamedIndividual())); result.addNode(new OWLNamedIndividualNode(axiom.getObject().asOWLNamedIndividual()));
public NodeSet<OWLNamedIndividual> getObjectPropertyValues(OWLNamedIndividual ind, OWLObjectPropertyExpression pe) throws InconsistentOntologyException, ReasonerInterruptedException, TimeOutException { return new OWLNamedIndividualNodeSet(); }