public List<OWLOntologyChange> applyChanges(List<? extends OWLOntologyChange> changes) { List<OWLOntologyChange> appliedChanges = new ArrayList<OWLOntologyChange>(changes.size() + 2); fireBeginChanges(changes.size()); for (OWLOntologyChange change : changes) { appliedChanges.addAll(enactChangeApplication(change)); fireChangeApplied(change); } fireEndChanges(); broadcastChanges(changes); return appliedChanges; }
public List<OWLOntologyChange> removeAxioms(OWLOntology ont, Set<? extends OWLAxiom> axioms) { List<OWLOntologyChange> changes = new ArrayList<OWLOntologyChange>(axioms.size()); // Optimisation - Precheck that the ontology is an immutable ontology. if (ont instanceof OWLMutableOntology) { fireBeginChanges(axioms.size()); for (OWLAxiom ax : axioms) { // Further optimisation - precheck that the axiom is in the ontology. if (ont.containsAxiom(ax)) { RemoveAxiom removeAxiom = new RemoveAxiom(ont, ax); changes.addAll(enactChangeApplication(removeAxiom)); fireChangeApplied(removeAxiom); } } fireEndChanges(); } broadcastChanges(changes); return changes; }
public List<OWLOntologyChange> addAxioms(OWLOntology ont, Set<? extends OWLAxiom> axioms) { List<OWLOntologyChange> changes = new ArrayList<OWLOntologyChange>(axioms.size()); // Optimisation - Precheck that the ontology is an immutable ontology. if (ont instanceof OWLMutableOntology) { fireBeginChanges(axioms.size()); for (OWLAxiom ax : axioms) { // Further optimisation - precheck that the axiom isn't in the ontology. if (!ont.containsAxiom(ax)) { AddAxiom addAx = new AddAxiom(ont, ax); changes.addAll(enactChangeApplication(addAx)); fireChangeApplied(addAx); } } fireEndChanges(); } broadcastChanges(changes); return changes; }
fireBeginChanges(changes.size()); actuallyApply(changes, rollbackRequested, allNoOps, appliedChanges); if (rollbackRequested.get()) {
fireBeginChanges(changes.size()); actuallyApply(changes, rollbackRequested, allNoOps, appliedChanges); if (rollbackRequested.get()) {
fireBeginChanges(changes.size()); actuallyApply(changes, rollbackRequested, allNoOps, appliedChanges); if (rollbackRequested.get()) {
public List<OWLOntologyChange> applyChange(OWLOntologyChange change) { fireBeginChanges(1); List<OWLOntologyChange> changes = enactChangeApplication(change); fireChangeApplied(change); fireEndChanges(); broadcastChanges(changes); return changes; }
fireBeginChanges(changes.size()); actuallyApply(changes, rollbackRequested, allNoOps, appliedChanges); if (rollbackRequested.get()) {