SwiftBeanCountRogersBankMapper
public struct SwiftBeanCountRogersBankMapper
Mapper to map downloaded accounts and activities to BeanCoutModel objects
-
Account name to which the expenses are posted
Declaration
Swift
public let expenseAccountName: AccountName
-
Creates a mapper
Declaration
Swift
public init(ledger: Ledger)
Parameters
ledger
Ledger which will be used to look up account names
-
Maps an account to a balance assertion
Throws
RogersBankMappingError if no matching account was foundDeclaration
Swift
public func mapAccountToBalance(account: RogersBankDownloader.Account) throws -> Balance
Parameters
account
account to map
Return Value
balance assertion with the current balance form the credit card account
-
Maps activities to transactions
Throws
RogersBankMappingErrorDeclaration
Swift
public func mapActivitiesToTransactions(activities: [Activity]) throws -> [Transaction]
Parameters
activities
Activities to map
Return Value
Transactions