Made methods overridable; made + 3 clearer

This commit is contained in:
dankito 2024-08-24 17:12:44 +02:00
parent eabe2c4930
commit 40b916a49f
1 changed files with 3 additions and 3 deletions

View File

@ -133,7 +133,7 @@ open class MessageBuilder(protected val utils: FinTsUtils = FinTsUtils()) {
} }
if (context.bank.customerSystemId == KundensystemID.Anonymous) { if (context.bank.customerSystemId == KundensystemID.Anonymous) {
segments.add(Synchronisierung(segments.size + 3, Synchronisierungsmodus.NeueKundensystemIdZurueckmelden)) segments.add(Synchronisierung(SignedMessagePayloadFirstSegmentNumber + segments.size, Synchronisierungsmodus.NeueKundensystemIdZurueckmelden))
} }
return createSignedMessageBuilderResult(context, MessageType.DialogInit, segments) return createSignedMessageBuilderResult(context, MessageType.DialogInit, segments)
@ -394,7 +394,7 @@ open class MessageBuilder(protected val utils: FinTsUtils = FinTsUtils()) {
return createSignedMessage(context, null, payloadSegments) return createSignedMessage(context, null, payloadSegments)
} }
open fun createSignedMessage(context: JobContext, tan: String? = null, payloadSegments: List<Segment>): String { protected open fun createSignedMessage(context: JobContext, tan: String? = null, payloadSegments: List<Segment>): String {
val date = utils.formatDateTodayAsInt() val date = utils.formatDateTodayAsInt()
val time = utils.formatTimeNowAsInt() val time = utils.formatTimeNowAsInt()
@ -406,7 +406,7 @@ open class MessageBuilder(protected val utils: FinTsUtils = FinTsUtils()) {
return createMessage(context, encryptedPayload, payloadSegments.size) return createMessage(context, encryptedPayload, payloadSegments.size)
} }
open fun createMessage(context: JobContext, payloadSegments: List<Segment>, countWrappedSegments: Int = 0): String { protected open fun createMessage(context: JobContext, payloadSegments: List<Segment>, countWrappedSegments: Int = 0): String {
val dialog = context.dialog val dialog = context.dialog
dialog.increaseMessageNumber() dialog.increaseMessageNumber()