Safe Haskell | None |
---|---|
Language | Haskell98 |
- data ServerSettings = ServerSettings {
- serverPort :: !Int
- serverHost :: !HostPreference
- serverSocket :: !(Maybe Socket)
- serverAfterBind :: !(Socket -> IO ())
- serverNeedLocalAddr :: !Bool
- data ClientSettings = ClientSettings {
- clientPort :: !Int
- clientHost :: !ByteString
- clientAddrFamily :: !Family
- data HostPreference
- data Message = Message {
- msgData :: !ByteString
- msgSender :: !SockAddr
- data AppData = AppData {
- appRead' :: !(IO ByteString)
- appWrite' :: !(ByteString -> IO ())
- appSockAddr' :: !SockAddr
- appLocalAddr' :: !(Maybe SockAddr)
- data ServerSettingsUnix = ServerSettingsUnix {
- serverPath :: !FilePath
- serverAfterBindUnix :: !(Socket -> IO ())
- data ClientSettingsUnix = ClientSettingsUnix {
- clientPath :: !FilePath
- data AppDataUnix = AppDataUnix {
- appReadUnix :: !(IO ByteString)
- appWriteUnix :: !(ByteString -> IO ())
Documentation
data ServerSettings Source
Settings for a TCP server. It takes a port to listen on, and an optional hostname to bind to.
ServerSettings | |
|
data ClientSettings Source
Settings for a TCP client, specifying how to connect to the server.
ClientSettings | |
|
data HostPreference Source
Which host to bind.
Note: The IsString
instance recognizes the following special values:
*
meansHostAny
*4
meansHostIPv4
!4
meansHostIPv4Only
*6
meansHostIPv6
!6
meansHostIPv6Only
Any other values is treated as a hostname. As an example, to bind to the IPv4 local host only, use "127.0.0.1".
Representation of a single UDP message
Message | |
|
The data passed to an Application
.
AppData | |
|
data ServerSettingsUnix Source
Settings for a Unix domain sockets server.
ServerSettingsUnix | |
|
data ClientSettingsUnix Source
Settings for a Unix domain sockets client.
data AppDataUnix Source
The data passed to a Unix domain sockets Application
.
AppDataUnix | |
|