- Type Parameters:
T
- type or base type supported by the operator
- All Superinterfaces:
MessageBodyOperator<MessageBodyWriterContext>
- All Known Implementing Classes:
BodyPartBodyStreamWriter
Conversion operator that generate HTTP payload from a stream of objects.
-
Nested Class Summary
Nested classes/interfaces inherited from interface io.helidon.media.common.MessageBodyOperator
MessageBodyOperator.PredicateResult
-
Method Summary
Modifier and TypeMethodDescriptionmarshall
(Flow.Publisher<T> publisher, GenericType<T> type) Create a marshalling function that can be used to marshall the publisher with a context.write
(Flow.Publisher<? extends T> publisher, GenericType<? extends T> type, MessageBodyWriterContext context) Generate HTTP payload from the given stream of objects.Methods inherited from interface io.helidon.media.common.MessageBodyOperator
accept
-
Method Details
-
write
Flow.Publisher<DataChunk> write(Flow.Publisher<? extends T> publisher, GenericType<? extends T> type, MessageBodyWriterContext context) Generate HTTP payload from the given stream of objects.- Parameters:
publisher
- objects to convert to payloadtype
- requested type representationcontext
- writer context- Returns:
- HTTP payload publisher
-
marshall
default Function<MessageBodyWriterContext,Flow.Publisher<DataChunk>> marshall(Flow.Publisher<T> publisher, GenericType<T> type) Create a marshalling function that can be used to marshall the publisher with a context.- Parameters:
publisher
- objects to convert to payloadtype
- requested type representation- Returns:
- Marshalling function
-