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

commonMain.aws.sdk.kotlin.services.kinesisvideo.model.UpdateStreamRequest.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 UpdateStreamRequest private constructor(builder: Builder) {
    /**
     * The version of the stream whose metadata you want to update.
     */
    public val currentVersion: kotlin.String? = builder.currentVersion
    /**
     * The name of the device that is writing to the stream.
     *
     *  In the current implementation, Kinesis Video Streams does not use this name.
     */
    public val deviceName: kotlin.String? = builder.deviceName
    /**
     * The stream's media type. Use `MediaType` to specify the type of content that the stream contains to the consumers of the stream. For more information about media types, see [Media Types](http://www.iana.org/assignments/media-types/media-types.xhtml). If you choose to specify the `MediaType`, see [Naming Requirements](https://tools.ietf.org/html/rfc6838#section-4.2).
     *
     * To play video on the console, you must specify the correct video type. For example, if the video in the stream is H.264, specify `video/h264` as the `MediaType`.
     */
    public val mediaType: kotlin.String? = builder.mediaType
    /**
     * The ARN of the stream whose metadata you want to update.
     */
    public val streamArn: kotlin.String? = builder.streamArn
    /**
     * The name of the stream whose metadata you want to update.
     *
     * The stream name is an identifier for the stream, and must be unique for each account and region.
     */
    public val streamName: kotlin.String? = builder.streamName

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

    override fun toString(): kotlin.String = buildString {
        append("UpdateStreamRequest(")
        append("currentVersion=$currentVersion,")
        append("deviceName=$deviceName,")
        append("mediaType=$mediaType,")
        append("streamArn=$streamArn,")
        append("streamName=$streamName")
        append(")")
    }

    override fun hashCode(): kotlin.Int {
        var result = currentVersion?.hashCode() ?: 0
        result = 31 * result + (deviceName?.hashCode() ?: 0)
        result = 31 * result + (mediaType?.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 UpdateStreamRequest

        if (currentVersion != other.currentVersion) return false
        if (deviceName != other.deviceName) return false
        if (mediaType != other.mediaType) 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.UpdateStreamRequest = Builder(this).apply(block).build()

    @SdkDsl
    public class Builder {
        /**
         * The version of the stream whose metadata you want to update.
         */
        public var currentVersion: kotlin.String? = null
        /**
         * The name of the device that is writing to the stream.
         *
         *  In the current implementation, Kinesis Video Streams does not use this name.
         */
        public var deviceName: kotlin.String? = null
        /**
         * The stream's media type. Use `MediaType` to specify the type of content that the stream contains to the consumers of the stream. For more information about media types, see [Media Types](http://www.iana.org/assignments/media-types/media-types.xhtml). If you choose to specify the `MediaType`, see [Naming Requirements](https://tools.ietf.org/html/rfc6838#section-4.2).
         *
         * To play video on the console, you must specify the correct video type. For example, if the video in the stream is H.264, specify `video/h264` as the `MediaType`.
         */
        public var mediaType: kotlin.String? = null
        /**
         * The ARN of the stream whose metadata you want to update.
         */
        public var streamArn: kotlin.String? = null
        /**
         * The name of the stream whose metadata you want to update.
         *
         * The stream name is an identifier for the stream, and must be unique for each account and region.
         */
        public var streamName: kotlin.String? = null

        @PublishedApi
        internal constructor()
        @PublishedApi
        internal constructor(x: aws.sdk.kotlin.services.kinesisvideo.model.UpdateStreamRequest) : this() {
            this.currentVersion = x.currentVersion
            this.deviceName = x.deviceName
            this.mediaType = x.mediaType
            this.streamArn = x.streamArn
            this.streamName = x.streamName
        }

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

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




© 2015 - 2024 Weber Informatics LLC | Privacy Policy