Class/Object

zio.concurrent

CyclicBarrier

Related Docs: object CyclicBarrier | package concurrent

Permalink

final class CyclicBarrier extends AnyRef

A synchronization aid that allows a set of fibers to all wait for each other to reach a common barrier point.

CyclicBarriers are useful in programs involving a fixed sized party of fibers that must occasionally wait for each other. The barrier is called cyclic because it can be re-used after the waiting fibers are released.

A CyclicBarrier supports an optional action command that is run once per barrier point, after the last fiber in the party arrives, but before any fibers are released. This barrier action is useful for updating shared-state before any of the parties continue.

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

Value Members

  1. final def !=(arg0: Any): Boolean

    Permalink
    Definition Classes
    AnyRef → Any
  2. final def ##(): Int

    Permalink
    Definition Classes
    AnyRef → Any
  3. final def ==(arg0: Any): Boolean

    Permalink
    Definition Classes
    AnyRef → Any
  4. final def asInstanceOf[T0]: T0

    Permalink
    Definition Classes
    Any
  5. val await: IO[Unit, Int]

    Permalink

    Waits until all parties have invoked await on this barrier.

    Waits until all parties have invoked await on this barrier. Fails if the barrier is broken.

  6. def clone(): AnyRef

    Permalink
    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  7. final def eq(arg0: AnyRef): Boolean

    Permalink
    Definition Classes
    AnyRef
  8. def equals(arg0: Any): Boolean

    Permalink
    Definition Classes
    AnyRef → Any
  9. def finalize(): Unit

    Permalink
    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( classOf[java.lang.Throwable] )
  10. final def getClass(): Class[_]

    Permalink
    Definition Classes
    AnyRef → Any
  11. def hashCode(): Int

    Permalink
    Definition Classes
    AnyRef → Any
  12. val isBroken: UIO[Boolean]

    Permalink

    Queries if this barrier is in a broken state.

  13. final def isInstanceOf[T0]: Boolean

    Permalink
    Definition Classes
    Any
  14. final def ne(arg0: AnyRef): Boolean

    Permalink
    Definition Classes
    AnyRef
  15. final def notify(): Unit

    Permalink
    Definition Classes
    AnyRef
  16. final def notifyAll(): Unit

    Permalink
    Definition Classes
    AnyRef
  17. def parties: Int

    Permalink

    The number of parties required to trip this barrier.

  18. val reset: UIO[Unit]

    Permalink

    Resets the barrier to its initial state.

    Resets the barrier to its initial state. Breaks any waiting party.

  19. final def synchronized[T0](arg0: ⇒ T0): T0

    Permalink
    Definition Classes
    AnyRef
  20. def toString(): String

    Permalink
    Definition Classes
    AnyRef → Any
  21. final def wait(): Unit

    Permalink
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  22. final def wait(arg0: Long, arg1: Int): Unit

    Permalink
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  23. final def wait(arg0: Long): Unit

    Permalink
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  24. val waiting: UIO[Int]

    Permalink

    The number of parties currently waiting at the barrier.

Inherited from AnyRef

Inherited from Any

Ungrouped