Package ru.tinkoff.kora.common.util
Class ByteBufferPublisherInputStream
java.lang.Object
java.io.InputStream
ru.tinkoff.kora.common.util.ByteBufferPublisherInputStream
- All Implemented Interfaces:
Closeable,AutoCloseable,Flow.Subscriber<ByteBuffer>
public class ByteBufferPublisherInputStream
extends InputStream
implements Flow.Subscriber<ByteBuffer>
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidclose()voidvoidvoidonNext(ByteBuffer byteBuffer) voidintread()intread(byte[] b, int off, int len) Methods inherited from class java.io.InputStream
available, mark, markSupported, nullInputStream, read, readAllBytes, readNBytes, readNBytes, reset, skip, skipNBytes, transferTo
-
Constructor Details
-
ByteBufferPublisherInputStream
-
-
Method Details
-
read
public int read()- Specified by:
readin classInputStream
-
read
public int read(@Nonnull byte[] b, int off, int len) - Overrides:
readin classInputStream
-
close
public void close()- Specified by:
closein interfaceAutoCloseable- Specified by:
closein interfaceCloseable- Overrides:
closein classInputStream
-
onSubscribe
- Specified by:
onSubscribein interfaceFlow.Subscriber<ByteBuffer>
-
onNext
- Specified by:
onNextin interfaceFlow.Subscriber<ByteBuffer>
-
onError
- Specified by:
onErrorin interfaceFlow.Subscriber<ByteBuffer>
-
onComplete
public void onComplete()- Specified by:
onCompletein interfaceFlow.Subscriber<ByteBuffer>
-