Uses of Interface
io.helidon.common.http.DataChunk
Package
Description
HTTP APIs and implementations usable by both server and client side of the HTTP story.
Common classes for accessing JSON based REST APIs of third party systems.
Common classes for processing content with a specific
MediaType
.Helidon Media MultiPart.
A reactive client for rest calls.
Reactive web server API.
-
Uses of DataChunk in io.helidon.common.http
Modifier and TypeMethodDescriptionstatic DataChunk
DataChunk.create
(boolean flush, boolean readOnly, Runnable releaseCallback, ByteBuffer... byteBuffers) Creates a reusable byteBuffers chunk.static DataChunk
DataChunk.create
(boolean flush, boolean readOnly, ByteBuffer... byteBuffers) Creates a reusable data chunk.static DataChunk
DataChunk.create
(boolean flush, Runnable releaseCallback, ByteBuffer... byteBuffers) Creates a reusable byteBuffers chunk.static DataChunk
DataChunk.create
(boolean flush, ByteBuffer... byteBuffers) Creates a reusable data chunk.static DataChunk
DataChunk.create
(byte[] bytes) Creates a simple byte array backed data chunk.static DataChunk
DataChunk.create
(ByteBuffer byteBuffer) Creates a simpleByteBuffer
backed data chunk.static DataChunk
DataChunk.create
(ByteBuffer... byteBuffers) Creates a data chunk backed by one or more ByteBuffer.default DataChunk
DataChunk.duplicate()
Makes a copy of this data chunk including its underlyingByteBuffer
.Modifier and TypeMethodDescriptiondefault Optional<CompletableFuture<DataChunk>>
DataChunk.writeFuture()
Returns a write future associated with this chunk.Modifier and TypeMethodDescriptiondefault CompletionStage<? extends R>
Reader.apply
(Flow.Publisher<DataChunk> publisher) Deprecated.Transforms a publisher into a completion stage.CompletionStage<? extends R>
Reader.apply
(Flow.Publisher<DataChunk> publisher, Class<? super R> clazz) Deprecated.Transforms a publisher into a completion stage.default <T extends R>
CompletionStage<? extends T>Reader.applyAndCast
(Flow.Publisher<DataChunk> publisher, Class<T> type) Deprecated.Transforms a publisher into a completion stage.void
Content.registerFilter
(Function<Flow.Publisher<DataChunk>, Flow.Publisher<DataChunk>> function) Deprecated.void
Content.registerFilter
(Function<Flow.Publisher<DataChunk>, Flow.Publisher<DataChunk>> function) Deprecated.since 2.0.0, useio.helidon.media.common.MessageBodyReaderContext.registerFilter
void
Content.subscribe
(Flow.Subscriber<? super DataChunk> subscriber) Deprecated.If possible, adds the given Subscriber to this publisher.default void
DataChunk.writeFuture
(CompletableFuture<DataChunk> writeFuture) Set a write future that will complete when data chunk has been written to a connection. -
Uses of DataChunk in io.helidon.integrations.common.rest
Modifier and TypeMethodDescriptiondefault <R,
T extends ApiOptionalResponse<R>>
Single<T>RestApi.getPublisher
(String path, ApiRequest<?> request, ApiOptionalResponse.BuilderBase<?, T, Multi<DataChunk>, R> responseBuilder) Get with a response consisting of a stream.protected <R,
T extends ApiOptionalResponse<R>>
Single<T>RestApiBase.handlePublisherResponse
(String path, ApiRequest<?> request, Http.RequestMethod method, String requestId, WebClientResponse response, ApiOptionalResponse.BuilderBase<?, T, Multi<DataChunk>, R> responseBuilder) Handle response for optional publisher entity.<T extends ApiResponse>
Single<T>RestApi.invokeBytesRequest
(Http.RequestMethod method, String path, ApiRequest<?> request, Flow.Publisher<DataChunk> byteRequest, ApiResponse.Builder<?, T> responseBuilder) The request media type should be provided in request, falls back toMediaType.APPLICATION_OCTET_STREAM
.<T extends ApiResponse>
Single<T>RestApiBase.invokeBytesRequest
(Http.RequestMethod method, String path, ApiRequest<?> request, Flow.Publisher<DataChunk> byteRequest, ApiResponse.Builder<?, T> responseBuilder) <R,
T extends ApiOptionalResponse<R>>
Single<T>RestApi.invokePublisherResponse
(Http.RequestMethod method, String path, ApiRequest<?> request, ApiOptionalResponse.BuilderBase<?, T, Multi<DataChunk>, R> responseBuilder) Invoke API call that is expected to return bytes as a publisher.<R,
T extends ApiOptionalResponse<R>>
Single<T>RestApiBase.invokePublisherResponse
(Http.RequestMethod method, String path, ApiRequest<?> request, ApiOptionalResponse.BuilderBase<?, T, Multi<DataChunk>, R> responseBuilder) protected Supplier<Single<WebClientResponse>>
RestApiBase.requestBytesPayload
(String path, ApiRequest<?> request, Http.RequestMethod method, String requestId, WebClientRequestBuilder requestBuilder, Flow.Publisher<DataChunk> publisher) Create a supplier for a response with publisher request. -
Uses of DataChunk in io.helidon.media.common
Modifier and TypeMethodDescriptionMessageBodyContext.applyFilters
(Flow.Publisher<DataChunk> publisher) Apply the filters on the given input publisher to form a publisher chain.protected Flow.Publisher<DataChunk>
MessageBodyContext.applyFilters
(Flow.Publisher<DataChunk> publisher, GenericType<?> type) Apply the filters on the given input publisher to form a publisher chain.static Function<byte[],
Flow.Publisher<DataChunk>> ContentWriters.byteArrayWriter
(boolean copy) Deprecated.since 2.0.0, useContentWriters.writeBytes(byte[], boolean)
insteadContentWriters.byteChannelWriter()
Deprecated.since 2.0.0, useDefaultMediaSupport.byteChannelWriter()
} insteadContentWriters.byteChannelWriter
(RetrySchema retrySchema) Deprecated.since 2.0.0, useDefaultMediaSupport.byteChannelWriter(RetrySchema)
} insteadstatic Function<CharBuffer,
Flow.Publisher<DataChunk>> ContentWriters.charBufferWriter
(Charset charset) Deprecated.since 2.0.0, useContentWriters.writeCharBuffer(CharBuffer, Charset)
insteadstatic Function<CharSequence,
Flow.Publisher<DataChunk>> ContentWriters.charSequenceWriter
(Charset charset) Deprecated.since 2.0.0, useContentWriters.writeCharSequence(CharSequence, Charset)
orDefaultMediaSupport.charSequenceWriter()
insteadMessageBodyStreamWriter.marshall
(Flow.Publisher<T> publisher, GenericType<T> type) Create a marshalling function that can be used to marshall the publisher with a context.Create a marshalling function that can be used to marshall the given value with a context.<T> Flow.Publisher<DataChunk>
MessageBodyWriterContext.marshall
(Single<T> content, GenericType<T> type) Convert a given input publisher into HTTP payload by selecting a writer that accepts the specified type and current context.<T> Flow.Publisher<DataChunk>
MessageBodyWriterContext.marshall
(Single<T> content, MessageBodyWriter<T> writer, GenericType<T> type) Convert a given input publisher into HTTP payload by selecting a writer with the specified class.<T> Flow.Publisher<DataChunk>
MessageBodyWriterContext.marshallStream
(Flow.Publisher<T> content, GenericType<T> type) Convert a given input publisher into HTTP payload by selecting a stream writer that accepts the specified type and current context.<T> Flow.Publisher<DataChunk>
MessageBodyWriterContext.marshallStream
(Flow.Publisher<T> content, MessageBodyStreamWriter<T> writer, GenericType<T> type) Convert a given input publisher into HTTP payload by selecting a stream writer with the specified class.MessageBodyStreamWriter.write
(Flow.Publisher<? extends T> publisher, GenericType<? extends T> type, MessageBodyWriterContext context) Generate HTTP payload from the given stream of objects.MessageBodyWriter.write
(Single<? extends T> single, GenericType<? extends T> type, MessageBodyWriterContext context) Generate HTTP payload from the objects of the given type.ContentWriters.writeBytes
(byte[] bytes, boolean copy) ContentWriters.writeCharBuffer
(CharBuffer buffer, Charset charset) ContentWriters.writeCharSequence
(CharSequence cs, Charset charset) ContentWriters.writeStackTrace
(Throwable throwable, Charset charset) Modifier and TypeMethodDescriptionMessageBodyContext.applyFilters
(Flow.Publisher<DataChunk> publisher) Apply the filters on the given input publisher to form a publisher chain.protected Flow.Publisher<DataChunk>
MessageBodyContext.applyFilters
(Flow.Publisher<DataChunk> publisher, GenericType<?> type) Apply the filters on the given input publisher to form a publisher chain.static MessageBodyReadableContent
MessageBodyReadableContent.create
(Flow.Publisher<DataChunk> publisher, MessageBodyReaderContext context) Create a new readable content backed by the given publisher and context.MessageBodyReader.read
(Flow.Publisher<DataChunk> publisher, GenericType<U> type, MessageBodyReaderContext context) Convert a HTTP payload into a Single publisher of the given type.<U extends T>
Flow.Publisher<U>MessageBodyStreamReader.read
(Flow.Publisher<DataChunk> publisher, GenericType<U> type, MessageBodyReaderContext context) Convert the given HTTP payload into objects of the given type.static Single<byte[]>
ContentReaders.readBytes
(Flow.Publisher<DataChunk> chunks) Collect theDataChunk
of the given publisher into a single byte array.ContentReaders.readString
(Flow.Publisher<DataChunk> chunks, Charset charset) ContentReaders.readURLEncodedString
(Flow.Publisher<DataChunk> chunks, Charset charset) void
MessageBodyReadableContent.registerFilter
(Function<Flow.Publisher<DataChunk>, Flow.Publisher<DataChunk>> function) Deprecated.void
MessageBodyReadableContent.registerFilter
(Function<Flow.Publisher<DataChunk>, Flow.Publisher<DataChunk>> function) Deprecated.MessageBodyWriterContext.registerWriter
(Class<T> type, MediaType contentType, Function<? extends T, Flow.Publisher<DataChunk>> function) Deprecated.since 2.0.0, useMessageBodyWriterContext.registerWriter(MessageBodyWriter)
insteadMessageBodyWriterContext.registerWriter
(Class<T> type, Function<T, Flow.Publisher<DataChunk>> function) Deprecated.since 2.0.0, useMessageBodyWriterContext.registerWriter(MessageBodyWriter)
insteadMessageBodyWriterContext.registerWriter
(Predicate<?> accept, MediaType contentType, Function<T, Flow.Publisher<DataChunk>> function) Deprecated.since 2.0.0, useMessageBodyWriterContext.registerWriter(MessageBodyWriter)
insteadMessageBodyWriterContext.registerWriter
(Predicate<?> accept, Function<T, Flow.Publisher<DataChunk>> function) Deprecated.since 2.0.0 useMessageBodyWriterContext.registerWriter(MessageBodyWriter)
insteadvoid
MessageBodyReadableContent.subscribe
(Flow.Subscriber<? super DataChunk> subscriber) void
ReadableByteChannelPublisher.subscribe
(Flow.Subscriber<? super DataChunk> subscriberParam) Deprecated, for removal: This API element is subject to removal in a future version.<T> Single<T>
MessageBodyReaderContext.unmarshall
(Flow.Publisher<DataChunk> payload, GenericType<T> type) Convert a given HTTP payload into a publisher by selecting a reader that accepts the specified type and current context.<T> Single<T>
MessageBodyReaderContext.unmarshall
(Flow.Publisher<DataChunk> payload, MessageBodyReader<T> reader, GenericType<T> type) Convert a given HTTP payload into a publisher by selecting a reader with the specified class.<T> Flow.Publisher<T>
MessageBodyReaderContext.unmarshallStream
(Flow.Publisher<DataChunk> payload, GenericType<T> type) Convert a given HTTP payload into a publisher by selecting a stream reader that accepts the specified type and current context.<T> Flow.Publisher<T>
MessageBodyReaderContext.unmarshallStream
(Flow.Publisher<DataChunk> payload, MessageBodyStreamReader<T> reader, GenericType<T> type) Convert a given HTTP payload into a publisher by selecting a stream reader with the payload class.ModifierConstructorDescriptionDataChunkInputStream
(Flow.Publisher<DataChunk> originalPublisher) Stores publisher for later subscription.DataChunkInputStream
(Flow.Publisher<DataChunk> originalPublisher, boolean validate) Stores publisher for later subscription and sets if executing thread should be validated. -
Uses of DataChunk in io.helidon.media.multipart
Modifier and TypeMethodDescriptionBodyPartBodyStreamWriter.write
(Flow.Publisher<? extends WriteableBodyPart> content, GenericType<? extends WriteableBodyPart> type, MessageBodyWriterContext context) MultiPartBodyWriter.write
(Single<? extends WriteableMultiPart> content, GenericType<? extends WriteableMultiPart> type, MessageBodyWriterContext context) Modifier and TypeMethodDescriptionWriteableBodyPart.Builder.publisher
(Flow.Publisher<DataChunk> publisher) Create a new body part backed by the specified publisher.<U extends ReadableBodyPart>
Flow.Publisher<U>BodyPartBodyStreamReader.read
(Flow.Publisher<DataChunk> publisher, GenericType<U> type, MessageBodyReaderContext context) void
MultiPartDecoder.DataChunkPublisher.subscribe
(Flow.Subscriber<? super DataChunk> sub) void
MultiPartEncoder.subscribe
(Flow.Subscriber<? super DataChunk> subscriber) -
Uses of DataChunk in io.helidon.webclient
Modifier and TypeMethodDescriptionvoid
Deprecated, for removal: This API element is subject to removal in a future version.Modifier and TypeMethodDescriptionWebClientRequestBuilder.submit
(Flow.Publisher<DataChunk> requestEntity) Performs prepared request and submitting request entity usingFlow.Publisher
.<T> Single<T>
WebClientRequestBuilder.submit
(Flow.Publisher<DataChunk> requestEntity, Class<T> responseType) Performs prepared request and submitting request entity usingFlow.Publisher
.WebClientRequestBuilder.submit
(Function<MessageBodyWriterContext, Flow.Publisher<DataChunk>> function) Performs prepared request and submitting request entity using a marshalling function.FileSubscriber.subscribeTo
(Flow.Publisher<DataChunk> publisher) Deprecated, for removal: This API element is subject to removal in a future version.Subscribes this instance to the obtained publisher. -
Uses of DataChunk in io.helidon.webserver
Modifier and TypeClassDescriptionclass
A special DataChunk implementation based on Netty's buffers.Modifier and TypeMethodDescriptionBareRequest.bodyPublisher()
Gets the Flow Publisher that allows a subscription for request body chunks.ByteBufDataChunk.writeFuture()
Modifier and TypeMethodDescriptionvoid
ProvidedByteBuffer
MUST be fully read during the method call.Modifier and TypeMethodDescriptionServerResponse.registerFilter
(Function<Flow.Publisher<DataChunk>, Flow.Publisher<DataChunk>> function) Deprecated.since 2.0.0, useServerResponse.registerFilter(io.helidon.media.common.MessageBodyFilter)
insteadServerResponse.registerFilter
(Function<Flow.Publisher<DataChunk>, Flow.Publisher<DataChunk>> function) Deprecated.since 2.0.0, useServerResponse.registerFilter(io.helidon.media.common.MessageBodyFilter)
instead<T> ServerResponse
ServerResponse.registerWriter
(Class<T> type, MediaType contentType, Function<? extends T, Flow.Publisher<DataChunk>> function) Deprecated.since 2.0.0, useServerResponse.registerWriter(io.helidon.media.common.MessageBodyWriter)
instead<T> ServerResponse
ServerResponse.registerWriter
(Class<T> type, Function<T, Flow.Publisher<DataChunk>> function) Deprecated.Since 2.0.0, useServerResponse.registerWriter(io.helidon.media.common.MessageBodyWriter)
instead<T> ServerResponse
ServerResponse.registerWriter
(Predicate<?> accept, MediaType contentType, Function<T, Flow.Publisher<DataChunk>> function) Deprecated.since 2.0.0, useServerResponse.registerWriter(io.helidon.media.common.MessageBodyWriter)
instead<T> ServerResponse
ServerResponse.registerWriter
(Predicate<?> accept, Function<T, Flow.Publisher<DataChunk>> function) Deprecated.since 2.0.0, useServerResponse.registerWriter(io.helidon.media.common.MessageBodyWriter)
insteadServerResponse.send
(Flow.Publisher<DataChunk> content) Send a message as is without any other marshalling, registered filters are applied.ServerResponse.send
(Flow.Publisher<DataChunk> content, boolean applyFilters) Send a message as is without any other marshalling.ServerResponse.send
(Function<MessageBodyWriterContext, Flow.Publisher<DataChunk>> function) Send a message using the given marshalling function.void
ByteBufDataChunk.writeFuture
(CompletableFuture<DataChunk> writeFuture)
io.helidon.media.common.MessageBodyReaderContext.registerFilter