public final class InputStreamSubscriber extends InputStream implements org.reactivestreams.Subscriber<ByteBuffer>, SdkAutoCloseable
Subscriber to a InputStream.
Reads from the stream will block until data is published to this subscriber. The amount of data stored in memory by this subscriber when the input stream is not being read is bounded.
| Constructor and Description |
|---|
InputStreamSubscriber() |
| Modifier and Type | Method and Description |
|---|---|
void |
close() |
void |
onComplete() |
void |
onError(Throwable t) |
void |
onNext(ByteBuffer byteBuffer) |
void |
onSubscribe(org.reactivestreams.Subscription s) |
int |
read() |
int |
read(byte[] b) |
int |
read(byte[] bytes,
int off,
int len) |
available, mark, markSupported, reset, skippublic void onSubscribe(org.reactivestreams.Subscription s)
onSubscribe in interface org.reactivestreams.Subscriber<ByteBuffer>public void onNext(ByteBuffer byteBuffer)
onNext in interface org.reactivestreams.Subscriber<ByteBuffer>public void onError(Throwable t)
onError in interface org.reactivestreams.Subscriber<ByteBuffer>public void onComplete()
onComplete in interface org.reactivestreams.Subscriber<ByteBuffer>public int read()
read in class InputStreampublic int read(byte[] b)
read in class InputStreampublic int read(byte[] bytes,
int off,
int len)
read in class InputStreampublic void close()
SdkAutoCloseableclose in interface Closeableclose in interface AutoCloseableclose in interface SdkAutoCloseableclose in class InputStreamCopyright © 2023. All rights reserved.