Class DefaultAnnotationReference

  • All Implemented Interfaces:
    io.annot8.core.references.AnnotationReference

    public class DefaultAnnotationReference
    extends io.annot8.common.implementations.references.AbstractAnnotationReference
    A reference which will always retrieve the latest annotation from the appropriate annotation store.

    Does not hold a reference to the group.

    • Constructor Detail

      • DefaultAnnotationReference

        public DefaultAnnotationReference​(io.annot8.core.data.Item item,
                                          String contentId,
                                          String annotationId)
        New reference either from another reference or manually created.
    • Method Detail

      • to

        public static DefaultAnnotationReference to​(io.annot8.core.data.Item item,
                                                    io.annot8.core.annotations.Annotation annotation)
        Create an annotation reference for the annotation.
      • getAnnotationId

        public String getAnnotationId()
      • getContentId

        public String getContentId()
      • toAnnotation

        public Optional<io.annot8.core.annotations.Annotation> toAnnotation()