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

commonMain.aws.sdk.kotlin.services.rolesanywhere.model.InstanceProperty.kt Maven / Gradle / Ivy

// Code generated by smithy-kotlin-codegen. DO NOT EDIT!

package aws.sdk.kotlin.services.rolesanywhere.model

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

/**
 * A key-value pair you set that identifies a property of the authenticating instance.
 */
public class InstanceProperty private constructor(builder: Builder) {
    /**
     * Indicates whether the temporary credential request was successful.
     */
    public val failed: kotlin.Boolean? = builder.failed
    /**
     * A list of instanceProperty objects.
     */
    public val properties: Map? = builder.properties
    /**
     * The ISO-8601 time stamp of when the certificate was last used in a temporary credential request.
     */
    public val seenAt: aws.smithy.kotlin.runtime.time.Instant? = builder.seenAt

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

    override fun toString(): kotlin.String = buildString {
        append("InstanceProperty(")
        append("failed=$failed,")
        append("properties=$properties,")
        append("seenAt=$seenAt")
        append(")")
    }

    override fun hashCode(): kotlin.Int {
        var result = failed?.hashCode() ?: 0
        result = 31 * result + (properties?.hashCode() ?: 0)
        result = 31 * result + (seenAt?.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 InstanceProperty

        if (failed != other.failed) return false
        if (properties != other.properties) return false
        if (seenAt != other.seenAt) return false

        return true
    }

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

    public class Builder {
        /**
         * Indicates whether the temporary credential request was successful.
         */
        public var failed: kotlin.Boolean? = null
        /**
         * A list of instanceProperty objects.
         */
        public var properties: Map? = null
        /**
         * The ISO-8601 time stamp of when the certificate was last used in a temporary credential request.
         */
        public var seenAt: aws.smithy.kotlin.runtime.time.Instant? = null

        @PublishedApi
        internal constructor()
        @PublishedApi
        internal constructor(x: aws.sdk.kotlin.services.rolesanywhere.model.InstanceProperty) : this() {
            this.failed = x.failed
            this.properties = x.properties
            this.seenAt = x.seenAt
        }

        @PublishedApi
        internal fun build(): aws.sdk.kotlin.services.rolesanywhere.model.InstanceProperty = InstanceProperty(this)
    }
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy