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

commonMain.aws.sdk.kotlin.services.kinesisvideo.model.UpdateNotificationConfigurationRequest.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

public class UpdateNotificationConfigurationRequest private constructor(builder: Builder) {
    /**
     * The structure containing the information required for notifications. If the structure is null, the configuration will be deleted from the stream.
     */
    public val notificationConfiguration: aws.sdk.kotlin.services.kinesisvideo.model.NotificationConfiguration? = builder.notificationConfiguration
    /**
     * The Amazon Resource Name (ARN) of the Kinesis video stream from where you want to update the notification configuration. You must specify either the `StreamName` or the `StreamARN`.
     */
    public val streamArn: kotlin.String? = builder.streamArn
    /**
     * The name of the stream from which to update the notification configuration. You must specify either the `StreamName` or the `StreamARN`.
     */
    public val streamName: kotlin.String? = builder.streamName

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

    override fun toString(): kotlin.String = buildString {
        append("UpdateNotificationConfigurationRequest(")
        append("notificationConfiguration=$notificationConfiguration,")
        append("streamArn=$streamArn,")
        append("streamName=$streamName")
        append(")")
    }

    override fun hashCode(): kotlin.Int {
        var result = notificationConfiguration?.hashCode() ?: 0
        result = 31 * result + (streamArn?.hashCode() ?: 0)
        result = 31 * result + (streamName?.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 UpdateNotificationConfigurationRequest

        if (notificationConfiguration != other.notificationConfiguration) return false
        if (streamArn != other.streamArn) return false
        if (streamName != other.streamName) return false

        return true
    }

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

    @SdkDsl
    public class Builder {
        /**
         * The structure containing the information required for notifications. If the structure is null, the configuration will be deleted from the stream.
         */
        public var notificationConfiguration: aws.sdk.kotlin.services.kinesisvideo.model.NotificationConfiguration? = null
        /**
         * The Amazon Resource Name (ARN) of the Kinesis video stream from where you want to update the notification configuration. You must specify either the `StreamName` or the `StreamARN`.
         */
        public var streamArn: kotlin.String? = null
        /**
         * The name of the stream from which to update the notification configuration. You must specify either the `StreamName` or the `StreamARN`.
         */
        public var streamName: kotlin.String? = null

        @PublishedApi
        internal constructor()
        @PublishedApi
        internal constructor(x: aws.sdk.kotlin.services.kinesisvideo.model.UpdateNotificationConfigurationRequest) : this() {
            this.notificationConfiguration = x.notificationConfiguration
            this.streamArn = x.streamArn
            this.streamName = x.streamName
        }

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

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

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




© 2015 - 2024 Weber Informatics LLC | Privacy Policy