Made collections val MutableList to be overridable with a derived collection class
This commit is contained in:
parent
400c13d6a2
commit
045774ff3f
|
@ -44,7 +44,7 @@ open class BankAccess(
|
|||
* [selectedTanMethod] to get selected TanMethod or iterate over [tanMethods] and filter selected one by this id.
|
||||
*/
|
||||
var selectedTanMethodIdentifier: String? = null,
|
||||
open var tanMethods: List<TanMethod> = listOf(),
|
||||
open val tanMethods: MutableList<out TanMethod> = mutableListOf(),
|
||||
|
||||
/**
|
||||
* Identifier of selected TanMedium.
|
||||
|
@ -53,7 +53,7 @@ open class BankAccess(
|
|||
* to get selected TanMedium or iterate over [tanMedia] and filter selected one by this medium name.
|
||||
*/
|
||||
var selectedTanMediumIdentifier: String? = null,
|
||||
open var tanMedia: List<TanMedium> = listOf(),
|
||||
open val tanMedia: MutableList<out TanMedium> = mutableListOf(),
|
||||
|
||||
var bankingGroup: BankingGroup? = null,
|
||||
open var serverAddress: String? = null,
|
||||
|
|
|
@ -26,9 +26,9 @@ open class BankAccount(
|
|||
open var lastAccountUpdateTime: Instant? = null,
|
||||
var retrievedTransactionsFrom: LocalDate? = null,
|
||||
|
||||
open var bookedTransactions: List<AccountTransaction> = emptyList(),
|
||||
open var prebookedTransactions: List<PrebookedAccountTransaction> = emptyList(),
|
||||
open var holdings: List<Holding> = emptyList(),
|
||||
open val bookedTransactions: MutableList<out AccountTransaction> = mutableListOf(),
|
||||
open val prebookedTransactions: MutableList<out PrebookedAccountTransaction> = mutableListOf(),
|
||||
open val holdings: MutableList<out Holding> = mutableListOf(),
|
||||
|
||||
var userSetDisplayName: String? = null,
|
||||
var displayIndex: Int = 0,
|
||||
|
|
|
@ -144,8 +144,8 @@ open class FinTs4kMapper {
|
|||
bank.accounts.map { mapAccount(it) }.sortedBy { it.type }
|
||||
.onEachIndexed { index, bankAccount -> bankAccount.displayIndex = index },
|
||||
|
||||
bank.selectedTanMethod?.securityFunction?.code, bank.tanMethods.map { mapTanMethod(it) },
|
||||
bank.selectedTanMedium?.mediumName, bank.tanMedia.map { mapTanMedium(it) },
|
||||
bank.selectedTanMethod?.securityFunction?.code, bank.tanMethods.map { mapTanMethod(it) }.toMutableList(),
|
||||
bank.selectedTanMedium?.mediumName, bank.tanMedia.map { mapTanMedium(it) }.toMutableList(),
|
||||
|
||||
info?.bankingGroup ?: getBankingGroup(bank.bankName, bank.bic),
|
||||
bank.finTsServerAddress,
|
||||
|
@ -163,8 +163,8 @@ open class FinTs4kMapper {
|
|||
mapMoney(account.balance),
|
||||
account.serverTransactionsRetentionDays,
|
||||
account.lastAccountUpdateTime, account.retrievedTransactionsFrom,
|
||||
bookedTransactions = mapBookedTransactions(account),
|
||||
holdings = mapHoldings(account.statementOfHoldings, account.currency, account.lastAccountUpdateTime)
|
||||
bookedTransactions = mapBookedTransactions(account).toMutableList(),
|
||||
holdings = mapHoldings(account.statementOfHoldings, account.currency, account.lastAccountUpdateTime).toMutableList()
|
||||
)
|
||||
|
||||
protected open fun mapAccountType(type: net.dankito.banking.client.model.BankAccountType): BankAccountType =
|
||||
|
|
Loading…
Reference in New Issue