-- Hoogle documentation, generated by Haddock
-- See Hoogle, http://www.haskell.org/hoogle/


-- | Conduit-based parsing and serialization for newline delimited JSON.
--   
--   Hackage documentation generation is not reliable. For up to date
--   documentation, please see:
--   <a>http://www.stackage.org/package/ndjson-conduit</a>.
@package ndjson-conduit
@version 0.1.0.5


module Data.Conduit.JSON.NewlineDelimited

-- | Consumes a stream of serializable values, and provides a stream of
--   bytestrings.
serializer :: (Monad m, ToJSON a) => Conduit a m ByteString

-- | Consumes a stream of aeson values, and provides a stream of
--   bytestrings.
valueSerializer :: Monad m => Conduit Value m ByteString

-- | Consumes a stream of bytestrings, and provides a stream of parsed
--   values, ignoring all parse errors.
parser :: (Monad m, FromJSON a) => Conduit ByteString m a

-- | Consumes a stream of bytestrings, and provides a stream of just parsed
--   values, or nothing on parse error.
maybeParser :: (Monad m, FromJSON a) => Conduit ByteString m (Maybe a)

-- | Consumes a stream of bytestrings, and provides a stream of right
--   parsed values, or left strings describing the parse error.
eitherParser :: (Monad m, FromJSON a) => Conduit ByteString m (Either String a)

-- | Consumes a stream of bytestrings, and provides a stream of aeson
--   values, ignoring all parse errors.
valueParser :: Monad m => Conduit ByteString m Value

-- | Consumes a stream of bytestrings, and provides a stream of just aeson
--   values, or nothing on parse error.
maybeValueParser :: Monad m => Conduit ByteString m (Maybe Value)

-- | Consumes a stream of bytestrings, and provides a stream of right aeson
--   values, or left strings describing the parse error.
eitherValueParser :: Monad m => Conduit ByteString m (Either String Value)

-- | Consumes a stream of bytestrings, and provides a stream of parse
--   results.
resultValueParser :: Monad m => Conduit ByteString m (Result Value)
