commonMain.aws.sdk.kotlin.services.route53.serde.CollectionSummaryDocumentDeserializer.kt Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of route53-jvm Show documentation
Show all versions of route53-jvm Show documentation
The AWS SDK for Kotlin client for Route 53
// Code generated by smithy-kotlin-codegen. DO NOT EDIT!
package aws.sdk.kotlin.services.route53.serde
import aws.sdk.kotlin.services.route53.model.CollectionSummary
import aws.smithy.kotlin.runtime.serde.getOrDeserializeErr
import aws.smithy.kotlin.runtime.serde.parseLong
import aws.smithy.kotlin.runtime.serde.xml.XmlTagReader
import aws.smithy.kotlin.runtime.serde.xml.tryData
internal fun deserializeCollectionSummaryDocument(reader: XmlTagReader): CollectionSummary {
val builder = CollectionSummary.Builder()
loop@while (true) {
val curr = reader.nextTag() ?: break@loop
when (curr.tagName) {
// Arn com.amazonaws.route53#CollectionSummary$Arn
"Arn" -> builder.arn = curr.tryData()
.getOrDeserializeErr { "expected (string: `com.amazonaws.route53#ARN`)" }
// Id com.amazonaws.route53#CollectionSummary$Id
"Id" -> builder.id = curr.tryData()
.getOrDeserializeErr { "expected (string: `com.amazonaws.route53#UUID`)" }
// Name com.amazonaws.route53#CollectionSummary$Name
"Name" -> builder.name = curr.tryData()
.getOrDeserializeErr { "expected (string: `com.amazonaws.route53#CollectionName`)" }
// Version com.amazonaws.route53#CollectionSummary$Version
"Version" -> builder.version = curr.tryData()
.parseLong()
.getOrDeserializeErr { "expected (long: `com.amazonaws.route53#CollectionVersion`)" }
else -> {}
}
curr.drop()
}
builder.correctErrors()
return builder.build()
}