Class GifMapImageEncoder

java.lang.Object
com.kheops.util.encoders.AbstractMapImageEncoder
com.kheops.util.encoders.GifMapImageEncoder
All Implemented Interfaces:
MapImageEncoder

public class GifMapImageEncoder extends AbstractMapImageEncoder
  • Constructor Details

    • GifMapImageEncoder

      public GifMapImageEncoder()
  • Method Details

    • encode

      public void encode(BufferedImage im, OutputStream os, String format, String params) throws Exception
      Description copied from interface: MapImageEncoder
      Encodes a BufferedImage to an OutputStream using the specified image format and parameters.
      Parameters:
      im - the BufferedImage to encode.
      os - the OutputStream to encode to.
      format - the image format to encode with.
      params - the parameter to use when encoding.
      Throws:
      Exception - if an exception occurs.
    • getColorType

      public int getColorType(String format, String params)
      Description copied from interface: MapImageEncoder
      Returns the color type to use for the specified image format and parameters.
      Parameters:
      format - an image format. (ex. "jpeg", "gif", etc.)
      params - image format parameters.
      Returns:
      the color type to use for the specified image format and parameters.
    • getSupportedFormat

      public String[] getSupportedFormat()
      Description copied from interface: MapImageEncoder
      Returns an array of String that contains all supported image formats that are supported by this MapImageEncoder.
      Returns:
      an array of String that contains all supported image formats that are supported by this MapImageEncoder.