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

commonMain.aws.sdk.kotlin.services.devicefarm.model.Project.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.devicefarm.model

import aws.smithy.kotlin.runtime.SdkDsl
import aws.smithy.kotlin.runtime.time.Instant

/**
 * Represents an operating-system neutral workspace for running and managing tests.
 */
public class Project private constructor(builder: Builder) {
    /**
     * The project's ARN.
     */
    public val arn: kotlin.String? = builder.arn
    /**
     * When the project was created.
     */
    public val created: aws.smithy.kotlin.runtime.time.Instant? = builder.created
    /**
     * The default number of minutes (at the project level) a test run executes before it times out. The default value is 150 minutes.
     */
    public val defaultJobTimeoutMinutes: kotlin.Int? = builder.defaultJobTimeoutMinutes
    /**
     * The project's name.
     */
    public val name: kotlin.String? = builder.name
    /**
     * The VPC security groups and subnets that are attached to a project.
     */
    public val vpcConfig: aws.sdk.kotlin.services.devicefarm.model.VpcConfig? = builder.vpcConfig

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

    override fun toString(): kotlin.String = buildString {
        append("Project(")
        append("arn=$arn,")
        append("created=$created,")
        append("defaultJobTimeoutMinutes=$defaultJobTimeoutMinutes,")
        append("name=$name,")
        append("vpcConfig=$vpcConfig")
        append(")")
    }

    override fun hashCode(): kotlin.Int {
        var result = arn?.hashCode() ?: 0
        result = 31 * result + (created?.hashCode() ?: 0)
        result = 31 * result + (defaultJobTimeoutMinutes ?: 0)
        result = 31 * result + (name?.hashCode() ?: 0)
        result = 31 * result + (vpcConfig?.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 Project

        if (arn != other.arn) return false
        if (created != other.created) return false
        if (defaultJobTimeoutMinutes != other.defaultJobTimeoutMinutes) return false
        if (name != other.name) return false
        if (vpcConfig != other.vpcConfig) return false

        return true
    }

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

    @SdkDsl
    public class Builder {
        /**
         * The project's ARN.
         */
        public var arn: kotlin.String? = null
        /**
         * When the project was created.
         */
        public var created: aws.smithy.kotlin.runtime.time.Instant? = null
        /**
         * The default number of minutes (at the project level) a test run executes before it times out. The default value is 150 minutes.
         */
        public var defaultJobTimeoutMinutes: kotlin.Int? = null
        /**
         * The project's name.
         */
        public var name: kotlin.String? = null
        /**
         * The VPC security groups and subnets that are attached to a project.
         */
        public var vpcConfig: aws.sdk.kotlin.services.devicefarm.model.VpcConfig? = null

        @PublishedApi
        internal constructor()
        @PublishedApi
        internal constructor(x: aws.sdk.kotlin.services.devicefarm.model.Project) : this() {
            this.arn = x.arn
            this.created = x.created
            this.defaultJobTimeoutMinutes = x.defaultJobTimeoutMinutes
            this.name = x.name
            this.vpcConfig = x.vpcConfig
        }

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

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

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




© 2015 - 2024 Weber Informatics LLC | Privacy Policy