Class ContentType.SettableContentType

    • Method Detail

      • reset

        public void reset()
        Description copied from class: ContentType
        Resets the ContentType state.
        Overrides:
        reset in class ContentType
      • set

        public void set​(ContentType contentType)
        Description copied from class: ContentType
        Sets the content type. This method must preserve any charset that may already have been set via a call to request/response.setContentType(), request/response.setLocale(), or request/response.setCharacterEncoding(). This method copies the passed contentType state into this ContentType.
        Overrides:
        set in class ContentType
        Parameters:
        contentType - the content type
      • set

        public void set​(String type)
        Description copied from class: ContentType
        Sets the content type. This method must preserve any charset that may already have been set via a call to request/response.setContentType(), request/response.setLocale(), or request/response.setCharacterEncoding().
        Overrides:
        set in class ContentType
        Parameters:
        type - the content type
      • setCharacterEncoding

        public void setCharacterEncoding​(String charset)
        Description copied from class: ContentType
        Sets the the character encoding (the content-type's charset attribute value).
        Overrides:
        setCharacterEncoding in class ContentType
        Parameters:
        charset - the character encoding (the content-type's charset attribute value)
      • setMimeType

        public void setMimeType​(String mimeType)
        Description copied from class: ContentType
        Sets the mime-type part of the content-type (the part without charset attribute).
        Overrides:
        setMimeType in class ContentType
        Parameters:
        mimeType - the mime-type part of the content-type (the part without charset attribute)