Copyright | © Jonathan Lorimer 2023 |
---|---|
License | MIT |
Maintainer | jonathanlorimer@pm.me |
Stability | stable |
Safe Haskell | None |
Language | Haskell2010 |
This module provides a type Value
for generating instances for "leaf"
elements of your configuration tree. These are the elements you actually
care about and want to parse out of a configuration source.
Since: 0.0.2.0
Documentation
This newtype is used to derive ValueParser
instances for your types
using the deriving via mechanism. In general this should be used for sum
types, and product types without named fields (i.e. not records). The
majority of the types that you would want as values should have instances in
Cfg.Source and Cfg.Parser.
Since: 0.0.2.0
Instances
ConfigSource (Value a :: Type) Source # | Base case for Since: 0.0.1.0 |
Defined in Cfg.Source | |
Generic a => Generic (Value a) Source # | Since: 0.0.2.0 |
(Generic a, GValueParser (Rep a)) => ConfigParser (Value a) Source # | Since: 0.0.2.0 |
Defined in Cfg.Deriving.Value parseConfig :: KeyTree Text Text -> Either ConfigParseError (Value a) Source # | |
(Generic a, GValueParser (Rep a)) => ValueParser (Value a) Source # | Since: 0.0.2.0 |
type Rep (Value a) Source # | |
Defined in Cfg.Deriving.Value |