Safe Haskell | None |
---|---|
Language | Haskell2010 |
- type AppT a = ReaderT AppState IO a
- type CommandHandler = StoreData -> AppT ()
- data AppState = AppState {}
- type ShellEnvironment = [(String, String)]
- data Configuration = Configuration {}
- loadConfiguration :: Maybe FilePath -> IO (Either String Configuration)
- fromShellEnvironment :: ShellEnvironment -> Maybe Configuration
- fromConfigurator :: Config -> IO (Maybe Configuration)
- data CommandOptions = CommandOptions {}
- data Command = Command {
- _cName :: String
- _cRequired :: [String]
- _cOptional :: [String]
- _cAllowedOptions :: [String]
- _cDescription :: String
- _cHandler :: CommandHandler
- data ConfigData = ConfigData {}
- newtype DbConnDescriptor = DbConnDescriptor String
- databaseTypes :: [(String, String -> IO Backend)]
- envDatabaseType :: String
- envDatabaseName :: String
- envStoreName :: String
Documentation
type CommandHandler = StoreData -> AppT () Source
The type of actions that are invoked to handle specific commands
Application state which can be accessed by any command handler.
type ShellEnvironment = [(String, String)] Source
data Configuration Source
fromConfigurator :: Config -> IO (Maybe Configuration) Source
data CommandOptions Source
CommandOptions are those options that can be specified at the command prompt to modify the behavior of a command.
A command has a name, a number of required arguments' labels, a number of optional arguments' labels, and an action to invoke.
Command | |
|
data ConfigData Source
ConfigOptions are those options read from configuration file