See discussion at ome/omero-py#489
When we load Annotations as proposed at ome/omero-web#682
E.g. /api/v0/m/annotations/?type=map&dataset=251&dataset=102
and these Annotations are marshalled with omero-marshal we don't have any way of preserving the AnnotationLink information.
This means that we don't know which Annotation is linked to which Dataset and we also lose permission, creationEvent etc that is on the AnnotationLink.
Instead, for users who want that info, we could load AnnotationLinks instead of annotations e.g.
/api/v0/m/annotationlinks/?type=map&dataset=251&dataset=102
These AnnotationLinks would then need to be marshalled by omero-marshal, with each object having a parent and child attribute containing the linked Object and Annotation respectively.
Since there is no AnnotationLink in the OME model, I guess this would look like:
class AnnotationLinkEncoder(Encoder):
TYPE = 'TBD#AnnotationLink'
See discussion at ome/omero-py#489
When we load Annotations as proposed at ome/omero-web#682
E.g.
/api/v0/m/annotations/?type=map&dataset=251&dataset=102and these Annotations are marshalled with
omero-marshalwe don't have any way of preserving theAnnotationLinkinformation.This means that we don't know which Annotation is linked to which Dataset and we also lose permission, creationEvent etc that is on the
AnnotationLink.Instead, for users who want that info, we could load
AnnotationLinksinstead of annotations e.g./api/v0/m/annotationlinks/?type=map&dataset=251&dataset=102These
AnnotationLinkswould then need to be marshalled byomero-marshal, with each object having aparentandchildattribute containing the linked Object and Annotation respectively.Since there is no
AnnotationLinkin the OME model, I guess this would look like: