Safe Haskell | None |
---|---|
Language | Haskell2010 |
- type Command = Text
- type Description = Text
- dumbHandler :: (Text -> IO Text, Description)
- lookupHandler :: Map Text Text -> (Text -> IO Text, Description)
- isUpHandler :: (Text -> IO Text, Description)
- helpHandler :: [(Command, (Text -> IO Text, Description))] -> (Text -> IO Text, Description)
- dispatch :: [(Command, (Text -> IO Text, x))] -> Text -> IO Text
Documentation
type Description = Text Source
dumbHandler :: (Text -> IO Text, Description) Source
Waits half a second, does nothing.
lookupHandler :: Map Text Text -> (Text -> IO Text, Description) Source
Performs lookups against an in-memory map.
isUpHandler :: (Text -> IO Text, Description) Source
Is the given port listening on the given host?
helpHandler :: [(Command, (Text -> IO Text, Description))] -> (Text -> IO Text, Description) Source
Builds the help message.