Package org.obolibrary.robot
Class RepairOperation
- java.lang.Object
-
- org.obolibrary.robot.RepairOperation
-
public class RepairOperation extends Object
Repair an ontology
-
-
Constructor Summary
Constructors Constructor Description RepairOperation()
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static Map<String,String>
getDefaultOptions()
Return a map from option name to default option value, for all the available repair options.static void
mergeAxiomAnnotations(org.semanticweb.owlapi.model.OWLOntology ontology)
Given an ontology, merge the annotations of duplicate axioms to create one axiom with all annotations.static void
repair(org.semanticweb.owlapi.model.OWLOntology ontology, IOHelper ioHelper)
Repairs ontologystatic void
repair(org.semanticweb.owlapi.model.OWLOntology ontology, IOHelper ioHelper, boolean mergeAxiomAnnotations)
Repairs ontologystatic void
repair(org.semanticweb.owlapi.model.OWLOntology ontology, IOHelper ioHelper, boolean mergeAxiomAnnotations, Set<org.semanticweb.owlapi.model.OWLAnnotationProperty> migrateAnnotations)
Repairs ontologystatic void
repair(org.semanticweb.owlapi.model.OWLOntology ontology, IOHelper ioHelper, Map<String,String> options)
Repairs ontologystatic void
repair(org.semanticweb.owlapi.model.OWLOntology ontology, IOHelper ioHelper, Map<String,String> options, boolean mergeAxiomAnnotations)
Repairs ontologystatic void
repair(org.semanticweb.owlapi.model.OWLOntology ontology, IOHelper ioHelper, Map<String,String> options, boolean mergeAxiomAnnotations, Set<org.semanticweb.owlapi.model.OWLAnnotationProperty> migrateAnnotations)
Repairs ontologystatic void
repairInvalidReferences(IOHelper iohelper, org.semanticweb.owlapi.model.OWLOntology ontology, Set<InvalidReferenceViolation> violations)
Repairs invalid referencesstatic void
repairInvalidReferences(IOHelper iohelper, org.semanticweb.owlapi.model.OWLOntology ontology, Set<InvalidReferenceViolation> violations, Set<org.semanticweb.owlapi.model.OWLAnnotationProperty> migrateAnnotations)
Repairs invalid references
-
-
-
Method Detail
-
getDefaultOptions
public static Map<String,String> getDefaultOptions()
Return a map from option name to default option value, for all the available repair options.- Returns:
- a map with default values for all available options
-
repair
public static void repair(org.semanticweb.owlapi.model.OWLOntology ontology, IOHelper ioHelper)
Repairs ontology- Parameters:
ontology
- the OWLOntology to repairioHelper
- IOHelper to work with the ontology
-
repair
public static void repair(org.semanticweb.owlapi.model.OWLOntology ontology, IOHelper ioHelper, boolean mergeAxiomAnnotations)
Repairs ontology- Parameters:
ontology
- the OWLOntology to repairioHelper
- IOHelper to work with the ontologymergeAxiomAnnotations
- if true, merge annotations on duplicate axioms
-
repair
public static void repair(org.semanticweb.owlapi.model.OWLOntology ontology, IOHelper ioHelper, boolean mergeAxiomAnnotations, Set<org.semanticweb.owlapi.model.OWLAnnotationProperty> migrateAnnotations)
Repairs ontology- Parameters:
ontology
- the OWLOntology to repairioHelper
- IOHelper to work with the ontologymergeAxiomAnnotations
- if true, merge annotations on duplicate axiomsmigrateAnnotations
- set of annotation properties for which to migrate values
-
repair
public static void repair(org.semanticweb.owlapi.model.OWLOntology ontology, IOHelper ioHelper, Map<String,String> options)
Repairs ontology- Parameters:
ontology
- the OWLOntology to repairioHelper
- IOHelper to work with the ontologyoptions
- map of repair options
-
repair
public static void repair(org.semanticweb.owlapi.model.OWLOntology ontology, IOHelper ioHelper, Map<String,String> options, boolean mergeAxiomAnnotations)
Repairs ontology- Parameters:
ontology
- the OWLOntology to repairioHelper
- IOHelper to work with the ontologyoptions
- map of repair optionsmergeAxiomAnnotations
- if true, merge annotations on duplicate axioms
-
repair
public static void repair(org.semanticweb.owlapi.model.OWLOntology ontology, IOHelper ioHelper, Map<String,String> options, boolean mergeAxiomAnnotations, Set<org.semanticweb.owlapi.model.OWLAnnotationProperty> migrateAnnotations)
Repairs ontology- Parameters:
ontology
- the OWLOntology to repairioHelper
- IOHelper to work with the ontologyoptions
- map of repair optionsmergeAxiomAnnotations
- if true, merge annotations on duplicate axiomsmigrateAnnotations
- set of annotation properties for which to migrate values
-
mergeAxiomAnnotations
public static void mergeAxiomAnnotations(org.semanticweb.owlapi.model.OWLOntology ontology)
Given an ontology, merge the annotations of duplicate axioms to create one axiom with all annotations.- Parameters:
ontology
- the OWLOntology to repair
-
repairInvalidReferences
public static void repairInvalidReferences(IOHelper iohelper, org.semanticweb.owlapi.model.OWLOntology ontology, Set<InvalidReferenceViolation> violations)
Repairs invalid referencesCurrently only able to repair references to deprecated classes.
Assumes OBO vocabulary
- Parameters:
iohelper
- IOHelper to work with the ontologyontology
- the OWLOntology to repairviolations
- set of references violations
-
repairInvalidReferences
public static void repairInvalidReferences(IOHelper iohelper, org.semanticweb.owlapi.model.OWLOntology ontology, Set<InvalidReferenceViolation> violations, Set<org.semanticweb.owlapi.model.OWLAnnotationProperty> migrateAnnotations)
Repairs invalid referencesCurrently only able to repair references to deprecated classes.
Assumes OBO vocabulary
- Parameters:
iohelper
- IOHelper to work with the ontologyontology
- the OWLOntology to repairviolations
- set of references violationsmigrateAnnotations
- set of annotation properties for which to migrate values
-
-