Moved extension methods to fints4k project
This commit is contained in:
parent
e024c764b2
commit
6a7f8d6780
|
@ -13,7 +13,7 @@ import kotlinx.datetime.minus
|
|||
import net.dankito.banking.client.model.parameter.GetAccountDataParameter
|
||||
import net.dankito.banking.client.model.parameter.RetrieveTransactions
|
||||
import net.dankito.banking.fints.model.TanMethodType
|
||||
import net.dankito.utils.multiplatform.extensions.todayAtEuropeBerlin
|
||||
import net.dankito.banking.fints.extensions.todayAtEuropeBerlin
|
||||
import util.OutputFormat
|
||||
|
||||
|
||||
|
|
|
@ -4,7 +4,7 @@ import kotlinx.datetime.LocalDate
|
|||
import kotlinx.serialization.Serializable
|
||||
import net.dankito.banking.fints.model.Amount
|
||||
import net.dankito.banking.fints.model.Money
|
||||
import net.dankito.utils.multiplatform.extensions.UnixEpochStart
|
||||
import net.dankito.banking.fints.extensions.UnixEpochStart
|
||||
|
||||
|
||||
@Serializable
|
||||
|
|
|
@ -4,8 +4,8 @@ import kotlinx.coroutines.GlobalScope
|
|||
import kotlinx.coroutines.launch
|
||||
import kotlinx.datetime.*
|
||||
import net.dankito.banking.fints.callback.FinTsClientCallback
|
||||
import net.dankito.utils.multiplatform.extensions.minusDays
|
||||
import net.dankito.utils.multiplatform.extensions.todayAtEuropeBerlin
|
||||
import net.dankito.banking.fints.extensions.minusDays
|
||||
import net.dankito.banking.fints.extensions.todayAtEuropeBerlin
|
||||
import net.dankito.banking.fints.messages.datenelemente.implementierte.tan.*
|
||||
import net.dankito.banking.fints.model.*
|
||||
import net.dankito.banking.fints.response.BankResponse
|
||||
|
|
|
@ -18,9 +18,9 @@ import net.dankito.banking.fints.response.segments.*
|
|||
import net.dankito.banking.fints.tan.FlickerCodeDecoder
|
||||
import net.dankito.banking.fints.tan.TanImageDecoder
|
||||
import net.dankito.banking.fints.util.TanMethodSelector
|
||||
import net.dankito.utils.multiplatform.extensions.minusDays
|
||||
import net.dankito.utils.multiplatform.extensions.todayAtEuropeBerlin
|
||||
import net.dankito.utils.multiplatform.extensions.todayAtSystemDefaultTimeZone
|
||||
import net.dankito.banking.fints.extensions.minusDays
|
||||
import net.dankito.banking.fints.extensions.todayAtEuropeBerlin
|
||||
import net.dankito.banking.fints.extensions.todayAtSystemDefaultTimeZone
|
||||
|
||||
|
||||
/**
|
||||
|
|
|
@ -11,7 +11,7 @@ import net.dankito.banking.fints.util.PureKotlinBase64Service
|
|||
import net.dankito.banking.fints.webclient.IWebClient
|
||||
import net.dankito.banking.fints.webclient.KtorWebClient
|
||||
import net.dankito.banking.fints.webclient.WebClientResponse
|
||||
import net.dankito.utils.multiplatform.extensions.getAllExceptionMessagesJoined
|
||||
import net.dankito.banking.fints.extensions.getAllExceptionMessagesJoined
|
||||
|
||||
|
||||
open class RequestExecutor(
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
package net.dankito.utils.multiplatform.extensions
|
||||
package net.dankito.banking.fints.extensions
|
||||
|
||||
import kotlinx.datetime.*
|
||||
import kotlin.js.JsName
|
|
@ -1,4 +1,4 @@
|
|||
package net.dankito.utils.multiplatform.extensions
|
||||
package net.dankito.banking.fints.extensions
|
||||
|
||||
import kotlinx.datetime.*
|
||||
|
|
@ -1,4 +1,4 @@
|
|||
package net.dankito.utils.multiplatform.extensions
|
||||
package net.dankito.banking.fints.extensions
|
||||
|
||||
|
||||
fun Int.toStringWithMinDigits(minimumCountDigits: Int, fillerString: Char = '0'): String {
|
|
@ -1,4 +1,4 @@
|
|||
package net.dankito.utils.multiplatform.extensions
|
||||
package net.dankito.banking.fints.extensions
|
||||
|
||||
import kotlinx.datetime.Clock
|
||||
import kotlin.random.Random
|
|
@ -1,4 +1,4 @@
|
|||
package net.dankito.utils.multiplatform.extensions
|
||||
package net.dankito.banking.fints.extensions
|
||||
|
||||
|
||||
/**
|
|
@ -1,4 +1,4 @@
|
|||
package net.dankito.utils.multiplatform.extensions
|
||||
package net.dankito.banking.fints.extensions
|
||||
|
||||
|
||||
fun Throwable.getAllExceptionMessagesJoined(maxDepth: Int = 5): String {
|
|
@ -0,0 +1,7 @@
|
|||
package net.dankito.banking.fints.extensions
|
||||
|
||||
import kotlinx.datetime.TimeZone
|
||||
|
||||
|
||||
val TimeZone.Companion.europeBerlin: TimeZone
|
||||
get() = TimeZone.of("Europe/Berlin")
|
|
@ -6,9 +6,9 @@ import net.codinux.log.logger
|
|||
import net.dankito.banking.fints.model.BankData
|
||||
import net.dankito.banking.fints.model.MessageLogEntry
|
||||
import net.dankito.banking.fints.model.MessageLogEntryType
|
||||
import net.dankito.utils.multiplatform.extensions.getInnerException
|
||||
import net.dankito.utils.multiplatform.extensions.nthIndexOf
|
||||
import net.dankito.utils.multiplatform.extensions.toStringWithMinDigits
|
||||
import net.dankito.banking.fints.extensions.getInnerException
|
||||
import net.dankito.banking.fints.extensions.nthIndexOf
|
||||
import net.dankito.banking.fints.extensions.toStringWithMinDigits
|
||||
import kotlin.reflect.KClass
|
||||
|
||||
|
||||
|
|
|
@ -13,8 +13,8 @@ import net.dankito.banking.fints.response.client.FinTsClientResponse
|
|||
import net.dankito.banking.fints.response.client.GetAccountTransactionsResponse
|
||||
import net.dankito.banking.fints.response.segments.AccountType
|
||||
import net.dankito.banking.fints.util.BicFinder
|
||||
import net.dankito.utils.multiplatform.extensions.minusDays
|
||||
import net.dankito.utils.multiplatform.extensions.todayAtEuropeBerlin
|
||||
import net.dankito.banking.fints.extensions.minusDays
|
||||
import net.dankito.banking.fints.extensions.todayAtEuropeBerlin
|
||||
|
||||
|
||||
open class FinTsModelMapper {
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
package net.dankito.banking.fints.messages
|
||||
|
||||
import net.dankito.utils.multiplatform.extensions.randomWithSeed
|
||||
import net.dankito.banking.fints.extensions.randomWithSeed
|
||||
import net.dankito.banking.fints.messages.datenelemente.implementierte.Aufsetzpunkt
|
||||
import net.dankito.banking.fints.messages.datenelemente.implementierte.KundensystemID
|
||||
import net.dankito.banking.fints.messages.datenelemente.implementierte.Synchronisierungsmodus
|
||||
|
|
|
@ -2,9 +2,9 @@ package net.dankito.banking.fints.messages.datenelemente.abgeleiteteformate
|
|||
|
||||
import kotlinx.datetime.LocalDate
|
||||
import net.codinux.log.logger
|
||||
import net.dankito.banking.fints.extensions.toStringWithMinDigits
|
||||
import net.dankito.banking.fints.messages.Existenzstatus
|
||||
import net.dankito.banking.fints.messages.datenelemente.basisformate.NumerischesDatenelement
|
||||
import net.dankito.utils.multiplatform.extensions.toStringWithMinDigits
|
||||
|
||||
|
||||
/**
|
||||
|
|
|
@ -2,9 +2,9 @@ package net.dankito.banking.fints.messages.datenelemente.abgeleiteteformate
|
|||
|
||||
import kotlinx.datetime.LocalTime
|
||||
import net.codinux.log.logger
|
||||
import net.dankito.banking.fints.extensions.toStringWithMinDigits
|
||||
import net.dankito.banking.fints.messages.Existenzstatus
|
||||
import net.dankito.banking.fints.messages.datenelemente.basisformate.ZiffernDatenelement
|
||||
import net.dankito.utils.multiplatform.extensions.toStringWithMinDigits
|
||||
|
||||
|
||||
/**
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
package net.dankito.banking.fints.messages.segmente.implementierte.sepa
|
||||
|
||||
import kotlinx.datetime.LocalDateTime
|
||||
import net.dankito.utils.multiplatform.extensions.nowAtUtc
|
||||
import net.dankito.banking.fints.extensions.nowAtUtc
|
||||
|
||||
|
||||
/**
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
package net.dankito.banking.fints.model
|
||||
|
||||
import kotlinx.datetime.LocalDate
|
||||
import net.dankito.utils.multiplatform.extensions.UnixEpochStart
|
||||
import net.dankito.banking.fints.extensions.UnixEpochStart
|
||||
|
||||
|
||||
open class AccountTransaction(
|
||||
|
|
|
@ -25,7 +25,7 @@ import net.dankito.banking.fints.model.CreditCardTransaction
|
|||
import net.dankito.banking.fints.model.Money
|
||||
import net.dankito.banking.fints.response.segments.*
|
||||
import net.dankito.banking.fints.util.MessageUtils
|
||||
import net.dankito.utils.multiplatform.extensions.getAllExceptionMessagesJoined
|
||||
import net.dankito.banking.fints.extensions.getAllExceptionMessagesJoined
|
||||
|
||||
|
||||
open class ResponseParser(
|
||||
|
|
|
@ -3,7 +3,7 @@ package net.dankito.banking.fints.transactions.mt940
|
|||
import kotlinx.datetime.LocalDate
|
||||
import kotlinx.datetime.Month
|
||||
import net.codinux.log.logger
|
||||
import net.dankito.utils.multiplatform.extensions.todayAtEuropeBerlin
|
||||
import net.dankito.banking.fints.extensions.todayAtEuropeBerlin
|
||||
import net.dankito.banking.fints.log.IMessageLogAppender
|
||||
import net.dankito.banking.fints.model.Amount
|
||||
import net.dankito.banking.fints.transactions.mt940.model.*
|
||||
|
|
|
@ -2,7 +2,7 @@ package net.dankito.banking.fints.transactions.mt940.model
|
|||
|
||||
import kotlinx.datetime.LocalDate
|
||||
import net.dankito.banking.fints.model.Amount
|
||||
import net.dankito.utils.multiplatform.extensions.UnixEpochStart
|
||||
import net.dankito.banking.fints.extensions.UnixEpochStart
|
||||
|
||||
|
||||
open class Balance(
|
||||
|
|
|
@ -3,8 +3,8 @@ package net.dankito.banking.fints.util
|
|||
import kotlinx.datetime.LocalDate
|
||||
import kotlinx.datetime.LocalDateTime
|
||||
import kotlinx.datetime.LocalTime
|
||||
import net.dankito.utils.multiplatform.extensions.nowAtEuropeBerlin
|
||||
import net.dankito.utils.multiplatform.extensions.todayAtEuropeBerlin
|
||||
import net.dankito.banking.fints.extensions.nowAtEuropeBerlin
|
||||
import net.dankito.banking.fints.extensions.todayAtEuropeBerlin
|
||||
import net.dankito.banking.fints.messages.datenelemente.abgeleiteteformate.Datum
|
||||
import net.dankito.banking.fints.messages.datenelemente.abgeleiteteformate.Uhrzeit
|
||||
|
||||
|
|
|
@ -2,7 +2,7 @@ package net.dankito.banking.fints
|
|||
|
||||
import kotlinx.datetime.LocalDate
|
||||
import net.dankito.banking.fints.callback.SimpleFinTsClientCallback
|
||||
import net.dankito.utils.multiplatform.extensions.randomWithSeed
|
||||
import net.dankito.banking.fints.extensions.randomWithSeed
|
||||
import net.dankito.banking.fints.messages.datenelemente.abgeleiteteformate.Datum
|
||||
import net.dankito.banking.fints.messages.datenelemente.abgeleiteteformate.Laenderkennzeichen
|
||||
import net.dankito.banking.fints.messages.datenelemente.implementierte.Dialogsprache
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
package net.dankito.utils.multiplatform.extensions
|
||||
package net.dankito.banking.fints.extensions
|
||||
|
||||
import kotlin.test.Test
|
||||
import kotlin.test.assertEquals
|
|
@ -1,4 +1,4 @@
|
|||
package net.dankito.utils.multiplatform.extensions
|
||||
package net.dankito.banking.fints.extensions
|
||||
|
||||
import kotlin.test.Test
|
||||
import kotlin.test.assertEquals
|
|
@ -1,6 +1,6 @@
|
|||
package net.dankito.banking.fints.messages.datenelemente.basisformate
|
||||
|
||||
import net.dankito.banking.fints.extensions.assertThrows
|
||||
import net.dankito.banking.fints.test.assertThrows
|
||||
import net.dankito.banking.fints.messages.Existenzstatus
|
||||
import net.dankito.banking.fints.messages.datenelementgruppen.implementierte.signatur.SicherheitsidentifikationDetails
|
||||
import kotlin.test.Test
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
package net.dankito.banking.fints.messages.datenelemente.basisformate
|
||||
|
||||
import net.dankito.banking.fints.extensions.assertThrows
|
||||
import net.dankito.banking.fints.test.assertThrows
|
||||
import net.dankito.banking.fints.messages.Existenzstatus
|
||||
import kotlin.test.Test
|
||||
import kotlin.test.assertEquals
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
package net.dankito.banking.fints.messages.datenelemente.implementierte
|
||||
|
||||
import net.dankito.banking.fints.extensions.assertThrows
|
||||
import net.dankito.banking.fints.test.assertThrows
|
||||
import net.dankito.banking.fints.messages.Existenzstatus
|
||||
import kotlin.test.Test
|
||||
import kotlin.test.assertEquals
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
package net.dankito.banking.fints.messages.datenelemente.implementierte
|
||||
|
||||
import net.dankito.banking.fints.extensions.assertThrows
|
||||
import net.dankito.banking.fints.test.assertThrows
|
||||
import net.dankito.banking.fints.messages.Existenzstatus
|
||||
import kotlin.test.Test
|
||||
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
package net.dankito.banking.fints.messages.datenelementgruppen
|
||||
|
||||
import net.dankito.banking.fints.extensions.assertEmpty
|
||||
import net.dankito.banking.fints.test.assertEmpty
|
||||
import net.dankito.banking.fints.messages.Separators
|
||||
import net.dankito.banking.fints.messages.datenelementgruppen.implementierte.signatur.BenutzerdefinierteSignatur
|
||||
import kotlin.test.Test
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
package net.dankito.banking.fints.messages.segmente.implementierte.sepa
|
||||
|
||||
import net.dankito.banking.fints.extensions.assertContains
|
||||
import net.dankito.banking.fints.test.assertContains
|
||||
import net.dankito.banking.fints.messages.segmente.id.CustomerSegmentId
|
||||
import net.dankito.banking.fints.model.*
|
||||
import kotlin.test.Test
|
||||
|
|
|
@ -12,10 +12,10 @@ import net.dankito.banking.fints.messages.segmente.id.ISegmentId
|
|||
import net.dankito.banking.fints.messages.segmente.id.MessageSegmentId
|
||||
import net.dankito.banking.fints.response.segments.*
|
||||
import kotlinx.datetime.LocalDate
|
||||
import net.dankito.banking.fints.extensions.assertContains
|
||||
import net.dankito.banking.fints.extensions.assertContainsExactly
|
||||
import net.dankito.banking.fints.extensions.assertEmpty
|
||||
import net.dankito.banking.fints.extensions.assertSize
|
||||
import net.dankito.banking.fints.test.assertContains
|
||||
import net.dankito.banking.fints.test.assertContainsExactly
|
||||
import net.dankito.banking.fints.test.assertEmpty
|
||||
import net.dankito.banking.fints.test.assertSize
|
||||
import net.dankito.banking.fints.model.Amount
|
||||
import kotlin.test.*
|
||||
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
package net.dankito.banking.fints.extensions
|
||||
package net.dankito.banking.fints.test
|
||||
|
||||
import kotlin.contracts.ExperimentalContracts
|
||||
import kotlin.contracts.contract
|
|
@ -8,7 +8,7 @@ import net.dankito.banking.fints.transactions.mt940.model.StatementLine
|
|||
import kotlinx.datetime.LocalDate
|
||||
import net.dankito.banking.fints.extensions.*
|
||||
import net.dankito.banking.fints.model.Amount
|
||||
import net.dankito.utils.multiplatform.extensions.toStringWithMinDigits
|
||||
import net.dankito.banking.fints.test.*
|
||||
import kotlin.test.Test
|
||||
import kotlin.test.assertContains
|
||||
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
package net.dankito.banking.fints.util
|
||||
|
||||
import net.dankito.utils.multiplatform.extensions.randomWithSeed
|
||||
import net.dankito.banking.fints.extensions.randomWithSeed
|
||||
import kotlin.random.Random
|
||||
import kotlin.test.Test
|
||||
import kotlin.test.assertEquals
|
||||
|
|
|
@ -1,7 +0,0 @@
|
|||
package net.dankito.utils.multiplatform.extensions
|
||||
|
||||
import kotlinx.datetime.TimeZone
|
||||
|
||||
|
||||
val TimeZone.Companion.europeBerlin: TimeZone
|
||||
get() = TimeZone.of("Europe/Berlin")
|
Loading…
Reference in New Issue