Class MBTilesReader

    • Constructor Detail

      • MBTilesReader

        public MBTilesReader​(Object source,
                             Hints hints)
                      throws IOException
        Throws:
        IOException
    • Method Detail

      • getFormat

        public Format getFormat()
        Description copied from interface: GridCoverageReader
        Returns the format handled by this GridCoverageReader.
      • read

        public GridCoverage2D read​(GeneralParameterValue[] parameters)
                            throws IllegalArgumentException,
                                   IOException
        Description copied from class: AbstractGridCoverage2DReader
        Read the current grid coverage from the stream.

        Example:

         
         
         
        Specified by:
        read in interface GridCoverage2DReader
        Specified by:
        read in interface GridCoverageReader
        Specified by:
        read in class AbstractGridCoverage2DReader
        Parameters:
        parameters - Optional parameters matching Format.getReadParameters().
        Returns:
        a grid coverage from the input source.
        Throws:
        InvalidParameterNameException - if a parameter in parameters doesn't have a recognized name.
        InvalidParameterValueException - if a parameter in parameters doesn't have a valid value.
        ParameterNotFoundException - if a parameter was required for the operation but was not provided in the parameters list.
        IOException - if a read operation failed for some other input/output reason, including FileNotFoundException if no file with the given name can be found, or IIOException if an error was thrown by the underlying image library.
        IllegalArgumentException
      • readImage

        protected static BufferedImage readImage​(byte[] data,
                                                 String format)
                                          throws IOException
        Throws:
        IOException
      • getStartImage

        protected BufferedImage getStartImage​(BufferedImage copyFrom,
                                              int width,
                                              int height)
      • getStartImage

        protected BufferedImage getStartImage​(int imageType,
                                              int width,
                                              int height)
      • getStartImage

        protected BufferedImage getStartImage​(int width,
                                              int height)