gopher.channels

ForeverSelectorBuilder

trait ForeverSelectorBuilder extends SelectorBuilder[Unit]

Builder for 'forever' selector. Can be obtained as gopherApi.select.forever.

Linear Supertypes
SelectorBuilder[Unit], AnyRef, Any
Known Subclasses
Ordering
  1. Alphabetic
  2. By inheritance
Inherited
  1. ForeverSelectorBuilder
  2. SelectorBuilder
  3. AnyRef
  4. Any
  1. Hide All
  2. Show all
Learn more about member selection
Visibility
  1. Public
  2. All

Abstract Value Members

  1. abstract def api: GopherAPI

    Definition Classes
    SelectorBuilder

Concrete 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. macro def apply(f: PartialFunction[Any, Unit]): Future[Unit]

    provide syntax for running select loop as async operation.

    provide syntax for running select loop as async operation.

    val receiver = gopherApi.select.forever{
                     case x: channel.read => Console.println(s"received:$x")
                   }
  5. final def asInstanceOf[T0]: T0

    Definition Classes
    Any
  6. def clone(): AnyRef

    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  7. implicit def ec: ExecutionContext

    Definition Classes
    SelectorBuilder
  8. final def eq(arg0: AnyRef): Boolean

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

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

    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( classOf[java.lang.Throwable] )
  11. macro def foreach(f: (Any) ⇒ Unit): Unit

    provide syntax for running select loop inside go (or async) block example of usage:

    provide syntax for running select loop inside go (or async) block example of usage:

    go {
      .....
      for(s <- gopherApi.select.forever)
        s match {
          case x: ch1.read => do something with x
          case q: chq.read => implicitly[FlowTermination[Unit]].doExit(())
          case y: ch2.write if (y=expr) => do something with y
          case _ => do somethig when idle.
        }

    Note, that you can use implicit instance of [FlowTermination[Unit]] to stop loop.

  12. def futureInput[A](f: Future[A]): FutureInput[A]

    Definition Classes
    SelectorBuilder
    Annotations
    @inline()
  13. final def getClass(): Class[_]

    Definition Classes
    AnyRef → Any
  14. def go: Future[Unit]

    Definition Classes
    SelectorBuilder
  15. def hashCode(): Int

    Definition Classes
    AnyRef → Any
  16. macro def idle(body: Unit): ForeverSelectorBuilder

  17. def idleWithFlowTerminationAsync(f: (ExecutionContext, FlowTermination[Unit]) ⇒ Future[Unit]): ForeverSelectorBuilder

    Annotations
    @inline()
  18. final def isInstanceOf[T0]: Boolean

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

    Definition Classes
    AnyRef
  20. final def notify(): Unit

    Definition Classes
    AnyRef
  21. final def notifyAll(): Unit

    Definition Classes
    AnyRef
  22. def onIdle(arg: SkipSelectorArgument[Unit]): ForeverSelectorBuilder.this.type

    Definition Classes
    SelectorBuilder
  23. def onRead[E](ch: Input[E])(arg: ReadSelectorArgument[E, Unit]): ForeverSelectorBuilder.this.type

    Definition Classes
    SelectorBuilder
  24. def onWrite[E](ch: Output[E])(arg: WriteSelectorArgument[E, Unit]): ForeverSelectorBuilder.this.type

    Definition Classes
    SelectorBuilder
  25. macro def reading[A](ch: Input[A])(f: (A) ⇒ Unit): ForeverSelectorBuilder

  26. def readingWithFlowTerminationAsync[A](ch: Input[A], f: (ExecutionContext, FlowTermination[Unit], A) ⇒ Future[Unit]): ForeverSelectorBuilder.this.type

  27. def selectorRun: Future[Unit]

    Definition Classes
    SelectorBuilder
  28. final def synchronized[T0](arg0: ⇒ T0): T0

    Definition Classes
    AnyRef
  29. def toString(): String

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

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

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

    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  33. def withIdle(f: (Skip[Unit]) ⇒ Option[Future[Continuated[Unit]]]): ForeverSelectorBuilder.this.type

    Definition Classes
    SelectorBuilder
    Annotations
    @inline()
  34. def withReader[B](ch: Input[B], f: (ContRead[B, Unit]) ⇒ Option[(In[B]) ⇒ Future[Continuated[Unit]]]): ForeverSelectorBuilder.this.type

    Definition Classes
    SelectorBuilder
    Annotations
    @inline()
  35. def withWriter[B](ch: Output[B], f: (ContWrite[B, Unit]) ⇒ Option[(B, Future[Continuated[Unit]])]): ForeverSelectorBuilder.this.type

    Definition Classes
    SelectorBuilder
    Annotations
    @inline()
  36. macro def writing[A](ch: Output[A], x: A)(f: (A) ⇒ Unit): ForeverSelectorBuilder

  37. def writingWithFlowTerminationAsync[A](ch: Output[A], x: ⇒ A, f: (ExecutionContext, FlowTermination[Unit], A) ⇒ Future[Unit]): ForeverSelectorBuilder

    Annotations
    @inline()

Inherited from SelectorBuilder[Unit]

Inherited from AnyRef

Inherited from Any

Ungrouped