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

commonMain.aws.sdk.kotlin.services.ivsrealtime.model.PublicKey.kt Maven / Gradle / Ivy

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

package aws.sdk.kotlin.services.ivsrealtime.model

import aws.smithy.kotlin.runtime.SdkDsl

/**
 * Object specifying a public key used to sign stage participant tokens.
 */
public class PublicKey private constructor(builder: Builder) {
    /**
     * Public key ARN.
     */
    public val arn: kotlin.String? = builder.arn
    /**
     * The public key fingerprint, a short string used to identify or verify the full public key.
     */
    public val fingerprint: kotlin.String? = builder.fingerprint
    /**
     * Public key name.
     */
    public val name: kotlin.String? = builder.name
    /**
     * Public key material.
     */
    public val publicKeyMaterial: kotlin.String? = builder.publicKeyMaterial
    /**
     * Tags attached to the resource. Array of maps, each of the form `string:string (key:value)`. See [Best practices and strategies](https://docs.aws.amazon.com/tag-editor/latest/userguide/best-practices-and-strats.html) in *Tagging AWS Resources and Tag Editor* for details, including restrictions that apply to tags and "Tag naming limits and requirements"; Amazon IVS has no constraints on tags beyond what is documented there.
     */
    public val tags: Map? = builder.tags

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

    override fun toString(): kotlin.String = buildString {
        append("PublicKey(")
        append("arn=$arn,")
        append("fingerprint=$fingerprint,")
        append("name=$name,")
        append("publicKeyMaterial=$publicKeyMaterial,")
        append("tags=$tags")
        append(")")
    }

    override fun hashCode(): kotlin.Int {
        var result = arn?.hashCode() ?: 0
        result = 31 * result + (fingerprint?.hashCode() ?: 0)
        result = 31 * result + (name?.hashCode() ?: 0)
        result = 31 * result + (publicKeyMaterial?.hashCode() ?: 0)
        result = 31 * result + (tags?.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 PublicKey

        if (arn != other.arn) return false
        if (fingerprint != other.fingerprint) return false
        if (name != other.name) return false
        if (publicKeyMaterial != other.publicKeyMaterial) return false
        if (tags != other.tags) return false

        return true
    }

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

    @SdkDsl
    public class Builder {
        /**
         * Public key ARN.
         */
        public var arn: kotlin.String? = null
        /**
         * The public key fingerprint, a short string used to identify or verify the full public key.
         */
        public var fingerprint: kotlin.String? = null
        /**
         * Public key name.
         */
        public var name: kotlin.String? = null
        /**
         * Public key material.
         */
        public var publicKeyMaterial: kotlin.String? = null
        /**
         * Tags attached to the resource. Array of maps, each of the form `string:string (key:value)`. See [Best practices and strategies](https://docs.aws.amazon.com/tag-editor/latest/userguide/best-practices-and-strats.html) in *Tagging AWS Resources and Tag Editor* for details, including restrictions that apply to tags and "Tag naming limits and requirements"; Amazon IVS has no constraints on tags beyond what is documented there.
         */
        public var tags: Map? = null

        @PublishedApi
        internal constructor()
        @PublishedApi
        internal constructor(x: aws.sdk.kotlin.services.ivsrealtime.model.PublicKey) : this() {
            this.arn = x.arn
            this.fingerprint = x.fingerprint
            this.name = x.name
            this.publicKeyMaterial = x.publicKeyMaterial
            this.tags = x.tags
        }

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

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




© 2015 - 2025 Weber Informatics LLC | Privacy Policy