random-bytestring-0.1.4: Efficient generation of random bytestrings
Copyright(c) Lars Kuhtz <lakuhtz@gmail.com> 2017
LicenseMIT
Maintainerlakuhtz@gmail.com
Stabilityexperimental
Safe HaskellNone
LanguageHaskell2010

Data.ByteString.Random.Internal

Description

 
Synopsis

Documentation

generate Source #

Arguments

:: RandomWords g 
=> g

PRNG

-> Natural

Length of the result bytestring in bytes

-> IO ByteString 

Generates uniformily distributed random bytestrings of length n using the given PRNG.

class RandomWords g where Source #

Methods

uniformW8 Source #

Arguments

:: g 
-> IO Word8

function that generates uniformily distributed random 8 bit words

uniformW64 Source #

Arguments

:: g 
-> IO Word64

function that generates uniformily distributed random 64 bit words

Instances

Instances details
g ~ GenIO => RandomWords g Source # 
Instance details

Defined in Data.ByteString.Random.MWC

g ~ GenIO => RandomWords g Source # 
Instance details

Defined in Data.ByteString.Random.PCG