conduit-extra-1.1.15: Batteries included conduit: adapters for common libraries.

Safe HaskellNone
LanguageHaskell98

Data.Conduit.Network.Unix

Contents

Synopsis

Basic utilities

sourceSocket :: MonadIO m => Socket -> Producer m ByteString Source #

Stream data from the socket.

This function does not automatically close the socket.

Since 0.0.0

sinkSocket :: MonadIO m => Socket -> Consumer ByteString m () Source #

Stream data to the socket.

This function does not automatically close the socket.

Since 0.0.0

Simple server/client interface

data AppDataUnix :: * #

Instances

HasReadWrite AppDataUnix 

Methods

readLens :: Functor f => (IO ByteString -> f (IO ByteString)) -> AppDataUnix -> f AppDataUnix

writeLens :: Functor f => ((ByteString -> IO ()) -> f (ByteString -> IO ())) -> AppDataUnix -> f AppDataUnix

appSource :: (HasReadWrite ad, MonadIO m) => ad -> Producer m ByteString Source #

appSink :: (HasReadWrite ad, MonadIO m) => ad -> Consumer ByteString m () Source #

Server

data ServerSettingsUnix :: * #

Instances

HasReadBufferSize ServerSettingsUnix 
HasPath ServerSettingsUnix 
HasAfterBind ServerSettingsUnix 

Methods

afterBindLens :: Functor f => ((Socket -> IO ()) -> f (Socket -> IO ())) -> ServerSettingsUnix -> f ServerSettingsUnix

Client

Getters

getPath :: HasPath a => a -> FilePath #

getAfterBind :: HasAfterBind a => a -> Socket -> IO () #

Setters

setPath :: HasPath a => FilePath -> a -> a #

setAfterBind :: HasAfterBind a => (Socket -> IO ()) -> a -> a #