public class StringContentReader extends Object implements Reader<String>
ByteBuffer publisher to
a single string while using a given charset. If the charset cannot be used by the JVM,
the returned completion stage ends exceptionally with an IllegalArgumentException.| Modifier and Type | Method and Description |
|---|---|
CompletionStage<String> |
apply(Flow.Publisher<DataChunk> publisher,
Class<? super String> clazz)
Converts a
ByteBuffer publisher to a single string while using the associated
charset. |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitapply, applyAndCastandThenpublic CompletionStage<String> apply(Flow.Publisher<DataChunk> publisher, Class<? super String> clazz)
ByteBuffer publisher to a single string while using the associated
charset. If the charset cannot be used by the JVM, the returned completion stage ends
exceptionally with an IllegalArgumentException.apply in interface Reader<String>apply in interface BiFunction<Flow.Publisher<DataChunk>,Class<? super String>,CompletionStage<? extends String>>publisher - the publisher from which to transform the byte chunks into a single
stringIllegalArgumentExceptionCopyright © 2018–2019 Oracle Corporation. All rights reserved.