@Override public void contextMarkSaturated(C context) { IndexedContextRoot root = context.getRoot(); if (!context.containsConclusion( conclusionFactory_.getContradiction(root))) { return; } // else if (root instanceof IndexedIndividual) { tellInconsistentIndividual( (IndexedIndividual) root); } else if (root == owlThing_) { tellInconsistentOwlThing(); } }
@Override public void contextMarkSaturated(C context) { IndexedContextRoot root = context.getRoot(); if (!context.containsConclusion( conclusionFactory_.getContradiction(root))) { return; } // else if (root instanceof IndexedIndividual) { tellInconsistentIndividual( (IndexedIndividual) root); } else if (root == owlThing_) { tellInconsistentOwlThing(); } }
@Override public void contextMarkSaturated(C context) { IndexedContextRoot root = context.getRoot(); if (!context.containsConclusion( conclusionFactory_.getContradiction(root))) { return; } // else if (root instanceof IndexedIndividual) { tellInconsistentIndividual( (IndexedIndividual) root); } else if (root == owlThing_) { tellInconsistentOwlThing(); } }
@Override public Collection<? extends EntailmentInference> getInferences( final Object conclusion) { if (!getQuery().equals(conclusion)) { return Collections.emptySet(); } // else final C context = saturationState.getContext(existential_); if (context == null) { // not entailed return Collections.emptySet(); } // else final SubClassInclusionComposed subsumption = conclusionFactory .getSubClassInclusionComposed(existential_, domain_); if (context.containsConclusion(subsumption)) { return Collections.singleton( new DerivedClassInclusionEntailsObjectPropertyDomainAxiomImpl( getQuery(), subsumption)); } // else return Collections.emptySet(); }
@Override public Collection<? extends EntailmentInference> getInferences( final Object conclusion) { if (!getQuery().equals(conclusion)) { return Collections.emptySet(); } // else final C context = saturationState.getContext(existential_); if (context == null) { // not entailed return Collections.emptySet(); } // else final SubClassInclusionComposed subsumption = conclusionFactory .getSubClassInclusionComposed(existential_, domain_); if (context.containsConclusion(subsumption)) { return Collections.singleton( new DerivedClassInclusionEntailsObjectPropertyDomainAxiomImpl( getQuery(), subsumption)); } // else return Collections.emptySet(); }
@Override public Collection<? extends EntailmentInference> getInferences( final Object conclusion) { if (!getQuery().equals(conclusion)) { return Collections.emptySet(); } // else final C context = saturationState.getContext(individual_); if (context == null) { // not entailed return Collections.emptySet(); } // else final SubClassInclusionComposed subsumption = conclusionFactory .getSubClassInclusionComposed(individual_, classExpression_); if (context.containsConclusion(subsumption)) { return Collections.singleton( new DerivedClassInclusionEntailsClassAssertionAxiomImpl( getQuery(), subsumption)); } // else return Collections.emptySet(); }
@Override public Collection<? extends EntailmentInference> getInferences( final Object conclusion) { if (!getQuery().equals(conclusion)) { return Collections.emptySet(); } // else final C context = saturationState.getContext(subject_); if (context == null) { // not entailed return Collections.emptySet(); } // else final SubClassInclusionComposed subsumption = conclusionFactory .getSubClassInclusionComposed(subject_, objectExistential_); if (context.containsConclusion(subsumption)) { return Collections.singleton( new DerivedClassInclusionEntailsObjectPropertyAssertionAxiomImpl( getQuery(), subsumption)); } // else return Collections.emptySet(); }
@Override public Collection<? extends EntailmentInference> getInferences( final Object conclusion) { if (!getQuery().equals(conclusion)) { return Collections.emptySet(); } // else final C context = saturationState.getContext(subject_); if (context == null) { // not entailed return Collections.emptySet(); } // else final SubClassInclusionComposed subsumption = conclusionFactory .getSubClassInclusionComposed(subject_, objectExistential_); if (context.containsConclusion(subsumption)) { return Collections.singleton( new DerivedClassInclusionEntailsObjectPropertyAssertionAxiomImpl( getQuery(), subsumption)); } // else return Collections.emptySet(); }
@Override public Collection<? extends EntailmentInference> getInferences( final Object conclusion) { if (!getQuery().equals(conclusion)) { return Collections.emptySet(); } // else final C context = saturationState.getContext(existential_); if (context == null) { // not entailed return Collections.emptySet(); } // else final SubClassInclusionComposed subsumption = conclusionFactory .getSubClassInclusionComposed(existential_, domain_); if (context.containsConclusion(subsumption)) { return Collections.singleton( new DerivedClassInclusionEntailsObjectPropertyDomainAxiomImpl( getQuery(), subsumption)); } // else return Collections.emptySet(); }
@Override public Collection<? extends EntailmentInference> getInferences( final Object conclusion) { if (!getQuery().equals(conclusion)) { return Collections.emptySet(); } // else final C context = saturationState.getContext(individual_); if (context == null) { // not entailed return Collections.emptySet(); } // else final SubClassInclusionComposed subsumption = conclusionFactory .getSubClassInclusionComposed(individual_, classExpression_); if (context.containsConclusion(subsumption)) { return Collections.singleton( new DerivedClassInclusionEntailsClassAssertionAxiomImpl( getQuery(), subsumption)); } // else return Collections.emptySet(); }
@Override public Collection<? extends EntailmentInference> getInferences( final Object conclusion) { if (!getQuery().equals(conclusion)) { return Collections.emptySet(); } // else final C context = saturationState.getContext(individual_); if (context == null) { // not entailed return Collections.emptySet(); } // else final SubClassInclusionComposed subsumption = conclusionFactory .getSubClassInclusionComposed(individual_, classExpression_); if (context.containsConclusion(subsumption)) { return Collections.singleton( new DerivedClassInclusionEntailsClassAssertionAxiomImpl( getQuery(), subsumption)); } // else return Collections.emptySet(); }
@Override public Collection<? extends EntailmentInference> getInferences( final Object conclusion) { if (!getQuery().equals(conclusion)) { return Collections.emptySet(); } // else final C context = saturationState.getContext(subject_); if (context == null) { // not entailed return Collections.emptySet(); } // else final SubClassInclusionComposed subsumption = conclusionFactory .getSubClassInclusionComposed(subject_, objectExistential_); if (context.containsConclusion(subsumption)) { return Collections.singleton( new DerivedClassInclusionEntailsObjectPropertyAssertionAxiomImpl( getQuery(), subsumption)); } // else return Collections.emptySet(); }
@Override protected Boolean defaultVisit(ClassConclusion conclusion) { Context originContext = state_.getContext(conclusion.getTraceRoot()); if (originContext.isInitialized() && originContext.isSaturated()) { LOGGER_.error("{}: adding conclusion {} to saturated context {}", contextRef_, conclusion, get().containsConclusion(conclusion) ? "(it is already there)" : ""); } return true; }
@Override protected Boolean defaultVisit(ClassConclusion conclusion) { Context originContext = state_.getContext(conclusion.getTraceRoot()); if (originContext.isInitialized() && originContext.isSaturated()) { LOGGER_.error("{}: adding conclusion {} to saturated context {}", contextRef_, conclusion, get().containsConclusion(conclusion) ? "(it is already there)" : ""); } return true; }
@Override protected Boolean defaultVisit(ClassConclusion conclusion) { Context originContext = state_.getContext(conclusion.getTraceRoot()); if (originContext.isInitialized() && originContext.isSaturated()) { LOGGER_.error("{}: adding conclusion {} to saturated context {}", contextRef_, conclusion, get().containsConclusion(conclusion) ? "(it is already there)" : ""); } return true; }
@Override public Boolean visit(ContextInitialization conclusion) { Context context = get(); if (context.containsConclusion(conclusion)) return false; // else // Mark context as non-saturated if conclusion was not already // initialized. It is important to mark before we insert, otherwise // the context can be found initialized and saturated when it is not. writer_.markAsNotSaturated(context.getRoot()); return defaultVisit(conclusion); }
@Override public Boolean visit(ContextInitialization conclusion) { Context context = get(); if (context.containsConclusion(conclusion)) return false; // else // Mark context as non-saturated if conclusion was not already // initialized. It is important to mark before we insert, otherwise // the context can be found initialized and saturated when it is not. writer_.markAsNotSaturated(context.getRoot()); return defaultVisit(conclusion); }
@Override public Boolean visit(ContextInitialization conclusion) { Context context = get(); if (context.containsConclusion(conclusion)) return false; // else // Mark context as non-saturated if conclusion was not already // initialized. It is important to mark before we insert, otherwise // the context can be found initialized and saturated when it is not. writer_.markAsNotSaturated(context.getRoot()); return defaultVisit(conclusion); }
final SubClassInclusionComposed subsumption = conclusionFactory .getSubClassInclusionComposed(subClass_, superClass_); if (context.containsConclusion(contradiction)) { result.add( new SubClassInconsistencyEntailsSubClassOfAxiomImpl( if (context.containsConclusion(subsumption)) { result.add( new DerivedClassInclusionEntailsSubClassOfAxiomImpl(
static ClassConclusion getConclusionToTrace(Context context, IndexedClassExpression subsumer) { if (context != null) { IndexedContextRoot root = context.getRoot(); ClassConclusion contradiction = FACTORY_.getContradiction(root); if (context.containsConclusion(contradiction)) { return contradiction; } return FACTORY_.getSubClassInclusionComposed(root, subsumer); } throw new IllegalArgumentException("Context may not be null"); }