/** * @return individuals to which we need to apply the initialization rules */ public Iterator<Individual> getInitializeIterator() { return new IndividualIterator(_abox); }
@Override public IndividualIterator getIndIterator() { return new IndividualIterator(this); }
/** * @return individuals to which we need to apply the initialization rules */ public Iterator<Individual> getInitializeIterator() { return new IndividualIterator(_abox); }
@Override public IndividualIterator getIndIterator() { return new IndividualIterator(this); }
protected void restoreAllValues() { for (final Iterator<Individual> i = new IndividualIterator(_abox); i.hasNext();) { final Individual ind = i.next(); _allValuesRule.apply(ind); } } }
protected void restoreAllValues() { for (final Iterator<Individual> i = new IndividualIterator(_abox); i.hasNext();) { final Individual ind = i.next(); _allValuesRule.apply(ind); } } }
final Iterator<Individual> i = new IndividualIterator(_abox); while (i.hasNext())
final Iterator<Individual> i = new IndividualIterator(_abox); while (i.hasNext())
for (final Iterator<Individual> i = new IndividualIterator(_abox); i.hasNext();)
for (final Iterator<Individual> i = new IndividualIterator(_abox); i.hasNext();)
/** * Choose a completion strategy based on the expressivity of the KB. The _abox given is not necessarily the ABox that belongs to this KB but can be a * derivative. * * @return the completion strategy choosen */ @Override public CompletionStrategy chooseStrategy(final ABox abox, final Expressivity expressivity) { if (null == abox || null == expressivity) return null; final boolean conceptSatisfiability = abox.size() == 1 && new IndividualIterator(abox).next().isConceptRoot(); // We don't need to use rules _strategy if we are checking concept satisfiability unless // there are nominals because then rules may affect concept satisfiability and we need // to use _rules _strategy if (getRules().size() > 0 && (expressivity.hasNominal() || !conceptSatisfiability)) return new ContinuousRulesStrategy(abox); final boolean fullDatatypeReasoning = OpenlletOptions.USE_FULL_DATATYPE_REASONING && (expressivity.hasCardinalityD() || expressivity.hasKeys()); if (!fullDatatypeReasoning) if (conceptSatisfiability && !expressivity.hasNominal()) return new EmptySRIQStrategy(abox); return new SROIQStrategy(abox); }
/** * Choose a completion strategy based on the expressivity of the KB. The _abox given is not necessarily the ABox that belongs to this KB but can be a * derivative. * * @return the completion strategy choosen */ @Override public CompletionStrategy chooseStrategy(final ABox abox, final Expressivity expressivity) { if (null == abox || null == expressivity) return null; final boolean conceptSatisfiability = abox.size() == 1 && new IndividualIterator(abox).next().isConceptRoot(); // We don't need to use rules _strategy if we are checking concept satisfiability unless // there are nominals because then rules may affect concept satisfiability and we need // to use _rules _strategy if (getRules().size() > 0 && (expressivity.hasNominal() || !conceptSatisfiability)) return new ContinuousRulesStrategy(abox); final boolean fullDatatypeReasoning = OpenlletOptions.USE_FULL_DATATYPE_REASONING && (expressivity.hasCardinalityD() || expressivity.hasKeys()); if (!fullDatatypeReasoning) if (conceptSatisfiability && !expressivity.hasNominal()) return new EmptySRIQStrategy(abox); return new SROIQStrategy(abox); }