composite-aeson- JSON for Vinyl/Frames records

Safe HaskellNone




data DateTimeFormat Source #

Structure carrying the date/time format string along with an example for error messaging and functions which optionally permute the input or output before using the format.

regularDateTimeFormat :: String -> String -> DateTimeFormat Source #

Construct a DateTimeFormat with no pre- or post- processing.

dateTimeJsonFormat :: (ParseTime t, FormatTime t) => TimeLocale -> NonEmpty DateTimeFormat -> JsonFormat e t Source #

JsonFormat for any type which ParseTime and FormatTime are defined for which maps to JSON via the first format given and maps from JSON via any format given.

iso8601DateJsonFormat :: JsonFormat e Day Source #

ISO8601 extended date format (yyyy-mm-dd).

iso8601DateTimeJsonFormat :: JsonFormat e UTCTime Source #

ISO8601 extended date/time format (yyyy-mm-ddThh:mm:ss.sssZ or yyyy-mm-ttThh:mm:ssZ)

iso8601TimeJsonFormat :: JsonFormat e TimeOfDay Source #

ISO8601 extended time format (hh:mm:ss.sss or hh:mm:ss)