Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add --drop-axiom-annotations feature with value constraints #1193

Merged
merged 6 commits into from
May 2, 2024

Conversation

matentzn
Copy link
Contributor

@matentzn matentzn commented Apr 8, 2024

Resolves #886

  • docs/ have been added/updated
  • tests have been added/updated
  • mvn verify says all tests pass
  • mvn site says all JavaDocs correct
  • CHANGELOG.md has been updated

This PR implements the last part of #886, which is to allow "value" expressions as constraints on the --drop-annotation-assertion parameter.

This does not at all affect the current behaviour on the master branch, and is a bit incomplete compared to the more powerful selector in remove and filter: only exact values and regex constraints are supported, nothing else (in particular not constraints like <IRI>).

  • @jamesaoverton note that i cannot run mvn site anymore: I get thousands of errors. Not sure why!

@matentzn matentzn requested a review from hkir-dev April 8, 2024 12:29
@@ -1660,11 +1662,15 @@ public static void trimOntology(OWLOntology ontology) {
* @param ontology OWLOntology to remove axiom annotations
* @param properties Annotation property IRIs to remove related axiom annotations.
*/
public static void removeAxiomAnnotations(OWLOntology ontology, List<IRI> properties) {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This breaks a public interface by removing the method with this signature. We try hard to avoid that. Can the old method/signature (with List<IRI>) be maintained (maybe as a thin wrapper) while the new method (with Map<IRI, String>) is added?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Done! Thanks you!

@jamesaoverton jamesaoverton merged commit fcc06fc into master May 2, 2024
3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

New parameter --axioms "axiom annotations" for remove and filter
2 participants