commonMain.aws.sdk.kotlin.services.configservice.serde.ConfigRuleDocumentSerializer.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.ConfigRule
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.Serializer
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 serializeConfigRuleDocument(serializer: Serializer, input: ConfigRule) {
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 CONFIGRULESTATE_DESCRIPTOR = SdkFieldDescriptor(SerialKind.Enum, JsonSerialName("ConfigRuleState"))
val CREATEDBY_DESCRIPTOR = SdkFieldDescriptor(SerialKind.String, JsonSerialName("CreatedBy"))
val DESCRIPTION_DESCRIPTOR = SdkFieldDescriptor(SerialKind.String, JsonSerialName("Description"))
val EVALUATIONMODES_DESCRIPTOR = SdkFieldDescriptor(SerialKind.List, JsonSerialName("EvaluationModes"))
val INPUTPARAMETERS_DESCRIPTOR = SdkFieldDescriptor(SerialKind.String, JsonSerialName("InputParameters"))
val MAXIMUMEXECUTIONFREQUENCY_DESCRIPTOR = SdkFieldDescriptor(SerialKind.Enum, JsonSerialName("MaximumExecutionFrequency"))
val SCOPE_DESCRIPTOR = SdkFieldDescriptor(SerialKind.Struct, JsonSerialName("Scope"))
val SOURCE_DESCRIPTOR = SdkFieldDescriptor(SerialKind.Struct, JsonSerialName("Source"))
val OBJ_DESCRIPTOR = SdkObjectDescriptor.build {
field(CONFIGRULEARN_DESCRIPTOR)
field(CONFIGRULEID_DESCRIPTOR)
field(CONFIGRULENAME_DESCRIPTOR)
field(CONFIGRULESTATE_DESCRIPTOR)
field(CREATEDBY_DESCRIPTOR)
field(DESCRIPTION_DESCRIPTOR)
field(EVALUATIONMODES_DESCRIPTOR)
field(INPUTPARAMETERS_DESCRIPTOR)
field(MAXIMUMEXECUTIONFREQUENCY_DESCRIPTOR)
field(SCOPE_DESCRIPTOR)
field(SOURCE_DESCRIPTOR)
}
serializer.serializeStruct(OBJ_DESCRIPTOR) {
input.configRuleName?.let { field(CONFIGRULENAME_DESCRIPTOR, it) }
input.configRuleArn?.let { field(CONFIGRULEARN_DESCRIPTOR, it) }
input.configRuleId?.let { field(CONFIGRULEID_DESCRIPTOR, it) }
input.description?.let { field(DESCRIPTION_DESCRIPTOR, it) }
input.scope?.let { field(SCOPE_DESCRIPTOR, it, ::serializeScopeDocument) }
input.source?.let { field(SOURCE_DESCRIPTOR, it, ::serializeSourceDocument) }
input.inputParameters?.let { field(INPUTPARAMETERS_DESCRIPTOR, it) }
input.maximumExecutionFrequency?.let { field(MAXIMUMEXECUTIONFREQUENCY_DESCRIPTOR, it.value) }
input.configRuleState?.let { field(CONFIGRULESTATE_DESCRIPTOR, it.value) }
input.createdBy?.let { field(CREATEDBY_DESCRIPTOR, it) }
if (input.evaluationModes != null) {
listField(EVALUATIONMODES_DESCRIPTOR) {
for (el0 in input.evaluationModes) {
serializeSdkSerializable(asSdkSerializable(el0, ::serializeEvaluationModeConfigurationDocument))
}
}
}
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy