object Spout

Linear Supertypes
AnyRef, Any
Ordering
  1. Alphabetic
  2. By Inheritance
Inherited
  1. Spout
  2. AnyRef
  3. Any
  1. Hide All
  2. Show All
Visibility
  1. Public
  2. All

Type Members

  1. sealed abstract class Unfolding [+S, +T] extends AnyRef

    Simple helper ADT for unfold.

Value Members

  1. final def !=(arg0: Any): Boolean
    Definition Classes
    AnyRef → Any
  2. final def ##(): Int
    Definition Classes
    AnyRef → Any
  3. final def ==(arg0: Any): Boolean
    Definition Classes
    AnyRef → Any
  4. def apply[T](first: T, second: T, more: T*): Spout[T]

    A Spout which produces the given elements.

  5. def apply[T](value: T)(implicit ev: Streamable[T]): Spout[Out]

    Turns the given value into a Spout provided an implicit Streamable instance can be found or constructed for it.

  6. final def asInstanceOf[T0]: T0
    Definition Classes
    Any
  7. def clone(): AnyRef
    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  8. def continually[T](elem: ⇒ T): Spout[T]

    A Spout which will evaluate the given call-by-name argument to produce an infinite stream of data elements.

    A Spout which will evaluate the given call-by-name argument to produce an infinite stream of data elements.

    CAUTION: The call-by-name argument might be executed from another thread if the stream is asynchronous!

  9. def doubles(from: Double, step: Double): Spout[Double]

    A Spout which produces an infinite stream of Double elements starting with the given start and increments of step.

  10. def empty[T]: Spout[T]

    A Spout which never produces any elements but completes immediately.

  11. def emptyFrom[T](future: Future[Unit]): Spout[T]

    A Spout which never produces any elements but terminates when the given future is fulfilled.

    A Spout which never produces any elements but terminates when the given future is fulfilled.

    The returned Spout instance cannot run synchronously.

  12. final def eq(arg0: AnyRef): Boolean
    Definition Classes
    AnyRef
  13. def equals(arg0: Any): Boolean
    Definition Classes
    AnyRef → Any
  14. def failing[T](cause: Throwable, eager: Boolean = true): Spout[T]

    A Spout which never produces any elements but terminates with the given error.

    A Spout which never produces any elements but terminates with the given error. If eager is true the error is produced immediately after stream start, otherwise the error is delayed until the first request signal is received from downstream.

  15. def finalize(): Unit
    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( classOf[java.lang.Throwable] )
  16. def fromFuture[T](future: Future[T]): Spout[T]

    A Spout which produces either one or zero elements when the given Future is completed.

    A Spout which produces either one or zero elements when the given Future is completed. If the Future is completed with an error no element is produced and the stream is failed with the exception in the future.

    The returned Spout instance cannot run synchronously.

  17. def fromIterable[T](iterable: Iterable[T]): Spout[T]

    A Spout which produces the same elements as the given Iterable.

  18. def fromIterator[T](iterator: Iterator[T]): Spout[T]

    A Spout which produces the same elements as the given Iterator.

    A Spout which produces the same elements as the given Iterator.

    CAUTION: iterator might be drained from another thread if the stream is asynchronous!

  19. def fromOption[T](option: Option[T]): Spout[T]

    A Spout which produces either one or zero elements depending on the given Option instance.

  20. def fromPublisher[T](publisher: Publisher[T]): Spout[T]

    A Spout which produces the same elements as the given Publisher.

    A Spout which produces the same elements as the given Publisher.

    The returned Spout instance cannot run synchronously.

  21. def fromTry[T](value: Try[T]): Spout[T]

    A Spout which produces either one or zero elements depending on the given Try instance.

  22. final def getClass(): Class[_]
    Definition Classes
    AnyRef → Any
  23. def hashCode(): Int
    Definition Classes
    AnyRef → Any
  24. def ints(from: Int, step: Int = 1): Spout[Int]

    A Spout which produces an infinite stream of Int elements starting with the given start and increments of step.

  25. final def isInstanceOf[T0]: Boolean
    Definition Classes
    Any
  26. def iterate[T](start: T)(f: (T) ⇒ T): Spout[T]

    A Spout which will iterate via the given function to produce an infinite stream of data elements.

    A Spout which will iterate via the given function to produce an infinite stream of data elements.

    CAUTION: f will be called from another thread if the stream is asynchronous!

  27. def lazyStart[T](onStart: () ⇒ Spout[T]): Spout[T]

    A Spout which produces the same elements as the Spout instance returned by the given function.

    A Spout which produces the same elements as the Spout instance returned by the given function. The given function is only executed when the outer stream is started.

    If the outer stream is synchronous the Spout returned by onStart must be able to run synchronously as well. If it doesn't the stream will fail with an IllegalAsyncBoundaryException.

  28. def longs(from: Long, step: Long = 1): Spout[Long]

    A Spout which produces an infinite stream of Long elements starting with the given start and increments of step.

  29. final def ne(arg0: AnyRef): Boolean
    Definition Classes
    AnyRef
  30. final def notify(): Unit
    Definition Classes
    AnyRef
  31. final def notifyAll(): Unit
    Definition Classes
    AnyRef
  32. def one[T](element: T): Spout[T]

    A Spout which produces the given element only once before completing.

  33. def push[T](initialBufferSize: Int, maxBufferSize: Int, notifyOnDequeued: (PushSpout[T], Int) ⇒ Unit = dropFunc2, notifyOnCancel: (PushSpout[T]) ⇒ Unit = dropFunc): PushSpout[T]

    Convenience constructor for PushSpout instances.

  34. def repeat[T](element: T): Spout[T]

    A Spout which produced an infinite stream of identical elements.

  35. final def synchronized[T0](arg0: ⇒ T0): T0
    Definition Classes
    AnyRef
  36. def tick[T](value: T, elements: Int, per: FiniteDuration): Spout[T]

    A Spout which produces the given element elements times per given interval.

    A Spout which produces the given element elements times per given interval.

    The returned Spout instance cannot run synchronously.

  37. def tick[T](value: T, interval: FiniteDuration): Spout[T]

    A Spout which produces the given element once per given interval.

    A Spout which produces the given element once per given interval.

    The returned Spout instance cannot run synchronously.

  38. def toString(): String
    Definition Classes
    AnyRef → Any
  39. def unfold[S, T](s: S)(f: (S) ⇒ Unfolding[S, T]): Spout[T]

    A Spout that unfolds a "state" instance of type S into the subsequent states and output elements of type T.

    A Spout that unfolds a "state" instance of type S into the subsequent states and output elements of type T.

    For example, all the Fibonacci numbers under 1M:

    Spout.unfold(01) {
     case (a, b) if b > 1000000 ⇒ Spout.Unfolding.EmitFinal(a)
     case (a, b) ⇒ Spout.Unfolding.Emit(a, b → (a + b))
    }

    CAUTION: f will be called from another thread if the stream is asynchronous!

  40. def unfoldAsync[S, T](s: S)(f: (S) ⇒ Future[Unfolding[S, T]]): Spout[T]

    Same as unfold, but asynchronous.

    Same as unfold, but asynchronous.

    The returned Spout instance cannot run synchronously.

    CAUTION: f will be called from another thread!

  41. final def wait(): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  42. final def wait(arg0: Long, arg1: Int): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  43. final def wait(arg0: Long): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  44. def withSubscriber[T]: (Spout[T], Subscriber[T])

    A Spout and an associated Subscriber.

    A Spout and an associated Subscriber. Both are directly linked to each other and thereby allow for connecting *swave* with other Reactive Streams implementations.

    The Spout produces all elements received by the Subscriber and the Subscriber forwards all request and cancel signals received by the Spout.

    The returned Spout instance cannot run synchronously.

  45. object Unfolding

Inherited from AnyRef

Inherited from Any

Ungrouped