Random

Companion
class
class Object
trait Matchable
class Any

Value members

Concrete methods

def apply[F[_]](implicit r: Random[F]): Random[F]
def resource[F[_]](implicit F: Sync[F]): Resource[F, Random[F]]
def threadLocalRandom[F[_]](implicit F: Sync[F]): Random[F]

Provides a Random[F] instance backed up by java.util.concurrent.ThreadLocalRandom.current()

Provides a Random[F] instance backed up by java.util.concurrent.ThreadLocalRandom.current()

This reduces contention on the same random instance in a concurrent setting.

Implicits

Implicits

implicit def randomForResource[F[_]](implicit random: Random[F]): Random[[_] =>> Resource[F, _$7]]