25#ifndef PERSONALFINANCE_ACCOUNT_H
26#define PERSONALFINANCE_ACCOUNT_H
33#include <nlohmann/json.hpp>
46 map<string, string> transactions;
47 map<string, string> recurring;
48 map<string, string> incomeList;
58 void setValues(
string str,
Money bal, map<string, string> tr, map<string, string> inc);
The Account class is used to perform various operations on an Account object.
Definition: Account.h:41
void setIncomeList(map< string, string > in)
Sets the income list on the account.
Money getGrossIncome()
Returns the gross income on the account.
void addToGrossIncome(Money m)
Adds a value to the gross income.
void addIncome(Income i)
Adds an income to the current account.
Money getTotalFromTransactions()
Returns the total amount spent on transactions.
void setBalance(Money bal)
Sets the account balance.
void setRecurringList(map< string, string > mp)
Sets the recurring transactions list on the account.
Money getTotalIncome()
Returns the total amount of income on the account.
void printAccountDetails()
Prints all details of the current account.
void setValues(string str, Money bal, map< string, string > tr, map< string, string > inc)
Sets the values of Account.
map< string, string > getIncomeList()
Returns the list of incomes currently on the account.
void setName(string name)
Sets the name of the account.
void printIncomeList()
Prints a list of all incomes on the account.
void addTransaction(Expense &e)
Adds an expense to the transaction list.
string getNameOfAccount()
Returns the name of the account.
void addToIncomeList(Income i)
Adds an income to the income list.
nlohmann::json toJSON()
Converts the Account object into a nlohmann::json object.
void printTransactions()
Prints a list of all transactions on the account.
map< string, string > getTransactions()
Returns the list of transactions on the account.
void updateBalance(Money &m)
Updates the current balance of the account.
Money getBalance()
Returns the current balance of the account.
map< string, string > getRecurringList()
Returns the list of recurring transactions on the account.
void setTransactions(map< string, string > mp)
Sets the transactions list on the account.
The Expense class is used to perform various operations on an Expense object.
Definition: Expense.h:21
This class is used to store income objects.
Definition: Income.h:20
The Money class is used to allow operations on Money.
Definition: Money.h:27