aws.sdk.kotlin.services.sagemaker.transform.RecommendationJobInputConfigDocumentSerializer.kt Maven / Gradle / Ivy
// Code generated by smithy-kotlin-codegen. DO NOT EDIT!
package aws.sdk.kotlin.services.sagemaker.transform
import aws.sdk.kotlin.services.sagemaker.model.EndpointInputConfiguration
import aws.sdk.kotlin.services.sagemaker.model.RecommendationJobInputConfig
import aws.sdk.kotlin.services.sagemaker.model.RecommendationJobResourceLimit
import aws.sdk.kotlin.services.sagemaker.model.TrafficPattern
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 serializeRecommendationJobInputConfigDocument(serializer: Serializer, input: RecommendationJobInputConfig) {
val ENDPOINTCONFIGURATIONS_DESCRIPTOR = SdkFieldDescriptor(SerialKind.List, JsonSerialName("EndpointConfigurations"))
val JOBDURATIONINSECONDS_DESCRIPTOR = SdkFieldDescriptor(SerialKind.Integer, JsonSerialName("JobDurationInSeconds"))
val MODELPACKAGEVERSIONARN_DESCRIPTOR = SdkFieldDescriptor(SerialKind.String, JsonSerialName("ModelPackageVersionArn"))
val RESOURCELIMIT_DESCRIPTOR = SdkFieldDescriptor(SerialKind.Struct, JsonSerialName("ResourceLimit"))
val TRAFFICPATTERN_DESCRIPTOR = SdkFieldDescriptor(SerialKind.Struct, JsonSerialName("TrafficPattern"))
val OBJ_DESCRIPTOR = SdkObjectDescriptor.build {
field(ENDPOINTCONFIGURATIONS_DESCRIPTOR)
field(JOBDURATIONINSECONDS_DESCRIPTOR)
field(MODELPACKAGEVERSIONARN_DESCRIPTOR)
field(RESOURCELIMIT_DESCRIPTOR)
field(TRAFFICPATTERN_DESCRIPTOR)
}
serializer.serializeStruct(OBJ_DESCRIPTOR) {
input.modelPackageVersionArn?.let { field(MODELPACKAGEVERSIONARN_DESCRIPTOR, it) }
input.jobDurationInSeconds?.let { field(JOBDURATIONINSECONDS_DESCRIPTOR, it) }
input.trafficPattern?.let { field(TRAFFICPATTERN_DESCRIPTOR, it, ::serializeTrafficPatternDocument) }
input.resourceLimit?.let { field(RESOURCELIMIT_DESCRIPTOR, it, ::serializeRecommendationJobResourceLimitDocument) }
if (input.endpointConfigurations != null) {
listField(ENDPOINTCONFIGURATIONS_DESCRIPTOR) {
for (el0 in input.endpointConfigurations) {
serializeSdkSerializable(asSdkSerializable(el0, ::serializeEndpointInputConfigurationDocument))
}
}
}
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy