abstract class Hub[F[+_], A] extends Enqueue[F, A] with Serializable
A Hub[F, A] is an asynchronous message hub. Publishers can publish
messages to the hub and subscribers can subscribe to take messages of from
the hub within the context of the effect F.
Linear Supertypes
Ordering
- Alphabetic
- By Inheritance
Inherited
- Hub
- Enqueue
- Serializable
- AnyRef
- Any
- Hide All
- Show All
Visibility
- Public
- Protected
Instance Constructors
- new Hub()
Abstract Value Members
- abstract def awaitShutdown(implicit trace: Trace): F[Unit]
- Definition Classes
- Enqueue
- See also
- abstract def capacity: Int
- Definition Classes
- Enqueue
- See also
- abstract def isEmpty(implicit trace: Trace): F[Boolean]
- Definition Classes
- Enqueue
- See also
- abstract def isFull(implicit trace: Trace): F[Boolean]
- Definition Classes
- Enqueue
- See also
- abstract def isShutdown(implicit trace: Trace): F[Boolean]
Checks whether the hub is shut down.
- abstract def offer(a: A)(implicit trace: Trace): F[Boolean]
- Definition Classes
- Enqueue
- See also
- abstract def offerAll(as: Iterable[A])(implicit trace: Trace): F[Boolean]
- Definition Classes
- Enqueue
- See also
- abstract def publish(a: A)(implicit trace: Trace): F[Boolean]
Publishes a message to the hub, returning whether the message was published to the hub.
- abstract def publishAll(as: Iterable[A])(implicit trace: Trace): F[Boolean]
Publishes all of the specified messages to the hub, returning whether they were published to the hub.
- abstract def shutdown(implicit trace: Trace): F[Unit]
- Definition Classes
- Enqueue
- See also
- abstract def size(implicit trace: Trace): F[Int]
- Definition Classes
- Enqueue
- See also
- abstract def subscribe(implicit trace: Trace): Resource[F, Dequeue[F, A]]
Subscribes to receive messages from the hub.
Subscribes to receive messages from the hub. The resulting subscription can be evaluated multiple times within the scope of the resource to take a message from the hub each time.
Concrete Value Members
- final def !=(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
- final def ##: Int
- Definition Classes
- AnyRef → Any
- final def ==(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
- final def asInstanceOf[T0]: T0
- Definition Classes
- Any
- def clone(): AnyRef
- Attributes
- protected[lang]
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.CloneNotSupportedException]) @native()
- final def eq(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
- def equals(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef → Any
- def finalize(): Unit
- Attributes
- protected[lang]
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.Throwable])
- final def getClass(): Class[_ <: AnyRef]
- Definition Classes
- AnyRef → Any
- Annotations
- @native()
- def hashCode(): Int
- Definition Classes
- AnyRef → Any
- Annotations
- @native()
- final def isInstanceOf[T0]: Boolean
- Definition Classes
- Any
- final def ne(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
- final def notify(): Unit
- Definition Classes
- AnyRef
- Annotations
- @native()
- final def notifyAll(): Unit
- Definition Classes
- AnyRef
- Annotations
- @native()
- final def synchronized[T0](arg0: => T0): T0
- Definition Classes
- AnyRef
- def toString(): String
- Definition Classes
- AnyRef → Any
- final def wait(): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.InterruptedException])
- final def wait(arg0: Long, arg1: Int): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.InterruptedException])
- final def wait(arg0: Long): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.InterruptedException]) @native()