Safe Haskell | None |
---|---|
Language | Haskell2010 |
- data Record m r = Record {
- recHeader :: RecordHeader
- recContent :: Producer ByteString m r
- type Warc m a = FreeT (Record m) m (Producer ByteString m a)
- parseWarc :: (Functor m, Monad m) => Producer ByteString m a -> Warc m a
- iterRecords :: forall m a. Monad m => (forall b. Record m b -> m b) -> Warc m a -> m (Producer ByteString m a)
- produceRecords :: forall m o a. Monad m => (forall b. RecordHeader -> Producer ByteString m b -> Producer o m b) -> Warc m a -> Producer o m (Producer ByteString m a)
- encodeRecord :: Monad m => Record m a -> Producer ByteString m a
- module Data.Warc.Header
Documentation
A WARC record
Record | |
|
Parsing
parseWarc :: (Functor m, Monad m) => Producer ByteString m a -> Warc m a Source #
Parse a WARC archive.
iterRecords :: forall m a. Monad m => (forall b. Record m b -> m b) -> Warc m a -> m (Producer ByteString m a) Source #
Iterate over the Record
s in a WARC archive
:: Monad m | |
=> (forall b. RecordHeader -> Producer ByteString m b -> Producer o m b) | consume the record producing some output |
-> Warc m a | a WARC archive (see |
-> Producer o m (Producer ByteString m a) | returns any leftovers |
Encoding
encodeRecord :: Monad m => Record m a -> Producer ByteString m a Source #
Headers
module Data.Warc.Header