Class PartBuilder.AbstractPartBuilder<T extends org.springframework.http.codec.multipart.Part>
- java.lang.Object
-
- org.bremersee.apiclient.webflux.contract.spring.multipart.PartBuilder.AbstractPartBuilder<T>
-
- Type Parameters:
T
- the type parameter
- Direct Known Subclasses:
PartBuilder.AbstractFilePartBuilder
,PartBuilder.FormFieldPartBuilder
- Enclosing class:
- PartBuilder
public abstract static class PartBuilder.AbstractPartBuilder<T extends org.springframework.http.codec.multipart.Part> extends Object
The abstract part builder.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description abstract T
build()
Build part.PartBuilder.AbstractPartBuilder<T>
contentType(org.springframework.http.MediaType contentType)
Content type.protected int
getBufferSize()
Gets buffer size.protected org.springframework.core.io.buffer.DataBufferFactory
getDataBufferFactory()
Gets data buffer factory.protected org.springframework.http.HttpHeaders
getHeaders()
Gets headers.PartBuilder.AbstractPartBuilder<T>
header(String headerName, String... headerValues)
Header.PartBuilder.AbstractPartBuilder<T>
headers(Consumer<org.springframework.http.HttpHeaders> headersConsumer)
Headers.PartBuilder.AbstractPartBuilder<T>
withBufferSize(int bufferSize)
With buffer size.PartBuilder.AbstractPartBuilder<T>
withDataBufferFactory(org.springframework.core.io.buffer.DataBufferFactory dataBufferFactory)
With data buffer factory.
-
-
-
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 nameheaderValues
- 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
-
-