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

commonMain.aws.sdk.kotlin.services.entityresolution.model.IdNamespaceIdMappingWorkflowProperties.kt Maven / Gradle / Ivy

There is a newer version: 1.3.99
Show newest version
// Code generated by smithy-kotlin-codegen. DO NOT EDIT!

package aws.sdk.kotlin.services.entityresolution.model

import aws.smithy.kotlin.runtime.SdkDsl

/**
 * An object containing `IdMappingType` and `ProviderProperties`.
 */
public class IdNamespaceIdMappingWorkflowProperties private constructor(builder: Builder) {
    /**
     * The type of ID mapping.
     */
    public val idMappingType: aws.sdk.kotlin.services.entityresolution.model.IdMappingType = requireNotNull(builder.idMappingType) { "A non-null value must be provided for idMappingType" }
    /**
     * An object which defines any additional configurations required by the provider service.
     */
    public val providerProperties: aws.sdk.kotlin.services.entityresolution.model.NamespaceProviderProperties? = builder.providerProperties

    public companion object {
        public operator fun invoke(block: Builder.() -> kotlin.Unit): aws.sdk.kotlin.services.entityresolution.model.IdNamespaceIdMappingWorkflowProperties = Builder().apply(block).build()
    }

    override fun toString(): kotlin.String = buildString {
        append("IdNamespaceIdMappingWorkflowProperties(")
        append("idMappingType=$idMappingType,")
        append("providerProperties=$providerProperties")
        append(")")
    }

    override fun hashCode(): kotlin.Int {
        var result = idMappingType.hashCode()
        result = 31 * result + (providerProperties?.hashCode() ?: 0)
        return result
    }

    override fun equals(other: kotlin.Any?): kotlin.Boolean {
        if (this === other) return true
        if (other == null || this::class != other::class) return false

        other as IdNamespaceIdMappingWorkflowProperties

        if (idMappingType != other.idMappingType) return false
        if (providerProperties != other.providerProperties) return false

        return true
    }

    public inline fun copy(block: Builder.() -> kotlin.Unit = {}): aws.sdk.kotlin.services.entityresolution.model.IdNamespaceIdMappingWorkflowProperties = Builder(this).apply(block).build()

    @SdkDsl
    public class Builder {
        /**
         * The type of ID mapping.
         */
        public var idMappingType: aws.sdk.kotlin.services.entityresolution.model.IdMappingType? = null
        /**
         * An object which defines any additional configurations required by the provider service.
         */
        public var providerProperties: aws.sdk.kotlin.services.entityresolution.model.NamespaceProviderProperties? = null

        @PublishedApi
        internal constructor()
        @PublishedApi
        internal constructor(x: aws.sdk.kotlin.services.entityresolution.model.IdNamespaceIdMappingWorkflowProperties) : this() {
            this.idMappingType = x.idMappingType
            this.providerProperties = x.providerProperties
        }

        @PublishedApi
        internal fun build(): aws.sdk.kotlin.services.entityresolution.model.IdNamespaceIdMappingWorkflowProperties = IdNamespaceIdMappingWorkflowProperties(this)

        /**
         * construct an [aws.sdk.kotlin.services.entityresolution.model.NamespaceProviderProperties] inside the given [block]
         */
        public fun providerProperties(block: aws.sdk.kotlin.services.entityresolution.model.NamespaceProviderProperties.Builder.() -> kotlin.Unit) {
            this.providerProperties = aws.sdk.kotlin.services.entityresolution.model.NamespaceProviderProperties.invoke(block)
        }

        internal fun correctErrors(): Builder {
            if (idMappingType == null) idMappingType = IdMappingType.SdkUnknown("no value provided")
            return this
        }
    }
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy