commonMain.aws.sdk.kotlin.services.configservice.serde.ConfigRuleEvaluationStatusDocumentDeserializer.kt Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of configservice-jvm Show documentation
Show all versions of configservice-jvm Show documentation
The AWS Kotlin client for Config Service
// Code generated by smithy-kotlin-codegen. DO NOT EDIT!
package aws.sdk.kotlin.services.configservice.serde
import aws.sdk.kotlin.services.configservice.model.ConfigRuleEvaluationStatus
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
internal fun deserializeConfigRuleEvaluationStatusDocument(deserializer: Deserializer): ConfigRuleEvaluationStatus {
val builder = ConfigRuleEvaluationStatus.Builder()
val CONFIGRULEARN_DESCRIPTOR = SdkFieldDescriptor(SerialKind.String, JsonSerialName("ConfigRuleArn"))
val CONFIGRULEID_DESCRIPTOR = SdkFieldDescriptor(SerialKind.String, JsonSerialName("ConfigRuleId"))
val CONFIGRULENAME_DESCRIPTOR = SdkFieldDescriptor(SerialKind.String, JsonSerialName("ConfigRuleName"))
val FIRSTACTIVATEDTIME_DESCRIPTOR = SdkFieldDescriptor(SerialKind.Timestamp, JsonSerialName("FirstActivatedTime"))
val FIRSTEVALUATIONSTARTED_DESCRIPTOR = SdkFieldDescriptor(SerialKind.Boolean, JsonSerialName("FirstEvaluationStarted"))
val LASTDEACTIVATEDTIME_DESCRIPTOR = SdkFieldDescriptor(SerialKind.Timestamp, JsonSerialName("LastDeactivatedTime"))
val LASTDEBUGLOGDELIVERYSTATUS_DESCRIPTOR = SdkFieldDescriptor(SerialKind.String, JsonSerialName("LastDebugLogDeliveryStatus"))
val LASTDEBUGLOGDELIVERYSTATUSREASON_DESCRIPTOR = SdkFieldDescriptor(SerialKind.String, JsonSerialName("LastDebugLogDeliveryStatusReason"))
val LASTDEBUGLOGDELIVERYTIME_DESCRIPTOR = SdkFieldDescriptor(SerialKind.Timestamp, JsonSerialName("LastDebugLogDeliveryTime"))
val LASTERRORCODE_DESCRIPTOR = SdkFieldDescriptor(SerialKind.String, JsonSerialName("LastErrorCode"))
val LASTERRORMESSAGE_DESCRIPTOR = SdkFieldDescriptor(SerialKind.String, JsonSerialName("LastErrorMessage"))
val LASTFAILEDEVALUATIONTIME_DESCRIPTOR = SdkFieldDescriptor(SerialKind.Timestamp, JsonSerialName("LastFailedEvaluationTime"))
val LASTFAILEDINVOCATIONTIME_DESCRIPTOR = SdkFieldDescriptor(SerialKind.Timestamp, JsonSerialName("LastFailedInvocationTime"))
val LASTSUCCESSFULEVALUATIONTIME_DESCRIPTOR = SdkFieldDescriptor(SerialKind.Timestamp, JsonSerialName("LastSuccessfulEvaluationTime"))
val LASTSUCCESSFULINVOCATIONTIME_DESCRIPTOR = SdkFieldDescriptor(SerialKind.Timestamp, JsonSerialName("LastSuccessfulInvocationTime"))
val OBJ_DESCRIPTOR = SdkObjectDescriptor.build {
field(CONFIGRULEARN_DESCRIPTOR)
field(CONFIGRULEID_DESCRIPTOR)
field(CONFIGRULENAME_DESCRIPTOR)
field(FIRSTACTIVATEDTIME_DESCRIPTOR)
field(FIRSTEVALUATIONSTARTED_DESCRIPTOR)
field(LASTDEACTIVATEDTIME_DESCRIPTOR)
field(LASTDEBUGLOGDELIVERYSTATUS_DESCRIPTOR)
field(LASTDEBUGLOGDELIVERYSTATUSREASON_DESCRIPTOR)
field(LASTDEBUGLOGDELIVERYTIME_DESCRIPTOR)
field(LASTERRORCODE_DESCRIPTOR)
field(LASTERRORMESSAGE_DESCRIPTOR)
field(LASTFAILEDEVALUATIONTIME_DESCRIPTOR)
field(LASTFAILEDINVOCATIONTIME_DESCRIPTOR)
field(LASTSUCCESSFULEVALUATIONTIME_DESCRIPTOR)
field(LASTSUCCESSFULINVOCATIONTIME_DESCRIPTOR)
}
deserializer.deserializeStruct(OBJ_DESCRIPTOR) {
loop@while (true) {
when (findNextFieldIndex()) {
CONFIGRULEARN_DESCRIPTOR.index -> builder.configRuleArn = deserializeString()
CONFIGRULEID_DESCRIPTOR.index -> builder.configRuleId = deserializeString()
CONFIGRULENAME_DESCRIPTOR.index -> builder.configRuleName = deserializeString()
FIRSTACTIVATEDTIME_DESCRIPTOR.index -> builder.firstActivatedTime = deserializeString().let { Instant.fromEpochSeconds(it) }
FIRSTEVALUATIONSTARTED_DESCRIPTOR.index -> builder.firstEvaluationStarted = deserializeBoolean()
LASTDEACTIVATEDTIME_DESCRIPTOR.index -> builder.lastDeactivatedTime = deserializeString().let { Instant.fromEpochSeconds(it) }
LASTDEBUGLOGDELIVERYSTATUS_DESCRIPTOR.index -> builder.lastDebugLogDeliveryStatus = deserializeString()
LASTDEBUGLOGDELIVERYSTATUSREASON_DESCRIPTOR.index -> builder.lastDebugLogDeliveryStatusReason = deserializeString()
LASTDEBUGLOGDELIVERYTIME_DESCRIPTOR.index -> builder.lastDebugLogDeliveryTime = deserializeString().let { Instant.fromEpochSeconds(it) }
LASTERRORCODE_DESCRIPTOR.index -> builder.lastErrorCode = deserializeString()
LASTERRORMESSAGE_DESCRIPTOR.index -> builder.lastErrorMessage = deserializeString()
LASTFAILEDEVALUATIONTIME_DESCRIPTOR.index -> builder.lastFailedEvaluationTime = deserializeString().let { Instant.fromEpochSeconds(it) }
LASTFAILEDINVOCATIONTIME_DESCRIPTOR.index -> builder.lastFailedInvocationTime = deserializeString().let { Instant.fromEpochSeconds(it) }
LASTSUCCESSFULEVALUATIONTIME_DESCRIPTOR.index -> builder.lastSuccessfulEvaluationTime = deserializeString().let { Instant.fromEpochSeconds(it) }
LASTSUCCESSFULINVOCATIONTIME_DESCRIPTOR.index -> builder.lastSuccessfulInvocationTime = deserializeString().let { Instant.fromEpochSeconds(it) }
null -> break@loop
else -> skipValue()
}
}
}
builder.correctErrors()
return builder.build()
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy