Create an bounded asynchronous queue.
Create an bounded asynchronous queue. Calls to enqueue1
will wait until the
queue's size is less than maxSize
. See mutable.Queue for more documentation.
Converts a discrete stream to a signal.
Converts a discrete stream to a signal. Returns a single-element stream.
Resulting signal is initially initial
, and is updated with latest value
produced by source
. If source
is empty, the resulting signal will always
be initial
.
discrete stream publishing values to this signal
Defined as hold(None, source.map(Some(_)))
Create a mutable.Semaphore
, initialized to the given count.
Creates a new continuous signal which may be controlled asynchronously,
and immediately sets the value to initialValue
.
A synchronous queue always has size 0.
A synchronous queue always has size 0. Any calls to enqueue1
block
until there is an offsetting call to dequeue1
. Any calls to dequeue1
block until there is an offsetting call to enqueue1
.
Creates asynchronous topic, that allows distribute published A
to arbitrary number of subscribers.
Creates asynchronous topic, that allows distribute published A
to arbitrary number of subscribers.
Each subscriber is guaranteed to received at least initial A
passed, or last value published by any publisher.
Create an unbounded asynchronous queue.
Create an unbounded asynchronous queue. See mutable.Queue for more documentation.