StreamOps
Attributes
- Source
- syntax.scala
- Graph
-
- Supertypes
-
class AnyValtrait Matchableclass Any
Members list
Value members
Concrete methods
Subscribes the provided Subscriber to this stream.
Subscribes the provided Subscriber to this stream.
The returned program will run until all the stream elements were consumed. Cancelling this program will gracefully shutdown the subscription.
Value parameters
- subscriber
-
the Subscriber that will receive the elements of the stream.
Attributes
- Source
- syntax.scala
Creates a Publisher from a Stream.
Creates a Publisher from a Stream.
The stream is only ran when elements are requested. Closing the Resource means not accepting new subscriptions, but waiting for all active ones to finish consuming. Canceling the Resource.use means gracefully shutting down all active subscriptions. Thus, no more elements will be published.
Attributes
- See also
-
unsafeToPublisher for an unsafe version that returns a plain Publisher.
subscribe for a simpler version that only requires a Subscriber.
- Note
-
This Publisher can be reused for multiple Subscribers, each Subscription will re-run the Stream from the beginning.
- Source
- syntax.scala