|
| 1 | +/* |
| 2 | + * Copyright (c) 2010-2024. Axon Framework |
| 3 | + * |
| 4 | + * Licensed under the Apache License, Version 2.0 (the "License"); |
| 5 | + * you may not use this file except in compliance with the License. |
| 6 | + * You may obtain a copy of the License at |
| 7 | + * |
| 8 | + * http://www.apache.org/licenses/LICENSE-2.0 |
| 9 | + * |
| 10 | + * Unless required by applicable law or agreed to in writing, software |
| 11 | + * distributed under the License is distributed on an "AS IS" BASIS, |
| 12 | + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
| 13 | + * See the License for the specific language governing permissions and |
| 14 | + * limitations under the License. |
| 15 | + */ |
1 | 16 | package org.axonframework.extensions.kotlin.serialization
|
2 | 17 |
|
3 |
| -import kotlinx.serialization.ExperimentalSerializationApi |
4 | 18 | import kotlinx.serialization.KSerializer
|
5 | 19 | import kotlinx.serialization.PolymorphicSerializer
|
6 | 20 | import kotlinx.serialization.SerializationException
|
@@ -208,10 +222,9 @@ object ReplayTokenSerializer : KSerializer<ReplayToken> {
|
208 | 222 | )
|
209 | 223 | }
|
210 | 224 |
|
211 |
| - @OptIn(ExperimentalSerializationApi::class) |
212 | 225 | override fun serialize(encoder: Encoder, value: ReplayToken) = encoder.encodeStructure(descriptor) {
|
213 | 226 | encodeSerializableElement(descriptor, 0, trackingTokenSerializer, value.tokenAtReset)
|
214 |
| - encodeNullableSerializableElement(descriptor, 1, trackingTokenSerializer, value.currentToken) |
| 227 | + encodeSerializableElement(descriptor, 1, trackingTokenSerializer, value.currentToken) |
215 | 228 | }
|
216 | 229 | }
|
217 | 230 |
|
|
0 commit comments