quantum-random-0.6.1: Retrieve, store and manage real quantum random data.

Safe HaskellNone
LanguageHaskell2010

Quantum.Random.Display

Description

Functionality for display of binary data. Seeing a visual representation of quantum random data lets a user visually verify that it is indeed random.

Usually to be imported via the Quantum.Random module.

Synopsis

Documentation

data DisplayStyle Source #

Represents the supported methods for displaying binary data. All styles show data separated by byte except for Hex.

Instances

Eq DisplayStyle Source # 
Show DisplayStyle Source # 
Generic DisplayStyle Source # 

Associated Types

type Rep DisplayStyle :: * -> * #

ToJSON DisplayStyle Source # 
FromJSON DisplayStyle Source # 
type Rep DisplayStyle Source # 
type Rep DisplayStyle = D1 (MetaData "DisplayStyle" "Quantum.Random.Display" "quantum-random-0.6.1-8tQ7qcJO96d50uDraRxHso" False) ((:+:) ((:+:) (C1 (MetaCons "Colors" PrefixI False) U1) ((:+:) (C1 (MetaCons "Spins" PrefixI False) U1) (C1 (MetaCons "Bits" PrefixI False) U1))) ((:+:) ((:+:) (C1 (MetaCons "Hex" PrefixI False) U1) (C1 (MetaCons "ColorSpins" PrefixI False) U1)) ((:+:) (C1 (MetaCons "ColorBits" PrefixI False) U1) (C1 (MetaCons "ColorHex" PrefixI False) U1))))

parseStyle :: String -> Maybe DisplayStyle Source #

Parse a string to one of the supported display styles.

display :: DisplayStyle -> [Word8] -> IO () Source #

Display a given list of bytes with the specified display style.