Class PartBuilder.AbstractPartBuilder<T extends org.springframework.http.codec.multipart.Part>

    • Method Detail

      • getDataBufferFactory

        protected org.springframework.core.io.buffer.DataBufferFactory getDataBufferFactory()
        Gets data buffer factory.
        Returns:
        the data buffer factory
      • getBufferSize

        protected int getBufferSize()
        Gets buffer size.
        Returns:
        the buffer size
      • getHeaders

        protected org.springframework.http.HttpHeaders getHeaders()
        Gets headers.
        Returns:
        the headers
      • withDataBufferFactory

        public PartBuilder.AbstractPartBuilder<T> withDataBufferFactory​(org.springframework.core.io.buffer.DataBufferFactory dataBufferFactory)
        With data buffer factory.
        Parameters:
        dataBufferFactory - the data buffer factory
        Returns:
        the abstract part builder
      • withBufferSize

        public PartBuilder.AbstractPartBuilder<T> withBufferSize​(int bufferSize)
        With buffer size.
        Parameters:
        bufferSize - the buffer size
        Returns:
        the abstract part builder
      • contentType

        public PartBuilder.AbstractPartBuilder<T> contentType​(org.springframework.http.MediaType contentType)
        Content type.
        Parameters:
        contentType - the content type
        Returns:
        the abstract part builder
      • header

        public PartBuilder.AbstractPartBuilder<T> header​(String headerName,
                                                         String... headerValues)
        Header.
        Parameters:
        headerName - the header name
        headerValues - the header values
        Returns:
        the abstract part builder
      • headers

        public PartBuilder.AbstractPartBuilder<T> headers​(Consumer<org.springframework.http.HttpHeaders> headersConsumer)
        Headers.
        Parameters:
        headersConsumer - the headers consumer
        Returns:
        the abstract part builder
      • build

        public abstract T build()
        Build part.
        Returns:
        the part