commonMain.aws.sdk.kotlin.services.codepipeline.serde.ActionDeclarationDocumentSerializer.kt Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of codepipeline-jvm Show documentation
Show all versions of codepipeline-jvm Show documentation
The AWS SDK for Kotlin client for CodePipeline
// Code generated by smithy-kotlin-codegen. DO NOT EDIT!
package aws.sdk.kotlin.services.codepipeline.serde
import aws.sdk.kotlin.services.codepipeline.model.ActionDeclaration
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 serializeActionDeclarationDocument(serializer: Serializer, input: ActionDeclaration) {
val ACTIONTYPEID_DESCRIPTOR = SdkFieldDescriptor(SerialKind.Struct, JsonSerialName("actionTypeId"))
val CONFIGURATION_DESCRIPTOR = SdkFieldDescriptor(SerialKind.Map, JsonSerialName("configuration"))
val INPUTARTIFACTS_DESCRIPTOR = SdkFieldDescriptor(SerialKind.List, JsonSerialName("inputArtifacts"))
val NAME_DESCRIPTOR = SdkFieldDescriptor(SerialKind.String, JsonSerialName("name"))
val NAMESPACE_DESCRIPTOR = SdkFieldDescriptor(SerialKind.String, JsonSerialName("namespace"))
val OUTPUTARTIFACTS_DESCRIPTOR = SdkFieldDescriptor(SerialKind.List, JsonSerialName("outputArtifacts"))
val REGION_DESCRIPTOR = SdkFieldDescriptor(SerialKind.String, JsonSerialName("region"))
val ROLEARN_DESCRIPTOR = SdkFieldDescriptor(SerialKind.String, JsonSerialName("roleArn"))
val RUNORDER_DESCRIPTOR = SdkFieldDescriptor(SerialKind.Integer, JsonSerialName("runOrder"))
val OBJ_DESCRIPTOR = SdkObjectDescriptor.build {
field(ACTIONTYPEID_DESCRIPTOR)
field(CONFIGURATION_DESCRIPTOR)
field(INPUTARTIFACTS_DESCRIPTOR)
field(NAME_DESCRIPTOR)
field(NAMESPACE_DESCRIPTOR)
field(OUTPUTARTIFACTS_DESCRIPTOR)
field(REGION_DESCRIPTOR)
field(ROLEARN_DESCRIPTOR)
field(RUNORDER_DESCRIPTOR)
}
serializer.serializeStruct(OBJ_DESCRIPTOR) {
field(NAME_DESCRIPTOR, input.name)
input.actionTypeId?.let { field(ACTIONTYPEID_DESCRIPTOR, it, ::serializeActionTypeIdDocument) }
input.runOrder?.let { field(RUNORDER_DESCRIPTOR, it) }
if (input.configuration != null) {
mapField(CONFIGURATION_DESCRIPTOR) {
input.configuration.forEach { (key, value) -> entry(key, value) }
}
}
if (input.outputArtifacts != null) {
listField(OUTPUTARTIFACTS_DESCRIPTOR) {
for (el0 in input.outputArtifacts) {
serializeSdkSerializable(asSdkSerializable(el0, ::serializeOutputArtifactDocument))
}
}
}
if (input.inputArtifacts != null) {
listField(INPUTARTIFACTS_DESCRIPTOR) {
for (el0 in input.inputArtifacts) {
serializeSdkSerializable(asSdkSerializable(el0, ::serializeInputArtifactDocument))
}
}
}
input.roleArn?.let { field(ROLEARN_DESCRIPTOR, it) }
input.region?.let { field(REGION_DESCRIPTOR, it) }
input.namespace?.let { field(NAMESPACE_DESCRIPTOR, it) }
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy