SelectGroup

class SelectGroup[F[_], S](api: Gopher[F]) extends SelectListeners[F, S, S]

Select group is a virtual 'lock' object, where only ne fro rieader and writer can exists at the sae time.

Select group is a virtual 'lock' object, where only ne fro rieader and writer can exists at the sae time.

trait SelectListeners[F, S, S]
class Object
trait Matchable
class Any

Type members

Classlikes

trait Expiration
case class ReaderRecord[A](ch: ReadChannel[F, A], action: Try[A] => F[S]) extends Reader[A] with Expiration
case class TimeoutRecord(duration: FiniteDuration, action: Try[FiniteDuration] => F[S]) extends Expiration
case class WriterRecord[A](ch: WriteChannel[F, A], element: A, action: Try[Unit] => F[S]) extends Writer[A] with Expiration

Value members

Concrete methods

def addReader[A](ch: ReadChannel[F, A], action: Try[A] => F[S]): Unit
def addWriter[A](ch: WriteChannel[F, A], element: A, action: Try[Unit] => F[S]): Unit
inline def apply(inline pf: PartialFunction[Any, S]): S
override def asyncMonad: CpsSchedulingMonad[F]
Definition Classes
def done[S](s: S): Done[S]

short alias for SelectFold.Done

short alias for SelectFold.Done

def onRead[A](ch: ReadChannel[F, A])(f: A => S): SelectGroup[F, S]

FluentDSL for user SelectGroup without macroses.

FluentDSL for user SelectGroup without macroses.

SelectGroup.onRead(input){ x => println(x) }
          .onRead(endSignal){ () => done=true }
def onReadAsync[A](ch: ReadChannel[F, A])(f: A => F[S]): SelectGroup[F, S]
def onRead_async[A](ch: ReadChannel[F, A])(f: A => F[S]): F[SelectGroup[F, S]]
def onTimeout(t: FiniteDuration)(f: FiniteDuration => S): SelectGroup[F, S]
def onTimeoutAsync(t: FiniteDuration)(f: FiniteDuration => F[S]): SelectGroup[F, S]
def onTimeout_async(t: FiniteDuration)(f: FiniteDuration => F[S]): F[SelectGroup[F, S]]
def onWrite[A](ch: WriteChannel[F, A], a: => A)(f: A => S): SelectGroup[F, S]

FluentDSL for user SelectGroup without macroses.

FluentDSL for user SelectGroup without macroses.

SelectGroup.onWrite(input){ x => println(x) }
          .onWrite(endSignal){ () => done=true }
def onWriteAsync[A](ch: WriteChannel[F, A], a: () => F[A])(f: A => F[S]): SelectGroup[F, S]
def runAsync(): F[S]
inline def select(inline pf: PartialFunction[Any, S]): S
def setTimeout(timeout: FiniteDuration, action: Try[FiniteDuration] => F[S]): Unit
def step(): F[S]

Inherited methods

inline def run(): S
Inherited from
SelectListeners

Concrete fields

var call: Try[S] => Unit
val retval: F[S]
val startTime: AtomicLong
val waitState: AtomicInteger

instance of select group created for call of select. 0 - free 1 - now processes 2 - expired

instance of select group created for call of select. 0 - free 1 - now processes 2 - expired