Safe Haskell | None |
---|---|
Language | Haskell2010 |
Synopsis
- pingPongServerStandard :: forall (m :: Type -> Type). Applicative m => PingPongServer m ()
- pingPongServerCount :: forall (m :: Type -> Type). Applicative m => PingPongServer m Int
- pingPongClientFlood :: forall (m :: Type -> Type) a. Applicative m => PingPongClient m a
- pingPongClientCount :: forall (m :: Type -> Type). Applicative m => Int -> PingPongClient m ()
- pingPongClientPipelinedMax :: forall (m :: Type -> Type). Monad m => Int -> PingPongClientPipelined Int m [Either Int Int]
- pingPongClientPipelinedMin :: forall (m :: Type -> Type). Monad m => Int -> PingPongClientPipelined Int m [Either Int Int]
- pingPongClientPipelinedLimited :: forall (m :: Type -> Type). Monad m => Int -> Int -> PingPongClientPipelined Int m [Either Int Int]
Documentation
pingPongServerStandard :: forall (m :: Type -> Type). Applicative m => PingPongServer m () Source #
The standard stateless ping-pong server instance.
pingPongServerCount :: forall (m :: Type -> Type). Applicative m => PingPongServer m Int Source #
An example ping-pong server instance that counts the number of ping messages.
pingPongClientFlood :: forall (m :: Type -> Type) a. Applicative m => PingPongClient m a Source #
An example ping-pong client that sends pings as fast as possible forever‽
This may not be a good idea‼
pingPongClientCount :: forall (m :: Type -> Type). Applicative m => Int -> PingPongClient m () Source #
An example ping-pong client that sends a fixed number of ping messages and then stops.
pingPongClientPipelinedMax :: forall (m :: Type -> Type). Monad m => Int -> PingPongClientPipelined Int m [Either Int Int] Source #
A pipelined ping-pong client that sends eagerly rather than waiting to collect any replies. This is maximum pipelining in some sense, and correspondingly it gives minimum choice to the environment (drivers).
It returns the interleaving of ping indexes sent, and collected.
pingPongClientPipelinedMin :: forall (m :: Type -> Type). Monad m => Int -> PingPongClientPipelined Int m [Either Int Int] Source #
A pipelined ping-pong client that sends eagerly but always tries to collect any replies if they are available. This allows pipelining but keeps it to a minimum, and correspondingly it gives maximum choice to the environment (drivers).
It returns the interleaving of ping indexes sent, and collected.
pingPongClientPipelinedLimited :: forall (m :: Type -> Type). Monad m => Int -> Int -> PingPongClientPipelined Int m [Either Int Int] Source #
A pipelined ping-pong client that sends eagerly up to some maximum limit of outstanding requests. It is also always ready to collect any replies if they are available. This allows limited pipelining and correspondingly limited choice to the environment (drivers).
It returns the interleaving of ping indexes sent, and collected.