Class GridCoverageWriterProgressAdapter

  • All Implemented Interfaces:
    EventListener, IIOWriteProgressListener, IIOWriteWarningListener

    public class GridCoverageWriterProgressAdapter
    extends BaseGridCoverageProgressAdapter
    implements IIOWriteProgressListener, IIOWriteWarningListener
    This class provide a means to wrap a GeoTools ProgressListener and have it control an ImageWriter while it is actually doing a ImageWriter.write(javax.imageio.IIOImage) operation.

    We also give user the ability to cancel the writing process

    Simone Giannecchini, GeoSolutions SAS
    • Constructor Detail

      • GridCoverageWriterProgressAdapter

        public GridCoverageWriterProgressAdapter​(ProgressListener monitor,
                                                 int numImages)
      • GridCoverageWriterProgressAdapter

        public GridCoverageWriterProgressAdapter​(ProgressListener monitor)
    • Method Detail

      • warningOccurred

        public void warningOccurred​(ImageWriter source,
                                    int imageIndex,
                                    String warning)
        Specified by:
        warningOccurred in interface IIOWriteWarningListener
      • imageStarted

        public void imageStarted​(ImageWriter source,
                                 int imageIndex)
        Specified by:
        imageStarted in interface IIOWriteProgressListener
      • imageProgress

        public void imageProgress​(ImageWriter source,
                                  float percentageDone)
        Specified by:
        imageProgress in interface IIOWriteProgressListener
      • imageComplete

        public void imageComplete​(ImageWriter source)
        Specified by:
        imageComplete in interface IIOWriteProgressListener
      • thumbnailStarted

        public void thumbnailStarted​(ImageWriter source,
                                     int imageIndex,
                                     int thumbnailIndex)
        Specified by:
        thumbnailStarted in interface IIOWriteProgressListener
      • thumbnailProgress

        public void thumbnailProgress​(ImageWriter source,
                                      float percentageDone)
        Specified by:
        thumbnailProgress in interface IIOWriteProgressListener
      • thumbnailComplete

        public void thumbnailComplete​(ImageWriter source)
        Specified by:
        thumbnailComplete in interface IIOWriteProgressListener
      • writeAborted

        public void writeAborted​(ImageWriter source)
        Specified by:
        writeAborted in interface IIOWriteProgressListener