summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPhilip Wedemann <22521688+hfhbd@users.noreply.github.com>2022-05-04 13:57:36 +0200
committerGitHub <noreply@github.com>2022-05-04 14:57:36 +0300
commitce8b05fe84a8bf8abeaa0506c984e40208a7c446 (patch)
treee51ece04ac7159fede2f15c2783c6582ca43844e
parent784892467f292dae27d3544148515795cd8eeee8 (diff)
downloadkotlinx.serialization-ce8b05fe84a8bf8abeaa0506c984e40208a7c446.tar.gz
Docs: Add decodeSequentially possible skipping decodeElementIndex (#1924)
-rw-r--r--core/commonMain/src/kotlinx/serialization/encoding/Decoding.kt2
1 files changed, 2 insertions, 0 deletions
diff --git a/core/commonMain/src/kotlinx/serialization/encoding/Decoding.kt b/core/commonMain/src/kotlinx/serialization/encoding/Decoding.kt
index 7ac3ec8e..3322b7fa 100644
--- a/core/commonMain/src/kotlinx/serialization/encoding/Decoding.kt
+++ b/core/commonMain/src/kotlinx/serialization/encoding/Decoding.kt
@@ -411,6 +411,8 @@ public interface CompositeDecoder {
* return descriptor.getElementIndex(nextKey) // getElementIndex can return UNKNOWN_NAME
* }
* ```
+ *
+ * If [decodeSequentially] returns `true`, the caller might skip calling this method.
*/
public fun decodeElementIndex(descriptor: SerialDescriptor): Int