Class ByteBufferFluxInputStream

java.lang.Object
java.io.InputStream
ru.tinkoff.kora.common.util.ByteBufferFluxInputStream
All Implemented Interfaces:
Closeable, AutoCloseable, org.reactivestreams.Subscriber<ByteBuffer>, reactor.core.CoreSubscriber<ByteBuffer>

public class ByteBufferFluxInputStream extends InputStream implements reactor.core.CoreSubscriber<ByteBuffer>
  • Constructor Details

    • ByteBufferFluxInputStream

      public ByteBufferFluxInputStream(reactor.core.publisher.Flux<ByteBuffer> byteBufferFlux)
  • Method Details

    • read

      public int read()
      Specified by:
      read in class InputStream
    • read

      public int read(@Nonnull byte[] b, int off, int len)
      Overrides:
      read in class InputStream
    • close

      public void close()
      Specified by:
      close in interface AutoCloseable
      Specified by:
      close in interface Closeable
      Overrides:
      close in class InputStream
    • onSubscribe

      public void onSubscribe(org.reactivestreams.Subscription s)
      Specified by:
      onSubscribe in interface reactor.core.CoreSubscriber<ByteBuffer>
      Specified by:
      onSubscribe in interface org.reactivestreams.Subscriber<ByteBuffer>
    • onNext

      public void onNext(ByteBuffer byteBuffer)
      Specified by:
      onNext in interface org.reactivestreams.Subscriber<ByteBuffer>
    • onError

      public void onError(Throwable t)
      Specified by:
      onError in interface org.reactivestreams.Subscriber<ByteBuffer>
    • onComplete

      public void onComplete()
      Specified by:
      onComplete in interface org.reactivestreams.Subscriber<ByteBuffer>
    • currentContext

      @Nonnull public reactor.util.context.Context currentContext()
      Specified by:
      currentContext in interface reactor.core.CoreSubscriber<ByteBuffer>