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

commonMain.aws.sdk.kotlin.services.kinesisvideo.model.ChannelInfo.kt Maven / Gradle / Ivy

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

package aws.sdk.kotlin.services.kinesisvideo.model

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

/**
 * A structure that encapsulates a signaling channel's metadata and properties.
 */
public class ChannelInfo private constructor(builder: Builder) {
    /**
     * The Amazon Resource Name (ARN) of the signaling channel.
     */
    public val channelArn: kotlin.String? = builder.channelArn
    /**
     * The name of the signaling channel.
     */
    public val channelName: kotlin.String? = builder.channelName
    /**
     * Current status of the signaling channel.
     */
    public val channelStatus: aws.sdk.kotlin.services.kinesisvideo.model.Status? = builder.channelStatus
    /**
     * The type of the signaling channel.
     */
    public val channelType: aws.sdk.kotlin.services.kinesisvideo.model.ChannelType? = builder.channelType
    /**
     * The time at which the signaling channel was created.
     */
    public val creationTime: aws.smithy.kotlin.runtime.time.Instant? = builder.creationTime
    /**
     * A structure that contains the configuration for the `SINGLE_MASTER` channel type.
     */
    public val singleMasterConfiguration: aws.sdk.kotlin.services.kinesisvideo.model.SingleMasterConfiguration? = builder.singleMasterConfiguration
    /**
     * The current version of the signaling channel.
     */
    public val version: kotlin.String? = builder.version

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

    override fun toString(): kotlin.String = buildString {
        append("ChannelInfo(")
        append("channelArn=$channelArn,")
        append("channelName=$channelName,")
        append("channelStatus=$channelStatus,")
        append("channelType=$channelType,")
        append("creationTime=$creationTime,")
        append("singleMasterConfiguration=$singleMasterConfiguration,")
        append("version=$version")
        append(")")
    }

    override fun hashCode(): kotlin.Int {
        var result = channelArn?.hashCode() ?: 0
        result = 31 * result + (channelName?.hashCode() ?: 0)
        result = 31 * result + (channelStatus?.hashCode() ?: 0)
        result = 31 * result + (channelType?.hashCode() ?: 0)
        result = 31 * result + (creationTime?.hashCode() ?: 0)
        result = 31 * result + (singleMasterConfiguration?.hashCode() ?: 0)
        result = 31 * result + (version?.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 ChannelInfo

        if (channelArn != other.channelArn) return false
        if (channelName != other.channelName) return false
        if (channelStatus != other.channelStatus) return false
        if (channelType != other.channelType) return false
        if (creationTime != other.creationTime) return false
        if (singleMasterConfiguration != other.singleMasterConfiguration) return false
        if (version != other.version) return false

        return true
    }

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

    @SdkDsl
    public class Builder {
        /**
         * The Amazon Resource Name (ARN) of the signaling channel.
         */
        public var channelArn: kotlin.String? = null
        /**
         * The name of the signaling channel.
         */
        public var channelName: kotlin.String? = null
        /**
         * Current status of the signaling channel.
         */
        public var channelStatus: aws.sdk.kotlin.services.kinesisvideo.model.Status? = null
        /**
         * The type of the signaling channel.
         */
        public var channelType: aws.sdk.kotlin.services.kinesisvideo.model.ChannelType? = null
        /**
         * The time at which the signaling channel was created.
         */
        public var creationTime: aws.smithy.kotlin.runtime.time.Instant? = null
        /**
         * A structure that contains the configuration for the `SINGLE_MASTER` channel type.
         */
        public var singleMasterConfiguration: aws.sdk.kotlin.services.kinesisvideo.model.SingleMasterConfiguration? = null
        /**
         * The current version of the signaling channel.
         */
        public var version: kotlin.String? = null

        @PublishedApi
        internal constructor()
        @PublishedApi
        internal constructor(x: aws.sdk.kotlin.services.kinesisvideo.model.ChannelInfo) : this() {
            this.channelArn = x.channelArn
            this.channelName = x.channelName
            this.channelStatus = x.channelStatus
            this.channelType = x.channelType
            this.creationTime = x.creationTime
            this.singleMasterConfiguration = x.singleMasterConfiguration
            this.version = x.version
        }

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

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

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




© 2015 - 2024 Weber Informatics LLC | Privacy Policy