commonMain.aws.sdk.kotlin.services.databasemigrationservice.serde.ReplicationTaskAssessmentResultDocumentDeserializer.kt Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of databasemigrationservice-jvm Show documentation
Show all versions of databasemigrationservice-jvm Show documentation
The AWS SDK for Kotlin client for Database Migration Service
The newest version!
// Code generated by smithy-kotlin-codegen. DO NOT EDIT!
package aws.sdk.kotlin.services.databasemigrationservice.serde
import aws.sdk.kotlin.services.databasemigrationservice.model.ReplicationTaskAssessmentResult
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
import aws.smithy.kotlin.runtime.time.Instant
import aws.smithy.kotlin.runtime.time.TimestampFormat
internal fun deserializeReplicationTaskAssessmentResultDocument(deserializer: Deserializer): ReplicationTaskAssessmentResult {
val builder = ReplicationTaskAssessmentResult.Builder()
val ASSESSMENTRESULTS_DESCRIPTOR = SdkFieldDescriptor(SerialKind.String, JsonSerialName("AssessmentResults"))
val ASSESSMENTRESULTSFILE_DESCRIPTOR = SdkFieldDescriptor(SerialKind.String, JsonSerialName("AssessmentResultsFile"))
val ASSESSMENTSTATUS_DESCRIPTOR = SdkFieldDescriptor(SerialKind.String, JsonSerialName("AssessmentStatus"))
val REPLICATIONTASKARN_DESCRIPTOR = SdkFieldDescriptor(SerialKind.String, JsonSerialName("ReplicationTaskArn"))
val REPLICATIONTASKIDENTIFIER_DESCRIPTOR = SdkFieldDescriptor(SerialKind.String, JsonSerialName("ReplicationTaskIdentifier"))
val REPLICATIONTASKLASTASSESSMENTDATE_DESCRIPTOR = SdkFieldDescriptor(SerialKind.Timestamp, JsonSerialName("ReplicationTaskLastAssessmentDate"))
val S3OBJECTURL_DESCRIPTOR = SdkFieldDescriptor(SerialKind.String, JsonSerialName("S3ObjectUrl"))
val OBJ_DESCRIPTOR = SdkObjectDescriptor.build {
field(ASSESSMENTRESULTS_DESCRIPTOR)
field(ASSESSMENTRESULTSFILE_DESCRIPTOR)
field(ASSESSMENTSTATUS_DESCRIPTOR)
field(REPLICATIONTASKARN_DESCRIPTOR)
field(REPLICATIONTASKIDENTIFIER_DESCRIPTOR)
field(REPLICATIONTASKLASTASSESSMENTDATE_DESCRIPTOR)
field(S3OBJECTURL_DESCRIPTOR)
}
deserializer.deserializeStruct(OBJ_DESCRIPTOR) {
loop@while (true) {
when (findNextFieldIndex()) {
ASSESSMENTRESULTS_DESCRIPTOR.index -> builder.assessmentResults = deserializeString()
ASSESSMENTRESULTSFILE_DESCRIPTOR.index -> builder.assessmentResultsFile = deserializeString()
ASSESSMENTSTATUS_DESCRIPTOR.index -> builder.assessmentStatus = deserializeString()
REPLICATIONTASKARN_DESCRIPTOR.index -> builder.replicationTaskArn = deserializeString()
REPLICATIONTASKIDENTIFIER_DESCRIPTOR.index -> builder.replicationTaskIdentifier = deserializeString()
REPLICATIONTASKLASTASSESSMENTDATE_DESCRIPTOR.index -> builder.replicationTaskLastAssessmentDate = deserializeInstant(TimestampFormat.EPOCH_SECONDS)
S3OBJECTURL_DESCRIPTOR.index -> builder.s3ObjectUrl = deserializeString()
null -> break@loop
else -> skipValue()
}
}
}
builder.correctErrors()
return builder.build()
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy