- Type Parameters:
T
- Type of the class which this builder support is added to.
- All Known Implementing Classes:
MediaContext.Builder
,WebClient.Builder
,WebServer.Builder
public interface MediaContextBuilder<T>
Adds methods to support adding readers, writers and media services to the builder.
-
Method Summary
Modifier and TypeMethodDescriptionaddMediaSupport
(MediaSupport mediaSupport) Adds new instance ofMediaSupport
.default T
addMediaSupport
(Supplier<MediaSupport> mediaSupportSupplier) Adds new instance ofMediaSupport
.addReader
(MessageBodyReader<?> reader) Registers new reader.default T
addReader
(Supplier<MessageBodyReader<?>> readerSupplier) Registers new reader.addStreamReader
(MessageBodyStreamReader<?> streamReader) Registers new stream reader.default T
addStreamReader
(Supplier<MessageBodyStreamReader<?>> streamReaderSupplier) Registers new stream reader.addStreamWriter
(MessageBodyStreamWriter<?> streamWriter) Registers new stream writer.default T
addStreamWriter
(Supplier<MessageBodyStreamWriter<?>> streamWriterSupplier) Registers new stream writer.addWriter
(MessageBodyWriter<?> writer) Registers new writer.default T
addWriter
(Supplier<MessageBodyWriter<?>> writerSupplier) Registers new writer.
-
Method Details
-
addMediaSupport
Adds new instance ofMediaSupport
.- Parameters:
mediaSupport
- media support- Returns:
- updated instance of the builder
-
addMediaSupport
Adds new instance ofMediaSupport
.- Parameters:
mediaSupportSupplier
- supplier for media support- Returns:
- updated instance of the builder
-
addReader
Registers new reader.- Parameters:
reader
- reader- Returns:
- updated instance of the builder
-
addReader
Registers new reader.- Parameters:
readerSupplier
- supplier for a new reader- Returns:
- updated instance of the builder
-
addStreamReader
Registers new stream reader.- Parameters:
streamReader
- stream reader- Returns:
- updated instance of the builder
-
addStreamReader
Registers new stream reader.- Parameters:
streamReaderSupplier
- supplier for a new stream reader- Returns:
- updated instance of the builder
-
addWriter
Registers new writer.- Parameters:
writer
- writer- Returns:
- updated instance of the builder
-
addWriter
Registers new writer.- Parameters:
writerSupplier
- writer- Returns:
- updated instance of the builder
-
addStreamWriter
Registers new stream writer.- Parameters:
streamWriter
- stream writer- Returns:
- updated instance of the builder
-
addStreamWriter
Registers new stream writer.- Parameters:
streamWriterSupplier
- stream writer- Returns:
- updated instance of the builder
-