Safe Haskell | None |
---|---|
Language | Haskell2010 |
Control.Restartable.Initial
Description
This module describes values that are initialized from a list of _all optional_ Aeson.Values. Initialization should be fully generic by default.
Documentation
class (FromJSON a, ToJSON a) => Initial a Source #
Special class for values that should give initial value when JSON parse fails.
initially :: (Generic a, GFromJSON Zero (Rep a)) => a -> Value -> Parser a Source #
Implements FromJSON with a fixed initialization. initializeWith :: (Generic a, GFromJSON Zero (Rep a)) => a -> Value -> Parser a
robustOptions :: Options Source #
JSON encoding options that are more robust to datatype migration.