Safe Haskell | None |
---|---|
Language | Haskell2010 |
A resuable optparse-applicative parser for creating a postgresql-simple
Connection
Synopsis
- data PartialOptions = PartialOptions {
- host :: Last String
- hostaddr :: Last String
- port :: Last Int
- user :: Last String
- password :: Last String
- dbname :: Last String
- connectTimeout :: Last Int
- clientEncoding :: Last String
- options :: Last String
- fallbackApplicationName :: Last String
- keepalives :: Last Int
- keepalivesIdle :: Last Int
- keepalivesCount :: Last Int
- sslmode :: Last String
- requiressl :: Last Int
- sslcompression :: Last Int
- sslcert :: Last String
- sslkey :: Last String
- sslrootcert :: Last String
- requirepeer :: Last String
- krbsrvname :: Last String
- gsslib :: Last String
- service :: Last String
- parseConnectionString :: String -> Either String PartialOptions
- completeParser :: Parser Options
- completeOptions :: PartialOptions -> Either [String] Options
Documentation
data PartialOptions Source #
An optional version of Options
. This includes an instance of
| ParseRecord
which provides the optparse-applicative Parser.
PartialOptions | |
|
Instances
completeParser :: Parser Options Source #
Useful for testing or if only Options are needed.
completeOptions :: PartialOptions -> Either [String] Options Source #