Class Attachment.Builder

  • Enclosing class:
    Attachment

    public static final class Attachment.Builder
    extends java.lang.Object
    Builds instances of type Attachment.

    Builder is not thread-safe and generally should not be stored in a field or collection, but instead used immediately to create instances.

    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      void setCharset​(java.nio.charset.Charset charset)
      Initializes the default value for the charset attribute.
      void setCharset​(java.util.Optional<java.nio.charset.Charset> charset)
      Initializes the value for the charset attribute.
      void setContent​(byte[] content)
      Initializes the value for the content attribute.
      void setMimeType​(org.springframework.util.MimeType mimeType)
      Initializes the value for the mimeType attribute.
      void setName​(java.lang.String name)
      Initializes the value for the name attribute.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Method Detail

      • setName

        public void setName​(java.lang.String name)
        Initializes the value for the name attribute.
        Parameters:
        name - The value for name
      • setMimeType

        public void setMimeType​(org.springframework.util.MimeType mimeType)
        Initializes the value for the mimeType attribute.
        Parameters:
        mimeType - The value for mimeType
      • setContent

        public void setContent​(byte[] content)
        Initializes the value for the content attribute.
        Parameters:
        content - The value for content
      • setCharset

        public void setCharset​(java.util.Optional<java.nio.charset.Charset> charset)
        Initializes the value for the charset attribute.
        Parameters:
        charset - The value for charset
      • setCharset

        public void setCharset​(java.nio.charset.Charset charset)
        Initializes the default value for the charset attribute.
        Parameters:
        charset - The value for charset