Class CanvasItemsGenerator

  • All Implemented Interfaces:
    IIIFResource

    @RequestScope
    @Component
    public class CanvasItemsGenerator
    extends Object
    implements IIIFResource
    This generator wraps the domain model for a Presentation API 2.1.1 Sequence. The IIIF sequence conveys the ordering of the views of the object.

    Please note that this is a request scoped bean. This means that for each http request a different instance will be initialized by Spring and used to serve this specific request.

    Sequence is removed with Presentation API version 3.0. Canvases are added to the Manifest items property instead.

    Author:
    Michael Spalti mspalti@willamette.edu, Andrea Bollini (andrea.bollini at 4science.it)
    • Constructor Detail

      • CanvasItemsGenerator

        public CanvasItemsGenerator()
    • Method Detail

      • setIdentifier

        public void setIdentifier​(String identifier)
        Sets the required identifier property.
        Parameters:
        identifier - URI string
      • addCanvas

        public String addCanvas​(CanvasGenerator canvas)
        Adds a single Canvas to the sequence.
        Parameters:
        canvas - generator for canvas
      • generateResource

        public de.digitalcollections.iiif.model.sharedcanvas.Resource<de.digitalcollections.iiif.model.sharedcanvas.Sequence> generateResource()
        Description copied from interface: IIIFResource
        Creates and returns a resource model.
        Specified by:
        generateResource in interface IIIFResource
        Returns:
        resource model