Maintainer | ongy |
---|---|
Stability | experimental |
Portability | Linux |
Safe Haskell | None |
Language | Haskell2010 |
This may change at any time when the main IP module changes. Consider this API unstable!
- data IP
- data IP4
- data IP6
- parseIP :: String -> IP4
- ipFromBS :: ByteString -> IP
- familyToNum :: Num a => AddressFamily -> a
- data AddressFamily
- getAddrFamily :: IP -> AddressFamily
Documentation
Datatype for IP addresses, abstracts over v4/v6
ipFromBS :: ByteString -> IP Source #
Read an IP from a ByteString. The type is determined by the size of the ByteString.
familyToNum :: Num a => AddressFamily -> a Source #
Get the number associated with the family address. This is for interfacing with libraries
getAddrFamily :: IP -> AddressFamily Source #
Get the address family for a given ip address