chatty-0.6: Some monad transformers and typeclasses for abstraction of global dependencies.

Safe HaskellSafe-Inferred

Text.Chatty.Channel.Printer

Description

Provides a printer class that offers several channels.

Synopsis

Documentation

class (ChPrinter m, Eq c) => ChChannelPrinter c m whereSource

Typeclass for all printers that offer several channels.

Methods

cbracket :: c -> m a -> m aSource

Run the function with the given channel.

cstart :: c -> m ()Source

Switch to the given channel

cfin :: c -> m ()Source

Return to the previous channel. The argument is bogus (just for type inference).

cprint :: c -> String -> m ()Source

Print the string to the given channel.

cthis :: m cSource

Return the current channel.

Instances

ChChannelPrinter Bool m0 => ChChannelPrinter Bool (HandleCloserT m0) 
ChChannelPrinter Bool m0 => ChChannelPrinter Bool (InRedirT m0) 
ChChannelPrinter Bool m0 => ChChannelPrinter Bool (QuietT m0) 
ChChannelPrinter Bool m0 => ChChannelPrinter Bool (HereStringT m0) 
ChChannelPrinter Bool m0 => ChChannelPrinter Bool (ScannerBufferT m0) 
ChChannelPrinter Bool m0 => ChChannelPrinter Bool (SpawnOverlayT m0) 
ChChannelPrinter Bool m0 => ChChannelPrinter Bool (NullExpanderT m0) 
ChChannelPrinter Bool m0 => ChChannelPrinter Bool (ExpanderT m0) 
ChChannelPrinter Bool m0 => ChChannelPrinter Bool (HistoryT m0) 
ChChannelPrinter Bool m0 => ChChannelPrinter Bool (HtmlPrinterT m0) 
ChChannelPrinter Bool m0 => ChChannelPrinter Bool (AnsiPrinterT m0) 
ChChannelPrinter Int m0 => ChChannelPrinter Int (HandleCloserT m0) 
ChChannelPrinter Int m0 => ChChannelPrinter Int (InRedirT m0) 
ChChannelPrinter Int m0 => ChChannelPrinter Int (QuietT m0) 
ChChannelPrinter Int m0 => ChChannelPrinter Int (HereStringT m0) 
ChChannelPrinter Int m0 => ChChannelPrinter Int (ScannerBufferT m0) 
ChChannelPrinter Int m0 => ChChannelPrinter Int (SpawnOverlayT m0) 
ChChannelPrinter Int m0 => ChChannelPrinter Int (NullExpanderT m0) 
ChChannelPrinter Int m0 => ChChannelPrinter Int (ExpanderT m0) 
ChChannelPrinter Int m0 => ChChannelPrinter Int (HistoryT m0) 
ChChannelPrinter Int m0 => ChChannelPrinter Int (HtmlPrinterT m0) 
ChChannelPrinter Int m0 => ChChannelPrinter Int (AnsiPrinterT m0) 
(Eq c, ChPrinter m) => ChChannelPrinter c (JoinerT m) 
ChChannelPrinter Handle m0 => ChChannelPrinter Handle (HandleCloserT m0) 
ChChannelPrinter Handle m0 => ChChannelPrinter Handle (InRedirT m0) 
ChChannelPrinter Handle m0 => ChChannelPrinter Handle (QuietT m0) 
ChChannelPrinter Handle m0 => ChChannelPrinter Handle (HereStringT m0) 
ChChannelPrinter Handle m0 => ChChannelPrinter Handle (ScannerBufferT m0) 
ChChannelPrinter Handle m0 => ChChannelPrinter Handle (SpawnOverlayT m0) 
ChChannelPrinter Handle m0 => ChChannelPrinter Handle (NullExpanderT m0) 
ChChannelPrinter Handle m0 => ChChannelPrinter Handle (ExpanderT m0) 
ChChannelPrinter Handle m0 => ChChannelPrinter Handle (HistoryT m0) 
ChChannelPrinter Handle m0 => ChChannelPrinter Handle (HtmlPrinterT m0) 
ChChannelPrinter Handle m0 => ChChannelPrinter Handle (AnsiPrinterT m0) 
(Eq c, ChPrinter m) => ChChannelPrinter c (FilterT c m) 
(Eq c, Monad m) => ChChannelPrinter c (ArchiverT c m) 

newtype ArchiverT c m a Source

Catches all output on multiple channels.

Constructors

Archiver 

Fields

runArchiverT' :: ([(c, [String])], [c]) -> m (a, ([(c, [String])], [c]))
 

runArchiverT :: (Eq c, Monad m) => c -> ArchiverT c m a -> m (a, [(c, Replayable)])Source

newtype JoinerT m a Source

Joins all output regardless of its channel.

Constructors

Joiner 

Fields

runJoinerT :: m a