gopher.ChannelWithExpiration.scala Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of scala-gopher_3.0.0-RC2 Show documentation
Show all versions of scala-gopher_3.0.0-RC2 Show documentation
scala-gopher: asynchronous implementation of CSP ( go-like channels/selectors ) in scala
The newest version!
package gopher
import cps._
import gopher.impl._
import scala.concurrent.duration.FiniteDuration
class ChannelWithExpiration[F[_],W,R](internal: Channel[F,W,R], ttl: FiniteDuration, throwTimeouts: Boolean)
extends WriteChannelWithExpiration[F,W](internal, ttl, throwTimeouts, internal.gopherApi)
with Channel[F,W,R]:
override def gopherApi: Gopher[F] = internal.gopherApi
override def asyncMonad: CpsSchedulingMonad[F] = gopherApi.asyncMonad
override def addReader(reader: Reader[R]): Unit =
internal.addReader(reader)
override def addDoneReader(reader: Reader[Unit]): Unit =
internal.addDoneReader(reader)
override def withExpiration(ttl: FiniteDuration, throwTimeouts: Boolean): ChannelWithExpiration[F,W,R] =
new ChannelWithExpiration(internal , ttl, throwTimeouts)
override def close(): Unit = internal.close()
override def isClosed: Boolean = internal.isClosed
def qqq: Int = 0
© 2015 - 2025 Weber Informatics LLC | Privacy Policy