penny-lib- Deprecated - use penny package instead

Safe HaskellNone



The Convert report. This report converts all account balances to a single commodity, which must be specified.



data Opts Source

Options for the Convert report. These are the only options you need to use if you are supplying options programatically (as opposed to parsing them in from the command line.)

type Sorter = (SubAccount, BottomLine) -> (SubAccount, BottomLine) -> OrderingSource

How to sort each line of the report. Each subaccount has only one BottomLine (unlike in the MultiCommodity report, where each subaccount may have more than one BottomLine, one for each commodity.)

report :: Opts -> [PricePoint] -> [(a, Posting)] -> Exceptional Text [Chunk]Source

The function for the Convert report. Use this function if you are setting the options from a program (as opposed to parsing them in from the command line.) Will fail if the balance conversions fail.

cmdLineReport :: DefaultOpts -> ReportSource

Creates a report respecting the standard interface for reports whose options are parsed in from the command line.

getSorter :: SortOrder -> SortBy -> SorterSource

Returns a function usable to sort pairs of SubAccount and BottomLine depending on how you want them sorted.