Get annotations on standard annotations

Posted by jlbellier on
URL: http://owlready.306.s1.nabble.com/Get-annotations-on-standard-annotations-tp2989.html

Hello,

In my ontology, I have defined an annotation called visible, to determine if an object (class, data property, object property or annotation property) can be visible in my application.
To do that, I assign annotation visible to it and set the value false to hide the corresponding object (class, data property, object property or annotation property). If 'visible' is not assigned on my object, or if another value is set on 'visible' annotation for the corresponding objeft, I consider it as visible and show it.

I works fine except for standard annotations, like comment, label, .. i.e. all the annotations that belong to the namespaces owl or rdfs.

In my process, I use getattr(, 'visible') and check if the result. If it is [false], I know that the annotation 'visible' has been set on my object with the value false, so I can decide what to do (in the present case, hide the object).

But for standard annotations, even if I put annotation 'visible' on it with the value false, getattr(, 'visible') always return an empty list.

Is there a way to get the annotations set on these standard annotations ? I check the standard object like __dict__ or other internal objects, but could not find any way to get any information.

Any hep woulf be greatly appreciated.

Thank you in advance.

Best regards,
Jean-Luc.