penny-lib-0.8.0.0: Extensible double-entry accounting system - library
Penny.Lincoln.Bits.Price
Synopsis
newtype From Source
Constructors
Fields
Instances
newtype To Source
newtype CountPerUnit Source
data Price Source
convert :: Price -> Amount -> Maybe AmountSource
Convert an amount from the From price to the To price. Fails if the From commodity in the Price is not the same as the commodity in the Amount.
newPrice :: From -> To -> CountPerUnit -> Maybe PriceSource
Succeeds only if From and To are different commodities.