Interface VertxPublisher


  • public interface VertxPublisher
    Expose Vert.x streams as Reactive Streams compliant publishers.
    • Method Summary

      Static Methods 
      Modifier and Type Method Description
      static <T> java.util.concurrent.Flow.Publisher<T> fromFuture​(java.util.function.Supplier<io.vertx.core.Future<? extends io.vertx.core.streams.ReadStream<T>>> futureStreamSupplier)
      Create a publisher from a Vert.x future stream supplier.
      static <T> java.util.concurrent.Flow.Publisher<T> fromSupplier​(java.util.function.Supplier<io.vertx.core.streams.ReadStream<T>> streamSupplier)
      Create a publisher from a Vert.x stream supplier.
    • Method Detail

      • fromSupplier

        static <T> java.util.concurrent.Flow.Publisher<T> fromSupplier​(java.util.function.Supplier<io.vertx.core.streams.ReadStream<T>> streamSupplier)
        Create a publisher from a Vert.x stream supplier. The supplier is called for each new publisher subscription.
        Type Parameters:
        T - the elements type
        Parameters:
        streamSupplier - the ReadStream supplier, cannot be null, cannot return null, must not throw an exception
        Returns:
        the new Flow.Publisher
      • fromFuture

        static <T> java.util.concurrent.Flow.Publisher<T> fromFuture​(java.util.function.Supplier<io.vertx.core.Future<? extends io.vertx.core.streams.ReadStream<T>>> futureStreamSupplier)
        Create a publisher from a Vert.x future stream supplier. The supplier is called for each new publisher subscription.
        Type Parameters:
        T - the elements type
        Parameters:
        futureStreamSupplier - the Future ReadStream supplier, cannot be null, cannot return null, must not throw an exception
        Returns:
        the new Flow.Publisher