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

commonMain.aws.sdk.kotlin.services.proton.model.AccountSettings.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.proton.model

import aws.smithy.kotlin.runtime.SdkDsl

/**
 * Proton settings that are used for multiple services in the Amazon Web Services account.
 */
public class AccountSettings private constructor(builder: Builder) {
    /**
     * The Amazon Resource Name (ARN) of the service role that Proton uses for provisioning pipelines. Proton assumes this role for CodeBuild-based provisioning.
     */
    public val pipelineCodebuildRoleArn: kotlin.String? = builder.pipelineCodebuildRoleArn
    /**
     * The linked repository for pipeline provisioning. Required if you have environments configured for self-managed provisioning with services that include pipelines. A linked repository is a repository that has been registered with Proton. For more information, see CreateRepository.
     */
    public val pipelineProvisioningRepository: aws.sdk.kotlin.services.proton.model.RepositoryBranch? = builder.pipelineProvisioningRepository
    /**
     * The Amazon Resource Name (ARN) of the service role you want to use for provisioning pipelines. Assumed by Proton for Amazon Web Services-managed provisioning, and by customer-owned automation for self-managed provisioning.
     */
    public val pipelineServiceRoleArn: kotlin.String? = builder.pipelineServiceRoleArn

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

    override fun toString(): kotlin.String = buildString {
        append("AccountSettings(")
        append("pipelineCodebuildRoleArn=$pipelineCodebuildRoleArn,")
        append("pipelineProvisioningRepository=$pipelineProvisioningRepository,")
        append("pipelineServiceRoleArn=$pipelineServiceRoleArn")
        append(")")
    }

    override fun hashCode(): kotlin.Int {
        var result = pipelineCodebuildRoleArn?.hashCode() ?: 0
        result = 31 * result + (pipelineProvisioningRepository?.hashCode() ?: 0)
        result = 31 * result + (pipelineServiceRoleArn?.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 AccountSettings

        if (pipelineCodebuildRoleArn != other.pipelineCodebuildRoleArn) return false
        if (pipelineProvisioningRepository != other.pipelineProvisioningRepository) return false
        if (pipelineServiceRoleArn != other.pipelineServiceRoleArn) return false

        return true
    }

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

    @SdkDsl
    public class Builder {
        /**
         * The Amazon Resource Name (ARN) of the service role that Proton uses for provisioning pipelines. Proton assumes this role for CodeBuild-based provisioning.
         */
        public var pipelineCodebuildRoleArn: kotlin.String? = null
        /**
         * The linked repository for pipeline provisioning. Required if you have environments configured for self-managed provisioning with services that include pipelines. A linked repository is a repository that has been registered with Proton. For more information, see CreateRepository.
         */
        public var pipelineProvisioningRepository: aws.sdk.kotlin.services.proton.model.RepositoryBranch? = null
        /**
         * The Amazon Resource Name (ARN) of the service role you want to use for provisioning pipelines. Assumed by Proton for Amazon Web Services-managed provisioning, and by customer-owned automation for self-managed provisioning.
         */
        public var pipelineServiceRoleArn: kotlin.String? = null

        @PublishedApi
        internal constructor()
        @PublishedApi
        internal constructor(x: aws.sdk.kotlin.services.proton.model.AccountSettings) : this() {
            this.pipelineCodebuildRoleArn = x.pipelineCodebuildRoleArn
            this.pipelineProvisioningRepository = x.pipelineProvisioningRepository
            this.pipelineServiceRoleArn = x.pipelineServiceRoleArn
        }

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

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

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




© 2015 - 2025 Weber Informatics LLC | Privacy Policy