Safe Haskell | None |
---|---|
Language | Haskell2010 |
SequenceFormats.Utils
Description
This module contains helper functions for file parsing.
Synopsis
- liftParsingErrors :: forall (m :: Type -> Type) r a. MonadThrow m => Either (ParsingError, Producer ByteString m r) () -> Producer a m ()
- consumeProducer :: forall (m :: Type -> Type) a. MonadThrow m => Parser a -> Producer ByteString m () -> Producer a m ()
- readFileProd :: forall (m :: Type -> Type). MonadSafe m => FilePath -> Producer ByteString m ()
- readFileProdCheckCompress :: forall (m :: Type -> Type). MonadSafe m => FilePath -> Producer ByteString m ()
- data SeqFormatException = SeqFormatException String
- deflateFinaliser :: MonadIO m => Deflate -> Handle -> m ()
- newtype Chrom = Chrom {}
- word :: Parser ByteString
- gzipConsumer :: forall (m :: Type -> Type). MonadIO m => Deflate -> Handle -> Consumer ByteString m ()
- writeFromPopper :: MonadIO m => Popper -> Handle -> m ()
- data Deflate
Documentation
liftParsingErrors :: forall (m :: Type -> Type) r a. MonadThrow m => Either (ParsingError, Producer ByteString m r) () -> Producer a m () Source #
A function to help with reporting parsing errors to stderr. Returns a clean Producer over the parsed datatype.
consumeProducer :: forall (m :: Type -> Type) a. MonadThrow m => Parser a -> Producer ByteString m () -> Producer a m () Source #
A helper function to parse a text producer, properly reporting all errors to stderr.
readFileProd :: forall (m :: Type -> Type). MonadSafe m => FilePath -> Producer ByteString m () Source #
readFileProdCheckCompress :: forall (m :: Type -> Type). MonadSafe m => FilePath -> Producer ByteString m () Source #
data SeqFormatException Source #
An exception type for parsing BioInformatic file formats.
Constructors
SeqFormatException String |
Instances
Exception SeqFormatException Source # | |
Defined in SequenceFormats.Utils Methods toException :: SeqFormatException -> SomeException # fromException :: SomeException -> Maybe SeqFormatException # | |
Show SeqFormatException Source # | |
Defined in SequenceFormats.Utils Methods showsPrec :: Int -> SeqFormatException -> ShowS # show :: SeqFormatException -> String # showList :: [SeqFormatException] -> ShowS # | |
Eq SeqFormatException Source # | |
Defined in SequenceFormats.Utils Methods (==) :: SeqFormatException -> SeqFormatException -> Bool # (/=) :: SeqFormatException -> SeqFormatException -> Bool # |
A wrapper datatype for Chromosome names.
Constructors
Chrom | |
Fields |
word :: Parser ByteString Source #
gzipConsumer :: forall (m :: Type -> Type). MonadIO m => Deflate -> Handle -> Consumer ByteString m () Source #