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

commonMain.aws.sdk.kotlin.services.glue.model.GetPlanRequest.kt Maven / Gradle / Ivy

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

package aws.sdk.kotlin.services.glue.model

import aws.smithy.kotlin.runtime.SdkDsl

public class GetPlanRequest private constructor(builder: Builder) {
    /**
     * A map to hold additional optional key-value parameters.
     *
     * Currently, these key-value pairs are supported:
     * + `inferSchema` — Specifies whether to set `inferSchema` to true or false for the default script generated by an Glue job. For example, to set `inferSchema` to true, pass the following key value pair:`--additional-plan-options-map '{"inferSchema":"true"}'`
     */
    public val additionalPlanOptionsMap: Map? = builder.additionalPlanOptionsMap
    /**
     * The programming language of the code to perform the mapping.
     */
    public val language: aws.sdk.kotlin.services.glue.model.Language? = builder.language
    /**
     * The parameters for the mapping.
     */
    public val location: aws.sdk.kotlin.services.glue.model.Location? = builder.location
    /**
     * The list of mappings from a source table to target tables.
     */
    public val mapping: List? = builder.mapping
    /**
     * The target tables.
     */
    public val sinks: List? = builder.sinks
    /**
     * The source table.
     */
    public val source: aws.sdk.kotlin.services.glue.model.CatalogEntry? = builder.source

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

    override fun toString(): kotlin.String = buildString {
        append("GetPlanRequest(")
        append("additionalPlanOptionsMap=$additionalPlanOptionsMap,")
        append("language=$language,")
        append("location=$location,")
        append("mapping=$mapping,")
        append("sinks=$sinks,")
        append("source=$source")
        append(")")
    }

    override fun hashCode(): kotlin.Int {
        var result = additionalPlanOptionsMap?.hashCode() ?: 0
        result = 31 * result + (language?.hashCode() ?: 0)
        result = 31 * result + (location?.hashCode() ?: 0)
        result = 31 * result + (mapping?.hashCode() ?: 0)
        result = 31 * result + (sinks?.hashCode() ?: 0)
        result = 31 * result + (source?.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 GetPlanRequest

        if (additionalPlanOptionsMap != other.additionalPlanOptionsMap) return false
        if (language != other.language) return false
        if (location != other.location) return false
        if (mapping != other.mapping) return false
        if (sinks != other.sinks) return false
        if (source != other.source) return false

        return true
    }

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

    @SdkDsl
    public class Builder {
        /**
         * A map to hold additional optional key-value parameters.
         *
         * Currently, these key-value pairs are supported:
         * + `inferSchema` — Specifies whether to set `inferSchema` to true or false for the default script generated by an Glue job. For example, to set `inferSchema` to true, pass the following key value pair:`--additional-plan-options-map '{"inferSchema":"true"}'`
         */
        public var additionalPlanOptionsMap: Map? = null
        /**
         * The programming language of the code to perform the mapping.
         */
        public var language: aws.sdk.kotlin.services.glue.model.Language? = null
        /**
         * The parameters for the mapping.
         */
        public var location: aws.sdk.kotlin.services.glue.model.Location? = null
        /**
         * The list of mappings from a source table to target tables.
         */
        public var mapping: List? = null
        /**
         * The target tables.
         */
        public var sinks: List? = null
        /**
         * The source table.
         */
        public var source: aws.sdk.kotlin.services.glue.model.CatalogEntry? = null

        @PublishedApi
        internal constructor()
        @PublishedApi
        internal constructor(x: aws.sdk.kotlin.services.glue.model.GetPlanRequest) : this() {
            this.additionalPlanOptionsMap = x.additionalPlanOptionsMap
            this.language = x.language
            this.location = x.location
            this.mapping = x.mapping
            this.sinks = x.sinks
            this.source = x.source
        }

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

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

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

        internal fun correctErrors(): Builder {
            return this
        }
    }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy