All Downloads are FREE. Search and download functionalities are using the official Maven repository.

commonMain.aws.sdk.kotlin.services.databasemigrationservice.serde.OracleSettingsDocumentDeserializer.kt Maven / Gradle / Ivy

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.CharLengthSemantics
import aws.sdk.kotlin.services.databasemigrationservice.model.OracleAuthenticationMethod
import aws.sdk.kotlin.services.databasemigrationservice.model.OracleSettings
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 kotlin.collections.mutableListOf

internal fun deserializeOracleSettingsDocument(deserializer: Deserializer): OracleSettings {
    val builder = OracleSettings.Builder()
    val ACCESSALTERNATEDIRECTLY_DESCRIPTOR = SdkFieldDescriptor(SerialKind.Boolean, JsonSerialName("AccessAlternateDirectly"))
    val ADDSUPPLEMENTALLOGGING_DESCRIPTOR = SdkFieldDescriptor(SerialKind.Boolean, JsonSerialName("AddSupplementalLogging"))
    val ADDITIONALARCHIVEDLOGDESTID_DESCRIPTOR = SdkFieldDescriptor(SerialKind.Integer, JsonSerialName("AdditionalArchivedLogDestId"))
    val ALLOWSELECTNESTEDTABLES_DESCRIPTOR = SdkFieldDescriptor(SerialKind.Boolean, JsonSerialName("AllowSelectNestedTables"))
    val ARCHIVEDLOGDESTID_DESCRIPTOR = SdkFieldDescriptor(SerialKind.Integer, JsonSerialName("ArchivedLogDestId"))
    val ARCHIVEDLOGSONLY_DESCRIPTOR = SdkFieldDescriptor(SerialKind.Boolean, JsonSerialName("ArchivedLogsOnly"))
    val ASMPASSWORD_DESCRIPTOR = SdkFieldDescriptor(SerialKind.String, JsonSerialName("AsmPassword"))
    val ASMSERVER_DESCRIPTOR = SdkFieldDescriptor(SerialKind.String, JsonSerialName("AsmServer"))
    val ASMUSER_DESCRIPTOR = SdkFieldDescriptor(SerialKind.String, JsonSerialName("AsmUser"))
    val AUTHENTICATIONMETHOD_DESCRIPTOR = SdkFieldDescriptor(SerialKind.Enum, JsonSerialName("AuthenticationMethod"))
    val CHARLENGTHSEMANTICS_DESCRIPTOR = SdkFieldDescriptor(SerialKind.Enum, JsonSerialName("CharLengthSemantics"))
    val CONVERTTIMESTAMPWITHZONETOUTC_DESCRIPTOR = SdkFieldDescriptor(SerialKind.Boolean, JsonSerialName("ConvertTimestampWithZoneToUTC"))
    val DATABASENAME_DESCRIPTOR = SdkFieldDescriptor(SerialKind.String, JsonSerialName("DatabaseName"))
    val DIRECTPATHNOLOG_DESCRIPTOR = SdkFieldDescriptor(SerialKind.Boolean, JsonSerialName("DirectPathNoLog"))
    val DIRECTPATHPARALLELLOAD_DESCRIPTOR = SdkFieldDescriptor(SerialKind.Boolean, JsonSerialName("DirectPathParallelLoad"))
    val ENABLEHOMOGENOUSTABLESPACE_DESCRIPTOR = SdkFieldDescriptor(SerialKind.Boolean, JsonSerialName("EnableHomogenousTablespace"))
    val EXTRAARCHIVEDLOGDESTIDS_DESCRIPTOR = SdkFieldDescriptor(SerialKind.List, JsonSerialName("ExtraArchivedLogDestIds"))
    val FAILTASKSONLOBTRUNCATION_DESCRIPTOR = SdkFieldDescriptor(SerialKind.Boolean, JsonSerialName("FailTasksOnLobTruncation"))
    val NUMBERDATATYPESCALE_DESCRIPTOR = SdkFieldDescriptor(SerialKind.Integer, JsonSerialName("NumberDatatypeScale"))
    val OPENTRANSACTIONWINDOW_DESCRIPTOR = SdkFieldDescriptor(SerialKind.Integer, JsonSerialName("OpenTransactionWindow"))
    val ORACLEPATHPREFIX_DESCRIPTOR = SdkFieldDescriptor(SerialKind.String, JsonSerialName("OraclePathPrefix"))
    val PARALLELASMREADTHREADS_DESCRIPTOR = SdkFieldDescriptor(SerialKind.Integer, JsonSerialName("ParallelAsmReadThreads"))
    val PASSWORD_DESCRIPTOR = SdkFieldDescriptor(SerialKind.String, JsonSerialName("Password"))
    val PORT_DESCRIPTOR = SdkFieldDescriptor(SerialKind.Integer, JsonSerialName("Port"))
    val READAHEADBLOCKS_DESCRIPTOR = SdkFieldDescriptor(SerialKind.Integer, JsonSerialName("ReadAheadBlocks"))
    val READTABLESPACENAME_DESCRIPTOR = SdkFieldDescriptor(SerialKind.Boolean, JsonSerialName("ReadTableSpaceName"))
    val REPLACEPATHPREFIX_DESCRIPTOR = SdkFieldDescriptor(SerialKind.Boolean, JsonSerialName("ReplacePathPrefix"))
    val RETRYINTERVAL_DESCRIPTOR = SdkFieldDescriptor(SerialKind.Integer, JsonSerialName("RetryInterval"))
    val SECRETSMANAGERACCESSROLEARN_DESCRIPTOR = SdkFieldDescriptor(SerialKind.String, JsonSerialName("SecretsManagerAccessRoleArn"))
    val SECRETSMANAGERORACLEASMACCESSROLEARN_DESCRIPTOR = SdkFieldDescriptor(SerialKind.String, JsonSerialName("SecretsManagerOracleAsmAccessRoleArn"))
    val SECRETSMANAGERORACLEASMSECRETID_DESCRIPTOR = SdkFieldDescriptor(SerialKind.String, JsonSerialName("SecretsManagerOracleAsmSecretId"))
    val SECRETSMANAGERSECRETID_DESCRIPTOR = SdkFieldDescriptor(SerialKind.String, JsonSerialName("SecretsManagerSecretId"))
    val SECURITYDBENCRYPTION_DESCRIPTOR = SdkFieldDescriptor(SerialKind.String, JsonSerialName("SecurityDbEncryption"))
    val SECURITYDBENCRYPTIONNAME_DESCRIPTOR = SdkFieldDescriptor(SerialKind.String, JsonSerialName("SecurityDbEncryptionName"))
    val SERVERNAME_DESCRIPTOR = SdkFieldDescriptor(SerialKind.String, JsonSerialName("ServerName"))
    val SPATIALDATAOPTIONTOGEOJSONFUNCTIONNAME_DESCRIPTOR = SdkFieldDescriptor(SerialKind.String, JsonSerialName("SpatialDataOptionToGeoJsonFunctionName"))
    val STANDBYDELAYTIME_DESCRIPTOR = SdkFieldDescriptor(SerialKind.Integer, JsonSerialName("StandbyDelayTime"))
    val TRIMSPACEINCHAR_DESCRIPTOR = SdkFieldDescriptor(SerialKind.Boolean, JsonSerialName("TrimSpaceInChar"))
    val USEALTERNATEFOLDERFORONLINE_DESCRIPTOR = SdkFieldDescriptor(SerialKind.Boolean, JsonSerialName("UseAlternateFolderForOnline"))
    val USEBFILE_DESCRIPTOR = SdkFieldDescriptor(SerialKind.Boolean, JsonSerialName("UseBFile"))
    val USEDIRECTPATHFULLLOAD_DESCRIPTOR = SdkFieldDescriptor(SerialKind.Boolean, JsonSerialName("UseDirectPathFullLoad"))
    val USELOGMINERREADER_DESCRIPTOR = SdkFieldDescriptor(SerialKind.Boolean, JsonSerialName("UseLogminerReader"))
    val USEPATHPREFIX_DESCRIPTOR = SdkFieldDescriptor(SerialKind.String, JsonSerialName("UsePathPrefix"))
    val USERNAME_DESCRIPTOR = SdkFieldDescriptor(SerialKind.String, JsonSerialName("Username"))
    val OBJ_DESCRIPTOR = SdkObjectDescriptor.build {
        field(ACCESSALTERNATEDIRECTLY_DESCRIPTOR)
        field(ADDSUPPLEMENTALLOGGING_DESCRIPTOR)
        field(ADDITIONALARCHIVEDLOGDESTID_DESCRIPTOR)
        field(ALLOWSELECTNESTEDTABLES_DESCRIPTOR)
        field(ARCHIVEDLOGDESTID_DESCRIPTOR)
        field(ARCHIVEDLOGSONLY_DESCRIPTOR)
        field(ASMPASSWORD_DESCRIPTOR)
        field(ASMSERVER_DESCRIPTOR)
        field(ASMUSER_DESCRIPTOR)
        field(AUTHENTICATIONMETHOD_DESCRIPTOR)
        field(CHARLENGTHSEMANTICS_DESCRIPTOR)
        field(CONVERTTIMESTAMPWITHZONETOUTC_DESCRIPTOR)
        field(DATABASENAME_DESCRIPTOR)
        field(DIRECTPATHNOLOG_DESCRIPTOR)
        field(DIRECTPATHPARALLELLOAD_DESCRIPTOR)
        field(ENABLEHOMOGENOUSTABLESPACE_DESCRIPTOR)
        field(EXTRAARCHIVEDLOGDESTIDS_DESCRIPTOR)
        field(FAILTASKSONLOBTRUNCATION_DESCRIPTOR)
        field(NUMBERDATATYPESCALE_DESCRIPTOR)
        field(OPENTRANSACTIONWINDOW_DESCRIPTOR)
        field(ORACLEPATHPREFIX_DESCRIPTOR)
        field(PARALLELASMREADTHREADS_DESCRIPTOR)
        field(PASSWORD_DESCRIPTOR)
        field(PORT_DESCRIPTOR)
        field(READAHEADBLOCKS_DESCRIPTOR)
        field(READTABLESPACENAME_DESCRIPTOR)
        field(REPLACEPATHPREFIX_DESCRIPTOR)
        field(RETRYINTERVAL_DESCRIPTOR)
        field(SECRETSMANAGERACCESSROLEARN_DESCRIPTOR)
        field(SECRETSMANAGERORACLEASMACCESSROLEARN_DESCRIPTOR)
        field(SECRETSMANAGERORACLEASMSECRETID_DESCRIPTOR)
        field(SECRETSMANAGERSECRETID_DESCRIPTOR)
        field(SECURITYDBENCRYPTION_DESCRIPTOR)
        field(SECURITYDBENCRYPTIONNAME_DESCRIPTOR)
        field(SERVERNAME_DESCRIPTOR)
        field(SPATIALDATAOPTIONTOGEOJSONFUNCTIONNAME_DESCRIPTOR)
        field(STANDBYDELAYTIME_DESCRIPTOR)
        field(TRIMSPACEINCHAR_DESCRIPTOR)
        field(USEALTERNATEFOLDERFORONLINE_DESCRIPTOR)
        field(USEBFILE_DESCRIPTOR)
        field(USEDIRECTPATHFULLLOAD_DESCRIPTOR)
        field(USELOGMINERREADER_DESCRIPTOR)
        field(USEPATHPREFIX_DESCRIPTOR)
        field(USERNAME_DESCRIPTOR)
    }

    deserializer.deserializeStruct(OBJ_DESCRIPTOR) {
        loop@while (true) {
            when (findNextFieldIndex()) {
                ACCESSALTERNATEDIRECTLY_DESCRIPTOR.index -> builder.accessAlternateDirectly = deserializeBoolean()
                ADDSUPPLEMENTALLOGGING_DESCRIPTOR.index -> builder.addSupplementalLogging = deserializeBoolean()
                ADDITIONALARCHIVEDLOGDESTID_DESCRIPTOR.index -> builder.additionalArchivedLogDestId = deserializeInt()
                ALLOWSELECTNESTEDTABLES_DESCRIPTOR.index -> builder.allowSelectNestedTables = deserializeBoolean()
                ARCHIVEDLOGDESTID_DESCRIPTOR.index -> builder.archivedLogDestId = deserializeInt()
                ARCHIVEDLOGSONLY_DESCRIPTOR.index -> builder.archivedLogsOnly = deserializeBoolean()
                ASMPASSWORD_DESCRIPTOR.index -> builder.asmPassword = deserializeString()
                ASMSERVER_DESCRIPTOR.index -> builder.asmServer = deserializeString()
                ASMUSER_DESCRIPTOR.index -> builder.asmUser = deserializeString()
                AUTHENTICATIONMETHOD_DESCRIPTOR.index -> builder.authenticationMethod = deserializeString().let { OracleAuthenticationMethod.fromValue(it) }
                CHARLENGTHSEMANTICS_DESCRIPTOR.index -> builder.charLengthSemantics = deserializeString().let { CharLengthSemantics.fromValue(it) }
                CONVERTTIMESTAMPWITHZONETOUTC_DESCRIPTOR.index -> builder.convertTimestampWithZoneToUtc = deserializeBoolean()
                DATABASENAME_DESCRIPTOR.index -> builder.databaseName = deserializeString()
                DIRECTPATHNOLOG_DESCRIPTOR.index -> builder.directPathNoLog = deserializeBoolean()
                DIRECTPATHPARALLELLOAD_DESCRIPTOR.index -> builder.directPathParallelLoad = deserializeBoolean()
                ENABLEHOMOGENOUSTABLESPACE_DESCRIPTOR.index -> builder.enableHomogenousTablespace = deserializeBoolean()
                EXTRAARCHIVEDLOGDESTIDS_DESCRIPTOR.index -> builder.extraArchivedLogDestIds =
                    deserializer.deserializeList(EXTRAARCHIVEDLOGDESTIDS_DESCRIPTOR) {
                        val col0 = mutableListOf()
                        while (hasNextElement()) {
                            val el0 = if (nextHasValue()) { deserializeInt() } else { deserializeNull(); continue }
                            col0.add(el0)
                        }
                        col0
                    }
                FAILTASKSONLOBTRUNCATION_DESCRIPTOR.index -> builder.failTasksOnLobTruncation = deserializeBoolean()
                NUMBERDATATYPESCALE_DESCRIPTOR.index -> builder.numberDatatypeScale = deserializeInt()
                OPENTRANSACTIONWINDOW_DESCRIPTOR.index -> builder.openTransactionWindow = deserializeInt()
                ORACLEPATHPREFIX_DESCRIPTOR.index -> builder.oraclePathPrefix = deserializeString()
                PARALLELASMREADTHREADS_DESCRIPTOR.index -> builder.parallelAsmReadThreads = deserializeInt()
                PASSWORD_DESCRIPTOR.index -> builder.password = deserializeString()
                PORT_DESCRIPTOR.index -> builder.port = deserializeInt()
                READAHEADBLOCKS_DESCRIPTOR.index -> builder.readAheadBlocks = deserializeInt()
                READTABLESPACENAME_DESCRIPTOR.index -> builder.readTableSpaceName = deserializeBoolean()
                REPLACEPATHPREFIX_DESCRIPTOR.index -> builder.replacePathPrefix = deserializeBoolean()
                RETRYINTERVAL_DESCRIPTOR.index -> builder.retryInterval = deserializeInt()
                SECRETSMANAGERACCESSROLEARN_DESCRIPTOR.index -> builder.secretsManagerAccessRoleArn = deserializeString()
                SECRETSMANAGERORACLEASMACCESSROLEARN_DESCRIPTOR.index -> builder.secretsManagerOracleAsmAccessRoleArn = deserializeString()
                SECRETSMANAGERORACLEASMSECRETID_DESCRIPTOR.index -> builder.secretsManagerOracleAsmSecretId = deserializeString()
                SECRETSMANAGERSECRETID_DESCRIPTOR.index -> builder.secretsManagerSecretId = deserializeString()
                SECURITYDBENCRYPTION_DESCRIPTOR.index -> builder.securityDbEncryption = deserializeString()
                SECURITYDBENCRYPTIONNAME_DESCRIPTOR.index -> builder.securityDbEncryptionName = deserializeString()
                SERVERNAME_DESCRIPTOR.index -> builder.serverName = deserializeString()
                SPATIALDATAOPTIONTOGEOJSONFUNCTIONNAME_DESCRIPTOR.index -> builder.spatialDataOptionToGeoJsonFunctionName = deserializeString()
                STANDBYDELAYTIME_DESCRIPTOR.index -> builder.standbyDelayTime = deserializeInt()
                TRIMSPACEINCHAR_DESCRIPTOR.index -> builder.trimSpaceInChar = deserializeBoolean()
                USEALTERNATEFOLDERFORONLINE_DESCRIPTOR.index -> builder.useAlternateFolderForOnline = deserializeBoolean()
                USEBFILE_DESCRIPTOR.index -> builder.useBFile = deserializeBoolean()
                USEDIRECTPATHFULLLOAD_DESCRIPTOR.index -> builder.useDirectPathFullLoad = deserializeBoolean()
                USELOGMINERREADER_DESCRIPTOR.index -> builder.useLogminerReader = deserializeBoolean()
                USEPATHPREFIX_DESCRIPTOR.index -> builder.usePathPrefix = deserializeString()
                USERNAME_DESCRIPTOR.index -> builder.username = deserializeString()
                null -> break@loop
                else -> skipValue()
            }
        }
    }
    builder.correctErrors()
    return builder.build()
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy