commonMain.aws.sdk.kotlin.services.databasemigrationservice.serde.DataProviderSettingsDocumentSerializer.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.DataProviderSettings
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.SerializationException
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 serializeDataProviderSettingsDocument(serializer: Serializer, input: DataProviderSettings) {
val DOCDBSETTINGS_DESCRIPTOR = SdkFieldDescriptor(SerialKind.Struct, JsonSerialName("DocDbSettings"))
val MARIADBSETTINGS_DESCRIPTOR = SdkFieldDescriptor(SerialKind.Struct, JsonSerialName("MariaDbSettings"))
val MICROSOFTSQLSERVERSETTINGS_DESCRIPTOR = SdkFieldDescriptor(SerialKind.Struct, JsonSerialName("MicrosoftSqlServerSettings"))
val MONGODBSETTINGS_DESCRIPTOR = SdkFieldDescriptor(SerialKind.Struct, JsonSerialName("MongoDbSettings"))
val MYSQLSETTINGS_DESCRIPTOR = SdkFieldDescriptor(SerialKind.Struct, JsonSerialName("MySqlSettings"))
val ORACLESETTINGS_DESCRIPTOR = SdkFieldDescriptor(SerialKind.Struct, JsonSerialName("OracleSettings"))
val POSTGRESQLSETTINGS_DESCRIPTOR = SdkFieldDescriptor(SerialKind.Struct, JsonSerialName("PostgreSqlSettings"))
val REDSHIFTSETTINGS_DESCRIPTOR = SdkFieldDescriptor(SerialKind.Struct, JsonSerialName("RedshiftSettings"))
val OBJ_DESCRIPTOR = SdkObjectDescriptor.build {
field(DOCDBSETTINGS_DESCRIPTOR)
field(MARIADBSETTINGS_DESCRIPTOR)
field(MICROSOFTSQLSERVERSETTINGS_DESCRIPTOR)
field(MONGODBSETTINGS_DESCRIPTOR)
field(MYSQLSETTINGS_DESCRIPTOR)
field(ORACLESETTINGS_DESCRIPTOR)
field(POSTGRESQLSETTINGS_DESCRIPTOR)
field(REDSHIFTSETTINGS_DESCRIPTOR)
}
serializer.serializeStruct(OBJ_DESCRIPTOR) {
when (input) {
is DataProviderSettings.RedshiftSettings -> field(REDSHIFTSETTINGS_DESCRIPTOR, input.value, ::serializeRedshiftDataProviderSettingsDocument)
is DataProviderSettings.PostgreSqlSettings -> field(POSTGRESQLSETTINGS_DESCRIPTOR, input.value, ::serializePostgreSqlDataProviderSettingsDocument)
is DataProviderSettings.MySqlSettings -> field(MYSQLSETTINGS_DESCRIPTOR, input.value, ::serializeMySqlDataProviderSettingsDocument)
is DataProviderSettings.OracleSettings -> field(ORACLESETTINGS_DESCRIPTOR, input.value, ::serializeOracleDataProviderSettingsDocument)
is DataProviderSettings.MicrosoftSqlServerSettings -> field(MICROSOFTSQLSERVERSETTINGS_DESCRIPTOR, input.value, ::serializeMicrosoftSqlServerDataProviderSettingsDocument)
is DataProviderSettings.DocDbSettings -> field(DOCDBSETTINGS_DESCRIPTOR, input.value, ::serializeDocDbDataProviderSettingsDocument)
is DataProviderSettings.MariaDbSettings -> field(MARIADBSETTINGS_DESCRIPTOR, input.value, ::serializeMariaDbDataProviderSettingsDocument)
is DataProviderSettings.MongoDbSettings -> field(MONGODBSETTINGS_DESCRIPTOR, input.value, ::serializeMongoDbDataProviderSettingsDocument)
is DataProviderSettings.SdkUnknown -> throw SerializationException("Cannot serialize SdkUnknown")
}
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy