commonMain.aws.sdk.kotlin.services.applicationdiscoveryservice.serde.CustomerMeCollectorInfoDocumentDeserializer.kt Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of applicationdiscoveryservice-jvm Show documentation
Show all versions of applicationdiscoveryservice-jvm Show documentation
The AWS SDK for Kotlin client for Application Discovery Service
// Code generated by smithy-kotlin-codegen. DO NOT EDIT!
package aws.sdk.kotlin.services.applicationdiscoveryservice.serde
import aws.sdk.kotlin.services.applicationdiscoveryservice.model.CustomerMeCollectorInfo
import aws.smithy.kotlin.runtime.serde.Deserializer
import aws.smithy.kotlin.runtime.serde.SdkFieldDescriptor
import aws.smithy.kotlin.runtime.serde.SdkObjectDescriptor
import aws.smithy.kotlin.runtime.serde.SerialKind
import aws.smithy.kotlin.runtime.serde.asSdkSerializable
import aws.smithy.kotlin.runtime.serde.deserializeList
import aws.smithy.kotlin.runtime.serde.deserializeMap
import aws.smithy.kotlin.runtime.serde.deserializeStruct
import aws.smithy.kotlin.runtime.serde.field
import aws.smithy.kotlin.runtime.serde.json.JsonDeserializer
import aws.smithy.kotlin.runtime.serde.json.JsonSerialName
import aws.smithy.kotlin.runtime.serde.serializeList
import aws.smithy.kotlin.runtime.serde.serializeMap
import aws.smithy.kotlin.runtime.serde.serializeStruct
internal fun deserializeCustomerMeCollectorInfoDocument(deserializer: Deserializer): CustomerMeCollectorInfo {
val builder = CustomerMeCollectorInfo.Builder()
val ACTIVEMECOLLECTORS_DESCRIPTOR = SdkFieldDescriptor(SerialKind.Integer, JsonSerialName("activeMeCollectors"))
val DENYLISTEDMECOLLECTORS_DESCRIPTOR = SdkFieldDescriptor(SerialKind.Integer, JsonSerialName("denyListedMeCollectors"))
val HEALTHYMECOLLECTORS_DESCRIPTOR = SdkFieldDescriptor(SerialKind.Integer, JsonSerialName("healthyMeCollectors"))
val SHUTDOWNMECOLLECTORS_DESCRIPTOR = SdkFieldDescriptor(SerialKind.Integer, JsonSerialName("shutdownMeCollectors"))
val TOTALMECOLLECTORS_DESCRIPTOR = SdkFieldDescriptor(SerialKind.Integer, JsonSerialName("totalMeCollectors"))
val UNHEALTHYMECOLLECTORS_DESCRIPTOR = SdkFieldDescriptor(SerialKind.Integer, JsonSerialName("unhealthyMeCollectors"))
val UNKNOWNMECOLLECTORS_DESCRIPTOR = SdkFieldDescriptor(SerialKind.Integer, JsonSerialName("unknownMeCollectors"))
val OBJ_DESCRIPTOR = SdkObjectDescriptor.build {
field(ACTIVEMECOLLECTORS_DESCRIPTOR)
field(DENYLISTEDMECOLLECTORS_DESCRIPTOR)
field(HEALTHYMECOLLECTORS_DESCRIPTOR)
field(SHUTDOWNMECOLLECTORS_DESCRIPTOR)
field(TOTALMECOLLECTORS_DESCRIPTOR)
field(UNHEALTHYMECOLLECTORS_DESCRIPTOR)
field(UNKNOWNMECOLLECTORS_DESCRIPTOR)
}
deserializer.deserializeStruct(OBJ_DESCRIPTOR) {
loop@while (true) {
when (findNextFieldIndex()) {
ACTIVEMECOLLECTORS_DESCRIPTOR.index -> builder.activeMeCollectors = deserializeInt()
DENYLISTEDMECOLLECTORS_DESCRIPTOR.index -> builder.denyListedMeCollectors = deserializeInt()
HEALTHYMECOLLECTORS_DESCRIPTOR.index -> builder.healthyMeCollectors = deserializeInt()
SHUTDOWNMECOLLECTORS_DESCRIPTOR.index -> builder.shutdownMeCollectors = deserializeInt()
TOTALMECOLLECTORS_DESCRIPTOR.index -> builder.totalMeCollectors = deserializeInt()
UNHEALTHYMECOLLECTORS_DESCRIPTOR.index -> builder.unhealthyMeCollectors = deserializeInt()
UNKNOWNMECOLLECTORS_DESCRIPTOR.index -> builder.unknownMeCollectors = deserializeInt()
null -> break@loop
else -> skipValue()
}
}
}
builder.correctErrors()
return builder.build()
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy