@Test void testByteArrayReader() throws Exception { String original = "Popokatepetl"; byte[] bytes = original.getBytes(StandardCharsets.UTF_8); CompletableFuture<? extends byte[]> future = ContentReaders.byteArrayReader() .apply(Multi.singleton(DataChunk.create(bytes))) .toCompletableFuture(); byte[] actualBytes = future.get(10, TimeUnit.SECONDS); assertThat(actualBytes, is(bytes)); }
@Deprecated(since = "2.0.0") public static Reader<byte[]> byteArrayReader() { return (publisher, clazz) -> readBytes(publisher).toStage(); }
ContentReaders { @Deprecated(since = "2.0.0") public static Reader<byte[]> byteArrayReader() { return (publisher, clazz) -> readBytes(publisher).toStage(); } }
ContentReaders { @Deprecated(since = "2.0.0") public static Reader<byte[]> byteArrayReader() { return (publisher, clazz) -> readBytes(publisher).toStage(); } private  ContentReaders(); }
ContentReaders { @Deprecated(since = "2.0.0") public static Reader<byte[]> byteArrayReader() { return (publisher, clazz) -> readBytes(publisher).toStage(); } private  ContentReaders(); static Single<byte[]> readBytes(Publisher<DataChunk> chunks); static Single<String> readString(Publisher<DataChunk> chunks, Charset charset); static Single<String> readURLEncodedString(Publisher<DataChunk> chunks,
            Charset charset); @Deprecated(since = "2.0.0") static Reader<String> stringReader(Charset charset); @Deprecated(since = "2.0.0") static Reader<String> urlEncodedStringReader(Charset charset); @Deprecated(since = "2.0.0") static Reader<byte[]> byteArrayReader(); @Deprecated(since = "2.0.0") static Reader<InputStream> inputStreamReader(); }
ContentReaders { @Deprecated(since = "2.0.0") public static Reader<byte[]> byteArrayReader() { return (publisher, clazz) -> readBytes(publisher).toStage(); } private  ContentReaders(); static Single<byte[]> readBytes(Publisher<DataChunk> chunks); static Single<String> readString(Publisher<DataChunk> chunks, Charset charset); static Single<String> readURLEncodedString(Publisher<DataChunk> chunks,
            Charset charset); @Deprecated(since = "2.0.0") static Reader<String> stringReader(Charset charset); @Deprecated(since = "2.0.0") static Reader<String> urlEncodedStringReader(Charset charset); @Deprecated(since = "2.0.0") static Reader<byte[]> byteArrayReader(); @Deprecated(since = "2.0.0") static Reader<InputStream> inputStreamReader();  }