Enum MimeTypes.Type

  • All Implemented Interfaces:
    java.io.Serializable, java.lang.Comparable<MimeTypes.Type>
    Enclosing class:
    MimeTypes

    public static enum MimeTypes.Type
    extends java.lang.Enum<MimeTypes.Type>
    • Field Detail

      • _string

        private final java.lang.String _string
      • _buffer

        private final java.nio.ByteBuffer _buffer
      • _charset

        private final java.nio.charset.Charset _charset
      • _charsetString

        private final java.lang.String _charsetString
      • _assumedCharset

        private final boolean _assumedCharset
    • Constructor Detail

      • Type

        private Type​(java.lang.String s)
      • Type

        private Type​(java.lang.String s,
                     java.nio.charset.Charset cs)
    • Method Detail

      • values

        public static MimeTypes.Type[] 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 (MimeTypes.Type c : MimeTypes.Type.values())
            System.out.println(c);
        
        Returns:
        an array containing the constants of this enum type, in the order they are declared
      • valueOf

        public static MimeTypes.Type 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
      • asBuffer

        public java.nio.ByteBuffer asBuffer()
      • getCharset

        public java.nio.charset.Charset getCharset()
      • getCharsetString

        public java.lang.String getCharsetString()
      • is

        public boolean is​(java.lang.String s)
      • asString

        public java.lang.String asString()
      • toString

        public java.lang.String toString()
        Overrides:
        toString in class java.lang.Enum<MimeTypes.Type>
      • isCharsetAssumed

        public boolean isCharsetAssumed()
      • getContentTypeField

        public HttpField getContentTypeField()