Safe Haskell | Safe-Inferred |
---|---|
Language | Haskell2010 |
Types & functions for converting Gemini API responses into CSV exports.
Synopsis
- data ExportData = ExportData {
- edTZ :: TimeZone
- edLine :: ExportLine
- makeExportData :: MonadIO m => ExportLine -> m ExportData
- makeExportCsv :: [ExportData] -> ByteString
- data ExportLine
- getExportLineTimestamp :: ExportLine -> POSIXTime
Documentation
data ExportData Source #
The data required for rendering a single CSV row.
ExportData | |
|
Instances
makeExportData :: MonadIO m => ExportLine -> m ExportData Source #
Determine the TimeZone
for the ExportLine
& return both as an
ExportData
.
makeExportCsv :: [ExportData] -> ByteString Source #
Render the export data as a CSV with a header row.
data ExportLine Source #
Split out the data required for different export line types.
Instances
Read ExportLine Source # | |
Defined in Console.Gemini.Exports.Csv readsPrec :: Int -> ReadS ExportLine # readList :: ReadS [ExportLine] # readPrec :: ReadPrec ExportLine # readListPrec :: ReadPrec [ExportLine] # | |
Show ExportLine Source # | |
Defined in Console.Gemini.Exports.Csv showsPrec :: Int -> ExportLine -> ShowS # show :: ExportLine -> String # showList :: [ExportLine] -> ShowS # | |
Eq ExportLine Source # | |
Defined in Console.Gemini.Exports.Csv (==) :: ExportLine -> ExportLine -> Bool # (/=) :: ExportLine -> ExportLine -> Bool # | |
Ord ExportLine Source # | |
Defined in Console.Gemini.Exports.Csv compare :: ExportLine -> ExportLine -> Ordering # (<) :: ExportLine -> ExportLine -> Bool # (<=) :: ExportLine -> ExportLine -> Bool # (>) :: ExportLine -> ExportLine -> Bool # (>=) :: ExportLine -> ExportLine -> Bool # max :: ExportLine -> ExportLine -> ExportLine # min :: ExportLine -> ExportLine -> ExportLine # |
getExportLineTimestamp :: ExportLine -> POSIXTime Source #
Get the timestamp field of an ExportLine
.