Enum PictureType

  • All Implemented Interfaces:
    java.io.Serializable, java.lang.Comparable<PictureType>

    public enum PictureType
    extends java.lang.Enum<PictureType>
    General enum class to define a picture format/type
    Since:
    POI 5.0
    • Enum Constant Summary

      Enum Constants 
      Enum Constant Description
      BMP
      Windows Bitmap (.bmp)
      CLIENT
      client defined blip type - native-id 32 to 255
      CMYKJPEG
      JPEG in the YCCK or CMYK color space.
      DIB
      Device independent bitmap
      EMF
      Extended windows meta file
      EPS
      Encapsulated Postscript (.eps)
      ERROR
      Picture type error - specific to escher bse record
      GIF
      GIF image format
      JPEG
      JPEG format
      PICT
      Mac PICT format
      PNG
      PNG format
      SVG
      Scalable vector graphics (.svg) - supported by Office 2016 and higher
      TIFF
      Tag Image File (.tiff)
      UNKNOWN
      Unknown picture type - specific to escher bse record
      WDP
      Microsoft Windows Media Photo image (.wdp)
      WMF
      Windows Meta File
      WPG
      WordPerfect graphics (.wpg)
    • Enum Constant Detail

      • EMF

        public static final PictureType EMF
        Extended windows meta file
      • WMF

        public static final PictureType WMF
        Windows Meta File
      • PICT

        public static final PictureType PICT
        Mac PICT format
      • JPEG

        public static final PictureType JPEG
        JPEG format
      • DIB

        public static final PictureType DIB
        Device independent bitmap
      • GIF

        public static final PictureType GIF
        GIF image format
      • TIFF

        public static final PictureType TIFF
        Tag Image File (.tiff)
      • EPS

        public static final PictureType EPS
        Encapsulated Postscript (.eps)
      • BMP

        public static final PictureType BMP
        Windows Bitmap (.bmp)
      • WPG

        public static final PictureType WPG
        WordPerfect graphics (.wpg)
      • WDP

        public static final PictureType WDP
        Microsoft Windows Media Photo image (.wdp)
      • SVG

        public static final PictureType SVG
        Scalable vector graphics (.svg) - supported by Office 2016 and higher
      • UNKNOWN

        public static final PictureType UNKNOWN
        Unknown picture type - specific to escher bse record
      • ERROR

        public static final PictureType ERROR
        Picture type error - specific to escher bse record
      • CMYKJPEG

        public static final PictureType CMYKJPEG
        JPEG in the YCCK or CMYK color space.
      • CLIENT

        public static final PictureType CLIENT
        client defined blip type - native-id 32 to 255
    • Field Detail

      • contentType

        public final java.lang.String contentType
      • extension

        public final java.lang.String extension
      • ooxmlId

        public final int ooxmlId
    • Method Detail

      • values

        public static PictureType[] values()
        Returns an array containing the constants of this enum type, in the order they are declared. This method may be used to iterate over the constants as follows:
        for (PictureType c : PictureType.values())
            System.out.println(c);
        
        Returns:
        an array containing the constants of this enum type, in the order they are declared
      • valueOf

        public static PictureType valueOf​(java.lang.String name)
        Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)
        Parameters:
        name - the name of the enum constant to be returned.
        Returns:
        the enum constant with the specified name
        Throws:
        java.lang.IllegalArgumentException - if this enum type has no constant with the specified name
        java.lang.NullPointerException - if the argument is null
      • getContentType

        public java.lang.String getContentType()
      • getExtension

        public java.lang.String getExtension()
      • getOoxmlId

        public int getOoxmlId()
      • valueOf

        public static PictureType valueOf​(FileMagic fm)
        Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)
        Parameters:
        fm - the name of the enum constant to be returned.
        Returns:
        the enum constant with the specified name
        Throws:
        java.lang.IllegalArgumentException - if this enum type has no constant with the specified name
        java.lang.NullPointerException - if the argument is null
      • findByOoxmlId

        public static PictureType findByOoxmlId​(int ooxmlId)
        Parameters:
        ooxmlId - for PictureType
        Returns:
        PictureType, null if ooxmlId does not match any PictureTypes